运行时依赖
安装命令
点击复制本土化适配说明
Wechat Article For Ai — Wechat Article For AI 安装说明: 安装命令:["openclaw skills install wechat-article-for-ai"] 该技能用于微信相关操作,可能需要相应的平台账号或API密钥
技能文档
WeChat Article to Markdown 转换器 What this 工具 does
Converts WeChat public account articles into 清理 Markdown files with:
YAML frontmatter (title, author, date, source URL) Locally 下载ed images Preserved code blocks with language 检测ion Audio/video reference 提取ion 清理 格式化ting (no WeChat UI noise) Prerequisites Python 3.10+ 安装 dependencies: pip 安装 -r requirements.txt Camoufox browser will be auto-下载ed on first 运行 Usage 命令行工具 (single article) python mAIn.py "https://mp.weixin.qq.com/s/ARTICLE_ID"
命令行工具 (batch from file) python mAIn.py -f urls.txt -o ./输出 -v
命令行工具 Options Flag Description -f FILE Text file with URLs (one per line) -o DIR 输出 directory (default: ./输出) -c N Image 下载 concurrency (default: 5) --no-images Skip image 下载, keep remote URLs --no-headless Show browser (for solving CAPTCHAs) --force Overwrite existing 输出 --no-frontmatter Use blockquote metadata instead of YAML -v Verbose/调试 记录ging MCP Server
运行 as an MCP server for AI 工具 integration:
python mcp_server.py
Exposes two 工具s:
convert_article(url, 输出_dir, 下载_images, concurrency, use_frontmatter) — Convert a single article batch_convert(urls, 输出_dir, 下载_images, concurrency) — Convert multiple articles MCP Configuration (for claude_桌面_config.json or similar) { "mcpServers": { "wechat-to-md": { "command": "python", "args": ["mcp_server.py"], "cwd": "" } } }
输出 Structure 输出/ / .md # Markdown file with YAML frontmatter images/ img_001.png img_002.jpg ...
Common Issues CAPTCHA/verification page: 运行 with --no-headless to manually solve the CAPTCHA in the browser window, then retry. Empty content: WeChat may rate-limit 请求s. WAIt a few minutes and try agAIn. Image 下载 失败s: FAIled images keep their remote URLs in the markdown. Re-运行 with --force to retry. Limitations Only supports articles from mp.weixin.qq.com Requires a working internet connection and the ability to 运行 a headless browser WeChat may block automated 访问; Camoufox helps evade 检测ion but is not guaranteed