# WooCommerce Product Feed: Prices, Discounts and Stock (`scrapme/woocommerce-product-feed`) Actor

Products, prices, discounts and stock from WooCommerce webshops, read from the stores' own open Store API. Add shop addresses, get one clean table, and optionally see only what changed since your last run.

- **URL**: https://apify.com/scrapme/woocommerce-product-feed.md
- **Developed by:** [MDBBusiness](https://apify.com/scrapme) (community)
- **Categories:** E-commerce
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.60 / 1,000 products

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## WooCommerce Product Feed: Prices, Discounts and Stock

Turn a list of webshops into one clean table of products, prices, discounts and stock status. Add the address of each shop (for example `woocommerce.com`) and get one row per product. Switch on **change tracking** and the Actor tells you, run after run, which products are new, cheaper, more expensive, back in stock, sold out or removed.

The Actor reads the **WooCommerce Store API** of each shop (`/wp-json/wc/store/v1/products`), which WooCommerce documents as an unauthenticated public API. No login, no browser, no proxy, no API key. It does not read prices from rendered pages, so it is fast and cheap to run. Shopify shops are not supported in this version.

Typical uses: price monitoring of competitors, finding discounts and sales, tracking stock of a product range, building product catalogues for comparison sites, market research on assortment and price levels (for example Danish and Nordic webshops), and daily alerts on price changes.

### What you get

One row per product.

| Field | Meaning |
|---|---|
| `platform`, `store`, `storeName` | `woocommerce`, the shop domain, the shop name (not available, null) |
| `productId`, `title`, `brand`, `category`, `tags`, `sku` | Product identity as published by the shop |
| `price`, `priceMax` | Lowest and highest variant price (equal for single-price products) |
| `compareAtPrice`, `discountPercent` | Before-price and discount in percent, only when the shop shows a real discount |
| `currency` | Currency code of the prices |
| `inStock`, `variantCount` | `true` if at least one variant can be bought; number of variants |
| `rating`, `reviewCount` | Average rating and number of reviews (WooCommerce only; no reviewer data) |
| `url`, `imageUrl` | Link to the product page and to the first image |
| `publishedAt`, `updatedAt` | Not available for WooCommerce (null) |
| `changeType`, `previousPrice`, `previousInStock` | Only with change tracking, see below |
| `scrapedAt` | UTC time of the run |

Prices are in the shop's own currency as published in its feed. The Actor does not convert currencies.

### Input

| Field | Meaning | Default |
|---|---|---|
| `stores` | One shop per line: the domain or any page of the shop. Write `woocommerce:example.com` to skip detection | required |
| `titleKeywords` | Keep products whose title, brand, category or tags contain one of these words | all products |
| `onlyInStock` | Keep only products that can be bought now | off |
| `onlyOnSale` | Keep only products with a before-price higher than the price | off |
| `minPrice`, `maxPrice` | Keep products whose lowest price is inside this range (shop currency) | no limit |
| `maxProductsPerStore` | First N products of each shop. You pay per row | 500 |
| `trackChanges` | Remember the last run of each shop and label rows with `changeType` | off |
| `onlyChanges` | Skip unchanged products (needs `trackChanges`) | off |
| `maxConcurrency` | Shops read in parallel (requests to one shop are always at least 1 second apart) | 3 |
| `delaySeconds` | Pause between requests to one shop (minimum 1) | 1 |

Example:

```json
{
  "stores": ["woocommerce.com", "woocommerce:example-shop.dk"],
  "titleKeywords": ["jacket"],
  "onlyInStock": true,
  "trackChanges": true,
  "onlyChanges": true
}
```

### Monitor prices with change tracking

Turn on `trackChanges` and schedule the Actor (for example daily). The first run of a shop marks every row `baseline`. Later runs mark each row:

| `changeType` | Meaning |
|---|---|
| `new` | Product was not in the feed last time |
| `price_down` / `price_up` | Lowest price changed (see `previousPrice`) |
| `back_in_stock` / `out_of_stock` | Stock status changed (see `previousInStock`) |
| `removed` | Product disappeared from the feed (only when the whole catalogue was read) |
| `unchanged` | Nothing changed |

With `onlyChanges` you only get, and pay for, the rows that changed. The Actor keeps its memory in a named key-value store called `webshop-product-feed-state` in your own account. If you cap the number of products (`maxProductsPerStore` lower than the catalogue), products outside the cap are never reported as removed.

### Good to know

- **Only shops with an open feed can be read.** Many WooCommerce shops publish the Store API, but some shops close it or hide it behind their own front end. Such a shop is reported in the key-value store record `STORE_SUMMARY` and is not charged.
- **The Actor respects `robots.txt`.** Before reading a shop it reads the shop's `robots.txt` and skips any path it forbids. A `Crawl-delay` (up to 30 seconds) is followed. A shop whose `robots.txt` cannot be read is skipped. The Actor never tries to get around a block.
- **You are responsible for how you use the data.** Check the shop's terms and the law that applies to you before you use prices or product data commercially.
- Only business data about products is collected: no customer, reviewer or seller names, no e-mail addresses, no phone numbers.
- WooCommerce's open feed does not list the price of each variant of a variable product; you get the lowest and highest price instead.
- The Actor stops pleasantly when your "Maximum cost per run" is reached and tells you how many rows were saved.

### Source

Each shop's own WooCommerce Store API `https://<shop>/wp-json/wc/store/v1/products`.

# Actor input Schema

## `stores` (type: `array`):

One WooCommerce webshop per line: the domain or any page of the shop, e.g. woocommerce.com. Only the domain is used. Shops that publish no open Store API (or that block it in robots.txt) cannot be read and are not charged.

## `titleKeywords` (type: `array`):

Only keep products where the title, brand, category or a tag contains at least one of these words (not case sensitive). Leave empty to keep all products.

## `onlyInStock` (type: `boolean`):

Only keep products that can be bought right now.

## `onlyOnSale` (type: `boolean`):

Only keep products that have a before-price higher than the current price.

## `minPrice` (type: `number`):

Only keep products whose lowest price is at least this amount, in the shop's own currency. Leave empty for no limit.

## `maxPrice` (type: `number`):

Only keep products whose lowest price is at most this amount, in the shop's own currency. Leave empty for no limit.

## `maxProductsPerStore` (type: `integer`):

The first products of the shop's feed, in the order the shop publishes them. You pay for every row returned, so lower this to control cost.

## `trackChanges` (type: `boolean`):

Remember the last run of each shop and mark every row as new, price_down, price_up, back_in_stock, out_of_stock, removed or unchanged. The first run of a shop marks all rows as baseline. Schedule the Actor daily to monitor prices.

## `onlyChanges` (type: `boolean`):

Skip unchanged products, so you only get (and pay for) what is new or changed. Needs 'Track changes between runs'. The first run of a shop still returns all products as baseline.

## `maxConcurrency` (type: `integer`):

How many shops are read at the same time. Requests to the same shop are always at least one second apart (longer if the shop's robots.txt asks for it).

## `delaySeconds` (type: `number`):

Pause between requests to the same shop. Minimum 1.

## Actor input object example

```json
{
  "stores": [
    "woocommerce.com"
  ],
  "onlyInStock": false,
  "onlyOnSale": false,
  "maxProductsPerStore": 500,
  "trackChanges": false,
  "onlyChanges": false,
  "maxConcurrency": 3,
  "delaySeconds": 1
}
```

# 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 = {
    "stores": [
        "woocommerce.com"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapme/woocommerce-product-feed").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 = { "stores": ["woocommerce.com"] }

# Run the Actor and wait for it to finish
run = client.actor("scrapme/woocommerce-product-feed").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 '{
  "stores": [
    "woocommerce.com"
  ]
}' |
apify call scrapme/woocommerce-product-feed --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapme/woocommerce-product-feed"
        }
    }
}
```

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/wrJQBomj1bZKXuTDe/builds/PM5MoIq0BKyRkwRKP/openapi.json
