Install
openclaw skills install @xuya227939/xiaohongshu-research-kitExtract and analyze Xiaohongshu (Little Red Book) content using yt-dlp and gallery-dl. Supports note metadata, image/video extraction, user profile analysis, and content research. Use when user mentions "Xiaohongshu research", "小红书分析", "小红书提取", "RED note", "Little Red Book", "XHS extract", or provides a xiaohongshu.com/xhslink.com URL.
openclaw skills install @xuya227939/xiaohongshu-research-kitExtract structured data from Xiaohongshu (小红书) notes, profiles, and content for research. Powered by yt-dlp and gallery-dl locally — no API key required.
Version: 1.0.0 Prerequisites: yt-dlp >= 2024.01.01, gallery-dl >= 1.26.0
# macOS
brew install yt-dlp gallery-dl
# pip
pip install yt-dlp gallery-dl
# Verify
yt-dlp --version && gallery-dl --version
Xiaohongshu requires cookies for most content. Export browser cookies:
yt-dlp --cookies-from-browser chrome "URL"
gallery-dl --cookies-from-browser chrome "URL"
Extract title, description, engagement stats from a video note.
yt-dlp --dump-json --skip-download --cookies-from-browser chrome \
"https://www.xiaohongshu.com/explore/NOTE_ID"
Key JSON fields:
| Field | JSON path |
|---|---|
| Title | .title |
| Description | .description |
| Author | .uploader |
| Upload date | .upload_date (YYYYMMDD → YYYY-MM-DD) |
| Views | .view_count |
| Likes | .like_count |
| Comments | .comment_count |
| Duration | .duration (video only) |
| Thumbnail | .thumbnail |
| Tags | .tags[] |
For image-based notes (图文笔记), use gallery-dl:
gallery-dl --dump-json --cookies-from-browser chrome \
"https://www.xiaohongshu.com/explore/NOTE_ID"
Returns JSON with image URLs, caption, and metadata. Image notes typically contain 1-9 images with text overlay.
yt-dlp --flat-playlist --dump-json --playlist-end 20 \
--cookies-from-browser chrome \
"https://www.xiaohongshu.com/user/profile/USER_ID"
For all content types (images + videos):
gallery-dl --dump-json --range 1-20 \
--cookies-from-browser chrome \
"https://www.xiaohongshu.com/user/profile/USER_ID"
Output format: Table with columns: #, Date, Type (Image/Video), Title (first 40 chars), Likes.
Xiaohongshu topic pages:
gallery-dl --dump-json --range 1-20 \
--cookies-from-browser chrome \
"https://www.xiaohongshu.com/search_result?keyword=KEYWORD"
| Pattern | Type |
|---|---|
xiaohongshu.com/explore/NOTE_ID | Single note |
xiaohongshu.com/discovery/item/NOTE_ID | Single note (alt) |
xhslink.com/SHORTCODE | Short link |
xiaohongshu.com/user/profile/USER_ID | User profile |
= 10000 →
{n/10000:.1f}万
= 1000 →
{n/1000:.1f}千
When user provides a Xiaohongshu URL:
--cookies-from-browser (almost always needed)When user asks to download media:
Xiaohongshu Research Kit is an open-source project by SnapVee.