# RedNote (Xiaohongshu) Profile Posts Scraper (`toolzerhub/rednote-xiaohongshu-profile-posts-scraper`) Actor

Collect public posts published by one RedNote (Xiaohongshu) profile with automatic pagination, and optionally add full post detail to every row with one extra request per post.

- **URL**: https://apify.com/toolzerhub/rednote-xiaohongshu-profile-posts-scraper.md
- **Developed by:** [ToolzerHub](https://apify.com/toolzerhub) (community)
- **Categories:** Social media, Automation, For creators
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.20 / 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.
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 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

## RedNote (Xiaohongshu) Profile Posts Scraper

Collect the public posts published by one RedNote or Xiaohongshu profile and save each post as a structured dataset row.

### From profile to dataset

Paste a public profile URL or send the profile ID directly in **`profile_id_or_url`**. URL extraction is handled by the ToolzerHub API.

```json
{
  "profile_id_or_url": "61b46d790000000010008153",
  "maxItems": 100
}
```

**`maxItems`** defaults to `100`. The Store form is prefilled with `20`. Set it to `0` when you want the Actor to keep paginating until RedNote has no more public rows.

### Fields you can use

| Field | Contents |
|---|---|
| **`id`** | Post ID |
| **`title`**, **`display_title`** | Post title fields returned by RedNote |
| **`likes`** | Like count |
| **`comments_count`** | Comment count |
| **`collected_count`** | Save or collect count |
| **`share_count`** | Share count |
| **`type`** | Post type |
| **`create_time`** | Unix creation timestamp |
| **`user`** | Author data attached to the post |
| **`post_detail`** | Full post detail, only present when **`addonPostDetails`** is on |

```json
{
  "id": "68b39115000000001c037dad",
  "title": "Trail day 3",
  "display_title": "Trail day 3",
  "likes": 2007,
  "comments_count": 89,
  "collected_count": 115,
  "type": "video",
  "create_time": 1756598549
}
```

### Add full post detail

Set **`addonPostDetails`** to `true` and every row gets a **`post_detail`** field merged in — the same fields [RedNote Post Scraper](https://apify.com/thenetaji/rednote-post-scraper) returns for that post, fetched with one extra request per row. Image and video posts route to the matching detail endpoint automatically based on the post's own **`type`**.

```json
{
  "profile_id_or_url": "61b46d790000000010008153",
  "maxItems": 20,
  "addonPostDetails": true
}
```

This adds a charged event per enriched row, on top of the per-row result charge. If a post's detail request fails, the row is still saved without **`post_detail`** — nothing is skipped and nothing is charged for that row's enrichment.

### Pagination behavior

The Actor follows RedNote's opaque continuation cursor. It stops at your cap, an empty page, the end of the public post list, or a repeated cursor. That last guard prevents a stalled run from looping forever.

### Common questions

**Why did the run stop below `maxItems`?**

The cap limits saved rows; it can't make RedNote expose more posts. A profile with fewer public posts produces fewer rows.

**Is a cookie required for profile posts?**

No. You don't provide a login, cookie, or session token.

**Does turning on `addonPostDetails` slow the run down?**

Yes, a little — each row now costs one extra request. Leave it off if you only need the feed-level fields already listed above.

Use [RedNote Profile Scraper](https://apify.com/thenetaji/rednote-profile-scraper) for the account record itself. [RedNote Favorites Scraper](https://apify.com/thenetaji/rednote-favorites-scraper) checks publicly visible saved posts, with an important visibility limitation.

# Actor input Schema

## `profile_id_or_url` (type: `string`):

Public RedNote profile ID or full profile URL.

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

Maximum rows to save. Set 0 to keep collecting until the source is exhausted.

## `addonPostDetails` (type: `boolean`):

Fetch full post detail for every post found. This makes one extra request per post and adds a charge per enriched row.

## Actor input object example

```json
{
  "profile_id_or_url": "https://www.xiaohongshu.com/user/profile/61b46d790000000010008153",
  "maxItems": 20,
  "addonPostDetails": false
}
```

# Actor output Schema

## `dataset` (type: `string`):

Every record collected during this run

# 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 = {
    "profile_id_or_url": "https://www.xiaohongshu.com/user/profile/61b46d790000000010008153",
    "maxItems": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("toolzerhub/rednote-xiaohongshu-profile-posts-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 = {
    "profile_id_or_url": "https://www.xiaohongshu.com/user/profile/61b46d790000000010008153",
    "maxItems": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("toolzerhub/rednote-xiaohongshu-profile-posts-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 '{
  "profile_id_or_url": "https://www.xiaohongshu.com/user/profile/61b46d790000000010008153",
  "maxItems": 20
}' |
apify call toolzerhub/rednote-xiaohongshu-profile-posts-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/bUfNNA7KdWx6ba7zh/builds/DOPx2tcFY5DLJKMjP/openapi.json
