# La Comer Mexico Scraper: Grocery Prices & Products (`latinamericadata/la-comer-mexico`) Actor

Extract La Comer Mexico grocery products, MXN prices, EAN barcodes, brands and promotions by store. Monitor supermarket prices and export JSON, CSV or Excel.

- **URL**: https://apify.com/latinamericadata/la-comer-mexico.md
- **Developed by:** [Latin America Data](https://apify.com/latinamericadata) (community)
- **Categories:** E-commerce
- **Stats:** 3 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 products

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/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## La Comer Mexico Scraper & API

Extract **La Comer Mexico supermarket products and prices by store**. Collect EAN barcodes, brands, MXN prices, advertised promotions, package information and original product links for retail price monitoring. Export JSON, CSV or Excel through Apify.

Independent tool by Latin America Data. Not affiliated with or endorsed by La Comer or Grupo La Comer.

### Quick start

```json
{"term":"leche","maxItems":3,"maxRuntimeSecs":90}
```

For an uncapped search:

```json
{"searchTerms":["leche","cafe"],"storeId":287,"maxRuntimeSecs":600}
```

Omit `maxItems` and `maxPages` to continue until the source ends, the time budget expires, or your Apify spending limit is reached. There is no default product/page cap. Time defaults to 240 seconds and can be increased to 7,200 seconds. Access recovery is automatic; no proxy configuration is required.

### Uses

- Compare EAN-matched products against other Mexican supermarket catalogs.
- Monitor price changes and promotions through scheduled runs.
- Analyze brands, assortment and package sizes in a selected store.
- Build dated grocery datasets for purchasing and retail research.

### Inputs

| Input | Description |
| --- | --- |
| term | Search term; defaults to leche. |
| searchTerms | Optional 1-100 searches; replaces term. Products deduplicate across searches. |
| storeId | One active La Comer store. Default 287, La Comer Coyoacan. Other brands are rejected. |
| maxItems | Optional total product limit; none by default. |
| maxPages | Optional pages per search; none by default. |
| startPage | First page, default 1. |
| maxRuntimeSecs | Time budget, default 240 seconds, maximum 7200. |

Find store IDs in the public storefront's store selector URLs (`succId`). Every run validates the store against the live directory. The actor does not silently switch to another store.

### Output

Each product includes `product_id` (EAN), `ean`, `sku`, `title`, `brand`, `price`, `list_price`, `currency`, `discount_percent`, `promotions`, `store_id`, `store_name`, `store_brand`, `available`, `reported_stock`, `availability_scope`, `category`, `subcategory`, `content_quantity`, `unit`, `package_description`, `sold_by_weight`, `price_basis`, `image_url`, `source_url`, `search_url`, `search_term`, `page`, `rank`, `scraped_at`, `source`, `country` and `status`.

Optional values can be null. Stock is reported by the store search index, not a checkout guarantee. A quantity on the package is not automatically the full multipack quantity; no guessed per-unit price is computed. Weighted products retain their source unit and must not be compared as fixed-price packages. Promotions are not automatically deducted from prices.

Products are delivered progressively and charged once per EAN per run. A later failure preserves earlier products.

### Run status

`RUN_SUMMARY` records results, completeness, stop reason and free performance metrics. `DIAGNOSTICS` contains free explanations, never billable rows.

- `success`: valid products; check complete and stop_reason for limits.
- `no_results`: explicitly empty search, zero product fees.
- `partial`: earlier products preserved after an error or time/spending limit.
- `blocked` / `failed`: no products obtained; the run fails visibly.

### Price

**USD 0.003 per delivered product**, plus customer-paid Apify platform usage (including compute, storage and automatic proxies when used). 1,000 products cost USD 3.00 in result fees. Empty searches and diagnostics have no product fee; platform usage still applies. Use an Apify spending limit to control costs.

### Source and limitations

The official Grupo La Comer storefront at https://www.lacomer.com.mx/lacomer/ supports La Comer stores through its store selector. This actor reads that storefront's public Amarello JSON search service, not a different retailer or a third-party delivery marketplace. It validates the selected store's brand and requests 50 listings per page.

The live storefront currently selects a search hostname containing the word "test"; that is the publicly configured route, not an inferred private environment. Pagination counts are checked; repeated or incomplete pages are treated as errors rather than silent completion.

Store prices and assortment can change during a run. Search ordering and relevance follow the source's search engine, including semantic matches. This is not every store, historical pricing, exact checkout stock, or a guarantee of uninterrupted source availability. No account login or private customer information is used.

### API and scheduled monitoring

Run through Apify's API or schedule repeated searches to build your own history. Product links and timestamps make results auditable. Respect source terms and applicable rules.

# Actor input Schema

## `term` (type: `string`):

Producto, marca o categoria.

## `searchTerms` (type: `array`):

Opcional. Sustituye term. Productos repetidos se guardan una sola vez.

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

Opcional. Sin limite predeterminado; continua hasta agotar resultados, tiempo o presupuesto.

## `maxPages` (type: `integer`):

Opcional. Sin limite de paginas predeterminado.

## `startPage` (type: `integer`):

Primera pagina consultada.

## `maxRuntimeSecs` (type: `integer`):

Presupuesto de tiempo para proteger el costo. Conserva los productos ya obtenidos.

## `storeId` (type: `integer`):

ID de sucursal La Comer. Por defecto 287 (La Comer Coyoacan). Se valida la marca automaticamente.

## Actor input object example

```json
{
  "term": "leche",
  "startPage": 1,
  "maxRuntimeSecs": 240,
  "storeId": 287
}
```

# Actor output Schema

## `products` (type: `string`):

No description

## `summary` (type: `string`):

No description

## `diagnostics` (type: `string`):

No description

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("latinamericadata/la-comer-mexico").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("latinamericadata/la-comer-mexico").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{}' |
apify call latinamericadata/la-comer-mexico --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,latinamericadata/la-comer-mexico"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/fIBcwcHZ5quxePKee/builds/F4OsO9G0qSVu7CzaG/openapi.json
