# Coles Scraper: Australian Grocery Prices & Stock (`axlymxp/coles-grocery-scraper`) Actor

Scrape Coles Australia supermarket products by category or product URL: price, was price, unit price, specials, stock quantity, barcode (GTIN), ingredients, allergens, nutrition and country of origin. Handles Coles' bot protection with a browser token and proxy rotation. Pay only for results.

- **URL**: https://apify.com/axlymxp/coles-grocery-scraper.md
- **Developed by:** [axly](https://apify.com/axlymxp) (community)
- **Categories:** E-commerce, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 dataset items

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

## Coles Grocery Scraper (Australia)

Scrape **Coles** (coles.com.au) supermarket products by category or product URL and get clean, structured rows:
current price, was price, unit price, specials, **stock quantity**, retail limits, category and aisle, and with
product details on: **barcode (GTIN)**, ingredients, allergens, dietary claims, nutrition panel, storage instructions
and country of origin.

Coles protects its site with Imperva bot protection. This actor handles that for you: it obtains an access token with
a real browser, then collects data quickly, rotating proxy exits when Coles pushes back.

### What data you get

| Field | Example | Notes |
|---|---|---|
| `id` | `8150288` | Coles product id |
| `name`, `brand`, `size` | `Full Cream Milk`, `Coles`, `3L` | |
| `price` | `4.95` | Current shelf price (AUD) |
| `wasPrice`, `onSpecial` | `null`, `false` | Was price when on special |
| `unitPrice`, `unitOfMeasure`, `unitPriceText` | `1.65`, `l`, `$1.65/ 1L` | Comparable unit price |
| `available`, `availabilityType`, `stockQuantity` | `true`, `InStoreAndOnline`, `2083` | Stock as reported by Coles online |
| `retailLimit`, `promotionalLimit` | `20`, `12` | Purchase limits |
| `department`, `category`, `aisle` | `Dairy, Eggs & Fridge`, `Milk`, `Full Cream Milk` | |
| `image`, `url` | product image and page | |
| `gtin` | `9300601186945` | With product details on |
| `ingredients`, `allergens`, `dietary`, `storage` | text | With product details on |
| `nutrition` | servings, serving size, per-serving / per-100 values | With product details on |
| `countryOfOrigin`, `originStatement` | `Australian`, `Australian Milk` | With product details on |
| `saveAmount`, `savePercent`, `promotionType` | specials detail | With product details on |
| `storeId`, `scrapedAt` | `7674`, ISO time | Prices are Coles online prices for its default store |

### Use cases

- **Price monitoring and competitor pricing**: schedule daily category crawls to track shelf prices, specials and unit prices.
- **Brand and category management**: see your range, stock levels, purchase limits and promotions across a category.
- **Grocery and nutrition apps**: barcode-keyed product data with ingredients, allergens and nutrition panels.
- **Research and journalism**: food-price inflation and unit-price comparisons over time.

### Input

| Field | Description |
|---|---|
| `categories` | Coles category paths or URLs, e.g. `dairy-eggs-fridge/milk` or `https://www.coles.com.au/browse/bakery`. Use `*` for every category. |
| `productUrls` | Product page URLs like `https://www.coles.com.au/product/coles-full-cream-milk-3l-8150288` (always scraped with details). |
| `maxItems` | Maximum number of products to return. |
| `includeDetails` | Fetch each product page for barcode, ingredients, nutrition and origin. |
| `proxyConfiguration` | Rotating proxies (Australian residential recommended). |

Keyword search is not offered: browse by category (Coles' own category tree covers the full range) or pass product URLs.

### Example input

```json
{
  "categories": ["dairy-eggs-fridge/milk", "bakery"],
  "maxItems": 200,
  "includeDetails": true,
  "proxyConfiguration": {"useApifyProxy": true, "apifyProxyGroups": ["RESIDENTIAL"], "apifyProxyCountry": "AU"}
}
```

### Example output

```json
{
  "id": 8150288,
  "url": "https://www.coles.com.au/product/coles-full-cream-milk-3l-8150288",
  "name": "Full Cream Milk",
  "brand": "Coles",
  "size": "3L",
  "price": 4.95,
  "wasPrice": null,
  "onSpecial": false,
  "unitPriceText": "$1.65/ 1L",
  "stockQuantity": 2083,
  "category": "Milk",
  "gtin": "9300601186945",
  "ingredients": "Homogenised and Pasteurised Full Cream Milk.",
  "allergens": "Contains Milk",
  "countryOfOrigin": "Australian",
  "scrapedAt": "2026-10-04T07:07:10Z"
}
```

### Scheduling and integrations

Run it on an Apify schedule (for example every morning) and send results to Google Sheets, a webhook, S3 or your
database with Apify integrations. Each run resumes from its checkpoint if the platform restarts it, without duplicates.

### Use with AI assistants (MCP)

Call this actor from Claude, ChatGPT or any MCP client through the Apify MCP server to answer questions such as
"what does a 2 L milk cost at Coles today?" with live data.

### FAQ

**Which store's prices are these?** Coles online prices for its default store. Store-by-store pricing is not supported yet.

**How long does a run take?** A run starts with a real browser obtaining the Coles access token (about a minute, longer if
an exit is rejected and the actor switches to a new one), then data is collected at a few pages per minute.

**How fresh is the data?** Live: every run reads the current Coles site.

**Why do I need proxies?** Coles uses Imperva bot protection that blocks an IP after a handful of requests without a
valid token. The actor gets the token automatically and rotates exits; Australian residential proxies work best.

**What happens if Coles blocks the run?** The actor switches to new proxy exits; if every attempt is blocked it stops with
a clear message instead of returning partial or empty data silently.

**Is it legal?** The actor collects publicly available product information and does not log in or access personal data.
You are responsible for how you use the data and for complying with Coles' terms and applicable law.

# Actor input Schema

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

Coles category paths or URLs, e.g. dairy-eggs-fridge/milk or https://www.coles.com.au/browse/bakery. Use \* for every category in the Coles sitemap.

## `productUrls` (type: `array`):

Coles product page URLs (https://www.coles.com.au/product/<name>-<id>). Always scraped with full details.

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

Maximum number of products to return across all inputs. You are charged per product.

## `includeDetails` (type: `boolean`):

Open each product page for barcode (GTIN), ingredients, allergens, nutrition, country of origin and promotion details. One extra request and a small extra charge per product.

## `proxyConfiguration` (type: `object`):

Coles is protected by Imperva bot protection. Rotating proxies are needed for more than a few pages; Australian residential works best.

## `headless` (type: `boolean`):

Run the token browser headless. Leave off unless headed mode fails.

## `timezone` (type: `string`):

IANA timezone of the token browser; match it to the proxy country (e.g. Australia/Sydney for AU proxies).

## Actor input object example

```json
{
  "categories": [
    "dairy-eggs-fridge/milk"
  ],
  "productUrls": [],
  "maxItems": 200,
  "includeDetails": false,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "AU"
  },
  "headless": false,
  "timezone": "Australia/Sydney"
}
```

# Actor output Schema

## `results` (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 = {
    "categories": [
        "dairy-eggs-fridge/milk"
    ],
    "productUrls": [],
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ],
        "apifyProxyCountry": "AU"
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("axlymxp/coles-grocery-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 = {
    "categories": ["dairy-eggs-fridge/milk"],
    "productUrls": [],
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
        "apifyProxyCountry": "AU",
    },
}

# Run the Actor and wait for it to finish
run = client.actor("axlymxp/coles-grocery-scraper").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 '{
  "categories": [
    "dairy-eggs-fridge/milk"
  ],
  "productUrls": [],
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "AU"
  }
}' |
apify call axlymxp/coles-grocery-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,axlymxp/coles-grocery-scraper"
        }
    }
}
```

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/FdcQl8TtkJi9p3E6M/builds/yEZgpKxzveUqPTIJr/openapi.json
