
Xiaohongshu (Little Red Book) MCP Server
io.github.shanyang-me由 GitHub 账号 shanyang-me 发布v0.1.1更新于 Oct 24, 2026
Publish, search, and manage Xiaohongshu (Little Red Book) content via MCP tools.
概览
本地运行的 MCP 服务器,让 AI 助手通过无头浏览器会话在小红书上发布、搜索和管理内容。
- 可以做什么
- 通过二维码登录小红书、检查登录状态、轮询扫码状态并从磁盘重新加载已保存的 Cookie。发布带标题、正文、图片和标签的图文笔记。按关键词搜索笔记并查看笔记完整详情。查询用户主页信息。
- 适用场景
- 适合让助手起草并发布小红书笔记、调研某个话题下的内容,或在不手动打开应用的情况下查看账号与笔记详情。
- 运行要求
- 以 Python 包形式本地运行(需 Python 3.12+),支持 stdio 或 HTTP 传输;需通过 Playwright 安装 Chromium。需要小红书账号,通过扫码登录,会话 Cookie 保存在本地文件。生成二维码图片需额外可选包。
安装
在 SourceWeft 中
- 打开 控制台中的 Xiaohongshu (Little Red Book) MCP Server,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
xiaohongshu-mcp-server
A Model Context Protocol (MCP) server for Xiaohongshu (Little Red Book) - China's leading lifestyle social media platform.
Publish image notes, search content, view note details, and manage your account - all through MCP tools that AI assistants can use directly.
How It Works
Uses Playwright to run a headless Chromium browser that:
- Loads your XHS session cookies
- Generates authentic API signatures via the XHS web app's built-in signing function
- Makes API calls through the browser's network context (bypasses anti-bot detection)
- Uploads images directly to XHS CDN
No browser automation of UI elements - all interactions go through XHS's internal API.
Tools
Installation
For QR code image generation (optional):
Quick Start
1. Start the server
HTTP mode (for Claude Code, Cursor, etc.):
stdio mode (for Claude Desktop):
2. Login
Call the get_login_qrcode tool, scan the QR code with the Xiaohongshu app, then call check_qrcode_status with the returned qr_id and code. Cookies are saved to ~/.xhs-mcp/cookies.json and persist across restarts.
3. Use
Ask your AI assistant to publish a note, search for content, etc.
Configuration
Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
Claude Code
Then start the server: xhs-mcp
As a LaunchAgent (macOS auto-start)
Create ~/Library/LaunchAgents/com.xhs-mcp.plist:
Example: Publish a Note
Requirements
- Python 3.12+
- Chromium (installed via
playwright install chromium) - A Xiaohongshu account
License
MIT
来源:README.md,提交 e4fb862
工具
0版本历史
1- v0.1.1最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分