# Mercado Livre Scraper (português Brasil) (`pegai/mercadolivre-deals-scraper`) Actor

Extraia ofertas do dia, ofertas relâmpago e descontos por categoria do Mercado Livre Brasil. JSON com preços, % de desconto, vendedor, avaliação, parcelas e frete grátis — para monitoramento de preços, dropshipping e inteligência de e-commerce. | Scrape Mercado Livre Brazil (MercadoLibre BR) deals.

- **URL**: https://apify.com/pegai/mercadolivre-deals-scraper.md
- **Developed by:** [Pega AI](https://apify.com/pegai) (community)
- **Categories:** E-commerce
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Mercado Livre Ofertas & Promoções — Scraper 🇧🇷

Extraia **dados estruturados das ofertas do Mercado Livre Brasil** — o maior marketplace da América Latina — em segundos. O scraper coleta as páginas oficiais de ofertas (ofertas do dia, ofertas relâmpago, descontos por categoria) e devolve JSON limpo, pronto para **monitoramento de preços, inteligência de e-commerce, pesquisa para dropshipping ou automação de afiliados**. Sem programar — rode pelo painel, agende ou chame pela API.

Feito por quem roda pipelines de dados do Mercado Livre em produção desde o início de 2026.

### O que você recebe por produto

```json
{
    "title": "Controle Xbox Wireless Series X|s Carbon Black",
    "url": "https://www.mercadolivre.com.br/...",
    "productId": "MLB5139965320",
    "price": 331.55,
    "priceIsPix": true,
    "originalPrice": 520.18,
    "discountPct": 36,
    "currency": "BRL",
    "installmentPrice": 349.9,
    "installmentText": "R$349,90 em 10x sem juros",
    "seller": "EasyTech",
    "rating": 4.8,
    "reviewsCount": 93378,
    "freeShipping": true,
    "imageUrl": "https://http2.mlstatic.com/...webp",
    "sourceUrl": "https://www.mercadolivre.com.br/ofertas?...",
    "scrapedAt": "2026-07-03T18:38:59.752Z"
}
````

> Os nomes dos campos ficam em inglês para facilitar a integração com planilhas, bancos de dados e agentes de IA.

### Casos de uso

- **Monitoramento de preços e descontos** — agende execuções diárias e acompanhe como os preços se movem.
- **Inteligência de e-commerce** — veja o que o maior marketplace do Brasil está descontando, por categoria.
- **Comunidades de ofertas e afiliados** — alimente grupos de WhatsApp/Telegram com ofertas novas (é exatamente para isso que usamos em produção).
- **Pesquisa de mercado** — vendedores, avaliações, número de reviews e preço no Pix em 16 categorias curadas.

### Como usar

1. Escolha o **modo**:
   - `Ofertas do dia` — a página principal de ofertas;
   - `Categorias` — 16 categorias curadas (celulares, games, eletrodomésticos, beleza, pet, automotivo…);
   - `URLs personalizadas` — cole qualquer URL de `mercadolivre.com.br/ofertas` com seus próprios filtros.
2. Defina `maxItems` (limite rígido — você nunca paga por mais que isso) e, opcionalmente, `minDiscountPct` para manter só as ofertas de verdade.
3. Rode uma vez, agende, ou chame pela API / n8n / Make.

Cada página de resultados traz ~48 produtos. `maxPagesPerSource` controla a profundidade da paginação.

Os resultados ficam em um dataset da Apify que você **exporta como JSON, CSV, Excel ou XML**, ou puxa direto para o Google Sheets, seu banco de dados ou qualquer cliente HTTP via API do dataset.

### Preço

Pague por resultado — você só é cobrado pelos produtos realmente enviados ao dataset, limitado por `maxItems`. Páginas que falham nunca são cobradas.

### Perguntas frequentes

**Precisa de proxy ou conta?** Não. O actor usa uma técnica de leitura via proxy estável em produção há meses. Para volumes agendados muito grandes, você pode opcionalmente adicionar sua própria chave do [Jina Reader](https://jina.ai) no input.

**É legal?** O actor extrai apenas **dados públicos** (sem login, sem dados pessoais) das páginas públicas de ofertas, a uma taxa de requisição educada.

**Uma categoria retornou poucos itens?** As ofertas relâmpago giram ao longo do dia — agende várias execuções para capturá-las.

**Algo quebrou?** O Mercado Livre muda o layout de vez em quando. Abra uma issue na aba Issues do actor — correções saem em até 48h.

***

#### English summary

Scrape **Mercado Livre Brazil** (MercadoLibre BR) deals and offers into clean JSON: prices, discount %, seller, rating, installments and free shipping. Ideal for price monitoring, e-commerce intelligence and dropshipping research. Three modes: deals of the day, 16 curated categories, or custom offer URLs. Pay per result, capped by `maxItems`. Field names are in English for easy integration.

### Roadmap

- Scraper de avaliações de produtos (actor separado)
- Scraper de catálogo de vendedor/loja
- Histórico de preços via execuções agendadas + guia de merge de datasets
- Versão para MercadoLibre hispânico (Argentina, México, Chile)

***

*Este Actor não é afiliado nem endossado pelo MercadoLibre, Inc. O ícone usa um glifo do [Font Awesome](https://fontawesome.com) ([CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)).*

# Actor input Schema

## `mode` (type: `string`):

O que coletar: ofertas do dia, uma seleção de categorias curadas, ou URLs de ofertas que você fornecer abaixo.

## `categories` (type: `array`):

Categorias de ofertas curadas do Mercado Livre.

## `customUrls` (type: `array`):

Qualquer URL de mercadolivre.com.br/ofertas, ex.: https://www.mercadolivre.com.br/ofertas?category=MLB1051

## `maxPagesPerSource` (type: `integer`):

Quantas páginas de resultados buscar por categoria/URL (cada página traz ~48 produtos).

## `maxItems` (type: `integer`):

Limite rígido de produtos enviados ao dataset (é o que você paga — a execução nunca ultrapassa isso).

## `minDiscountPct` (type: `integer`):

Ignora produtos com desconto menor que esta porcentagem. 0 = sem filtro.

## `jinaApiKey` (type: `string`):

Chave opcional do jina.ai para limites de requisição maiores em execuções grandes. Execuções pequenas funcionam sem ela.

## Actor input object example

```json
{
  "mode": "deals",
  "categories": [
    "celulares",
    "informatica",
    "games"
  ],
  "customUrls": [
    "https://www.mercadolivre.com.br/ofertas"
  ],
  "maxPagesPerSource": 1,
  "maxItems": 100,
  "minDiscountPct": 0
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "customUrls": [
        "https://www.mercadolivre.com.br/ofertas"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("pegai/mercadolivre-deals-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "customUrls": ["https://www.mercadolivre.com.br/ofertas"] }

# Run the Actor and wait for it to finish
run = client.actor("pegai/mercadolivre-deals-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "customUrls": [
    "https://www.mercadolivre.com.br/ofertas"
  ]
}' |
apify call pegai/mercadolivre-deals-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=pegai/mercadolivre-deals-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Mercado Livre Scraper (português Brasil)",
        "description": "Extraia ofertas do dia, ofertas relâmpago e descontos por categoria do Mercado Livre Brasil. JSON com preços, % de desconto, vendedor, avaliação, parcelas e frete grátis — para monitoramento de preços, dropshipping e inteligência de e-commerce. | Scrape Mercado Livre Brazil (MercadoLibre BR) deals.",
        "version": "0.1",
        "x-build-id": "BJmDkmNdxel2XcNmH"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/pegai~mercadolivre-deals-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-pegai-mercadolivre-deals-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/pegai~mercadolivre-deals-scraper/runs": {
            "post": {
                "operationId": "runs-sync-pegai-mercadolivre-deals-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/pegai~mercadolivre-deals-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-pegai-mercadolivre-deals-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "mode"
                ],
                "properties": {
                    "mode": {
                        "title": "Modo",
                        "enum": [
                            "deals",
                            "categories",
                            "customUrls"
                        ],
                        "type": "string",
                        "description": "O que coletar: ofertas do dia, uma seleção de categorias curadas, ou URLs de ofertas que você fornecer abaixo.",
                        "default": "deals"
                    },
                    "categories": {
                        "title": "Categorias (para o modo 'Categorias curadas')",
                        "type": "array",
                        "description": "Categorias de ofertas curadas do Mercado Livre.",
                        "items": {
                            "type": "string",
                            "enum": [
                                "celulares",
                                "informatica",
                                "games",
                                "eletrodomesticos",
                                "casa",
                                "moda",
                                "perfumes",
                                "beleza",
                                "pet",
                                "bebes",
                                "seguranca",
                                "automotivo",
                                "suplementos",
                                "somvideo",
                                "ate200",
                                "de50a300"
                            ],
                            "enumTitles": [
                                "Celulares",
                                "Informática",
                                "Games",
                                "Eletrodomésticos",
                                "Casa e cozinha",
                                "Moda",
                                "Perfumes",
                                "Beleza",
                                "Pet",
                                "Bebês",
                                "Segurança",
                                "Automotivo",
                                "Suplementos",
                                "Áudio e vídeo",
                                "Até R$200",
                                "R$50–300"
                            ]
                        },
                        "default": [
                            "celulares",
                            "informatica",
                            "games"
                        ]
                    },
                    "customUrls": {
                        "title": "URLs de ofertas personalizadas (para o modo 'URLs personalizadas')",
                        "type": "array",
                        "description": "Qualquer URL de mercadolivre.com.br/ofertas, ex.: https://www.mercadolivre.com.br/ofertas?category=MLB1051",
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxPagesPerSource": {
                        "title": "Máx. de páginas por fonte",
                        "minimum": 1,
                        "maximum": 20,
                        "type": "integer",
                        "description": "Quantas páginas de resultados buscar por categoria/URL (cada página traz ~48 produtos).",
                        "default": 1
                    },
                    "maxItems": {
                        "title": "Máx. de resultados",
                        "minimum": 1,
                        "type": "integer",
                        "description": "Limite rígido de produtos enviados ao dataset (é o que você paga — a execução nunca ultrapassa isso).",
                        "default": 100
                    },
                    "minDiscountPct": {
                        "title": "Desconto mínimo (%)",
                        "minimum": 0,
                        "maximum": 99,
                        "type": "integer",
                        "description": "Ignora produtos com desconto menor que esta porcentagem. 0 = sem filtro.",
                        "default": 0
                    },
                    "jinaApiKey": {
                        "title": "Chave da API Jina Reader (opcional)",
                        "type": "string",
                        "description": "Chave opcional do jina.ai para limites de requisição maiores em execuções grandes. Execuções pequenas funcionam sem ela."
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
