XHS Publisher Skill

Publishes formatted Markdown or text posts with optimized images to Xiaohongshu via MCP endpoint.

2|Updated Apr 2, 2026
One-click install
npx skills add https://github.com/MushroomDAO/blog --skill xhs-publisher-skill
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: XHS Publisher Skill
Source: https://github.com/MushroomDAO/blog/tree/main/.agents/skills/xhs-publisher
Command: npx skills add https://github.com/MushroomDAO/blog --skill xhs-publisher-skill

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and assets (resource) and references (resource) components.

What problem does it solve?

It solves the time-consuming and failure-prone process of publishing posts to 小红书 by automatically compressing and formatting images to meet 小红书 constraints, then publishing via an MCP service.

Core Features & Use Cases

  • Automatic image compression (~200KB, 3:4 ratio): Converts/resize images to 900x1200, strips metadata, and iteratively lowers quality (85→75→65→55→45) until the target size is reached.
  • MCP-based publishing workflow: Checks MCP health and verifies login status (requires prior QR login) before calling the publish endpoint.
  • Content optimization & publishing: Generates a post title, content, and up to 10 tags for the publish request, using an optimizer layer.
  • Use Case: You want to publish an article with food or lifestyle photos without manually editing image size/quality and without getting upload timeouts.

Quick Start

Use the xhs-publisher publish script to publish your content file and images by running: ./.agents/skills/xhs-publisher/scripts/publish.sh content.txt --images photo.jpg

Frequently Asked Questions about XHS Publisher Skill

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate publishing markdown posts to 小红书 without image upload failures?

To automate publishing to 小红书, use a script that processes markdown content and compresses images to roughly 200KB. This Skill resizes photos to a 3:4 ratio and verifies MCP service login status before submitting the post.

What is the best way to compress images for 小红书 to meet platform constraints?

The best way to compress images for 小红书 is converting them to 900x1200 pixels and iteratively lowering quality until reaching 200KB. This process uses ImageMagick to strip metadata and ensure uploads do not timeout.

Does this MCP publishing workflow require manual QR code login?

Yes, the MCP publishing workflow requires a prior manual QR code login. The system checks the MCP service health and verifies your existing login status before proceeding with the automated post submission.

Can I publish multi-photo notes to 小红书 using text files?

Yes, you can publish multi-photo notes by providing a content text file and multiple image paths to the publishing script. The workflow generates optimized titles, content, and up to 10 tags for the request.

Why does 小红书 publishing fail with large images and how to fix it?

小红书 publishing fails with large images because of strict platform constraints and upload timeouts. Fix this by automatically resizing images to a 3:4 ratio and compressing them to about 200KB using ImageMagick.