Connect DotCraft to WeCom
Connect a WeCom group bot to DotCraft as a channel with the callback settings from your enterprise admin console.
Quick setup
Open the target workspace in DotCraft Desktop.
Open Channels, select WeCom, then select Connect.

Set the callback listen host, port, and scheme. The default local listener is
0.0.0.0:9000.Add a robot entry with a callback path, Token, and EncodingAESKey.
Add at least one admin user, allowed user, or allowed chat.

Save the channel and turn it on.
In WeCom, set the group bot callback URL to the public URL that reaches the DotCraft listener.
Paste the same Token and EncodingAESKey into the WeCom bot settings.
Desktop should show the WeCom channel as connected after WeCom verifies the callback.
Platform setup details
In the WeCom admin console:
- Create or open the group bot that should call DotCraft.
- Enable callback mode.
- Set the callback URL to your public HTTPS endpoint plus the robot path from Desktop.
- Set Token to the same robot token from Desktop.
- Set EncodingAESKey to the same robot AES key from Desktop.
- Add the bot to the chats where DotCraft should respond.
WeCom must reach the callback from the public internet. For local Desktop use, put an HTTPS reverse proxy or tunnel in front of the Desktop listener.
Test the connection
- Send a message in an allowed WeCom chat.
- Confirm DotCraft replies in the same chat.
- Ask DotCraft to do something that needs approval.
- Confirm the approval request appears in WeCom and that your reply is accepted.
What works after setup
- DotCraft answers messages from allowed users and chats.
- Admin users can approve higher-risk actions from WeCom.
- Approval replies accept
同意,允许,yes,approve,拒绝,no,reject, anddeny. Replying同意全部orapprove allallows the same kind of action for the rest of the session. - File and image delivery are available through channel delivery tools.
- Messages from users or chats outside the allowlist are ignored.
Standalone adapter
Run the WeCom adapter yourself only when Desktop is not managing the channel process.
cd sdk/typescript
npm run build --workspace @dotcraft/channel-wecom
npx dotcraft-channel-wecom --workspace /path/to/workspaceThe standalone ExternalChannels registration is in the channel configuration reference.
Related docs
- Channel configuration reference — every field, default, and registration shape for the WeCom config file.
- Channel adapters — the adapter base class, its message flow, and the handler contract.
- Weixin channel — personal WeChat takes a different route, through a Tencent iLink QR login.