Agent skill
md2wechat-lite
Manages md2wx CLI for converting Markdown to WeChat Official Account drafts. Use when working with WeChat article publishing, Markdown to HTML conversion, or WeChat media upload.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/md2wechat-lite
SKILL.md
md2wx - Markdown to WeChat
CLI tool for converting Markdown to WeChat Official Account formatted drafts.
Quick start
Install:
curl -fsSL https://raw.githubusercontent.com/geekjourneyx/md2wechat-lite/main/cli/scripts/install.sh | sh
Configure credentials:
md2wx config set wechat-appid "wx123..."
md2wx config set wechat-appsecret "your_secret"
md2wx config set api-key "wme_your_key"
Commands
| Command | Purpose |
|---|---|
article-draft |
Create article draft from Markdown |
newspic-draft |
Create Xiaolvshu (image card) draft |
batch-upload |
Upload images to WeChat CDN |
themes list |
List available themes |
config |
Manage settings (set/get/list/path) |
Article draft
Convert Markdown to WeChat article:
md2wx article-draft --file article.md --theme bytedance --cover-image "https://cdn.example.com/cover.jpg"
Or pass inline Markdown:
md2wx article-draft --markdown "# Title\n\nContent" --theme elegant-red --cover-image "https://cdn.example.com/cover.jpg"
Note:
article-draftdoes not read from stdin pipe directly.- For API compatibility, always provide
--cover-imagewith a public URL.
Newspic draft
Create image-rich card drafts:
md2wx newspic-draft --title "标题" --content "内容" --images "https://cdn.example.com/img1.jpg,https://cdn.example.com/img2.png"
Batch upload
Upload images and get WeChat CDN URLs:
md2wx batch-upload --images "https://cdn.example.com/a.jpg,https://cdn.example.com/b.jpg"
Image input constraints:
- API accepts public image URLs only.
- Local file paths and glob patterns are not supported.
Themes
Built-in (6): default, bytedance, chinese, apple, sports, cyber
Template (32): {minimal|focus|elegant|bold}-{gold|green|blue|orange|red|navy|gray|sky}
List/search themes:
md2wx themes list [--verbose] [--search query]
For theme descriptions: See cli/pkg/themes/list.go
Configuration
Config file: ~/.md2wx/config.yaml (stored as key=value lines)
Priority: Command args > Environment vars > Config file > Defaults
Environment variables:
MD2WX_WECHAT_APPIDMD2WX_WECHAT_APPSECRETMD2WX_API_KEYMD2WX_API_BASE_URLMD2WX_DEFAULT_THEMEMD2WX_BACKGROUND_TYPEMD2WX_FONT_SIZE
Project structure
cli/
├── main.go # Root command
├── article-draft.go # Article draft
├── newspic-draft.go # Xiaolvshu draft
├── batch-upload.go # Image upload
├── config.go # Config management
├── themes.go # Theme list command
└── pkg/
├── api/client.go # HTTP API client
├── config/ # Config file I/O
├── themes/ # Theme definitions
└── output/ # JSON formatter
Output format
All commands output JSON:
{
"success": true,
"data": { "media_id": "...", "url": "..." }
}
Implementation details
- Zero dependencies (except cobra): Manual key=value config parsing
- Go 1.24+ required
- Single binary distribution
See source files for:
- API client:
cli/pkg/api/client.go - Config handling:
cli/pkg/config/config.go - Theme list:
cli/pkg/themes/list.go
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?