WeCom Bot MCP Server
A Python server implementation for WeCom (WeChat Work) bot that follows the Model Context Protocol (MCP). This server provides a standardized interface for handling automated messaging and context-aware interactions within enterprise WeChat environments.
Overview
WeCom Bot MCP Server is a Python server implementation designed for WeCom (WeChat Work) bots that adheres to the Model Context Protocol (MCP). It provides a standardized interface for automated messaging and context-aware interactions within enterprise WeChat environments.
To use the WeCom Bot MCP Server, set the environment variable for your WeCom bot webhook URL, run the server, and then you can send messages using the provided functions.
- Built on the FastMCP framework - Supports Markdown message format - Asynchronous message sending - Message history tracking - Complete type hints for better development experience - Comprehensive unit tests to ensure reliability
- Automating responses in enterprise WeChat environments.
- Sending notifications and alerts to team members.
- Tracking message history for compliance and auditing purposes.
Add to your AI client
Use these steps to connect WeCom Bot MCP Server in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.
Cursor
Add this to your .cursor/mcp.json file in your project root, then restart Cursor.
.cursor/mcp.json
{
"mcpServers": {
"wecom-bot-mcp-server-loonghao": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-wecom-bot-mcp-server-loonghao"
]
}
}
}Claude Desktop
Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.
~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)
{
"mcpServers": {
"wecom-bot-mcp-server-loonghao": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-wecom-bot-mcp-server-loonghao"
]
}
}
}Claude Code
Add this to your project's .mcp.json file. Claude Code will detect it automatically.
.mcp.json (project root)
{
"mcpServers": {
"wecom-bot-mcp-server-loonghao": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-wecom-bot-mcp-server-loonghao"
]
}
}
}VS Code (Copilot)
Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.
.vscode/mcp.json
{
"servers": {
"wecom-bot-mcp-server-loonghao": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-wecom-bot-mcp-server-loonghao"
]
}
}
}Windsurf
Add this to your Windsurf MCP config file, then restart Windsurf.
~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"wecom-bot-mcp-server-loonghao": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-wecom-bot-mcp-server-loonghao"
]
}
}
}Cline
Open Cline settings, navigate to MCP Servers, and add this server configuration.
Cline MCP Settings (via UI)
{
"mcpServers": {
"wecom-bot-mcp-server-loonghao": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-wecom-bot-mcp-server-loonghao"
]
}
}
}