Prototype · Preview: every server in the official registry, synced every 30 minutes. Sign in with Google to write reviews.Prototype · updated every 30 min
PopNx MCPMCP servers for people who use AI · explained in plain words

xiaohongshu-cli Skill

by jackwener★ 2,7341 skills

Install

What it does

A CLI for Xiaohongshu (小红书) — search, read, interact via reverse-engineered API

  • Connects Instruction files the AI reads; connects to nothing
  • Account or key No key needed
  • Category Data and research
For makers: add a badge to your README

If you made this, paste this code into your README. The badge links back to this page.

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/skill/jackwener-xiaohongshu-cli.svg)](https://mcp.popnx.com/en/skills/jackwener-xiaohongshu-cli)

Use together with

MCP servers that connect the AI to services for the same work

Firebase MCP

Gives AI development tools Firebase-specific capabilities and expertise.

by firebaseWidely used↓ 4.9M/wk★ 4.5K Stars for the whole repoUpdated 12 months ago

MCP · Connects a serviceRuns on your computer

Supabase

Supabase’s official server lets AI create tables, query data and review project settings in your Supabase database.

by supabaseWidely used↓ 245.5K/wk★ 3K Stars for the whole repoUpdated 3 days ago

MCP · Connects a serviceComputer or cloud✓ service owner · supabase.com

Dbx

Query databases from AI agents using connections configured in DBX.

by t8y2Widely used↓ 9.4K/wk★ 30.4KUpdated 7 months ago

MCP · Connects a serviceRuns on your computer

Similar Skills

Same kind of work, ordered like the Skills list

Compared with similar ones
This one
xiaohongshu-cli
timesfmShadowbrokergoogle-maps-scrapertradingview-mcp
Makerjackwenergoogle-researchBigBodyCobaingosomatilaahmettaner
Skills11111
GitHub stars2,73435,56711,5808,1075,292
Last code changeMar 21, 2026Nov 13, 2026Nov 16, 2026Nov 15, 2026Nov 15, 2026
License–Apache-2.0AGPL-3.0MITMIT

1 skills (instruction sets) by jackwener that an AI reads and follows · not an MCP server

How a Skill differs from MCP

MCP = the hands

Connects the AI to an outside service or data, such as reading Notion or creating an invoice. A program or server has to be running.

Skill = the manual

A text file that teaches the AI how to do a task. It connects to nothing.

Some overlap: a few Skills run scripts that call tools, and a few MCP servers only send knowledge. Start from the task you want done.

Works with

Claude CodeCursor

From the maker’s README and the folders in the repo

Install

Is it safe?

  • Who made it

    GitHub account jackwener (person), 9 years old

  • Use and upkeep

    ★ 2,734 stars · code last changed Mar 21, 2026

  • Any scripts?

    40 scripts that can run on a computer: tests/__init__.py, tests/conftest.py, tests/test_anti_detection.py, tests/test_cli.py and 36 more

  • Uses the internet?

    Could not check every script (some are too large); read them first

  • Changes machine-wide settings?

    No hooks or writes to machine settings found

Checked automatically from the repo files at commit 4d63f3c (read only, nothing was run). Not a safety guarantee: read it and decide for yourself

First: which AI do you use?

Pick your app and this page shows only how to install it there

Option 1Upload to claude.ai (web and app)

  1. Download from GitHub

    This skill has no license, so we do not hand out a ZIP from our site. Download it from GitHub and arrange the folder yourself, or use "Let the AI install it" above, which is easier

    Download from GitHub (whole repo) ↗

    Unzip it, then zip only the xiaohongshu-cli folder again. The ZIP must have a xiaohongshu-cli folder with SKILL.md at the top level, no loose files

  2. Open Skills on claude.ai and upload

    +Create skillUpload a skillpick xiaohongshu-cli.zip

    Open claude.ai/customize/skills ↗

  3. No Upload button? Turn on file creation first

    SettingsCapabilitiesCode execution and file creation

    Turn on Code execution and file creation first (newer menus: Create and edit files) · personal plans: Settings → Capabilities · Team/Enterprise: an admin turns it on under Organization settings → Plugins & skills · every plan, including Free

Upload once; it works in claude.ai and Claude Desktop, and in recent Claude Code signed in with a Claude account (not with an API key)

Cowork and cloud sessions use the skills turned on in your claude.ai account, not ~/.claude/skills on your computer (Claude Desktop scheduled tasks run locally and still load it)

Checked against official docs Nov 12, 2026 · Source: support.claude.com, support.claude.com, code.claude.com

Option 1Let Claude Code install it

Copy this sentence and paste it into a Claude Code chat

Where to install

Checking the commands · copy buttons appear once they pass

Checking the commands · copy buttons appear once they pass

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Restart Claude Code, then type /xiaohongshu-cli or ask for a matching task and Claude picks it up

Checked against official docs Nov 12, 2026 · Source: code.claude.com

For Terminal users

A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.

The maker’s recommended way

Install Node.js (if you don’t have it)

Already installed? Check first · Open Terminal, type this command and press Enter

node -v
  • A version number such as v26.13.1 = installed, skip this step
  • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
How to open Terminal

Mac: press ⌘ + Space, type Terminal, press Enter

Windows: open Start, type Windows PowerShell, then Open

Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed

Open the Node.js download page ↗

When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v

Install once; it works for everything that needs Node.js

Checking the commands · copy buttons appear once they pass

Copied from the maker’s README; it downloads and runs the maker’s code

  1. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead

  2. Copy the skill folder to ~/.claude/skills

    This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md

    Checking the commands · copy buttons appear once they pass

  3. Restart Claude Code, then type /xiaohongshu-cli or ask for a matching task and Claude picks it up

Skills you install yourself work in the ChatGPT desktop app, Codex CLI and the Codex IDE extension · ChatGPT on the web and mobile cannot use skills you install yourself, only skills that come with a plugin from the directory

ChatGPT desktop app

The ChatGPT desktop app has Codex built in, and Codex reads skills from ~/.agents/skills

Option 1Let ChatGPT install it

Open Codex in the ChatGPT desktop app and paste this sentence into the chat

Where to install

Checking the commands · copy buttons appear once they pass

Checking the commands · copy buttons appear once they pass

The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Option 2Put the folder there yourself

Put the xiaohongshu-cli folder at ~/.agents/skills/xiaohongshu-cli

~ is your home folder ($HOME)

For Terminal users

A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.

  1. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead

  2. Copy the skill folder to ~/.agents/skills

    This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md

    Checking the commands · copy buttons appear once they pass

After installing

  • ChatGPT desktop app: open Skills in the sidebar to see that the skill is there
  • To use it: in ChatGPT type @ and pick the skill · in Codex CLI or the IDE extension run /skills or type $ and the skill name
  • Codex picks up newly installed skills by itself; if one does not show up, restart Codex

Checked against official docs Nov 15, 2026 · Source: learn.chatgpt.com

ChatGPT on the web and mobile

Skills you install yourself do not work here; only skills that come with a plugin from the directory

To use this skill with ChatGPT, use the ChatGPT desktop app as above

Checked against official docs Nov 15, 2026 · Source: learn.chatgpt.com

Option 1Let Codex install it

Copy this sentence and paste it into a Codex chat · Works in Codex inside the ChatGPT desktop app, Codex CLI and the IDE extension

Where to install

Checking the commands · copy buttons appear once they pass

Checking the commands · copy buttons appear once they pass

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Codex picks up newly installed skills by itself; if one does not show up, restart Codex · To use it: in ChatGPT type @ and pick the skill · in Codex CLI or the IDE extension run /skills or type $ and the skill name

Checked against official docs Nov 15, 2026 · Source: learn.chatgpt.com

For Terminal users

A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.

  1. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead

  2. Copy the skill folder to ~/.agents/skills

    This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md

    Checking the commands · copy buttons appear once they pass

  3. Restart Codex, then ask for a matching task; Codex lists the skill

Option 1Let Cursor install it

Copy this sentence and paste it into a Cursor chat

Where to install

Checking the commands · copy buttons appear once they pass

Checking the commands · copy buttons appear once they pass

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

In Cursor’s Agent chat, type / and pick xiaohongshu-cli

Checked against official docs Nov 12, 2026 · Source: cursor.com

For Terminal users

A Skill is instructions the AI will follow. Read the files before installing, and install only from makers you trust.

  1. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: the command below does not work in PowerShell; use “Let AI install it” above instead

  2. Copy the skill folder to ~/.cursor/skills

    This downloads the repo to a temporary folder and copies only the folders that contain a SKILL.md

    Checking the commands · copy buttons appear once they pass

  3. In Cursor’s Agent chat, type / and pick xiaohongshu-cli

Option 1Let the AI install it

For other apps that read skills. The sentence gives the paths for Claude Code, Codex and Cursor so the AI picks the one for your app · Copy this sentence into the app’s chat

Where to install

Checking the commands · copy buttons appear once they pass

Checking the commands · copy buttons appear once they pass

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Checked against official docs Nov 12, 2026 · Source: code.claude.com, learn.chatgpt.com, cursor.com

For Terminal users

Other apps that support Agent Skills (such as Gemini CLI or GitHub Copilot) use different folders. Check that app’s guide, then copy the folder with the SKILL.md there.

View on GitHub ↗

Skill folders checked against the official Claude Code, Codex and Cursor guides on Nov 11, 2026

View the original SKILL.md

The text below comes from the maker’s repo, not from PopNx MCP

Showing the first 8,000 characters · Open the full file on GitHub

---
name: xiaohongshu-cli
description: Use xiaohongshu-cli for ALL Xiaohongshu (Little Red Book, 小红书) operations — searching notes, reading content, browsing users, liking, collecting, commenting, following, and posting. Invoke whenever the user requests any Xiaohongshu interaction.
author: jackwener
version: "0.6.4"
tags:
  - xiaohongshu
  - xhs
  - redbook
  - 小红书
  - social-media
  - cli
---

# xiaohongshu-cli — Xiaohongshu CLI Tool

**Binary:** `xhs`
**Credentials:** browser cookies (auto-extracted) or browser-assisted QR login (`--qrcode`)

## Setup

```bash
# Install (requires Python 3.10+)
uv tool install xiaohongshu-cli
# Or: pipx install xiaohongshu-cli

# Upgrade to latest (recommended to avoid API errors)
uv tool upgrade xiaohongshu-cli
# Or: pipx upgrade xiaohongshu-cli
```

## Authentication

**IMPORTANT FOR AGENTS**: Before executing ANY xhs command, check if credentials exist first. Do NOT assume cookies are configured.

### Step 0: Check if already authenticated

```bash
xhs status --yaml >/dev/null && echo "AUTH_OK" || echo "AUTH_NEEDED"
```

If `AUTH_OK`, skip to [Command Reference](#command-reference).
If `AUTH_NEEDED`, proceed to Step 1. Prefer `--qrcode` when browser cookie extraction is unavailable but launching a browser is acceptable.

### Step 1: Guide user to authenticate

Ensure user is logged into xiaohongshu.com in any browser supported by [browser_cookie3](https://github.com/borisbabic/browser_cookie3). Supported browsers: Chrome, Arc, Edge, Firefox, Safari, Brave, Chromium, Opera, Opera GX, Vivaldi, LibreWolf, Lynx, w3m. Then:

```bash
xhs login                              # auto-detect browser with valid cookies
xhs login --cookie-source arc          # specify browser explicitly
xhs login --qrcode                     # browser-assisted QR login with terminal QR output
```

Verify with:

```bash
xhs status
xhs whoami
```

### Step 2: Handle common auth issues

| Symptom | Agent action |
|---------|-------------|
| `NoCookieError: No 'a1' cookie found` | Guide user to login to xiaohongshu.com in browser |
| `NeedVerifyError: Captcha required` | Ask user to open browser, complete captcha, then retry |
| `IpBlockedError: IP blocked` | Suggest switching network (hotspot/VPN) |
| `SessionExpiredError` | Run `xhs login` to refresh cookies |

## Agent Defaults

All machine-readable output uses the envelope documented in [SCHEMA.md](./SCHEMA.md).
Payloads live under `.data`.

- Non-TTY stdout → auto YAML
- `--json` / `--yaml` → explicit format
- `OUTPUT=json` env → global override
- `OUTPUT=rich` env → force human output

## Command Reference

### Reading

| Command | Description | Example |
|---------|-------------|---------|
| `xhs search <keyword>` | Search notes | `xhs search "美食" --sort popular --type video` |
| `xhs read <id_or_url_or_index>` | Read a note by ID, URL, or short index | `xhs read 1` / `xhs read "https://...?xsec_token=xxx"` |
| `xhs comments <id_or_url_or_index>` | Get comments by ID, URL, or short index | `xhs comments 1` / `xhs comments "https://...?xsec_token=..."` |
| `xhs comments <id_or_url> --all` | Get ALL comments (auto-paginate) | `xhs comments "<url>" --all --json` |
| `xhs sub-comments <note_id> <comment_id>` | Get replies to comment | `xhs sub-comments abc 123` |
| `xhs user <user_id>` | View user profile | `xhs user 5f2e123` |
| `xhs user-posts <user_id>` | List user's notes | `xhs user-posts 5f2e123 --cursor ""` |
| `xhs feed` | Browse recommendation feed | `xhs feed --yaml` |
| `xhs hot` | Browse trending notes | `xhs hot -c food` |
| `xhs topics <keyword>` | Search topics/hashtags | `xhs topics "旅行"` |
| `xhs search-user <keyword>` | Search users | `xhs search-user "摄影"` |
| `xhs my-notes` | List own published notes | `xhs my-notes --page 0` |
| `xhs notifications` | View notifications | `xhs notifications --type likes` |
| `xhs unread` | Show unread counts | `xhs unread --json` |

### Interactions (Write)

| Command | Description | Example |
|---------|-------------|---------|
| `xhs like <id_or_url_or_index>` | Like a note | `xhs like 1` / `xhs like abc123` |
| `xhs like <id_or_url_or_index> --undo` | Unlike a note | `xhs like 1 --undo` |
| `xhs favorite <id_or_url_or_index>` | Bookmark a note | `xhs favorite 1` |
| `xhs unfavorite <id_or_url_or_index>` | Remove bookmark | `xhs unfavorite 1` |
| `xhs comment <id_or_url_or_index> -c "text"` | Post a comment | `xhs comment 1 -c "好看!"` |
| `xhs reply <id_or_url_or_index> --comment-id ID -c "text"` | Reply to comment | `xhs reply 1 --comment-id 456 -c "谢谢"` |
| `xhs delete-comment <note_id> <comment_id>` | Delete own comment | `xhs delete-comment abc 123 -y` |

### Social

| Command | Description | Example |
|---------|-------------|---------|
| `xhs follow <user_id>` | Follow a user | `xhs follow 5f2e123` |
| `xhs unfollow <user_id>` | Unfollow a user | `xhs unfollow 5f2e123` |
| `xhs favorites [user_id]` | List bookmarked notes (defaults to self) | `xhs favorites --json` |

### Creator

| Command | Description | Example |
|---------|-------------|---------|
| `xhs post --title "..." --body "..." --images img.png` | Publish a note | `xhs post --title "Test" --body "Hello"` |
| `xhs delete <id_or_url>` | Delete own note | `xhs delete abc123 -y` |

### Account

| Command | Description |
|---------|-------------|
| `xhs login` | Extract cookies from browser (auto-detect) |
| `xhs login --qrcode` | Browser-assisted QR login — terminal QR output, browser completes login |
| `xhs status` | Check authentication status |
| `xhs logout` | Clear cached cookies |
| `xhs whoami` | Show current user profile |

## Agent Workflow Examples

### Search → Read → Like pipeline

```bash
NOTE_ID=$(xhs search "美食推荐" --json | jq -r '.data.items[0].id')
xhs read "$NOTE_ID" --json | jq '.data'
xhs like "$NOTE_ID"
```

### Browse trending food notes

```bash
xhs hot -c food --json | jq '.data.items[:5] | .[].note_card | {title, likes: .interact_info.liked_count}'
```

### Get user info then follow

```bash
xhs user 5f2e123 --json | jq '.data.basic_info | {nickname, user_id}'
xhs follow 5f2e123
```

### Check notifications

```bash
xhs unread --json | jq '.data'
xhs notifications --type mentions --json | jq '.data.message_list[:5]'
```

### Analyze all comments on a note

```bash
# Fetch ALL comments and analyze themes
xhs comments "$NOTE_URL" --all --json | jq '.data.comments | length'
# Count questions
xhs comments "$NOTE_URL" --all --json | jq '[.data.comments[] | select(.content | test("[\uff1f?]"))] | length'
```

### Daily reading workflow

```bash
# Browse recommendation feed
xhs feed --yaml

# Interactive short-index workflow
xhs search "旅行"
xhs read 1
xhs comments 1
xhs like 1
xhs favorite 1
xhs comment 1 -c "收藏了"

# Browse trending by category
xhs hot -c food --yaml
xhs hot -c travel --yaml
```

### QR code login

```bash
# When browser cookie extraction is not available
xhs login --qrcode
# → Launches a browser-assisted login flow
# → Renders QR in terminal using Unicode half-blocks
# → Scan with Xiaohongshu app → confirm → export cookies
```

### URL to insights pipeline

```bash
# User pastes a URL → read + all comments
xhs read "https://www.xiaohongshu.com/explore/xxx?xsec_token=yyy" --json
xhs comments "https://www.xiaohongshu.com/explore/xxx?xsec_token=yyy" --all --json
```

## Hot Categories

Available for `xhs hot -c <category>`:
`fashion`, `food`, `cosmetics`, `movie`, `career`, `love`, `home`, `gaming`, `travel`, `fitness`

## Error Codes

Structured error codes returned in the `error.code` field:
- `not_authenticated` — cookies expired or missing
- `verification_required` — captcha/verification needed
- `ip_blocked` — IP rate limited
- `signature_error` — request signing failed
- `api_error` — upstream API error
- `unsupported_operation` — operation not available

## Limitations

- **No video download** — cannot download note images/videos
- **No DMs** — cannot access private messages
- **No live streaming** — live features not supported
- **No

Discussion

Ask, share a tip or report that it does not work. Sorted by what people marked helpful.

No posts yet. Be the first to ask or share.

Posts here are written by users, not the PopNx team.

Sign in to post

From GitHub

GitHub stars
2,734
Maker
jackwener
License
Not stated
Last code change
Mar 21, 2026
SKILL.md files in the repo (including translated copies and templates)
1