Wechat binding

From Starchild-ai-agent/official-skills · View interactive version

Wechat binding is an AI agent skill from the GitHub repository Starchild-ai-agent/official-skills. WeChat binding: QR scan, bind, unbind, reconnect, status check. Use when setting up or repairing WeChat delivery (e.g. connect WeChat, scan QR, why isn't WeChat pushing, disconnect WeChat).

How to use this skill

Skill file

📱 WeChat Binding

Connect / reconnect / disconnect the user's WeChat account so the agent can push messages via send_to_wechat.

The wechat tool stays built-in. This SKILL.md is the reference doc.

See also


Typical binding flow

qrcode → user scans → qrcode_status(qrcode=...) → connect(bot_token=...)
  1. Generate QR: wechat(action="qrcode") — saves an image to workspace, returns qrcode (id) + file_path.
  2. Show the QR to the user. On web channel: include the file_path so the frontend renders the image. On TG/WeChat channel: send the image via send_to_telegram with the file_path.
  3. Wait for the user to scan + confirm in WeChat. Don't auto-poll — let them say "scanned" / "done" first.
  4. Poll for completion: wechat(action="qrcode_status", qrcode=<id from step 1>). Returns bot_token once scan + confirm completes.
  5. Connect: wechat(action="connect", bot_token=<from step 4>). Optional: ilink_bot_id, ilink_user_id if the user has multiple WeChat accounts.
  6. Confirm to user: "WeChat connected. You can now push messages with send_to_wechat."

Actions

| action | required | purpose |

|---|---|---|

| status | — | Current WeChat connection state. Use before reconnect, to verify binding. |

| qrcode | — | Generate QR code image (saved to workspace). Returns qrcode id + file_path. |

| qrcode_status | qrcode | Poll whether user has scanned + confirmed. Returns bot_token on success. |

| connect | bot_token | Complete a NEW WeChat connection (after first-ever QR scan). Optional: ilink_bot_id, ilink_user_id. |

| disconnect | — | Terminate current WeChat session (unlink). |

| reconnect | bot_token | Re-establish a previously-bound WeChat (token from a fresh QR scan). |


connect vs. reconnect

When in doubt, call status first:


Channel-aware QR display

| User channel | How to show the QR |

|---|---|

| Web | Include file_path in your reply — frontend renders it inline |

| Telegram | send_to_telegram(file_path=<qr_path>, message_type="photo") |

| WeChat | (You can't — they're trying to bind WeChat in the first place. Tell them to open the web app.) |


Critical rules

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.