mcp_server_wechat

mcp_server_wechat

9

The MCP Server WeChat automates WeChat message retrieval and sending using the MCP technology, specifically built atop the pywechat tool. It features functions to retrieve message history and send customizable messages, supporting single and bulk messaging workflows efficiently.

Overview

The MCP Server WeChat is a server utilizing the Model Context Protocol (MCP) for automating WeChat operations through the pywechat tool.### Features

  • Retrieve WeChat chat history by date
  • Send a single message to one friend
  • Send multiple messages to one friend
  • Send a single or multiple messages to multiple friends

Installation

Install using pip:

pip install mcp_server_wechat

Upgrade to the latest version:

pip install --upgrade mcp_server_wechat

Usage Example

Configure as MCP Service

Add the following to your MCP configuration:

"mcpServers": { "wechat": { "command": "python", "args": ["-m", "mcp_server_wechat","--folder-path=history-folder"] } }

Debugging

Use MCP inspector to debug the server:

npx @modelcontextprotocol/inspector python -m mcp_server_wechat

Notes

  • WeChat desktop version must remain logged in
  • Ensure WeChat window is operable when retrieving chats or sending messages
  • Avoid manual operations to prevent interference with automation