wechat-devtools-mcp

Automates WeChat Mini Program IDE control, debugging, testing, and deployment via MCP.

4|Updated May 16, 2026
One-click install
npx skills add https://github.com/reason-machines/devtools-skills --skill wechat-devtools-mcp-reason-machines
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: wechat-devtools-mcp
Source: https://github.com/reason-machines/devtools-skills/tree/main/skills/wechat-devtools-mcp
Command: npx skills add https://github.com/reason-machines/devtools-skills --skill wechat-devtools-mcp-reason-machines

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires uv, wechat-devtools-mcp, and includes references (resource) components.

What problem does it solve? AI coding agents cannot directly control the WeChat Developer Tools IDE, forcing developers to manually compile, preview, debug, and upload mini programs. This Skill wraps the WeChat DevTools CLI as an MCP server so agents can run the full mini program lifecycle programmatically. ## Core Features & Use Cases - IDE Lifecycle & Build/Deploy: Open, login, compile, generate preview QR codes, and upload releases with semantic versions through the wechat_ide and wechat_build tools. - Automated Testing & Debugging: Tap elements, input text, mock WeChat APIs, capture console/CDP logs, and take screenshots using wechat_automator, wechat_inspector, and wechat_screenshot. - Use Case: Run a full page health check by listing all pages with wechat_file, navigating to each one, capturing console logs, and flagging any page containing runtime errors before deployment. ## Quick Start Ask the agent to check the WeChat IDE connection status and then compile and preview the current mini program project.

Frequently Asked Questions about wechat-devtools-mcp

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate WeChat Mini Program testing with an AI agent?▼

Install the wechat-devtools-mcp server via uv, enable the IDE service port, and configure your MCP client. Then use wechat_automator actions like tap, input, and mock_wx to drive UI tests and wechat_inspector to capture console logs.

How to generate a WeChat mini program preview QR code from the CLI?▼

Call wechat_build with action 'preview' and set qr_format to 'terminal', 'image', or 'base64'. For image output, provide an absolute qr_output path, and run a compile action first to catch build errors.

Does wechat-devtools-mcp work on macOS and Windows?▼

Yes, it is cross-platform on Windows and macOS. Set WECHAT_DEVTOOLS_CLI to cli.bat on Windows or the cli binary inside wechatwebdevtools.app on macOS, and use escaped backslashes on Windows paths.

Why does wechat-devtools-mcp return connection refused errors?▼

Connection refused means the WeChat Developer Tools service port is disabled. Open the IDE, go to Settings, Security, Service Port, enable it, restart the IDE, and verify connectivity with wechat_ide action 'status'.

Why do wechat_automator commands time out during testing?▼

Timeouts usually mean the page has not fully loaded or the selector is invalid. Add a wait_for delay, verify the selector with element_info, and check the current navigation state with page_stack.

Can I mock WeChat APIs like wx.request in automated tests?▼

Yes, use wechat_automator action 'mock_wx' with the exact case-sensitive API name such as request or getStorage. Call mock_wx before triggering the API, and verify behavior by capturing console logs with wechat_inspector.