Credentials. Feishu, QQ, and DingTalk app secrets and tokens grant access to live accounts and must stay in .env, not in code.
Who it is forA team lead whose users are split across Feishu, DingTalk, and QQ and who wants one bot behavior everywhere.
The problemWriting separate handlers for each IM platform duplicates agent logic and multiplies maintenance work.
The outcomeOne async processor that answers messages from three platforms, with the source shown in the reply.
What you need first
- Python 3.12+
- Credentials for each platform you connect, such as a Telegram bot token, Feishu app ID and secret, or a Discord bot token
- Access to the developer portal of each platform you use
- A processor function that reads InboundMessage and yields MessageEvent objects
Steps
- Run
pip install "octop-gateway[examples]"to install the library with the example extras. - Copy
.env.exampleto.envand fill in FEISHU_APP_ID, FEISHU_APP_SECRET, QQ_APP_ID, QQ_TOKEN, QQ_SECRET, DINGTALK_APP_KEY, and DINGTALK_APP_SECRET. - Write one async processor that yields MessageEvent.text and MessageEvent.completed, using msg.channel_type in the reply.
- Create a ChannelManager with that processor, then call add_feishu_channel, add_qq_channel, and add_dingtalk_channel with their config objects.
- Send a test message from each platform and confirm the reply includes the channel type.
Prompt for your agent
In the TencentCloud/octop-gateway repo, build a ChannelManager that attaches Feishu, QQ, and DingTalk channels to one processor using credentials from my .env file. Expected output: a running process that replies to a test message from each platform with the channel type in brackets. Verify that all three channels start without errors in the logs.
Caveat. Each platform needs its own app or bot set up in its developer console, which the README does not walk through.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for TencentCloud/octop-gateway and "Serve one agent on Feishu, DingTalk, and QQ at once"
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer