# RedNote Note Detail Scraper (`maximedupre/rednote-note-detail-scraper`) Actor

Scrape public RedNote/Xiaohongshu note details from share links, full note URLs, or copied share text. Export titles, authors, engagement, tags, timestamps, images, video streams, subtitles, and optional media files.

- **URL**: https://apify.com/maximedupre/rednote-note-detail-scraper.md
- **Developed by:** [Maxime Dupré](https://apify.com/maximedupre) (community)
- **Categories:** Social media, Videos
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $7.15 / 1,000 scraped notes

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

### 🔎 RedNote note detail scraper for Xiaohongshu links

RedNote Note Detail Scraper exports public note details from [RedNote / Xiaohongshu](https://www.xiaohongshu.com/). Paste `xhslink.com` share links, full Xiaohongshu note URLs, or copied share text, then get one clean dataset row per public note with title, description, author, engagement counts, tags, timestamps, image URLs, video streams, subtitles, source links, and optional saved media files.

Use this RedNote note detail scraper when you already have note links and need structured Xiaohongshu data for creator research, content review, campaign tracking, social listening, China market research, or an API workflow. The easiest first run is the prefilled `xhslink.com` share links with all download options off. Share links and full note URLs usually include the source token RedNote uses to open rich note detail.

The Actor works with public note pages. It does not ask for RedNote cookies, a RedNote account, a QR login, or an API key. Invalid, expired, removed, private, blocked, or tokenless targets are skipped with clear logs instead of creating placeholder rows.

### ✅ What this Actor does

- Scrapes public RedNote / Xiaohongshu note detail pages.
- Accepts `xhslink.com` share links.
- Accepts full `xiaohongshu.com/discovery/item/...` and `xiaohongshu.com/explore/...` note URLs when they carry usable source context.
- Accepts copied app share text that contains a supported note link.
- Saves one dataset row per successfully scraped public note.
- Extracts note text, author fields, engagement counts, tags, mentions, location, timestamps, source URLs, and scrape time.
- Extracts image gallery URLs with dimensions when RedNote exposes them.
- Extracts video stream and subtitle metadata when the source note includes it.
- Can optionally save video files, cover images, gallery images, and subtitles to Apify key-value storage.
- Runs without user-provided cookies, login, or RedNote API keys.

This Actor is focused on known note targets. It does not search RedNote, scrape profiles, scrape user post catalogs, collect comments or replies, record live streams, scrape private notes, or discover notes from keywords.

### 📦 Data you can export

Each output row represents one public RedNote note detail. Core fields include:

- `sourceInput`, `inputIndex`, and `inputType` - the submitted target, row number, and target kind.
- `resolvedUrl`, `canonicalUrl`, `noteId`, and `xsecToken` - source links and note identifiers.
- `noteType`, `title`, and `description`.
- `author.userId`, `author.nickname`, `author.avatarUrl`, `author.xsecToken`, and `author.profileUrl`.
- `engagement.likedCount`, `engagement.collectedCount`, `engagement.commentCount`, and `engagement.shareCount`, plus source count text.
- `publishedAt`, `publishedAtTimestamp`, `updatedAt`, and `updatedAtTimestamp`.
- `ipLocation`, `tags`, `atUserList`, and `aiGeneratedFlag`.
- `images` with image URLs, preview URLs, dimensions, live-photo flags, and source image scenes.
- `video` with video URLs, duration, dimensions, streams, codecs, qualities, backup URLs, and subtitles when available.
- `mediaCounts`, `scrapedAt`, and `status`.
- `imageFiles`, `videoFile`, `coverFile`, and `subtitleFiles` when media download options are enabled and files are saved.

You can open the dataset in Apify, export it as JSON, CSV, Excel, XML, RSS, or HTML, call it through the Apify API, schedule repeat runs, or send results to webhooks and integrations.

### 🚀 How to run it

1. Open the Input tab.
2. Add one RedNote or Xiaohongshu note target per line in `RedNote notes`.
3. Use an `xhslink.com` share link when possible, or paste the full note URL copied from RedNote.
4. Keep `Note limit` at `23` for a small first run, or raise it up to `100` for a larger batch.
5. Leave media downloads off when direct media URLs are enough.
6. Turn on video, cover, image, or subtitle downloads only when you need saved files in Apify storage.
7. Run the Actor and open the dataset, or pull the rows through the Apify API.

### 🛠️ Input

#### 🧪 Example input

```json
{
	"targets": [
		"http://xhslink.com/o/6oKW7wkJf09"
	],
	"maxNotes": 23,
	"downloadVideos": false,
	"downloadCovers": false,
	"downloadImages": false,
	"downloadSubtitles": false
}
````

#### 🎯 RedNote notes

Add one note target per line. Supported target forms:

- `http://xhslink.com/o/6oKW7wkJf09`
- `https://www.xiaohongshu.com/discovery/item/6a06c9360000000036001d5a?xsec_token=...`
- `https://www.xiaohongshu.com/explore/6a06c9360000000036001d5a?xsec_token=...`
- copied share text that contains one supported link

Share links are the safest choice for a first run because they usually include the token RedNote requires for rich note detail. Bare note IDs are not a reliable public input on their own.

#### 🔢 Note limit

Set how many submitted targets to process in one run. The default is `23`, and the public maximum is `100`.

#### 💾 Media files

Leave all media download options off when direct source URLs are enough. Turn them on when you need files saved to Apify key-value storage:

- `downloadVideos` saves video files when a note exposes a video URL.
- `downloadCovers` saves the first available cover image.
- `downloadImages` saves gallery images.
- `downloadSubtitles` saves subtitle tracks when a video note includes them.
- `mediaKvStoreName` lets you choose a key-value store name. Leave it blank to use the run's default store.

### 📊 Output example

```json
{
	"sourceInput": "http://xhslink.com/o/6oKW7wkJf09",
	"inputIndex": 0,
	"inputType": "shareLink",
	"sourcePlatform": "rednote",
	"resolvedUrl": "https://www.xiaohongshu.com/discovery/item/6a06c9360000000036001d5a?xsec_token=...",
	"canonicalUrl": "https://www.xiaohongshu.com/discovery/item/6a06c9360000000036001d5a?xsec_token=...",
	"noteId": "6a06c9360000000036001d5a",
	"xsecToken": "CBMGWfsLhSw2M1wEoqMFHysjfF-fV_7lWjNwhVjRiLZNU=",
	"noteType": "normal",
	"title": "审美积累｜💪 勇敢、自由、有力量",
	"description": "Public note text from RedNote...",
	"author": {
		"userId": "5c0892a5000000000500f3b6",
		"nickname": "艺文搭搭",
		"avatarUrl": "https://sns-avatar-qc.xhscdn.com/avatar/...",
		"profileUrl": "https://www.xiaohongshu.com/user/profile/5c0892a5000000000500f3b6?xsec_token=..."
	},
	"engagement": {
		"likedCount": 2293,
		"collectedCount": 394,
		"commentCount": 24,
		"shareCount": 92
	},
	"publishedAt": "2026-05-15T07:20:22.000Z",
	"updatedAt": "2026-05-15T07:20:23.000Z",
	"ipLocation": "福建",
	"tags": [
		{
			"id": "5f7f2936000000000101d891",
			"name": "审美累积",
			"type": "topic"
		}
	],
	"images": [
		{
			"index": 0,
			"url": "http://sns-webpic-qc.xhscdn.com/...",
			"previewUrl": "http://sns-webpic-qc.xhscdn.com/...",
			"width": 1080,
			"height": 1417,
			"livePhoto": false
		}
	],
	"video": null,
	"mediaCounts": {
		"images": 10,
		"videoStreams": 0,
		"subtitles": 0
	},
	"aiGeneratedFlag": true,
	"scrapedAt": "2026-06-11T15:00:00.000Z",
	"status": "scraped"
}
```

Some fields can be `null` when RedNote does not show them on the public note page.

### 💳 Pricing

This Actor uses pay-per-event pricing. You are charged only for successfully saved note details, using the primary event `note-detail-scraped`. There is no Actor-start charge and no separate Actor-owned charge for optional media downloads.

Current note-detail prices:

| Apify tier | Price per note | Price per 1,000 notes |
| ---------- | -------------- | --------------------- |
| Free | `$0.00895` | `$8.95` |
| Bronze | `$0.00805` | `$8.05` |
| Silver | `$0.00790` | `$7.90` |
| Gold | `$0.00715` | `$7.15` |
| Platinum | `$0.00715` | `$7.15` |
| Diamond | `$0.00715` | `$7.15` |

Apify platform usage and storage costs may still apply to the run, especially when you download media files.

### ⚠️ Limits and caveats

- Public share links and token-bearing note URLs work best.
- Bare note IDs are not a reliable public input on their own.
- Expired share links, removed notes, private notes, blocked notes, and tokenless targets may produce no dataset row.
- Media URLs and media file downloads depend on what RedNote exposes for the note at run time.
- Subtitle fields appear only when the source video note includes subtitle data.
- Comments and replies are not part of this Actor. Use a comments-specific workflow if you need comment rows.
- Public source pages can change. If a target stops working, file a ticket with the note target and run ID.

### ❓ FAQ

#### 🔑 Do I need RedNote cookies or an account?

No. The Actor is built for public note links and does not ask for RedNote cookies, a RedNote login, a QR code, or a private API key.

#### 🔗 Why are share links recommended?

RedNote share links usually include the source token needed to open full note detail. A full Xiaohongshu note URL can also work when it contains the same usable context. A bare note ID often does not carry enough public context.

#### 💬 Does this scrape comments?

No. This Actor returns one note-detail row per public note. It includes the visible comment count when RedNote exposes it, but it does not scrape comment text, replies, or comment authors.

#### 📁 Are downloaded media files included in the dataset?

The dataset includes file metadata and storage URLs when a media download option is enabled and the file is saved. The binary files are stored in the selected Apify key-value store.

### 📝 Changelog

- 0.1: Initial release.

### 🆘 Support

For issues, questions, or feature requests, [file a ticket](https://console.apify.com/actors/maximedupre~rednote-note-detail-scraper/issues) and I'll fix or implement it in less than 24h 🫡

### 🔗 Other actors

- [RedNote Profile Scraper ↗](https://apify.com/maximedupre/rednote-profile-scraper) - Export public Xiaohongshu profile data, follower metrics, bios, avatars, and tags.
- [RedNote User Posts Scraper ↗](https://apify.com/maximedupre/rednote-user-posts-scraper) - Export public post cards from RedNote profile pages.
- [Pinterest Video Downloader ↗](https://apify.com/maximedupre/pinterest-video-downloader) - Extract public Pinterest video and image URLs with pin metadata.
- [TikTok Video Downloader ↗](https://apify.com/maximedupre/tiktok-video-downloader) - Save public TikTok video or audio files with source metadata.
- [TikTok Transcript Scraper ↗](https://apify.com/maximedupre/tiktok-transcript-scraper) - Export public TikTok captions and timed transcript segments.

**Made with ❤️ by Maxime Dupré**

# Actor input Schema

## `targets` (type: `array`):

Add one note per line. Use an `xhslink.com` share link, a full RedNote/Xiaohongshu note URL, or copied share text.

## `maxNotes` (type: `integer`):

Maximum notes to save from the target list. Keep this low for a small first run.

## `downloadVideos` (type: `boolean`):

Save each video note's MP4 file to the run key-value store when a video URL is available.

## `downloadCovers` (type: `boolean`):

Save each video note's cover image as a file.

## `downloadImages` (type: `boolean`):

Save image-note gallery images as files.

## `downloadSubtitles` (type: `boolean`):

Save subtitle tracks as files when a video note includes them.

## `mediaKvStoreName` (type: `string`):

Optional key-value store name for downloaded media files. Leave blank to use the run's default store.

## Actor input object example

```json
{
  "targets": [
    "https://www.xiaohongshu.com/discovery/item/643552d20000000014027d75?xsec_token=AB8lnDuoqkSPI_vrrTYJPAh9_Mixg6YTx-iZao0xQmuus%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64605e6b0000000013007da2?xsec_token=ABPvi0oh9iU51HRVhTWlzjIp5GTqa_NcEyWqvYrKjPMAI%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/63e99375000000001303ea1f?xsec_token=ABYEbTl9m40eVQ0iOsKM2OEWh3StnxMAmrA0xc2MZHjgM%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/63f0a0fc0000000013035d20?xsec_token=ABXJJ2635KTF205D1uFVKM153-OLxnSz5wuYSIin7ZLeY%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64a64092000000001a0131df?xsec_token=ABHw9Fxfoe2IWxSSeFXFmaxRQxN0zHjpwezI86rccOFLc%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/646dae23000000000800edbc?xsec_token=ABbZaL9LdDJMsZ8VF00w7995x9gRFZTiXywwhEwfPcWys%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64c4d5c6000000001701bcee?xsec_token=ABNkvUjLh_aMt5M2Rq8xPesqYQmCXQPsxBJyNWJgeNYto%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6421815e0000000012031421?xsec_token=ABBv0YOV672wLx_a2Ka-Vi23T0UnOzjvV-iBnFoGq6vnk%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/647eef06000000000703a18c?xsec_token=ABk6FPauX9H1YOf-yVxln8XmzsiGmohd2eUOYipgWyNNw%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64bcd3ee000000000c0357dd?xsec_token=ABaXusImtsM-iMJ1OzSpzRhzMGmE0KFYkbxFkpUNm85rc%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6458314c000000001303682d?xsec_token=AB9rVcowaP4fPljDopxuzJvjJWIS1EciD_HOEguDt6QZE%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/63ff2a3b0000000013035918?xsec_token=ABulzGrH2Y3uWgfql9j6LDHWvmdOHoWZQRRFPHOUHYbWg%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/640607380000000013006cc5?xsec_token=ABqE-_T7Q69uM7rgbYueogbFI_9y6lJSBhSkr8DfEVJCQ%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6409ca5b0000000011011506?xsec_token=ABWUNJIYkJFsMbLJ4sNQcaxe6QewTTmUHbu22qP0rd2Ag%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/646caae400000000120316e5?xsec_token=ABeNSXYxrgqmZ9qNY1tqSh1FdTbReFmgubq5GYt6hc3BI%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64564b9e0000000014024aa1?xsec_token=ABfmENQeSFCwtgHcuVxcapfQCcQK3W2SA_BkM-KBzX3KU%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6447282d000000000703bc87?xsec_token=ABC5WkgTW12fCdB4aYixakmZMgI9JYFVNA_m9CVG0aqYQ%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64067e320000000014025f54?xsec_token=ABqE-_T7Q69uM7rgbYueogbIaR2C_vVLeDo0MC8b5Mtkg%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/640fedb00000000012032415?xsec_token=ABFc9WNg7DpZfwqmzVJOuVNBQmpYV4T25olL2CTKwNQ_g%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64c78745000000000c036e09?xsec_token=ABrqOF6N7JN_nLBdKP_9qhSh6V6O9bffRMsLrr9F2WECM%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64b949d9000000001201b9f5?xsec_token=ABXf8zAOzKGymyrBCNhejgDKLATbTKV0zyL3J297H2FiU%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/644e48da000000000800fa3a?xsec_token=ABo1xRFmXyX08eZHvupYbFxRcmPkYhAmVJSQYRL6IKV9o%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6428c5f90000000013009c10?xsec_token=ABDONnntgLXZ3BJzA5CJnxRg0Ab-GUtggRtIK-vMPAR7s%3D&xsec_source=pc_feed"
  ],
  "maxNotes": 23,
  "downloadVideos": false,
  "downloadCovers": false,
  "downloadImages": false,
  "downloadSubtitles": false
}
```

# Actor output Schema

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

Open the dataset with note text, author fields, engagement counts, tags, timestamps, image URLs, video streams, subtitles, source links, and optional saved media file metadata.

# 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 = {
    "targets": [
        "https://www.xiaohongshu.com/discovery/item/643552d20000000014027d75?xsec_token=AB8lnDuoqkSPI_vrrTYJPAh9_Mixg6YTx-iZao0xQmuus%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64605e6b0000000013007da2?xsec_token=ABPvi0oh9iU51HRVhTWlzjIp5GTqa_NcEyWqvYrKjPMAI%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/63e99375000000001303ea1f?xsec_token=ABYEbTl9m40eVQ0iOsKM2OEWh3StnxMAmrA0xc2MZHjgM%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/63f0a0fc0000000013035d20?xsec_token=ABXJJ2635KTF205D1uFVKM153-OLxnSz5wuYSIin7ZLeY%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64a64092000000001a0131df?xsec_token=ABHw9Fxfoe2IWxSSeFXFmaxRQxN0zHjpwezI86rccOFLc%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/646dae23000000000800edbc?xsec_token=ABbZaL9LdDJMsZ8VF00w7995x9gRFZTiXywwhEwfPcWys%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64c4d5c6000000001701bcee?xsec_token=ABNkvUjLh_aMt5M2Rq8xPesqYQmCXQPsxBJyNWJgeNYto%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6421815e0000000012031421?xsec_token=ABBv0YOV672wLx_a2Ka-Vi23T0UnOzjvV-iBnFoGq6vnk%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/647eef06000000000703a18c?xsec_token=ABk6FPauX9H1YOf-yVxln8XmzsiGmohd2eUOYipgWyNNw%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64bcd3ee000000000c0357dd?xsec_token=ABaXusImtsM-iMJ1OzSpzRhzMGmE0KFYkbxFkpUNm85rc%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6458314c000000001303682d?xsec_token=AB9rVcowaP4fPljDopxuzJvjJWIS1EciD_HOEguDt6QZE%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/63ff2a3b0000000013035918?xsec_token=ABulzGrH2Y3uWgfql9j6LDHWvmdOHoWZQRRFPHOUHYbWg%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/640607380000000013006cc5?xsec_token=ABqE-_T7Q69uM7rgbYueogbFI_9y6lJSBhSkr8DfEVJCQ%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6409ca5b0000000011011506?xsec_token=ABWUNJIYkJFsMbLJ4sNQcaxe6QewTTmUHbu22qP0rd2Ag%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/646caae400000000120316e5?xsec_token=ABeNSXYxrgqmZ9qNY1tqSh1FdTbReFmgubq5GYt6hc3BI%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64564b9e0000000014024aa1?xsec_token=ABfmENQeSFCwtgHcuVxcapfQCcQK3W2SA_BkM-KBzX3KU%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6447282d000000000703bc87?xsec_token=ABC5WkgTW12fCdB4aYixakmZMgI9JYFVNA_m9CVG0aqYQ%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64067e320000000014025f54?xsec_token=ABqE-_T7Q69uM7rgbYueogbIaR2C_vVLeDo0MC8b5Mtkg%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/640fedb00000000012032415?xsec_token=ABFc9WNg7DpZfwqmzVJOuVNBQmpYV4T25olL2CTKwNQ_g%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64c78745000000000c036e09?xsec_token=ABrqOF6N7JN_nLBdKP_9qhSh6V6O9bffRMsLrr9F2WECM%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64b949d9000000001201b9f5?xsec_token=ABXf8zAOzKGymyrBCNhejgDKLATbTKV0zyL3J297H2FiU%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/644e48da000000000800fa3a?xsec_token=ABo1xRFmXyX08eZHvupYbFxRcmPkYhAmVJSQYRL6IKV9o%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6428c5f90000000013009c10?xsec_token=ABDONnntgLXZ3BJzA5CJnxRg0Ab-GUtggRtIK-vMPAR7s%3D&xsec_source=pc_feed"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("maximedupre/rednote-note-detail-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 = { "targets": [
        "https://www.xiaohongshu.com/discovery/item/643552d20000000014027d75?xsec_token=AB8lnDuoqkSPI_vrrTYJPAh9_Mixg6YTx-iZao0xQmuus%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64605e6b0000000013007da2?xsec_token=ABPvi0oh9iU51HRVhTWlzjIp5GTqa_NcEyWqvYrKjPMAI%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/63e99375000000001303ea1f?xsec_token=ABYEbTl9m40eVQ0iOsKM2OEWh3StnxMAmrA0xc2MZHjgM%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/63f0a0fc0000000013035d20?xsec_token=ABXJJ2635KTF205D1uFVKM153-OLxnSz5wuYSIin7ZLeY%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64a64092000000001a0131df?xsec_token=ABHw9Fxfoe2IWxSSeFXFmaxRQxN0zHjpwezI86rccOFLc%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/646dae23000000000800edbc?xsec_token=ABbZaL9LdDJMsZ8VF00w7995x9gRFZTiXywwhEwfPcWys%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64c4d5c6000000001701bcee?xsec_token=ABNkvUjLh_aMt5M2Rq8xPesqYQmCXQPsxBJyNWJgeNYto%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6421815e0000000012031421?xsec_token=ABBv0YOV672wLx_a2Ka-Vi23T0UnOzjvV-iBnFoGq6vnk%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/647eef06000000000703a18c?xsec_token=ABk6FPauX9H1YOf-yVxln8XmzsiGmohd2eUOYipgWyNNw%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64bcd3ee000000000c0357dd?xsec_token=ABaXusImtsM-iMJ1OzSpzRhzMGmE0KFYkbxFkpUNm85rc%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6458314c000000001303682d?xsec_token=AB9rVcowaP4fPljDopxuzJvjJWIS1EciD_HOEguDt6QZE%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/63ff2a3b0000000013035918?xsec_token=ABulzGrH2Y3uWgfql9j6LDHWvmdOHoWZQRRFPHOUHYbWg%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/640607380000000013006cc5?xsec_token=ABqE-_T7Q69uM7rgbYueogbFI_9y6lJSBhSkr8DfEVJCQ%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6409ca5b0000000011011506?xsec_token=ABWUNJIYkJFsMbLJ4sNQcaxe6QewTTmUHbu22qP0rd2Ag%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/646caae400000000120316e5?xsec_token=ABeNSXYxrgqmZ9qNY1tqSh1FdTbReFmgubq5GYt6hc3BI%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64564b9e0000000014024aa1?xsec_token=ABfmENQeSFCwtgHcuVxcapfQCcQK3W2SA_BkM-KBzX3KU%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6447282d000000000703bc87?xsec_token=ABC5WkgTW12fCdB4aYixakmZMgI9JYFVNA_m9CVG0aqYQ%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64067e320000000014025f54?xsec_token=ABqE-_T7Q69uM7rgbYueogbIaR2C_vVLeDo0MC8b5Mtkg%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/640fedb00000000012032415?xsec_token=ABFc9WNg7DpZfwqmzVJOuVNBQmpYV4T25olL2CTKwNQ_g%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64c78745000000000c036e09?xsec_token=ABrqOF6N7JN_nLBdKP_9qhSh6V6O9bffRMsLrr9F2WECM%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/64b949d9000000001201b9f5?xsec_token=ABXf8zAOzKGymyrBCNhejgDKLATbTKV0zyL3J297H2FiU%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/644e48da000000000800fa3a?xsec_token=ABo1xRFmXyX08eZHvupYbFxRcmPkYhAmVJSQYRL6IKV9o%3D&xsec_source=pc_feed",
        "https://www.xiaohongshu.com/discovery/item/6428c5f90000000013009c10?xsec_token=ABDONnntgLXZ3BJzA5CJnxRg0Ab-GUtggRtIK-vMPAR7s%3D&xsec_source=pc_feed",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("maximedupre/rednote-note-detail-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 '{
  "targets": [
    "https://www.xiaohongshu.com/discovery/item/643552d20000000014027d75?xsec_token=AB8lnDuoqkSPI_vrrTYJPAh9_Mixg6YTx-iZao0xQmuus%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64605e6b0000000013007da2?xsec_token=ABPvi0oh9iU51HRVhTWlzjIp5GTqa_NcEyWqvYrKjPMAI%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/63e99375000000001303ea1f?xsec_token=ABYEbTl9m40eVQ0iOsKM2OEWh3StnxMAmrA0xc2MZHjgM%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/63f0a0fc0000000013035d20?xsec_token=ABXJJ2635KTF205D1uFVKM153-OLxnSz5wuYSIin7ZLeY%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64a64092000000001a0131df?xsec_token=ABHw9Fxfoe2IWxSSeFXFmaxRQxN0zHjpwezI86rccOFLc%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/646dae23000000000800edbc?xsec_token=ABbZaL9LdDJMsZ8VF00w7995x9gRFZTiXywwhEwfPcWys%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64c4d5c6000000001701bcee?xsec_token=ABNkvUjLh_aMt5M2Rq8xPesqYQmCXQPsxBJyNWJgeNYto%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6421815e0000000012031421?xsec_token=ABBv0YOV672wLx_a2Ka-Vi23T0UnOzjvV-iBnFoGq6vnk%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/647eef06000000000703a18c?xsec_token=ABk6FPauX9H1YOf-yVxln8XmzsiGmohd2eUOYipgWyNNw%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64bcd3ee000000000c0357dd?xsec_token=ABaXusImtsM-iMJ1OzSpzRhzMGmE0KFYkbxFkpUNm85rc%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6458314c000000001303682d?xsec_token=AB9rVcowaP4fPljDopxuzJvjJWIS1EciD_HOEguDt6QZE%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/63ff2a3b0000000013035918?xsec_token=ABulzGrH2Y3uWgfql9j6LDHWvmdOHoWZQRRFPHOUHYbWg%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/640607380000000013006cc5?xsec_token=ABqE-_T7Q69uM7rgbYueogbFI_9y6lJSBhSkr8DfEVJCQ%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6409ca5b0000000011011506?xsec_token=ABWUNJIYkJFsMbLJ4sNQcaxe6QewTTmUHbu22qP0rd2Ag%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/646caae400000000120316e5?xsec_token=ABeNSXYxrgqmZ9qNY1tqSh1FdTbReFmgubq5GYt6hc3BI%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64564b9e0000000014024aa1?xsec_token=ABfmENQeSFCwtgHcuVxcapfQCcQK3W2SA_BkM-KBzX3KU%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6447282d000000000703bc87?xsec_token=ABC5WkgTW12fCdB4aYixakmZMgI9JYFVNA_m9CVG0aqYQ%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64067e320000000014025f54?xsec_token=ABqE-_T7Q69uM7rgbYueogbIaR2C_vVLeDo0MC8b5Mtkg%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/640fedb00000000012032415?xsec_token=ABFc9WNg7DpZfwqmzVJOuVNBQmpYV4T25olL2CTKwNQ_g%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64c78745000000000c036e09?xsec_token=ABrqOF6N7JN_nLBdKP_9qhSh6V6O9bffRMsLrr9F2WECM%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/64b949d9000000001201b9f5?xsec_token=ABXf8zAOzKGymyrBCNhejgDKLATbTKV0zyL3J297H2FiU%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/644e48da000000000800fa3a?xsec_token=ABo1xRFmXyX08eZHvupYbFxRcmPkYhAmVJSQYRL6IKV9o%3D&xsec_source=pc_feed",
    "https://www.xiaohongshu.com/discovery/item/6428c5f90000000013009c10?xsec_token=ABDONnntgLXZ3BJzA5CJnxRg0Ab-GUtggRtIK-vMPAR7s%3D&xsec_source=pc_feed"
  ]
}' |
apify call maximedupre/rednote-note-detail-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "RedNote Note Detail Scraper",
        "description": "Scrape public RedNote/Xiaohongshu note details from share links, full note URLs, or copied share text. Export titles, authors, engagement, tags, timestamps, images, video streams, subtitles, and optional media files.",
        "version": "0.1",
        "x-build-id": "rAnPaIeY4p9j0DO9e"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/maximedupre~rednote-note-detail-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-maximedupre-rednote-note-detail-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/maximedupre~rednote-note-detail-scraper/runs": {
            "post": {
                "operationId": "runs-sync-maximedupre-rednote-note-detail-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/maximedupre~rednote-note-detail-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-maximedupre-rednote-note-detail-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": [
                    "targets",
                    "maxNotes",
                    "downloadVideos",
                    "downloadCovers",
                    "downloadImages",
                    "downloadSubtitles"
                ],
                "properties": {
                    "targets": {
                        "title": "RedNote notes",
                        "minItems": 1,
                        "maxItems": 100,
                        "uniqueItems": true,
                        "type": "array",
                        "description": "Add one note per line. Use an `xhslink.com` share link, a full RedNote/Xiaohongshu note URL, or copied share text.",
                        "items": {
                            "type": "string",
                            "minLength": 1
                        }
                    },
                    "maxNotes": {
                        "title": "Note limit",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Maximum notes to save from the target list. Keep this low for a small first run.",
                        "default": 23
                    },
                    "downloadVideos": {
                        "title": "Download videos",
                        "type": "boolean",
                        "description": "Save each video note's MP4 file to the run key-value store when a video URL is available.",
                        "default": false
                    },
                    "downloadCovers": {
                        "title": "Download video covers",
                        "type": "boolean",
                        "description": "Save each video note's cover image as a file.",
                        "default": false
                    },
                    "downloadImages": {
                        "title": "Download gallery images",
                        "type": "boolean",
                        "description": "Save image-note gallery images as files.",
                        "default": false
                    },
                    "downloadSubtitles": {
                        "title": "Download subtitles",
                        "type": "boolean",
                        "description": "Save subtitle tracks as files when a video note includes them.",
                        "default": false
                    },
                    "mediaKvStoreName": {
                        "title": "Media store name",
                        "pattern": "^[A-Za-z0-9-]{0,63}$",
                        "type": "string",
                        "description": "Optional key-value store name for downloaded media files. Leave blank to use the run's default store."
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
