A Feishu (Lark) channel plugin for Clawdbot, enabling your AI assistant to communicate through Feishu messaging platform.
- ✅ Direct messages (1:1 chat)
- ✅ Group chat support
- ✅ WebSocket-based real-time messaging
- ✅ Seamless integration with Clawdbot agents
- ✅ Image support - Send and receive images
- ✅ Video support - Send video files with auto-generated thumbnails
- ✅ Audio support - Send audio messages
- ✅ File support - Send any file type
- Clawdbot installed and configured
- A Feishu developer account
- A Feishu application with bot capabilities
- Clone the repository:
cd ~/.clawdbot/extensions
git clone https://github.com/nil957/clawdbot-feishu.git feishu
cd feishu- Install dependencies:
npm install- Go to Feishu Open Platform
- Create a new application (or use an existing one)
- Navigate to Add Capabilities → Enable Bot
- Configure Events and Callbacks:
- Go to Events and Callbacks → Subscription method
- Select Use WebSocket to receive events (使用长连接接收事件)
- Go to Events and Callbacks → Add Event, add:
im.message.receive_v1(Receive messages)
- Go to Permissions & Scopes, add the following permissions:
im:message- Read and send messagesim:message:send_as_bot- Send messages as botim:chat:readonly- Read chat info (for group chats)im:resource- Upload images and files
- Create App Version and Publish (or enable development mode for testing)
- Go to Credentials & Basic Info, copy:
- App ID (starts with
cli_) - App Secret
- App ID (starts with
Add the following to your ~/.clawdbot/clawdbot.json:
{
"plugins": {
"entries": {
"feishu": {
"enabled": true,
"config": {
"appId": "cli_xxxxxxxxxx",
"appSecret": "your-app-secret-here"
}
}
}
}
}Note: If your
clawdbot.jsonalready has other content, merge thefeishusection into the existingplugins.entriesobject.
- Restart Clawdbot gateway:
clawdbot gateway restart- Verify the plugin is loaded:
cat /tmp/clawdbot/*.log | grep -i "feishu.*registered"You should see: [feishu] Plugin registered, appId: cli_xxx
- Start chatting:
- Open Feishu and find your bot
- Send a direct message to start a conversation
- In group chats, @mention the bot to trigger a response
-
Check if the plugin is loaded:
cat /tmp/clawdbot/*.log | grep -i feishu
-
Verify WebSocket connection: Look for
[feishu] WebSocket client startedin the logs. -
Check for errors:
cat /tmp/clawdbot/*.log | grep -iE "feishu.*error"
-
Common issues:
- App ID or App Secret is incorrect
- WebSocket subscription not enabled in Feishu console
- Bot permissions not configured
- App not published (try enabling development mode first)
- Verify your network can reach Feishu servers
- Check if a firewall is blocking WebSocket connections
- Try restarting the gateway:
clawdbot gateway restart
- Check if Clawdbot agent is configured correctly
- Verify LLM provider settings in
clawdbot.json - Look for agent errors in logs:
cat /tmp/clawdbot/*.log | grep -i agent
MIT