Back to MCP directory
publicPublicdnsLocal runtime

wexin-read-mcp

一个极简的微信文章阅读器MCP服务,通过浏览器模拟和内容提取技术,让大模型能够获取并分析微信公众号文章内容。

article

README

🚀 微信文章阅读器 - Weixin MCP

这是一个极简的MCP,借助它大模型能够轻松阅读微信公众号文章,为信息获取提供便利。

🚀 快速开始

1. 安装依赖

# 安装Python依赖
pip install -r requirements.txt

2. 配置

{
  "mcpServers": {
    "weixin-reader": {
      "command": "python",
      "args": [
        "C:/Users/你的用户名/Desktop/wx-mcp/wx-mcp-server/src/server.py"
      ]
    }
  }
}

⚠️ 重要提示

请将路径替换为你的实际项目路径。

✨ 主要特性

  • 🎭 浏览器模拟:使用 Playwright 完整模拟浏览器环境
  • 📝 内容提取:自动提取标题、作者、发布时间、正文内容
  • 简洁实现:最少的代码实现核心功能

📦 安装指南

1. 安装依赖

# 安装Python依赖
pip install -r requirements.txt

2. 配置

{
  "mcpServers": {
    "weixin-reader": {
      "command": "python",
      "args": [
        "C:/Users/你的用户名/Desktop/wx-mcp/wx-mcp-server/src/server.py"
      ]
    }
  }
}

注意: 请将路径替换为你的实际项目路径。

💻 使用示例

基础用法

在Claude中直接使用:

请帮我总结这篇文章:https://mp.weixin.qq.com/s/nEJhdxGea-KLZA_IGw9R5A

Claude会自动调用read_weixin_article工具获取文章内容并进行分析。 alt text

📚 详细文档

read_weixin_article(url: str)

读取微信公众号文章内容。 参数:

  • url: 微信文章URL,格式: https://mp.weixin.qq.com/s/xxx 返回:
{
  "success": true,
  "title": "文章标题",
  "author": "作者名",
  "publish_time": "2025-11-05",
  "content": "文章正文内容...",
  "error": null
}

🔧 技术细节

工作流程

  1. 用户发送URL和需求给大模型
  2. 大模型调用MCP工具
  3. MCP获取文章内容发送给大模型
  4. 大模型根据文章内容输出自然语言

技术栈

  • Python 3.10+
  • fastmcp - MCP框架
  • Playwright - 浏览器自动化
  • BeautifulSoup4 - HTML解析

📄 许可证

暂未提及相关许可证信息。

⚠️ 重要提示

  • 仅用于个人学习和研究
  • 遵守微信公众平台服务协议
  • 不建议高频爬取(建议间隔 > 2秒)
  • 不用于商业用途
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client