# Price & Stock Monitor – Any Online Store (`flets_sv/price-stock-monitor`) Actor

Check the price and stock status of product pages in any online store. Reads JSON-LD, microdata, Open Graph and Shopify data, and respects robots.txt. Pay per product checked.

- **URL**: https://apify.com/flets_sv/price-stock-monitor.md
- **Developed by:** [FlEtsv](https://apify.com/flets_sv) (community)
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

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

## Price & Stock Monitor – Any Online Store

Price & Stock Monitor – Any Online Store · Precio y stock de cualquier tienda online

### English

#### What does it do?

Price & Stock Monitor checks product pages in any online store and reports the current price, currency and availability. For each URL it reads structured data first (JSON-LD, microdata, Open Graph meta tags and Shopify product data) and falls back to visible text when nothing structured is found. Each row says where the price came from, so you can judge how much to trust it.

Before fetching any page, the actor downloads the domain's `robots.txt`, respects its `Disallow` rules and any `Crawl-delay`, and keeps a polite pause between requests to the same site. Pages blocked by robots.txt are reported with the status `bloqueado` and are never requested.

#### Input

- **Product page URLs** (`urls`): a list of product page URLs, one per line. Leave it empty to run the default store page.

Example input:

```json
{
  "urls": ["https://example.com/product/example-item"]
}
```

#### Output

Each URL produces one row in the dataset with these fields: `url`, `estado` (`ok`, `sin_precio`, `bloqueado` or `error`), `precio`, `moneda`, `disponibilidad` (`in_stock`, `out_of_stock` or `unknown`), `fuente` (where the price was read from), `motivo` (the reason when there is no price or the page was blocked) and `cobrado` (whether this row was charged).

#### Pricing (pay per event)

You pay per event `product-checked`, at 0.001 USD per product page checked with a price found. A page with no price, a page blocked by robots.txt or a page that failed to load is not charged.

#### FAQ

**Does it need an API key for the target store?** No. It reads public product pages only.

**Does it ignore robots.txt?** No. robots.txt is checked before each domain is fetched, and disallowed pages are skipped and reported as `bloqueado`.

**Why is a row not charged?** Only rows with estado `ok` are charged, so a page without a price, a blocked page or a failed request costs nothing.

**Can it log in or read prices behind a login?** No. It only reads pages that anyone can open without signing in.

### Español

#### ¿Qué hace?

Price & Stock Monitor revisa páginas de producto de cualquier tienda online y devuelve el precio actual, la moneda y la disponibilidad. Para cada URL lee primero los datos estructurados (JSON-LD, microdatos, etiquetas meta Open Graph y datos de producto de Shopify) y, si no encuentra nada estructurado, recurre al texto visible. Cada fila indica de dónde salió el precio, para que puedas juzgar cuánto fiarte.

Antes de descargar cualquier página, el actor baja el `robots.txt` del dominio, respeta sus reglas `Disallow` y cualquier `Crawl-delay`, y espera una pausa entre peticiones al mismo sitio. Las páginas bloqueadas por robots.txt se marcan con el estado `bloqueado` y nunca se piden.

#### Entrada

- **URLs de páginas de producto** (`urls`): una lista de URLs de producto, una por línea. Déjala vacía para usar la página de la tienda por defecto.

Ejemplo de entrada:

```json
{
  "urls": ["https://example.com/product/example-item"]
}
```

#### Salida

Cada URL genera una fila en el dataset con estos campos: `url`, `estado` (`ok`, `sin_precio`, `bloqueado` o `error`), `precio`, `moneda`, `disponibilidad` (`in_stock`, `out_of_stock` o `unknown`), `fuente` (de dónde se leyó el precio), `motivo` (la razón cuando no hay precio o la página estaba bloqueada) y `cobrado` (si esa fila se ha cobrado).

#### Precios (pago por evento)

Se cobra por el evento `product-checked`, a 0,001 USD por cada página de producto comprobada con precio encontrado. Una página sin precio, bloqueada por robots.txt o que no se pudo cargar no se cobra.

#### Preguntas frecuentes

**¿Necesita una clave de API de la tienda?** No. Solo lee páginas de producto públicas.

**¿Ignora robots.txt?** No. Se comprueba robots.txt antes de cada dominio; las páginas no permitidas se omiten y se marcan como `bloqueado`.

**¿Por qué una fila no se cobra?** Solo se cobran las filas con estado `ok`, así que una página sin precio, una página bloqueada o una petición fallida no cuestan nada.

**¿Puede leer precios detrás de un login?** No. Solo lee páginas que cualquiera puede abrir sin iniciar sesión.

# Actor input Schema

## `urls` (type: `array`):

One product page URL per line. robots.txt is checked for each domain before its pages are fetched.

## Actor input object example

```json
{
  "urls": [
    "https://apify.com/store",
    "https://example.com/product/example-item"
  ]
}
```

# Actor output Schema

## `resultados` (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 = {
    "urls": [
        "https://apify.com/store",
        "https://example.com/product/example-item"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("flets_sv/price-stock-monitor").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 = { "urls": [
        "https://apify.com/store",
        "https://example.com/product/example-item",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("flets_sv/price-stock-monitor").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 '{
  "urls": [
    "https://apify.com/store",
    "https://example.com/product/example-item"
  ]
}' |
apify call flets_sv/price-stock-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,flets_sv/price-stock-monitor"
        }
    }
}
```

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/XYIzT0laBIX54TJrJ/builds/G3dB32KgCScEbRrSW/openapi.json
