# StockX Listings Scraper (`piotrv1001/stockx-listings-scraper`) Actor

The StockX Listings Scraper extracts product data from StockX based on search keywords and categories, capturing names, URLs, images, detailed pricing, condition, model, and category—ideal for market research and resale analysis.

- **URL**: https://apify.com/piotrv1001/stockx-listings-scraper.md
- **Developed by:** [FalconScrape](https://apify.com/piotrv1001) (community)
- **Categories:** E-commerce, Lead generation, Automation
- **Stats:** 70 total users, 6 monthly users, 98.5% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 product listings

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

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### 🚀 StockX Listings Scraper

Easily extract product listings from StockX by **search keyword**, **brand**, **category**, or **direct product URL**. The **StockX Listings Scraper** returns flattened, structured records with full market data — lowest ask, highest bid, last sale, and 90-day statistics — ideal for resale analysis, market research, and price tracking.

### ✨ Features

- 🏷️ **Comprehensive Product Data**: Title, brand, model, gender, condition, release date, image, and product URL — flattened from StockX's inline SSR data.
- 💰 **Real Market Data**: `lowestAsk`, `highestBid`, `lastSale`, plus 90-day and annual averages, sales counts, volatility, and price premium.
- 🔎 **Four Input Modes**: Keyword search, brand slug, category slug, or direct product URLs — mix and match in a single run.
- 🛍️ **Optional PDP Enrichment**: Toggle `includePdpDetails` to add `styleId`, `colorway`, `retailPrice`, the full size matrix (US M / UK / CM / KR / EU / US W), and the media gallery.
- ⚡ **Smart Tiering**: Cheap proxy for search pages, Anti Scraping Protection for brand/category/PDP — so you pay the minimum needed per request.

### 🛠️ How It Works

1. **Pick your inputs** – any combination of `searches`, `brands`, `categories`, or `productUrls`.
2. **(Optional) toggle PDP enrichment** – set `includePdpDetails: true` to fetch each product's detail page for the full size matrix, retail price, and gallery.
3. **Run the scraper** – paginated listings are flattened, deduplicated by `urlKey`, and pushed to the dataset.

### ⚙️ Input

| Field                 | Type       | Required | Description                                                                                                                                              |
| --------------------- | ---------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `searches`            | `string[]` | One of   | Keyword queries crawled via `https://stockx.com/search?s=...`. Each query paginates up to StockX's 1000-result cap (25 pages × 40).                      |
| `brands`              | `string[]` | One of   | Brand slugs crawled via `https://stockx.com/brands/{slug}` — e.g. `jordan`, `nike`, `adidas`.                                                            |
| `categories`          | `string[]` | One of   | Category slugs crawled via `https://stockx.com/category/{slug}` — e.g. `sneakers`, `apparel`, `accessories`, `electronics`, `collectibles`, `trading-cards`. |
| `productUrls`         | `string[]` | One of   | Specific product pages or url-keys to scrape directly — e.g. `https://stockx.com/air-jordan-4-retro-toro-bravo-2026` or just `air-jordan-4-retro-toro-bravo-2026`. Always fetched as PDPs. |
| `includePdpDetails`   | `boolean`  | No       | After collecting browse-page records, fetch each PDP to add `styleId`, `colorway`, `retailPrice`, full size matrix, and gallery. Default `false`.        |
| `maxItems`            | `integer`  | No       | Stop after this many records. Leave empty to crawl everything (capped at 1000 per browse query by StockX).                                               |

At least one of `searches`, `brands`, `categories`, or `productUrls` must be provided.

### 📊 Sample Output Data

#### Shallow listing (from `searches` / `brands` / `categories`)

```json
{
    "source": "search",
    "sourceValue": "vaporfly",
    "id": "74ddd080-1608-4bc8-b158-45f9af54e03c",
    "title": "Nike ZoomX Vaporfly 3 Multi-Color",
    "name": "Multi-Color",
    "urlKey": "nike-zoomx-vaporfly-3-multi-color",
    "productUrl": "https://stockx.com/nike-zoomx-vaporfly-3-multi-color",
    "image": "https://images.stockx.com/images/Nike-ZoomX-Vaporfly-3-Multi-Color-Product.jpg?...",
    "brand": "Nike",
    "model": "Nike ZoomX Vaporfly 3",
    "gender": "men",
    "productCategory": "sneakers",
    "primaryCategory": "Nike Other",
    "condition": "New",
    "listingType": "STANDARD",
    "releaseDate": "2024-10-03",
    "lowestAsk": 109,
    "lowestAskAt": "2026-05-13T02:44:23Z",
    "highestBid": 90,
    "highestBidAt": "2026-05-04T21:26:23Z",
    "lastSale": 104,
    "avgPrice90d": 131,
    "salesCount90d": 132,
    "avgPriceAnnual": 129,
    "salesCountAnnual": 996,
    "volatilityAnnual": 0.127194,
    "pricePremiumAnnual": -0.6,
    "salesCount72h": 3
}
```

#### Detailed record (from `productUrls` or with `includePdpDetails: true`)

Adds the following fields on top of the shallow listing:

```json
{
    "styleId": "HQ3219-902",
    "colorway": "Multi-Color/Volt/Hyper Pink/Black",
    "retailPrice": 260,
    "variants": [
        {
            "id": "7a4c2a58-9723-427a-8615-1fea62856835",
            "size": "4",
            "sizeChart": {
                "us m": "US M 4",
                "uk": "UK 3.5",
                "cm": "CM 23",
                "kr": "KR 230",
                "eu": "EU 36",
                "us w": "US W 5.5"
            }
        }
    ],
    "gallery": [],
    "fullDescription": "The Nike ZoomX Vaporfly 3 Multi-Color is a vibrantly colored trainer..."
}
```

> Note: per-variant ask/bid is not exposed on the PDP (StockX hydrates it client-side via a separate XHR). Use the shallow listing's product-level `lowestAsk` / `highestBid` for pricing.

### 💵 Pricing — Pay Per Event

This actor uses the **Pay Per Event** pricing model. You only pay for what you extract.

| Event              | When it fires                                                                                                  | Price             |
| ------------------ | -------------------------------------------------------------------------------------------------------------- | ----------------- |
| `product-listing`  | Each product returned from a search, brand, or category browse page (shallow listing with market data).        | **$2 / 1,000 results** |
| `item-detail`      | Each product enriched with PDP details — fired for every record from `productUrls` and every record when `includePdpDetails` is enabled. | **$6 / 1,000 results** |

Examples:

- `searches: ["vaporfly"]`, `maxItems: 500` → 500 × `product-listing` → **$1.00**
- `brands: ["jordan"]`, `includePdpDetails: false`, `maxItems: 1000` → 1000 × `product-listing` → **$2.00**
- `productUrls: [...50 URLs]` → 50 × `item-detail` → **$0.30**
- `searches: ["jordan"]`, `includePdpDetails: true`, `maxItems: 100` → 100 × `item-detail` → **$0.60**

Optimize your resale strategy with **StockX Listings Scraper** today! 🚀

# Actor input Schema

## `searches` (type: `array`):

Keyword queries crawled via https://stockx.com/search?s=... — each query is paginated up to the 1000-result cap (25 pages x 40).

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

Brand slugs crawled via https://stockx.com/brands/{slug} (e.g. `jordan`, `nike`, `adidas`).

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

Category slugs crawled via https://stockx.com/category/{slug} (e.g. `sneakers`, `apparel`, `accessories`, `electronics`, `collectibles`, `trading-cards`).

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

Specific StockX product pages or url-keys to scrape (e.g. `https://stockx.com/air-jordan-4-retro-toro-bravo-2026` or just `air-jordan-4-retro-toro-bravo-2026`).

## `includePdpDetails` (type: `boolean`):

After collecting browse-page results, fetch each product's PDP to add styleId, colorway, retailPrice, full size matrix, and media gallery. Significantly increases run time and cost for large crawls.

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

Stop after pushing this many records. Leave empty to crawl everything (StockX caps each browse query at 1000 results).

## Actor input object example

```json
{
  "searches": [
    "vaporfly"
  ],
  "includePdpDetails": false
}
```

# 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 = {
    "searches": [
        "vaporfly"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("piotrv1001/stockx-listings-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 = { "searches": ["vaporfly"] }

# Run the Actor and wait for it to finish
run = client.actor("piotrv1001/stockx-listings-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "searches": [
    "vaporfly"
  ]
}' |
apify call piotrv1001/stockx-listings-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=piotrv1001/stockx-listings-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/acts/1KRcuBobwyDzK9DUm/builds/zZQAnVYqrhzLu5Wth/openapi.json
