wechatArticleCleaner
Provides tools for collecting, cleaning, and managing WeChat public account articles: full-history retrieval via WeChat Reading, official-account search/conversion via the WeChat public platform, multi-account subscription monitoring, and export of cleaned Markdown with metadata such as read/like counts.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
微信公众号文章采集、多号订阅与深度清洗工作台
零外部
npm依赖 · 纯 Node.js 22+ 原生实现 · Web 工作台 + CLI + 本地 MCP(stdio / Streamable HTTP) 三合一
将微信公众号文章转化为无尾部脏字符、带规范 YAML Frontmatter、自动去重、支持多号定时追更的高质量 Markdown,直接适配 Obsidian / Notion / 本地知识库与 AI RAG。
核心特性
双通道采集 + 按公众号名搜号换算
微信读书通道(全量历史 + 阅读点赞数 · 推荐):通过本地 Edge/Chrome 原生 CDP 驱动 微信读书网页版,工作台内嵌实时微信扫码弹窗,Cookie 持久化在本地
data/weread-profile/,支持wr_rt无感续期。支持输入公众号名称 / 单篇文章链接 / 含__biz=的合集链接 /MP_WXS_<数字>自动换算并拉取全量历史目录(含阅读数readNum、点赞数likeNum),断点续传 + 自动防限速熔断 + 单日配额护栏。搜公众号名助手(
searchbiz换算MP_WXS_...):可选扫码个人微信公众平台(data/mp-admin-profile/),直接输入任意公众号名称秒查并换算为MP_WXS_<数字>与__biz,一键填入采集框或加入多号定时订阅(无需先手动找文章链接)。公开链接直抓 & 本地目录净化:支持单篇/多行公开链接、公开合集(
appmsgalbum)、TXT/CSV/JSON 链接清单拖拽导入、自动探测合集与文内关联推荐,以及深度净化其他工具导出的脏.html/.md文件。
多公众号定时自动订阅
支持批量添加多个公众号、分组管理、单号独立启停、自定义检查间隔(15 分钟 ~ 每天)。
极低请求量增量策略:每次仅检查最新 1–2 页,命中本地已归档文章立刻提前停止翻页,仅在发布新文章时拉取正文并清洗入库。
高质量 Markdown 深度清洗 & 多层去重
自动剥离微信头尾 UI 垃圾文本(
预览时标签不可点、继续滑动看下一个、取消 允许等)。自动写入规范 YAML Frontmatter(
title、account、author、published_at、ip_region、read_num、like_num、source_url、content_sha256、tags)。基于
review_id/article_key/source_url/content_sha256/公众号+日期+标题+时间戳多层去重(同日同标题不同发布时间会自动保留并追加_HHmm后缀),自动维护00_文章索引.md,支持一键导出 Excel UTF-8 BOM CSV 与wechat_articles.jsonl。
开箱即用的本地 MCP 服务(14 个工具)
界面一键实时启停
Streamable HTTPMCP(默认http://127.0.0.1:4546/mcp),同时也支持独立stdio模式(node mcp-server.mjs),可直接接入各类 AI 客户端搜号、检索、同步和管理公众号订阅。
Related MCP server: WeChat Official Account MCP
快速开始
方式一:Windows 绿色便携版(推荐,零安装)
前往本仓库 Releases 页面 下载
WeChatArticleWorkbench-v*-win64-portable.zip并全部解压;双击
启动前端工作台.bat,等待 1–2 秒自动打开浏览器工作台(http://127.0.0.1:4546);点击蓝色 「登录微信读书」,用微信扫工作台弹窗内的二维码完成登录,即可开始全量拉取或添加多号定时订阅。
环境要求:Windows 10 / 11(自带 Microsoft Edge 或已安装 Google Chrome),无需安装 Node.js。
方式二:从源码运行(Windows / macOS / Linux)
前置要求:Node.js >= 22.0.0(使用原生 WebSocket 与 fetch,无需 npm install),本机已安装 Microsoft Edge 或 Google Chrome。
git clone https://github.com/zianxu78-ux/wechat-article-workbench.git
cd wechat-article-workbench
# 启动 Web 可视化工作台 + 本地 MCP(自动打开浏览器)
node web-server.mjs --port 4546 --open
# Windows 也可直接双击 启动前端工作台.bat
# macOS / Linux 可运行 ./start.shCLI 命令行用法
# 1. 微信读书扫码登录
node cli.mjs weread-login
# 2. 解析公众号全量历史目录(支持单篇文章链接 / 合集链接 / MP_WXS_...)
node cli.mjs weread-list MP_WXS_1234567890 --from 2024-01-01
# 3. 批量拉取正文并深度清洗为干净 Markdown(断点续传去重)
node cli.mjs weread-sync MP_WXS_1234567890 --from 2024-01-01 --delay 4000 --jsonl
# 4. 按公众号名称搜索并换算为 MP_WXS_<数字>(基于个人公众号后台 searchbiz)
node cli.mjs mp-login
node cli.mjs mp-search "公众号名称"
# 5. 多公众号定时订阅管理
node cli.mjs sub-list
node cli.mjs sub-add MP_WXS_1234567890 https://mp.weixin.qq.com/s/xxxxxxx --category 投研
node cli.mjs sub-sync
node cli.mjs sub-watch --interval 60
# 6. 公开链接抓取 / 本地目录净化 / 知识库检索
node cli.mjs fetch https://mp.weixin.qq.com/s/xxxxxxx
node cli.mjs clean-dir "/path/to/exported/articles"
node cli.mjs index --keyword 关键词本地 MCP 接入示例
Streamable HTTP(随 Web 工作台一键启停):
{
"mcpServers": {
"wechatArticleCleaner": {
"type": "streamableHttp",
"url": "http://127.0.0.1:4546/mcp"
}
}
}Stdio(无需打开 Web 界面):
{
"mcpServers": {
"wechatArticleCleaner": {
"command": "node",
"args": ["/absolute/path/to/wechat-article-workbench/mcp-server.mjs"]
}
}
}自行构建发给朋友的绿色便携 ZIP
在 Windows 上运行内置打包脚本,自动剥离你的个人 Cookie(data/)与已下载文章(公众号清洗归档/),一键生成纯净的绿色便携压缩包:
powershell -ExecutionPolicy Bypass -File .\scripts\build-portable-zip.ps1产物输出在 dist/ 目录:
WeChatArticleWorkbench-v*-win64-portable.zip(含官方node.exe,解压双击即用)WeChatArticleWorkbench-v*-source.zip(纯源码轻量包)
隐私、防风控与合规声明
防风控配额建议(重要):微信读书对单个账号存在单日接口频率保护(实测单日连续拉取接近 1,500~1,800 篇易触发
-2041 ErrorNeedVerify安全校验)。本工作台已内置单日安全上限(默认1,200篇/日,界面可自定义)、每 35 篇自动冷却、软频控「操作频繁」自动退避重试以及长期凭证wr_rt无感续期;批量回溯大号历史时建议等待时间设为4~6秒并分天完成(已归档篇目和已知空文下次均 0 耗时自动跳过)。本工具所有数据(微信读书登录态
data/weread-profile/、公众号后台搜号登录态data/mp-admin-profile/、订阅配置data/subscriptions.json、归档文章公众号清洗归档/)均严格保存在用户本地设备,无任何远程上报或第三方服务器中转。严格遵循合规边界:绝不绕过人机验证、验证码或登录鉴权;遇到平台频控或登录失效会立即安全停止并保留已完成归档。
本项目仅供个人学习、研究与合法资料整理备份,请尊重原创作者版权并遵守微信与微信读书平台相关用户协议,请勿高频滥用或用于商业非法采集。
License
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
660+ data tools for agents: TikTok, Douyin, Instagram, YouTube, X, weather, GitHub. Pay per call.
Market data for AI agents: WeChat, Xiaohongshu, Douyin, TikTok, X and 16 more. Pay per call.
AI Reasoning Cache & Consensus Layer with 11 MCP tools via Streamable HTTP.
Remote streamable-HTTP MCP server running on a single Cloudflare Worker. Your assistant gets live Airbnb, Amazon, Booking.com, Google Flights, Maps and Reddit data, social search on X, Instagram and TikTok, the Meta Ad Library, and image/video generation without any keys. Connect your own accounts to let it send WhatsApp or Telegram messages, work an IMAP inbox, manage Meta Ads campaigns and publish to X and LinkedIn. OAuth 2.1 with PKCE; stored credentials are AES-256-GCM encrypted.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables fetching, searching, and summarizing WeChat public account articles through browser automation. Supports multiple output formats and provides article metadata and statistics.-
- AlicenseNot gradedqualityBmaintenanceEnables AI applications to manage WeChat Official Accounts through standardized tools for authentication, media uploads, draft creation, article publishing, and permanent material management.90 npm67MIT
- AlicenseAqualityFmaintenanceEnables AI agents to publish articles to WeChat Official Account (微信公众号). Supports image upload, draft creation, and publishing via standardized MCP protocol.51ISC
- AlicenseAqualityCmaintenanceEnables MCP-compatible AI clients to read WeChat Official Account articles directly by fetching and converting them into clean structured Markdown, including single and batch article retrieval.21MIT