# Xiaohongshu (RedNote) Scraper — Notes, Users & Search (`sian.agency/xiaohongshu-rednote-scraper`) Actor

Xiaohongshu + RedNote (Little Red Book) scraper — note details, user profiles, full note catalogs, comments, search across notes and users. KOL discovery, engagement metrics, lifestyle trend mining for China market research. Six operations, one clean dataset per run. No API key.

- **URL**: https://apify.com/sian.agency/xiaohongshu-rednote-scraper.md
- **Developed by:** [SIÁN OÜ](https://apify.com/sian.agency) (community)
- **Categories:** Social media, E-commerce, Automation
- **Stats:** 3 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $37.50 / 1,000 note details

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

## Xiaohongshu (RedNote) Scraper — Notes, KOLs, Comments & Search 📕

[![SIÁN Agency Store](https://img.shields.io/badge/Store-SI%C3%81N%20Agency-1AE392)](https://apify.com/sian.agency?fpr=sian) [![Taobao & Tmall](https://img.shields.io/badge/SI%C3%81N-Taobao%20%26%20Tmall-FF4F00)](https://apify.com/sian.agency/taobao-tmall-product-scraper?fpr=sian) [![Kwai & Kuaishou](https://img.shields.io/badge/SI%C3%81N-Kwai%20%26%20Kuaishou-FF4906)](https://apify.com/sian.agency/kwai-kuaishou-scraper?fpr=sian) [![Instagram Transcripts](https://img.shields.io/badge/SI%C3%81N-Instagram%20Transcripts-E4405F)](https://apify.com/sian.agency/instagram-ai-transcript-extractor?fpr=sian)

#### 🎉 Six scrapers in one — extract Xiaohongshu / RedNote (Little Red Book / 小红书 / XHS) notes, profiles, comments & search results
##### Built for KOL agencies, China-market researchers, brand teams, and lifestyle / beauty / fashion / food strategists who need clean structured RedNote data — no API key, no setup, no scraping headaches

---

### 📋 Overview

**Tired of brittle DIY scrapers that break every time Xiaohongshu / RedNote ships a UI tweak?** This actor delivers reliable, flat structured datasets from China's #1 lifestyle-discovery platform (300M+ MAU) — one clean run per task, one tidy dataset out.

Whether you call it **Xiaohongshu**, **RedNote**, **Little Red Book**, **小红书**, or **XHS**, this scraper has you covered. The actor unifies six Xiaohongshu / RedNote scraping operations under one Apify actor — pick the operation, paste the input, run.

**Why teams choose SIÁN for Xiaohongshu / RedNote data:**
- ✅ **Six operations, one actor**: note detail · user profile · user note catalog · comments · search notes · search users
- ⚡ **~20 results per page** on search & user feeds — paginate to 50 pages in a single run
- 🎯 **Production-ready data shape**: curated camelCase aliases (`noteId`, `likedCount`, `collectedCount`, `userName`, `redId`, `noteTitle`, `notePageUrl`…) PLUS the raw upstream fields for power users
- 💰 **Pay-per-result pricing** — only charged for successful extractions, never for empty pages or errors
- 💎 **No API key, no setup, no proxies** — paste a note ID, user ID, or keyword and run
- ✨ **Retry-resilient**: auto-retry on transient upstream failures (which competitors silently surface as broken rows)
- 🌐 **Chinese AND English keyword search** — every other RedNote scraper documents one or the other; we handle both natively

---

### ✨ Features

- 📕 **Note Detail**: title, description, images, like/save/share/comment counts, creator info, timestamps, video info (for video notes)
- 👤 **User Profile**: fan count, follow count, note count, bio, verification badge, level, location, full avatar set, collected-content stats
- 📰 **User Notes**: full creator note catalog with engagement metrics, paginated ~20 notes/page
- 💬 **Note Comments**: top + reply comments with author, IP location, like count, plus a top-5 reply sample per thread
- 🔍 **Search Notes**: keyword search supporting Chinese, English, and mixed queries — ~20 results/page
- 🔎 **Search Users**: discover creators by keyword with handle, RedID, verification, bio — ~20 results/page
- 🖼️ **HTTPS-normalized URLs**: every cover, avatar, and image URL ready to embed
- 🔐 **xsec_token passthrough**: surfaces the per-note signed token so subsequent detail / comment calls have higher reliability on geo-sensitive notes
- 📄 **Cursor-based pagination**: stream through up to 50 pages per run with one input parameter
- 📊 **HTML run report**: saved automatically to key-value store with success rate, errors, duration, inputs

---

### 🎬 Quick Start

Paste a Xiaohongshu / RedNote keyword and run — no RedNote API or Xiaohongshu account required.

```bash
curl -X POST https://api.apify.com/v2/acts/sian.agency~xiaohongshu-rednote-scraper/runs?token=YOUR_TOKEN \
  -H "Content-Type: application/json" \
  -d '{"operation":"searchNote","keyword":"美食","maxPages":3}'
````

***

### 🚀 Getting Started (3 Simple Steps)

#### 1. Pick your operation

| Operation | Input | Output rows / page | Best for |
|---|---|---|---|
| 📕 `noteDetail` | `noteId` (24-char hex) | 1 | Deep scrape of a single note |
| 👤 `userDetail` | `userId` (24-char hex) | 1 | Full creator profile + counters |
| 📰 `userNotes` | `userId` + `maxPages` | ~20 | Creator's full note catalog |
| 💬 `noteComments` | `noteId` + `maxPages` | ~10 | Comment mining + sentiment |
| 🔍 `searchNote` | `keyword` + `maxPages` | ~20 | Discover notes in a niche |
| 🔎 `searchUser` | `keyword` + `maxPages` | ~20 | Discover creators in a niche |

#### 2. Paste your input

- **Note ID** → 24-char hex like `69ec85eb000000001e00cd6c` (find it in the RedNote URL `https://www.xiaohongshu.com/explore/{ID}`)
- **User ID** → 24-char hex like `5ee58a2e000000000100057e` (find it in the profile URL `https://www.xiaohongshu.com/user/profile/{ID}`)
- **Keyword** → any Chinese, English, or mixed query (`美食`, `outfit`, `skincare`, `穿搭`)

#### 3. Run it

Every run produces:

- 📦 A clean dataset (one row per extracted item)
- 📊 An HTML summary report (success rate, errors, duration)

***

### 💰 Pricing — Pay Per Result

Transparent per-event pricing. **You are only charged for successful extractions.** Failed pages and empty results cost nothing.

| Event | Charge |
|---|---|
| Actor run start | $0.015 (one-time) |
| 📕 Note detail result | $0.020 per row |
| 👤 User profile result | $0.020 per row |
| 📰 User notes result | $0.005 per row |
| 💬 Note comment result | $0.005 per row |
| 🔍 Search note result | $0.005 per row |
| 🔎 Search user result | $0.005 per row |

Apify Marketplace tier discounts apply automatically — Silver (10% off), Gold (50% off), Platinum & Diamond (deeper savings).

***

### 🎯 Use Cases

#### 1. KOL & Creator Discovery

Search Xiaohongshu / RedNote by keyword to surface trending creators in beauty, fashion, food, travel, parenting, or any niche. Then pull full profiles (fans, verification, level, bio) to shortlist KOLs for brand campaigns.

#### 2. China Market Entry Research

RedNote / Little Red Book is China's #1 discovery platform for Western brands targeting Gen-Z and Millennial consumers. Monitor lifestyle, beauty, fashion, food, and travel trends with daily keyword scrapes.

#### 3. Content Trend Tracking

Scrape keyword searches daily to track viral notes, emerging hashtags, and breakout creators. Combine `likedCount`, `collectedCount`, and `commentsCount` to identify which content shapes are working **right now**.

#### 4. Comment Sentiment Mining

Pull comments on any note — buyer reactions, brand feedback, community sentiment — for NLP analysis, customer-service intelligence, or competitor monitoring. The `subCommentSample` field gives you reply context in a single row.

#### 5. Creator Catalog Mapping

For any user ID, pull their complete note history with engagement metrics, titles, and posting times — ideal for KOL audit, content-strategy reverse-engineering, and influencer due diligence.

#### 6. Lifestyle Trend Intelligence

Track what's trending in beauty 💄, fashion 👗, food 🍜, travel ✈️, fitness 💪, parenting 👶 — Xiaohongshu is the canonical signal for consumer-lifestyle trends in China.

***

### 📊 Sample Output (`searchNote`)

```json
{
  "_operation": "searchNote",
  "_fetchedAt": "2026-05-12T13:20:50Z",
  "_sourceKeyword": "美食",
  "_page": 1,
  "status": "success",
  "noteId": "69ec85eb000000001e00cd6c",
  "noteTitle": "我妈尝了一口，让我原地出摊！！",
  "noteDesc": "...",
  "noteType": "normal",
  "xsecToken": "YBJwDVhExZtED4VfSbDR5egiH44n0JKZ4ODgqZapZ7YGE=",
  "noteCoverUrl": "https://sns-webpic-qc.xhscdn.com/...",
  "noteImageUrls": ["https://sns-webpic-qc.xhscdn.com/..."],
  "likedCount": 4231,
  "collectedCount": 892,
  "commentsCount": 167,
  "sharedCount": 23,
  "userId": "5ee58a2e000000000100057e",
  "userName": "香香的美食",
  "userRedId": "257152115",
  "userVerified": false,
  "userAvatarUrl": "https://sns-avatar-qc.xhscdn.com/...",
  "postedAt": 1729184563,
  "notePageUrl": "https://www.xiaohongshu.com/explore/69ec85eb000000001e00cd6c?xsec_token=..."
}
```

***

### 🆚 Why This Scraper

| | This actor | Most competitors |
|---|---|---|
| Operations bundled | 6 (notes, users, comments, search) | 1 per actor — costs 6× more |
| Pricing model | Per-result (only successful rows) | Often per-dataset-item (charges errors too) |
| Chinese keyword support | ✅ Native | ⚠️ Often documented only with English seeds |
| Retry on transient upstream failures | ✅ Auto with backoff | ❌ Surfaces broken rows |
| `xsec_token` passthrough | ✅ | ❌ |
| Curated camelCase + raw fields | ✅ Both | ⚠️ Usually one or the other |
| `subCommentSample` (replies in one row) | ✅ | ❌ Requires second fetch |

***

### ❓ FAQ

**Q: Do I need an Xiaohongshu / RedNote account?**
A: No. The actor handles authentication on the backend. Paste a note ID, user ID, or keyword and run.

**Q: Is this affiliated with Xiaohongshu / RedNote?**
A: No. This is an independent third-party scraping tool. See trademark disclaimer below.

**Q: What's the difference between Xiaohongshu, RedNote, and Little Red Book?**
A: All three names refer to the same platform (小红书 / XHS). "Xiaohongshu" is the original Chinese name; "RedNote" is the international app rebrand; "Little Red Book" is the direct English translation.

**Q: Where do I get a `noteId` or `userId`?**
A: From any RedNote URL — `https://www.xiaohongshu.com/explore/{noteId}` or `https://www.xiaohongshu.com/user/profile/{userId}`. Both IDs are 24-character hex strings. You can also harvest them from any `searchNote` / `searchUser` run.

**Q: How many notes can I scrape per run?**
A: Paginated operations (`userNotes`, `noteComments`, `searchNote`, `searchUser`) support up to **50 pages** per run, ~20 rows/page → up to ~1,000 rows.

**Q: What if a note is private or deleted?**
A: The actor returns an `error` row with a human-readable `errorMessage`. You are never charged for error rows.

**Q: Does it support Xiaohongshu video notes?**
A: Yes. Video notes are returned with a `videoInfo` field plus all the normal note metadata. Use `noteType` (`normal` | `video` | `multi`) to filter.

***

### ✨ Other SIÁN Agency Actors

- 🛍️ [Taobao & Tmall Product Scraper](https://apify.com/sian.agency/taobao-tmall-product-scraper?fpr=sian) — China e-commerce product data
- 🎥 [Kwai & Kuaishou Scraper](https://apify.com/sian.agency/kwai-kuaishou-scraper?fpr=sian) — China short-video scraper & KOL data
- 🎬 [Best TikTok AI Transcript Extractor](https://apify.com/sian.agency/best-tiktok-ai-transcript-extractor?fpr=sian) — short-video transcripts
- 📸 [Instagram AI Transcript Extractor](https://apify.com/sian.agency/instagram-ai-transcript-extractor?fpr=sian) — Reels & Stories transcription
- 🏠 [Smart Idealista Scraper](https://apify.com/sian.agency/smart-idealista-scraper?fpr=sian) — Spain real estate intelligence
- 🌐 [Browse all SIÁN actors →](https://apify.com/sian.agency?fpr=sian)

***

### 📞 Support

- 🐛 **Bug reports & feature requests:** Apify Console → Issues tab
- 📧 **Email:** ventures.sian@gmail.com
- ⭐ **Loving this actor?** [Leave a 5-star review](https://apify.com/sian.agency/xiaohongshu-rednote-scraper/reviews) — it helps us build more features.
- 💬 **Telegram:** [![Telegram](https://img.shields.io/badge/Telegram-Contact-26A5E4)](https://t.me/sianagency)

***

### ⚠️ Trademark Disclaimer

This is an **independent scraping tool**. It is **not affiliated with, endorsed by, or sponsored by** Xingyin Information Technology (Shanghai) Co., Ltd. or any of its affiliates. The **Xiaohongshu®**, **RedNote®**, **Little Red Book®**, and **小红书®** trademarks are the property of their respective owners and appear here under nominative fair use solely to identify the source platform that this tool helps you collect publicly available data from.

This tool extracts only publicly available data. Users are responsible for complying with applicable laws, the platform's terms of service, and the privacy rights of individuals whose public posts they collect. SIÁN Agency does not store, resell, or redistribute scraped content.

***

### ⚖️ Legal

This scraper is provided as-is, under the Apache 2.0 license. By using it, you agree to:

- Use the data for lawful purposes only.
- Comply with the **GDPR** and any other applicable data-protection laws when collecting data on EU residents.
- Comply with Xiaohongshu / RedNote's terms of service.
- Take responsibility for your downstream use of the collected data.

Read [Apify's guide to ethical web scraping](https://blog.apify.com/is-web-scraping-legal/) for context on what constitutes lawful scraping.

***

# Actor input Schema

## `operation` (type: `string`):

🎯 **PICK ONE OPERATION PER RUN.** Each run produces one clean dataset matching the chosen mode.

- **📕 Note Detail** — deep scrape of a single note by ID (title, description, images, like/save/share/comment counts, creator info, timestamps)
- **👤 User Profile** — full profile by user ID (fan count, follow count, note count, bio, verification, level, location, avatar)
- **📰 User Notes** — paginated list of a creator's full note history (~20 notes/page)
- **💬 Note Comments** — paginated comments on a single note, with reply samples (~10 comments/page)
- **🔍 Search Notes** — keyword search across Xiaohongshu / RedNote notes, paginated (~20 results/page)
- **🔎 Search Users** — keyword search across Xiaohongshu / RedNote creators, paginated (~20 results/page)

💡 **TIP:** To combine operations, run the actor multiple times with different configurations.

## `noteId` (type: `string`):

📕 **Required for `Note Detail` and `Note Comments` operations.**

The 24-character hex Xiaohongshu / RedNote note ID. You can find it:

- In any RedNote / Xiaohongshu note URL: `https://www.xiaohongshu.com/explore/{ID}` → the trailing path segment
- In the `noteId` / `id` field of any search or user-notes result row

💡 **TIP:** To analyze a batch of notes, run a `Search Notes` operation first, copy the `noteId` from the result rows, then run `Note Detail` per ID.

⚠️ **Ignored** for User Profile, User Notes, and Search operations.

## `xsecToken` (type: `string`):

🔐 **Optional.** A short-lived signed token attached to public notes — surfaced as `xsecToken` in any search or user-notes result row.

Provide it if you have it (improves reliability on geo-restricted or sensitive notes); leave blank otherwise.

## `userId` (type: `string`):

👤 **Required for `User Profile` and `User Notes` operations.**

The 24-character hex Xiaohongshu / RedNote user ID (not the human-readable `red_id`). You can find it:

- In the `userId` / `userid` field of any note, search, or comment result row
- In a creator's profile URL: `https://www.xiaohongshu.com/user/profile/{ID}`

💡 **TIP:** To build a list of creators in a niche, run `Search Users` with a keyword first, then use the top `userId` values to drill into individual profiles or note catalogs.

⚠️ **Ignored** for Note Detail, Note Comments, and Search operations.

## `keyword` (type: `string`):

🔍 **Required for `Search Notes` and `Search Users` operations.**

Any Xiaohongshu / RedNote search query. Supports Chinese, English, and mixed queries:

- `美食` (food)
- `穿搭` (outfit)
- `skincare`
- `makeup tutorial`
- `travel tips`

💡 **TIP:** Specific niches return higher-relevance results. Chinese-language queries surface more native creators; English queries surface international RedNote / Little Red Book content.

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

📄 **Applies to paginated operations** (User Notes, Note Comments, Search Notes, Search Users). Ignored for single-record operations (Note Detail, User Profile).

- **User Notes:** ~20 notes per page
- **Note Comments:** ~10 comments per page
- **Search Notes:** ~20 results per page
- **Search Users:** ~20 results per page

💡 **TIP:** Start small (1–3 pages) to preview results before scaling up.

⚠️ Hard cap: 50 pages to prevent runaway runs.

## Actor input object example

```json
{
  "operation": "searchNote",
  "noteId": "69ec85eb000000001e00cd6c",
  "xsecToken": "YBJwDVhExZtED4VfSbDR5egiH44n0JKZ4ODgqZapZ7YGE=",
  "userId": "5ee58a2e000000000100057e",
  "keyword": "美食",
  "maxPages": 5
}
```

# Actor output Schema

## `output` (type: `string`):

Notes, profiles, comments, or search results — one flat row per upstream item with curated camelCase aliases (noteId, userId, likedCount, collectedCount, noteTitle, noteDesc, noteCoverUrl, userName, redId, postedAt, notePageUrl, userPageUrl, …) plus the raw upstream fields spread alongside.

## `report` (type: `string`):

HTML report with run status, success/error row counts, success rate, pages fetched, duration, and the inputs used — written even on fatal crash.

# 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 = {
    "noteId": "69ec85eb000000001e00cd6c",
    "userId": "5ee58a2e000000000100057e",
    "keyword": "美食"
};

// Run the Actor and wait for it to finish
const run = await client.actor("sian.agency/xiaohongshu-rednote-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 = {
    "noteId": "69ec85eb000000001e00cd6c",
    "userId": "5ee58a2e000000000100057e",
    "keyword": "美食",
}

# Run the Actor and wait for it to finish
run = client.actor("sian.agency/xiaohongshu-rednote-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 '{
  "noteId": "69ec85eb000000001e00cd6c",
  "userId": "5ee58a2e000000000100057e",
  "keyword": "美食"
}' |
apify call sian.agency/xiaohongshu-rednote-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Xiaohongshu (RedNote) Scraper — Notes, Users & Search",
        "description": "Xiaohongshu + RedNote (Little Red Book) scraper — note details, user profiles, full note catalogs, comments, search across notes and users. KOL discovery, engagement metrics, lifestyle trend mining for China market research. Six operations, one clean dataset per run. No API key.",
        "version": "1.0",
        "x-build-id": "R8fkcWmPCHJb7801h"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/sian.agency~xiaohongshu-rednote-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-sian.agency-xiaohongshu-rednote-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/sian.agency~xiaohongshu-rednote-scraper/runs": {
            "post": {
                "operationId": "runs-sync-sian.agency-xiaohongshu-rednote-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/sian.agency~xiaohongshu-rednote-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-sian.agency-xiaohongshu-rednote-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "operation"
                ],
                "properties": {
                    "operation": {
                        "title": "🎯 Operation — what do you want to scrape?",
                        "enum": [
                            "noteDetail",
                            "userDetail",
                            "userNotes",
                            "noteComments",
                            "searchNote",
                            "searchUser"
                        ],
                        "type": "string",
                        "description": "🎯 **PICK ONE OPERATION PER RUN.** Each run produces one clean dataset matching the chosen mode.\n\n- **📕 Note Detail** — deep scrape of a single note by ID (title, description, images, like/save/share/comment counts, creator info, timestamps)\n- **👤 User Profile** — full profile by user ID (fan count, follow count, note count, bio, verification, level, location, avatar)\n- **📰 User Notes** — paginated list of a creator's full note history (~20 notes/page)\n- **💬 Note Comments** — paginated comments on a single note, with reply samples (~10 comments/page)\n- **🔍 Search Notes** — keyword search across Xiaohongshu / RedNote notes, paginated (~20 results/page)\n- **🔎 Search Users** — keyword search across Xiaohongshu / RedNote creators, paginated (~20 results/page)\n\n💡 **TIP:** To combine operations, run the actor multiple times with different configurations.",
                        "default": "searchNote"
                    },
                    "noteId": {
                        "title": "📕 Note ID (for Note Detail / Note Comments)",
                        "type": "string",
                        "description": "📕 **Required for `Note Detail` and `Note Comments` operations.**\n\nThe 24-character hex Xiaohongshu / RedNote note ID. You can find it:\n- In any RedNote / Xiaohongshu note URL: `https://www.xiaohongshu.com/explore/{ID}` → the trailing path segment\n- In the `noteId` / `id` field of any search or user-notes result row\n\n💡 **TIP:** To analyze a batch of notes, run a `Search Notes` operation first, copy the `noteId` from the result rows, then run `Note Detail` per ID.\n\n⚠️ **Ignored** for User Profile, User Notes, and Search operations."
                    },
                    "xsecToken": {
                        "title": "🔐 xsec_token (optional — for Note Detail / Note Comments)",
                        "type": "string",
                        "description": "🔐 **Optional.** A short-lived signed token attached to public notes — surfaced as `xsecToken` in any search or user-notes result row.\n\nProvide it if you have it (improves reliability on geo-restricted or sensitive notes); leave blank otherwise."
                    },
                    "userId": {
                        "title": "👤 User ID (for User Profile / User Notes)",
                        "type": "string",
                        "description": "👤 **Required for `User Profile` and `User Notes` operations.**\n\nThe 24-character hex Xiaohongshu / RedNote user ID (not the human-readable `red_id`). You can find it:\n- In the `userId` / `userid` field of any note, search, or comment result row\n- In a creator's profile URL: `https://www.xiaohongshu.com/user/profile/{ID}`\n\n💡 **TIP:** To build a list of creators in a niche, run `Search Users` with a keyword first, then use the top `userId` values to drill into individual profiles or note catalogs.\n\n⚠️ **Ignored** for Note Detail, Note Comments, and Search operations."
                    },
                    "keyword": {
                        "title": "🔍 Search Keyword (for Search Notes / Search Users)",
                        "type": "string",
                        "description": "🔍 **Required for `Search Notes` and `Search Users` operations.**\n\nAny Xiaohongshu / RedNote search query. Supports Chinese, English, and mixed queries:\n- `美食` (food)\n- `穿搭` (outfit)\n- `skincare`\n- `makeup tutorial`\n- `travel tips`\n\n💡 **TIP:** Specific niches return higher-relevance results. Chinese-language queries surface more native creators; English queries surface international RedNote / Little Red Book content."
                    },
                    "maxPages": {
                        "title": "📄 Max pages to fetch",
                        "minimum": 1,
                        "maximum": 50,
                        "type": "integer",
                        "description": "📄 **Applies to paginated operations** (User Notes, Note Comments, Search Notes, Search Users). Ignored for single-record operations (Note Detail, User Profile).\n\n- **User Notes:** ~20 notes per page\n- **Note Comments:** ~10 comments per page\n- **Search Notes:** ~20 results per page\n- **Search Users:** ~20 results per page\n\n💡 **TIP:** Start small (1–3 pages) to preview results before scaling up.\n\n⚠️ Hard cap: 50 pages to prevent runaway runs.",
                        "default": 5
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
