# El Palacio de Hierro Scraper - Products, Prices & Stock (`abotapi/elpalaciodehierro-scraper`) Actor

Scrape El Palacio de Hierro (elpalaciodehierro.com) products: MXN price, list price, discount, stock units, brand, GTIN, sizes, colours, variants, categories, images and ratings. Search by keyword, walk departments or paste links; optional product details and price change tracking.

- **URL**: https://apify.com/abotapi/elpalaciodehierro-scraper.md
- **Developed by:** [Abot API](https://apify.com/abotapi) (community)
- **Categories:** Automation, Developer tools, E-commerce
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.30 / 1,000 product results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/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

## El Palacio de Hierro Scraper: Products, Prices, Stock & Sizes (elpalaciodehierro.com)

El Palacio de Hierro Scraper turns elpalaciodehierro.com, Mexico's luxury department store, into structured product data. Search by keyword, walk whole departments, or paste search, category, brand and product links, and get the price in Mexican pesos, the list price and discount, stock and stock units, brand, GTIN barcode, every size and colour variant with its own price and availability, the full set of categories, badges and promotions, all images and the review summary of every product. Turn on product details to add the model number, order limits, availability messages, estimated shipping date and every option with its low-stock flag and international size equivalents. Export to JSON, CSV or Excel, or pull results straight into your app through the API.

### Why This Scraper?

- **Every way into the catalogue.** Keyword searches, the store's 28 departments by name, pasted search pages, any category, brand or collection list page, and single product links, each read to its natural end or to the cap you set.
- **100 products per request.** Lists are read from the store's own catalogue data, so a run is fast and light on proxy traffic (about 3.5 MB for every thousand products listed).
- **Prices that tell the whole story.** Current price, list price, discount percent, lowest and highest variant price, badges and promotions such as interest-free instalments, in MXN.
- **Sizes, colours and stock.** Every variant with its size, colour, GTIN, price, list price and availability, plus the stock status and the number of units the store reports.
- **Product details when you need them.** Model, UPC, stock units (shown, never counted as a change), availability messages, estimated shipping date, minimum and maximum order quantity, sale limit, promotion price and every option with its availability, low-stock flag and US, UK and European size equivalents.
- **Monitoring built in.** Label every product NEW, UPDATED, REAPPEARED or EXPIRED across scheduled runs, track price and stock only, resume an interrupted crawl, get a chat alert when a run finishes, and export through MCP connectors.
- **Honest runs.** A list the store cuts at 10,000 products, a page that could not be read or a run stopped by its timeout is said so in the log and never reported as products that disappeared.

### Use Cases

- **Luxury and fashion price monitoring:** track prices, list prices and discounts across designer, fashion, beauty, watches, jewellery and home, and get alerted only to what changed.
- **Assortment and brand analysis:** compare ranges, price bands and brand coverage by department, brand page or keyword.
- **Size and stock tracking:** follow which sizes and colours sell out, and how stock units move.
- **Product data enrichment:** match products to your catalogue by GTIN or model number and pull descriptions, materials and images.
- **Market research in Mexico:** benchmark department store prices against other Mexican retailers.

#### How it compares

| | This actor | The other El Palacio de Hierro actor in the Store |
| --- | --- | --- |
| Keyword search | Yes | Yes |
| Whole departments by name | Yes (28) | No |
| Pasted search, category, brand and product links | Yes | No |
| Price, list price, discount, stock status, promotions | Yes | Yes |
| Stock units, GTIN, every size and colour variant with price and availability | Yes | Partly (sizes) |
| All categories with their parent path, all images, material, fit, gender | Yes | Partly (one category) |
| Review summary (rating and review count) | Yes | No |
| Model, order limits, shipping date, size equivalents | Yes (product details) | No |
| Filters by price, rating, brand, offers, stock | Yes | No |
| NEW / UPDATED / EXPIRED tracking for scheduled runs | Yes | No |
| Resume, chat alerts, MCP export | Yes | No |

Each row carries 47 top-level fields (53 with the incremental change fields), plus the 21-key product details block when product details are on; every field the other actor returns has a counterpart here (the field mapping ships with the actor).

### Data You Get

> Sample shape: values are illustrative placeholders, not from a live record.

| Field | Example |
| --- | --- |
| `productId` / `variantId` / `url` | `"45000000"` (the store's product number) / the default variant / the product page link |
| `name` / `brand` | `"Camisa Muestra Manga Larga Hombre"` / `"Marca Muestra"` |
| `price` / `listPrice` / `discountPercent` / `currency` | `839.4` / `1399` / `40` / `"MXN"` |
| `priceMin` / `priceMax` | lowest and highest variant price |
| `inStock` / `stockStatus` / `stockQuantity` | `true` / `"IN_STOCK"` / `16` (units the store reports) |
| `gtin` | the barcode where the store publishes it |
| `sizes` / `colors` | `["CH", "M", "G"]` / `["AZUL"]` |
| `variants` | each with `variantId`, `size`, `size2`, `color`, `gtin`, `price`, `listPrice`, `stockStatus`, `available`, `url` |
| `gender` / `material` / `fit` / `collection` / `description` | `"Hombre"` / `"100% Algodón."` / `"Slim"` / a collection name / the product copy |
| `division` / `department` | `"CABALLEROS"` / `"HOMBRE FORMAL"` |
| `categories` / `categoryIds` / `categoryPaths` | every category the product sits in: a flat list of names, their ids, and each one with its parent path (`categoryPaths[].path`) |
| `badges` / `promotions` | `["Meses Sin Intereses"]` / the badges that are promotions |
| `isOutlet` / `isNew` / `isBestSeller` / `isExclusive` / `isPreorder` / `backorderAllowed` | the store's own product flags |
| `imageUrl` / `images` | the main picture / every picture |
| `rating` / `reviewCount` | `5` / `1` (most products have no reviews yet: `null` / `0`) |
| `position` / `page` / `query` / `sourceUrl` / `scrapedAt` | where and when the row was read |
| `detail` | product details only: `model`, `upc`, `sku`, `online`, `available`, `stockUnits` (shown, never counted as a change), `availabilityMessages`, `inStockDate`, `estimatedShippingDate`, `minOrderQuantity`, `maxOrderQuantity`, `saleLimit`, `promotionPrice`, `productPriceDiscount`, `isLuxuryBrand`, `oneClickBuy`, `extendedWarrantyOffered`, `isPreorder`, `isGift`, `videoUrl`, `options` (each colour or size with `selectable`, `lowStock` and size `equivalents`) |
| `changeType` / `changedFields` / `firstSeenAt` / `lastSeenAt` | incremental mode only: `"NEW"`, `"UPDATED"`, `"UNCHANGED"`, `"REAPPEARED"` or `"EXPIRED"`, the fields that changed, and when the product was first and last seen |

Fields such as `listPrice`, `gtin` and `rating` are filled only for products that have them; `detail` is null unless product details are on.

**Output views.** The dataset has three views in the Console: **Products**, **Product details** and **Changes (incremental)**. Each run also stores a run summary under the `OUTPUT` key of its default key-value store.

### How to Use

1. Keep the default **search** mode and add keywords, or switch to **category** and pick departments, or to **url** and paste links.
2. Pick a sort order and, if you like, narrow by price, rating, brand, offers only or in stock only.
3. Turn on **Product details** if you need the model, order limits and size availability.
4. Set **Max items** to control run size and cost, then click **Start**.

**Quick keyword search:**

```json
{
  "mode": "search",
  "searchTerms": ["camisa"],
  "maxItems": 20
}
```

**Perfumes on offer, cheapest first, with product details:**

```json
{
  "mode": "search",
  "searchTerms": ["perfume"],
  "onlyOffers": true,
  "sortBy": "price_low",
  "fetchDetails": true,
  "maxItems": 50
}
```

**A whole department:**

```json
{
  "mode": "category",
  "departments": ["Relojes"],
  "maxItems": 0
}
```

**Pasted links:**

```json
{
  "mode": "url",
  "urls": [
    "https://www.elpalaciodehierro.com/buscar?q=camisa",
    "https://www.elpalaciodehierro.com/mujer/ropa/camisas-moda/",
    "https://www.elpalaciodehierro.com/marcas/the-north-face/",
    "https://www.elpalaciodehierro.com/michael-kors-camisa-de-rayas-manga-larga-hombre-45383638.html"
  ],
  "maxItemsPerSearch": 10,
  "maxItems": 30
}
```

#### Pasted links

- **Search pages** such as `/buscar?q=camisa`.
- **Category, brand and collection list pages** such as `/mujer/ropa/camisas-moda/` or `/marcas/the-north-face/`: the page is read once to find its list, then the list is read 100 products at a time.
- **Product pages** ending in `-<number>.html` return that one product. A product link the store no longer shows is reported as not found.
- A link pasted at a later offset (`?start=52`) starts exactly there: the products before the offset are skipped. Such a list is partial, so it never marks products EXPIRED.
- The sort and filters above (price, rating, brand, offers only, in stock only) are applied to every pasted link; a link's own filters (colour, size, price range) are not, and the log says so.
- Sitemaps, robots.txt, account, cart and checkout pages, content pages, image and service addresses and other site pages are not product listings: they are skipped with a note in the log before any request, and a run given only such links fails at once.

#### Caps and pagination

**Max items** stops the whole run once that many products have been returned (`0` = no cap), also across a platform restart of the same run. **Max items per keyword, department or link** caps each one on its own. **Max pages** limits how many result pages (100 products each) each list walks; it does not cap the run by itself. The store lists at most 10,000 products for one search or category: when a department or keyword matches more (for example Mujer, Hogar, Marcas), the log says so, and you can paste sub-category or brand links to reach the rest.

#### Resume and recurring updates

- **Resume** (`resumeFromRunId`) skips products already collected by an earlier run: paste its run or dataset ID and those products are neither returned nor charged again.
- **Incremental mode** (`incrementalMode`) is for scheduled runs over the same setup. Each product is classified `NEW`, `UPDATED` (with `changedFields`), `UNCHANGED` (left out and not billed unless `emitUnchanged` is on), `REAPPEARED`, or `EXPIRED` (only with `emitExpired` on, and only after a complete scan: every list walked to its confirmed end; never after a capped, page-limited, cost-limited, resumed, restarted or timeout-stopped run, for product links or links pasted at a later offset, for a list the store cuts at 10,000 products, or a run where any page could not be read). The result position and page, the scrape time and the keyword or link a product was found through never count as a change. The product details block is compared key by key (each top-level key of the block on its own), and only when both runs read it, so turning product details on or off never reports products as UPDATED. `ignoreFieldsForChanges` defaults to the rating (`rating`), the review count (`reviewCount`) and the top-level stock-unit count (`stockQuantity`), which drift with every review or sale; remove names to be told about them, or add more. Inside the product details block, the stock-unit count (`detail.stockUnits`) is always left out of the comparison, and any other key of the block can be left out with `detail.<key>` (for example `detail.availabilityMessages`). A product details change that happens while a run has product details off is not reported: the next run with details on compares against the block last saved. States saved by an earlier version of this actor carry the details block in an older form: the first run after the update compares everything else as usual, never reports the details block as changed, and saves it in the new form. `changeScope: "priceAndStock"` compares only price, list price, discount, stock status, the in-stock flag and each variant's price, list price and availability; `compactUpdates` returns slim rows with just what moved. `stateKey` names the stored state; leave it empty and the actor derives one from the run's setup. If runs with a different keyword, department, link, sort, filter or page-limit setup share one `stateKey`, they list different products: such a run still compares products but marks nothing `EXPIRED`, says so once in the log, and products only the earlier setup listed are never marked `EXPIRED` by the new one. Use one `stateKey` per setup. With product details on, a product whose details could not be read is held back (not compared, saved or charged) and compared on the next run. At the default memory one state key tracks up to 1,500 products (4.2 MB of saved state; more with more memory): past that, the run still returns the extra products as NEW, says so once in the log, and leaves the saved state unchanged.

#### Alerts

Fill in a Slack incoming webhook, a Discord channel webhook, or a Telegram bot token with its chat ID, and the actor posts one short summary when the run finishes: the number of rows (and, in incremental mode, how many are new, updated, reappeared or expired) followed by up to **Rows listed per alert** products. With **Alert on changes only** on and Incremental changes on, nothing is sent when nothing changed. Sending an alert adds no charge of its own and never changes the run's result; leave every field empty to skip them.

### Send results into your apps (MCP connectors)

Optionally pipe the scraped results into the apps you already use, via Model Context Protocol (MCP) connectors. This is an extra delivery step **after** the scrape: the Apify dataset is never changed.

**What gets written to the connector:** a condensed, human-readable **summary** of each record, not the full JSON. Each item becomes one entry with a **title** and its key fields flattened to plain text. The **complete record always stays in the Apify dataset**.

1. Authorize a connector once under **Apify, Settings, Integrations** (Notion, Linear, Airtable, or Apify).
2. Select it in the **"Pipe results into your apps"** input field (`mcpConnectors`). (If the picker is empty, you haven't authorized a connector yet.)
3. For **Notion**, also set `notionParentPageUrl` to the page where items should be created.
4. Optionally set `maxNotifyListings` to cap how many items are written to each connector per run (default 50).

The connection is mediated by Apify's MCP proxy, so this actor never sees your third-party credentials. Leave the field empty to skip.

### Input Parameters

| Parameter | Type | Default | Description |
| --- | --- | --- | --- |
| `mode` | string | `search` | `search` (keywords), `category` (departments) or `url` (pasted links). |
| `searchTerms` | array | `camisa` | Search mode: keywords, each walked separately. |
| `departments` | array | (none) | Category mode: the store's departments to walk. |
| `sortBy` | string | `relevance` | `relevance`, `price_low` or `price_high`. |
| `brands` | array | (none) | Keep only these brands (not case sensitive). |
| `minPrice` | number | (none) | Lowest price kept, in Mexican pesos. |
| `maxPrice` | number | (none) | Highest price kept, in Mexican pesos. |
| `minRating` | number | (none) | Only products rated at least this many stars. |
| `onlyOffers` | boolean | `false` | Only products with a list price above the current price. |
| `inStockOnly` | boolean | `false` | Only products shown as in stock. |
| `urls` | array | a search and a category link | URL mode: search, category, brand and product links, see Pasted links above. |
| `fetchDetails` | boolean | `false` | Also read each product's option data and add the `detail` block (charged per row that carries it). |
| `maxPages` | integer | (none) | Optional page limit per list; does not cap the run, Max items does. |
| `maxItems` | integer | `20` | Cap on the whole run; `0` = no cap. |
| `maxItemsPerSearch` | integer | `0` | Cap per keyword, department or link; `0` = no per-list cap. |
| `proxy` | object | Apify Proxy, Residential, Mexico | Apify Proxy settings, or your own proxy URLs. |
| `resumeFromRunId` | string | (none) | Run or dataset ID whose products are skipped. |
| `incrementalMode` | boolean | `false` | Return only new, changed and reappeared products on repeat runs. |
| `stateKey` | string | (auto) | Name the incremental state (one key per setup). |
| `changeScope` | string | `all` | `all` or `priceAndStock`. |
| `compactUpdates` | boolean | `false` | Slim UPDATED rows with only what moved. |
| `expireAfterMissedScans` | integer | `1` | Complete scans a product must be missing before EXPIRED. |
| `emitUnchanged` | boolean | `false` | Also return UNCHANGED rows (billed as rows). |
| `emitExpired` | boolean | `false` | Also return EXPIRED rows after a complete scan (billed as rows). |
| `ignoreFieldsForChanges` | array | `rating`, `reviewCount`, `stockQuantity` | Fields that never count as a change; remove names to be told about them. Use `detail.<key>` (or the bare key) for a key inside the product details block; `detail.stockUnits` is always left out. |
| `mcpConnectors` | array | (none) | Optional MCP connectors to send results into, see above. |
| `notionParentPageUrl` | string | (none) | Notion page that receives the items (Notion connector only). |
| `maxNotifyListings` | integer | `50` | Cap on items written to each connector per run. |
| `notifyOnlyChanges` | boolean | `false` | Send the alert only when something changed (needs Incremental changes). |
| `notificationLimit` | integer | `5` | Product rows listed in an alert. |
| `slackWebhookUrl` | string | (none) | Optional Slack incoming webhook for the run summary. |
| `discordWebhookUrl` | string | (none) | Optional Discord channel webhook for the run summary. |
| `telegramBotToken` | string | (none) | Optional Telegram bot token for the run summary. |
| `telegramChatId` | string | (none) | Telegram chat ID that receives the run summary. |

### Output Example

> Sample shape: values are illustrative placeholders, not from a live record.

```json
{
  "productId": "45000000",
  "variantId": "45000002",
  "name": "Camisa Muestra Manga Larga Hombre",
  "brand": "Marca Muestra",
  "url": "https://www.elpalaciodehierro.com/marca-muestra-camisa-muestra-manga-larga-hombre-45000002.html",
  "price": 839.4,
  "listPrice": 1399.0,
  "discountPercent": 40.0,
  "currency": "MXN",
  "priceMin": 839.4,
  "priceMax": 839.4,
  "inStock": true,
  "stockStatus": "IN_STOCK",
  "stockQuantity": 16,
  "gtin": "0000000000000",
  "sizes": ["CH", "M", "G"],
  "colors": ["AZUL"],
  "variants": [
    {"variantId": "45000001", "size": "CH", "size2": null, "color": "AZUL", "gtin": "0000000000000", "price": 839.4, "listPrice": 1399.0, "stockStatus": "IN_STOCK", "available": true, "url": "https://www.elpalaciodehierro.com/marca-muestra-camisa-muestra-manga-larga-hombre-45000001.html"}
  ],
  "gender": "Hombre",
  "material": "100% Algodón.",
  "fit": "Slim",
  "collection": null,
  "description": "Sample description text.",
  "division": "CABALLEROS",
  "department": "HOMBRE FORMAL",
  "categories": ["Camisas para Hombre", "Marca Muestra Hombre"],
  "categoryIds": ["10500101", "11900001"],
  "categoryPaths": [
    {"id": "10500101", "name": "Camisas para Hombre", "path": ["HOMBRE", "ROPA DE HOMBRE", "Camisas para Hombre"]},
    {"id": "11900001", "name": "Marca Muestra Hombre", "path": ["MARCAS", "MARCA MUESTRA", "Marca Muestra Hombre"]}
  ],
  "badges": ["Meses Sin Intereses"],
  "promotions": ["Meses Sin Intereses"],
  "isOutlet": false,
  "isNew": false,
  "isBestSeller": false,
  "isExclusive": false,
  "isPreorder": false,
  "backorderAllowed": false,
  "productType": "master",
  "imageUrl": "https://media.example.com/sample-1.jpg",
  "images": ["https://media.example.com/sample-1.jpg", "https://media.example.com/sample-2.jpg"],
  "rating": null,
  "reviewCount": 0,
  "position": 1,
  "page": 1,
  "query": "camisa",
  "sourceUrl": "https://www.elpalaciodehierro.com/buscar?q=camisa",
  "scrapedAt": "2026-01-20T08:00:00+00:00",
  "detail": {
    "model": "MODEL-000",
    "upc": null,
    "sku": "45000000",
    "online": true,
    "available": true,
    "stockUnits": 0,
    "availabilityMessages": [],
    "inStockDate": null,
    "estimatedShippingDate": null,
    "minOrderQuantity": 1,
    "maxOrderQuantity": 10,
    "saleLimit": null,
    "promotionPrice": null,
    "productPriceDiscount": 40.0,
    "isLuxuryBrand": false,
    "oneClickBuy": true,
    "extendedWarrantyOffered": null,
    "isPreorder": null,
    "isGift": null,
    "videoUrl": null,
    "options": [
      {"attribute": "size1", "name": "Talla", "values": [{"value": "M", "selectable": true, "lowStock": false, "equivalents": {"USA": "6", "Europa": "38"}}]}
    ]
  }
}
```

### Plan Requirement

Pay per event: one unit per returned product row, one product details unit per returned row that carries the `detail` block (only when **Product details** is on), plus an actor start event. Each unit is charged per row, as the row is delivered, never as a single total at the end. An unchanged product left out in incremental mode is neither returned nor charged, and a compact UPDATED row (which carries no product details block) is never charged the product details unit.

The store's product data sits behind a browser check that serves residential connections in Mexico (measured: every residential read served; datacenter connections were refused most product-detail reads). The default setting is Apify Proxy Residential with country Mexico, billed to your own Apify plan: about 3.5 MB of traffic for every thousand products listed, plus about 14 KB per product read for product details. If you never turn on product details, a datacenter connection also serves the lists (measured on every request). Apify free plans do not include residential proxies: on a free plan the run can only use your own proxy URL or the actor's backup connection, which the store often refuses for product details.

### FAQ

#### How much does it cost?

You pay per product row returned, plus the product details unit for rows that carry it. The **Pricing** tab shows the current rates. Use **Max items** to cap the cost of any run; residential traffic is billed by Apify to your own plan.

#### Is it legal to scrape elpalaciodehierro.com?

This actor collects only publicly available product data that El Palacio de Hierro shows on its own pages, without logging in. You are responsible for how you use it: follow the site's terms and the laws that apply to you, and get legal advice if you plan commercial redistribution. Prices and product attributes are generally facts, but images and description text may be subject to third-party rights.

#### Can I get only new or changed products on a schedule?

Yes. Schedule the actor from the **Schedules** tab and turn on **Incremental mode**. Each run then returns only new, updated and reappeared products; unchanged ones are not billed unless you turn `emitUnchanged` on. Use `changeScope: "priceAndStock"` to be told only about price and stock moves, including a size selling out.

#### Why does a department return fewer products than the store has?

The store lists at most 10,000 products for one search or category. The log says so when that happens; paste sub-category or brand links (for example `/mujer/ropa/camisas-moda/`) to reach the rest. Filters you set narrow the rows further.

#### Why do most products have no rating?

The store shows a review summary only for products that have reviews, and most of its catalogue has none yet. Those rows carry `rating: null` and `reviewCount: 0`.

#### Which proxy should I use?

Keep the default (Residential, Mexico). If a residential connection is refused by the store's browser check, the actor drops that connection and continues on a fresh one, so this is normal and never ends the run on its own. If the connection you selected is unavailable or keeps getting refused, the run automatically continues on a backup connection (the other Apify proxy tier, then a backup gateway) rather than stopping; that escalation is disclosed in the run log the first time it happens, and any residential traffic it uses is billed to your own Apify plan. Set `ELPALACIODEHIERRO_COM_ALTERNATE_CONNECTION=0` in the run's environment variables to disable the backup connection entirely. If you enter your own proxy URLs, they are used as-is with no backup connection; if your proxy re-signs HTTPS traffic, the run says so once in the log ("The custom proxy re-signs HTTPS traffic; retrying without certificate verification for it.") and continues on it.

#### Why did my run fail instead of returning an empty dataset?

If every search or link could not be read, the run stops with a clear message so "no products matched" is never confused with "nothing could be read". Run it again in a few minutes. The messages you may see in the run log:

- When the selected connection is unavailable to your account, the log says: "The selected connection is unavailable to this run. Apify free plans do not include residential proxies. Continuing on a backup connection; some pages may still be unavailable. For residential access, upgrade at https://apify.com/pricing or supply your own proxy URLs."
- When requests are then served over the backup connection: "Served over the backup connection (the default connection was unavailable)." Set `ELPALACIODEHIERRO_COM_ALTERNATE_CONNECTION=0` in the run's environment variables to disable the backup connection.
- If the proxy connection is refused for the account and nothing could be read: "The proxy connection was refused for this account, so no page could be read. Your Apify plan does not include proxy access; a paid plan is required: https://apify.com/pricing. If you entered your own proxy URLs, check that their credentials are valid."
- If the run reaches the maximum cost per run you set, it stops and its status says: "Stopped early: the run reached the maximum cost per run you set, after N row(s). Nothing more was read, delivered or charged. Raise the maximum cost per run to collect more."
- If the run is about to reach its timeout, it stops reading about 20 seconds before, keeps every row already returned, and ends with the status: "Partial results: stopped before the platform timeout (N row(s) saved). Give the run more time (Timeout in the run options) to collect everything in one run." Such a run never marks products EXPIRED. Set `ELPALACIODEHIERRO_COM_STOP_BEFORE_TIMEOUT=0` in the run's environment variables to turn this off.
- Links that are not product listings (sitemaps, robots.txt, account, cart and checkout pages, content pages, image and service addresses, files and other site pages) are skipped before any request, with one log line each.
- If the run has no residential access and the backup connection still could not load the data: "No results: residential proxies are unavailable on this run (Apify free plans do not include them), and the backup connection could not load the requested El Palacio de Hierro pages. Upgrade at https://apify.com/pricing or supply your own proxy URLs, then try again."
- If every request failed for another reason: "Could not load any results page (the requests failed), so nothing was collected. This is a connection problem, not an empty search. Please try again later."

Each of these failure messages ends with how many of your searches or links could not be read. A run with no keywords, departments or supported links fails at once with "Nothing to scrape: add search keywords in Search mode, pick departments in Category mode, or paste valid elpalaciodehierro.com search, category or product links in URL mode." If only some keywords or links could be read, you still get what was found, and the run's status message says how many could not be read.

#### Can I use it with AI agents or MCP?

Yes. Call it from any Apify integration or MCP client, and use the connector field to push results into Notion, Linear or Airtable.

### 🔗 Want more e-commerce data?

Pair this actor with these related scrapers from the same team:

<table>
<tr><td>⚽ <a href="https://apify.com/abotapi/sports-direct-scraper"><b>Sports Direct UK Scraper</b></a><br>Scrape Sports Direct (sportsdirect.com) UK products by keyword, filters or URL. Extract...</td><td>🛒 <a href="https://apify.com/abotapi/johnlewis-com-scraper"><b>John Lewis Scraper</b></a><br>Scrape John Lewis (johnlewis.com) products: prices and price history, promotions, colour...</td></tr>
<tr><td>👗 <a href="https://apify.com/abotapi/ounass-scraper"><b>Ounass Scraper</b></a><br>Scrape Ounass (ounass.ae) luxury fashion across UAE, Saudi Arabia, Kuwait, Qatar, Bahrain...</td><td>🛒 <a href="https://apify.com/abotapi/boots-com-scraper"><b>Boots Scraper</b></a><br>Scrape Boots (boots.com) products: current and regular prices, savings, price per unit...</td></tr>
<tr><td>👗 <a href="https://apify.com/abotapi/asos-com-scraper"><b>ASOS Scraper</b></a><br>Scrape ASOS (asos.com) fashion products by keyword, category or URL. Extract selling...</td><td>👗 <a href="https://apify.com/abotapi/theiconic-com-au-scraper"><b>THE ICONIC Scraper</b></a><br>Scrape THE ICONIC (theiconic.com.au) fashion products: name, brand, price, sale price...</td></tr>
</table>

👉 [Browse all abotapi scrapers](https://apify.com/abotapi)

### 💬 Support

- 🐞 **Found a bug or a missing field?** Open a ticket on the [Issues tab](https://apify.com/abotapi/elpalaciodehierro-scraper/issues/open). We usually reply within hours.
- 🛠️ **Need another site, extra fields or a private build?** Email <contact@abotapi.com>.
- ⭐ **Enjoying it?** A quick review on the actor page helps other users find it.

# Actor input Schema

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

Choose 'search' to run keyword searches, 'category' to walk the store's departments, or 'url' to paste elpalaciodehierro.com search, category, brand or product links.

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

Search mode only. One walk per keyword, exactly as the store's own search box (Spanish keywords match best, for example camisa, perfume, tenis, bolsa).

## `departments` (type: `array`):

Category mode only. Pick one or more of the store's departments; each is walked page by page. The store lists at most 10,000 products for one list, so a larger department (Mujer, Hogar, Marcas, Ofertas de Temporada, Regalos, Temporada, Nuevos Productos) is cut there: paste sub-category or brand links in URL mode to reach the rest.

## `sortBy` (type: `string`):

Order of the results, as the store sorts them: most relevant, price low to high, or price high to low. Applies to every list, including pasted links.

## `brands` (type: `array`):

Keep only products of these brands (exact brand name as the store shows it, for example Michael Kors or Calvin Klein; not case sensitive). Applied to the rows read, before anything is returned or charged.

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

Keep only products priced at or above this amount in Mexican pesos. Applied before anything is returned or charged.

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

Keep only products priced at or below this amount in Mexican pesos. Applied before anything is returned or charged.

## `minRating` (type: `number`):

Keep only products rated at least this many stars (1-5). Most products on this store have no reviews yet, so products without a rating are left out when this is set.

## `onlyOffers` (type: `boolean`):

Keep only products that show a list price above the current price (a discount).

## `inStockOnly` (type: `boolean`):

Keep only products the store shows as in stock.

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

Paste elpalaciodehierro.com links: a search page (/buscar?q=camisa), a category, brand or collection list page (for example /mujer/ropa/camisas-moda/ or /marcas/the-north-face/), or a product page (ending in -<number>.html), which returns that one product. A link pasted at a later offset (?start=200) starts there. Sitemaps, robots.txt, account, cart and checkout pages, content pages, image and service addresses are skipped before any request.

## `fetchDetails` (type: `boolean`):

Off by default. When on, each product's own option data is also read and the row gains a 'detail' block: model number, UPC, stock units, availability messages, estimated shipping date, minimum and maximum order quantity, sale limit, promotion price, one-click-buy and warranty flags, and every option (colour, size) with its availability, low-stock flag and international size equivalents. Each row delivered with this block is charged the product detail event, and each product is one more small read on your proxy.

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

Optional. Limits how many result pages (100 products each) each keyword, department or link walks. Empty or 0 means no page limit; it does NOT cap the run by itself, Max items below does.

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

THE cap on this run: the maximum number of product rows returned across the whole run. Defaults to 20 so a first run is quick and cheap. 0 means no limit from this setting: the run then reads a whole search or category and is still bounded by the end of the results and by your maximum cost per run.

## `maxItemsPerSearch` (type: `integer`):

Optional. Caps how many products each keyword, department or pasted link may return, so one large list cannot use up the whole run. 0 (default) = no per-list cap; Max items still caps the run.

## `proxy` (type: `object`):

Leave this on the default (Residential, Mexico): it serves every mode and option. Residential traffic is billed to your own Apify plan (about 3.5 MB per 1,000 products listed, plus about 14 KB per product with details). If you never turn on product details, a datacenter connection also serves the lists. You can also paste your own proxy URL (a Mexican residential one works best).

## `resumeFromRunId` (type: `string`):

Paste a previous run ID or dataset ID to continue a large crawl without returning or charging for products already collected there. For recurring monitoring of the same search, use Incremental mode below instead.

## `incrementalMode` (type: `boolean`):

Turn this on for daily or recurring monitoring. The first run returns every matching product as NEW. Later runs normally return only NEW, UPDATED and REAPPEARED products. A product counts as UPDATED when any of its fields changed, except the result position and page, the scrape time and the keyword or link it was found through, and by default its rating, review count and stock-unit count (see Ignore fields below); the product details block is compared key by key, and only when both runs read it. With 'Price and stock only' just price, list price, discount, stock status, the in-stock flag and each variant's price, list price and availability are compared. State is kept separately for each keyword, department, link, sort and filter setup; use State key to name a monitoring campaign (one key per setup).

## `stateKey` (type: `string`):

Optional. Name this monitoring campaign to keep its state stable across runs with the same setup. If runs with a different keyword, department, link, sort, filter or page-limit setup share one key, they list different products, so such a run marks nothing EXPIRED (it says so in the log); use one key per setup. Leave empty to derive a key automatically from this run's setup. One state key tracks up to 1,500 products at the default memory (more with more memory).

## `changeScope` (type: `string`):

'Price and stock only' compares just price, list price, discount, stock status, the in-stock flag and each variant's price, list price and availability (a size added, removed or selling out counts); a name, image, badge or category change is treated as UNCHANGED and is never returned or billed as UPDATED. 'All fields' compares the whole record (minus the fields listed under Ignore fields).

## `compactUpdates` (type: `boolean`):

When on, an UPDATED row carries only identifiers plus the price and stock fields that actually moved (priceChanges, and variantChanges for each size or colour variant added, removed or changed), instead of the full record. A compact row carries no product details block, so it is never charged the product detail event. Off by default.

## `expireAfterMissedScans` (type: `integer`):

A tracked product absent from this many consecutive complete scans in a row is marked EXPIRED; fewer misses are held over without being reported. 1 (default) expires on the first miss, matching this actor's previous behaviour.

## `emitUnchanged` (type: `boolean`):

Off by default. Turn on to also return products that have not changed since the last run, marked UNCHANGED. This returns, and bills, extra rows you already have.

## `emitExpired` (type: `boolean`):

Off by default. Turn on to also return products that were present in a previous run but are no longer found, marked EXPIRED. Only produced after a complete scan: every list walked to its confirmed end. Never when Max items, Max pages or the maximum cost per run stopped it, when the store cuts a list at 10,000 products, for product links or links pasted at a later page, when any page could not be read, when the run stopped before its timeout, or when Resume was used. This returns, and bills, extra synthetic rows.

## `ignoreFieldsForChanges` (type: `array`):

Field names that must NOT count as a change in incremental mode. The default list leaves out the rating (rating), the review count (reviewCount) and the stock-unit count (stockQuantity), which drift with every review or sale; remove names from the list to be told about them. A product whose only differences are in these fields is treated as UNCHANGED, so it is not returned or billed as UPDATED. Names match at any nesting depth outside images, categories and description, which are compared as one unit each (use their own name, for example 'images', to ignore one as a whole). Inside the product details block, use 'detail.<key>' or the bare key (for example 'detail.availabilityMessages'); 'detail.stockUnits' is always left out; 'detail' ignores the whole block. The fields still appear in the output of rows that are returned.

## `mcpConnectors` (type: `array`):

Optionally send results into the apps you already use, via Model Context Protocol (MCP) connectors. Authorize one under Apify, Settings, API & Integrations, then select it here. Notion gets a rich page-per-item export; other connectors get a best-effort write or digest. Leave empty to skip; this never changes the dataset output. Supported: Notion (https://mcp.notion.com/mcp), Linear (https://mcp.linear.app/sse), Airtable (https://mcp.airtable.com/mcp), Apify (https://mcp.apify.com).

## `notionParentPageUrl` (type: `string`):

URL or id of the Notion page under which item pages are created. Required to enable the Notion export; ignored by other connectors.

## `maxNotifyListings` (type: `integer`):

Cap on items written to each connector per run. Does not affect the dataset.

## `notifyOnlyChanges` (type: `boolean`):

Only send the alert when Incremental changes is on and at least one row is NEW, UPDATED, REAPPEARED or EXPIRED. Without Incremental changes every finished run sends its summary.

## `notificationLimit` (type: `integer`):

How many rows the alert message lists (the run's totals are always in the first line).

## `slackWebhookUrl` (type: `string`):

Optional Slack incoming-webhook URL to post the summary to.

## `discordWebhookUrl` (type: `string`):

Optional Discord channel webhook URL to post the summary to.

## `telegramBotToken` (type: `string`):

Optional Telegram bot token to post the summary with (needs the chat ID below).

## `telegramChatId` (type: `string`):

Optional Telegram chat ID that receives the summary (needs the bot token above).

## Actor input object example

```json
{
  "mode": "search",
  "searchTerms": [
    "camisa"
  ],
  "sortBy": "relevance",
  "onlyOffers": false,
  "inStockOnly": false,
  "urls": [
    "https://www.elpalaciodehierro.com/buscar?q=camisa",
    "https://www.elpalaciodehierro.com/mujer/ropa/camisas-moda/",
    "https://www.elpalaciodehierro.com/marcas/the-north-face/",
    "https://www.elpalaciodehierro.com/michael-kors-camisa-de-rayas-manga-larga-hombre-45383638.html"
  ],
  "fetchDetails": false,
  "maxItems": 20,
  "maxItemsPerSearch": 0,
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "MX"
  },
  "incrementalMode": false,
  "changeScope": "all",
  "compactUpdates": false,
  "expireAfterMissedScans": 1,
  "emitUnchanged": false,
  "emitExpired": false,
  "ignoreFieldsForChanges": [
    "rating",
    "reviewCount",
    "stockQuantity"
  ],
  "maxNotifyListings": 50,
  "notifyOnlyChanges": false,
  "notificationLimit": 5
}
```

# Actor output Schema

## `overview` (type: `string`):

No description

## `details` (type: `string`):

No description

## `changes` (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 = {
    "mode": "search",
    "searchTerms": [
        "camisa"
    ],
    "sortBy": "relevance",
    "onlyOffers": false,
    "inStockOnly": false,
    "urls": [
        "https://www.elpalaciodehierro.com/buscar?q=camisa",
        "https://www.elpalaciodehierro.com/mujer/ropa/camisas-moda/",
        "https://www.elpalaciodehierro.com/marcas/the-north-face/",
        "https://www.elpalaciodehierro.com/michael-kors-camisa-de-rayas-manga-larga-hombre-45383638.html"
    ],
    "fetchDetails": false,
    "maxItems": 20,
    "proxy": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ],
        "apifyProxyCountry": "MX"
    },
    "incrementalMode": false,
    "compactUpdates": false,
    "emitUnchanged": false,
    "emitExpired": false,
    "ignoreFieldsForChanges": [
        "rating",
        "reviewCount",
        "stockQuantity"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("abotapi/elpalaciodehierro-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 = {
    "mode": "search",
    "searchTerms": ["camisa"],
    "sortBy": "relevance",
    "onlyOffers": False,
    "inStockOnly": False,
    "urls": [
        "https://www.elpalaciodehierro.com/buscar?q=camisa",
        "https://www.elpalaciodehierro.com/mujer/ropa/camisas-moda/",
        "https://www.elpalaciodehierro.com/marcas/the-north-face/",
        "https://www.elpalaciodehierro.com/michael-kors-camisa-de-rayas-manga-larga-hombre-45383638.html",
    ],
    "fetchDetails": False,
    "maxItems": 20,
    "proxy": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
        "apifyProxyCountry": "MX",
    },
    "incrementalMode": False,
    "compactUpdates": False,
    "emitUnchanged": False,
    "emitExpired": False,
    "ignoreFieldsForChanges": [
        "rating",
        "reviewCount",
        "stockQuantity",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("abotapi/elpalaciodehierro-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 '{
  "mode": "search",
  "searchTerms": [
    "camisa"
  ],
  "sortBy": "relevance",
  "onlyOffers": false,
  "inStockOnly": false,
  "urls": [
    "https://www.elpalaciodehierro.com/buscar?q=camisa",
    "https://www.elpalaciodehierro.com/mujer/ropa/camisas-moda/",
    "https://www.elpalaciodehierro.com/marcas/the-north-face/",
    "https://www.elpalaciodehierro.com/michael-kors-camisa-de-rayas-manga-larga-hombre-45383638.html"
  ],
  "fetchDetails": false,
  "maxItems": 20,
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "MX"
  },
  "incrementalMode": false,
  "compactUpdates": false,
  "emitUnchanged": false,
  "emitExpired": false,
  "ignoreFieldsForChanges": [
    "rating",
    "reviewCount",
    "stockQuantity"
  ]
}' |
apify call abotapi/elpalaciodehierro-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,abotapi/elpalaciodehierro-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/L04KLXASXdz0BuOWD/builds/m5LUa9oxp8uf9B7fu/openapi.json
