Added Nov 3, 2026
xiaohongshu-cli
A command-line tool that talks to Xiaohongshu's web interface to search and read notes, like, comment, follow and post.
- Ecosystem
- Agent Skills
- Skill category
- Automation
- Creator / organization
- jackwener(GitHub 用户)
What it is
xiaohongshu-cli is a Xiaohongshu command-line tool (CLI) by GitHub user jackwener, and the repo ships a SKILL.md that teaches AI agents how to use it. From your terminal you can search notes, users and topics, browse trending and recommended posts, read note text, comments and replies, look at user profiles, collections and likes, and read your own profile and notifications. On the writing side, it can follow and unfollow, like, collect, comment and reply, delete your own comments, and upload images to post image notes.
It works differently from the same author's xhs-cli. xhs-cli opens a headless browser for every command; xiaohongshu-cli calls Xiaohongshu's web interface directly for most actions (the author calls it a reverse-engineered API) and only uses a browser for QR login. It has no DMs, no live streams, no follower or following lists, and it can't post videos.
Who it's for:Developers who live in the terminal and want an AI agent to look things up on Xiaohongshu. Readers who don't write code won't get much from it.
Before you start: The author recommends installing with uv tool install xiaohongshu-cli or pipx, and you need Python 3.10 or later. You can also git clone and install from source with uv sync. For an AI agent, run npx skills add jackwener/xiaohongshu-cli or put it in .agents/skills. The README gives an install flag for Claude Code but no separate Codex steps, and the old ClawHub install is retired. QR login needs the Camoufox browser downloaded separately (python -m camoufox fetch). The docs don't list supported operating systems.
There are two ways to sign in: read your Xiaohongshu cookies from the browsers on your computer, or scan a QR code. Login data is saved at ~/.xiaohongshu-cli/cookies.json. The same folder holds note context, recently viewed notes and your search history, and the code sets these files so only you can read them. The review read the source and found no code that sends your cookies anywhere other than Xiaohongshu, but it didn't check every third-party library the tool uses.
It sends your search terms, account actions, post text and chosen images to Xiaohongshu. Posting has no second confirmation step and is public by default; you need --private to post privately. The author marks the delete-note command as unstable. The README says the tool is built to avoid anti-bot checks: it imitates browser request headers, waits random intervals, and retries automatically when rate-limited.
It can sign in by reading cookies from your browsers, which means going into the browsers on your computer to pull out your Xiaohongshu login. The agent can also like, comment, follow or post without your approval, speaking for you from your own account. The older QR login flow may write session details into debug logs.
We found no paid API. If you use these features, weigh your account's safety and the platform's rules yourself. AI Inspiration World is not responsible for any consequences. The README and package info say Apache-2.0, but the repo has no separate license file, and the license doesn't mean Xiaohongshu has authorized the tool.
Based on the project's public documentation. Not tested by AI Inspiration World.