</>MCP Agents Market
Skill

xiaohongshu-cli

by jackwener2.6kPythonUpdated 2026-03-21

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

xiaohongshu-cli is a command-line agent skill that enables AI assistants to search, read, and interact with Xiaohongshu (小红书), a popular Chinese social media platform. Built on a reverse-engineered API, it provides authenticated access to notes, comments, user profiles, feeds, and creator functions through structured YAML/JSON output optimized for non-interactive agent use. The skill includes anti-detection measures like Gaussian jitter and browser fingerprint consistency to minimize rate-limiting, and supports short-index navigation for chaining commands efficiently.

Key Features

Authenticated access via auto-extracted browser cookies, QR code login, or saved sessions with 7-day validity
Comprehensive search across notes, users, and topics with filtering by type (video/image) and sorting options
Reading capabilities including note details, paginated comments with xsec_token caching, user profiles, and recommendation feeds
Social interactions: like, favorite, comment, reply, follow/unfollow, and creator functions (post, delete notes)
Short-index navigation system allowing commands like 'xhs read 1' to reference the first result from the last listing
Anti-detection suite with Gaussian jitter delays, macOS Chrome fingerprint consistency, captcha cooldown, and exponential backoff
Structured YAML/JSON output with stable envelope schema (ok/schema_version/data/error) for reliable agent parsing
Notification access for unread counts, mentions, likes, and new followers

Use Cases

  • 01AI agents monitoring trending topics or hot notes in specific categories (food, fashion, travel) for content research
  • 02Automated social media management: scheduling posts, replying to comments, and tracking engagement metrics
  • 03Content curation workflows that search, filter, and bookmark relevant Xiaohongshu notes based on keywords
  • 04User research and competitor analysis by fetching profiles, post histories, and engagement patterns
  • 05Notification monitoring and automated response systems for creator accounts
  • 06Cross-platform content aggregation combining Xiaohongshu data with other social media CLI tools from the same author

Related Skills

View more

xiaohongshu-cli — FAQ

What is xiaohongshu-cli?+

xiaohongshu-cli is a Python-based agent skill that provides command-line access to Xiaohongshu (小红书) for searching, reading, and interacting with notes, users, and feeds via a reverse-engineered API with structured output for AI agents.

How do I install xiaohongshu-cli?+

Install using 'uv tool install xiaohongshu-cli' (recommended) or 'pipx install xiaohongshu-cli'. For agent integration, run 'npx skills add jackwener/xiaohongshu-cli' or manually clone the repository into .agents/skills/xiaohongshu-cli.

Which AI clients work with this skill?+

Any AI agent that can execute shell commands and parse YAML/JSON output can use this skill. It's designed for Skills CLI-compatible agents and includes a SKILL.md instruction file for automatic agent integration.

Do I need API keys or authentication?+

Yes, you must authenticate with a Xiaohongshu account. Run 'xhs login' to auto-extract cookies from an installed browser (Chrome, Arc, Edge, Firefox, Safari, etc.) or use 'xhs login --qrcode' for QR code login. Cookies remain valid for 7 days.

Is xiaohongshu-cli free to use?+

Yes, the tool is open-source under Apache-2.0 license. It requires a free Xiaohongshu account for authentication but has no additional costs.

What are the prerequisites for using this skill?+

Requires Python ≥3.10, a Xiaohongshu account, and an installed browser with active login cookies. The tool automatically handles rate limiting and anti-detection, but aggressive use may trigger captchas or IP blocks.

How do I install xiaohongshu-cli?+

Open the source repository on GitHub and follow its README. xiaohongshu-cli is a skill — MCP Agents Market links you directly to the official repo.

Is xiaohongshu-cli free?+

xiaohongshu-cli is an open-source project hosted on GitHub. Check the repository for its license and any usage requirements.

Related searches