# Target Category Scraper - $0.90 / 1000 Products (`scrapeunblocker/target-category-scraper`) Actor

Scrape Target category and brand listings by id or link: every product with price, sale price, rating, promotions, image and link, sorted by featured, best selling, newest, rating or price, up to 240 products per category. No login. $0.90 per 1000 products.

- **URL**: https://apify.com/scrapeunblocker/target-category-scraper.md
- **Developed by:** [Scrapeunblocker](https://apify.com/scrapeunblocker) (community)
- **Features:** Limited permissions
- **Stats:** 3 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.90 / 1,000 results

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

## Target Category Scraper

List the products of any **Target category or brand page** as clean JSON: for every product the TCIN, title, brand, price (or price range), sale price, rating and rating count, promotions, image and link, with its position and the category name. Sort by featured, best selling, newest, guest rating or price, and collect up to 240 products per category. No Target account or API key.

### Features

- **Category id or link** - `5xtro` or `https://www.target.com/c/.../-/N-5xtro`; a brand page (`/b/<brand>/-/N-<id>`) lists that brand.
- **Sort orders** - featured, best selling, newest, guest rating, price low to high, price high to low.
- **Paging** - start at any page (1-50); 24 products per Target page, up to 240 per category.
- **Many categories per run** - processed in parallel.

### Use cases

- **Category and assortment tracking** - what Target lists in a category over time.
- **Price monitoring** across a whole category or brand.
- **Best-seller and new-arrival watching** with the sort orders.

### Input

| Field | Type | Default | Description |
|-------|------|---------|-------------|
| `categories` | array | `5xtro` (example) | Category ids or category / brand links. |
| `sort` | string | `relevance` | `relevance`, `best_selling`, `newest`, `rating`, `price_low`, `price_high`. |
| `maxResultsPerCategory` | integer | `24` | Products to keep per category (1-240). |
| `page` | integer | `1` | Page to start from (1-50). |
| `concurrency` | integer | `3` | Categories processed at the same time (1-5). |

```json
{ "categories": ["5xtro", "https://www.target.com/b/hamilton-beach/-/N-5xzpd"], "sort": "best_selling", "maxResultsPerCategory": 48 }
```

### Output

One dataset item per product:

```json
{
  "input": "5xtro",
  "categoryId": "5xtro",
  "categoryName": "Coffee & Espresso Makers",
  "position": 1,
  "tcin": "52580270",
  "title": "Hamilton Beach 12 Cup Programmable Coffee Maker Black 46290",
  "brand": "Hamilton Beach",
  "price": 27.99,
  "originalPrice": null,
  "formattedPrice": "$27.99",
  "currency": "USD",
  "rating": 4.19,
  "ratingCount": 2688,
  "promotions": [],
  "url": "https://www.target.com/p/hamilton-beach-12-cup-programmable-coffee-maker-black-46290/-/A-52580270"
}
```

The `LISTINGS` record holds each category's name, breadcrumbs, total results and pages read. Categories with no products (or that failed) are **not billed** and are listed in the `ERRORS` record.

### Pricing

**$0.90 per 1,000 products.** You pay only for products in the dataset.

### Powered by ScrapeUnblocker

The actor calls the [ScrapeUnblocker](https://www.scrapeunblocker.com) Target category plugin (`/marketplace/target-category`). For full product pages use the [Target Product Scraper](https://apify.com/scrapeunblocker/target-product-scraper).

# Actor input Schema

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

Target categories to list: the id after N- in a category link (e.g. 5xtro) or the link itself (https://www.target.com/c/.../-/N-5xtro). A brand page link (/b/<brand>/-/N-<id>) lists that brand.

## `sort` (type: `string`):

Order of the listing.

## `maxResultsPerCategory` (type: `integer`):

How many products to keep from each category (1-240). Target shows 24 per page; more products read more pages.

## `page` (type: `integer`):

Listing page to start from (1-50).

## `concurrency` (type: `integer`):

How many inputs are processed at the same time (1-5).

## Actor input object example

```json
{
  "categories": [
    "5xtro"
  ],
  "sort": "relevance",
  "maxResultsPerCategory": 24,
  "page": 1,
  "concurrency": 3
}
```

# Actor output Schema

## `results` (type: `string`):

One item per product with the category it came from and its position

## `listings` (type: `string`):

Per category: name, breadcrumbs, total results and pages read

## `errors` (type: `string`):

Inputs that returned no product (unknown id, not sold there, blocked or failed), with the reason (not billed)

# 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": [
        "5xtro"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapeunblocker/target-category-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": ["5xtro"] }

# Run the Actor and wait for it to finish
run = client.actor("scrapeunblocker/target-category-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": [
    "5xtro"
  ]
}' |
apify call scrapeunblocker/target-category-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapeunblocker/target-category-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/5wklMTuwU6IkA7dwf/builds/Uc3dF5dMpTpdUAwSe/openapi.json
