跳到主要内容

通过接口将 Bot 加入群聊

如果你需要通过后端程序控制 Bot 入群,可以调用加群接口完成自动化接入。

你需要准备什么

  • bot_id
  • bot_token
  • 目标群聊 ID
curl --location 'https://api-coco.typex.im/open/robot/add_chat' \
--header 'Authorization: Bearer <bot_token>' \
--header 'Content-Type: application/json' \
--data '{
"bot_id": "your_bot_id",
"feed_id": "target_group_id"
}'