Lark Bot Integration
Configure Lark custom app event subscriptions and webhook callbacks to publish your FastGPT application as an interactive Lark bot.
Starting from version 4.8.10, FastGPT commercial edition supports direct Lark bot integration without additional APIs.

The screenshot shows the FastGPT configuration form. Enter credentials from your own platform application. Follow the official platform console linked below for its current console layout.
1. Create a Lark App
Creating a free test enterprise makes debugging easier.
- Create a custom enterprise app in the Lark Open Platform developer console.
Add a Bot capability to the app.
2. Get App ID and App Secret
In the Lark Open Platform developer console, find the App ID and App Secret for the custom enterprise app you just created, and copy them.
(Optional) In the Lark Open Platform developer console, go to Events & Callbacks -> Encryption Strategy to get the Encrypt Key, and copy it.
The Encrypt Key encrypts communication between Lark servers and FastGPT. If using HTTPS, the Encrypt Key is not needed. If using HTTP, the Encrypt Key is recommended. The Verification Token is generated by default for source verification. However, we use Lark's officially recommended, more secure verification method, so this configuration can be ignored.
3. Create a Publishing Channel in FastGPT
In FastGPT, select the App you want to integrate. On the Publishing Channels → Lark Bot page, click New in the upper-right corner, fill in the basic information, and enter the App ID and App Secret from the previous step (both required) plus the optional Encrypt Key to create the channel.
4. Configure Callback URL
After creating the publishing channel, click Request URL and copy the corresponding request URL.
In the Lark console, click Events & Callbacks on the left sidebar, click the edit icon next to Configure Subscription Method, and paste the copied request URL into the input field.
5. Configure Bot Callback Events and Permissions
- Add the
Receive Messageevent
On the Events & Callbacks page, click Add Event.
Search for Receive Message, or directly search for im.message.receive_v1, find the Receive Message v2.0 event, check it, and click Confirm Add.
After adding the event, enable the permissions below for the messages you intend to receive. Select the current permission versions offered by the platform.
- If "Read messages users send to the bot in private chats" is enabled, private messages sent to the bot will be forwarded to FastGPT
- If "Receive @bot message events in group chats" is enabled, messages @mentioning the bot in group chats will be forwarded to FastGPT
- If (not recommended) "Get all messages in groups" is enabled, all group chat messages will be forwarded to FastGPT
6. Configure Message Read and Reply Permissions
In the Lark console, click Permission Management on the left sidebar, enter send message in the search box, find the Send messages as the app permission, and enable it. Also search for group messages and enable Get private and group messages, then confirm the requested permissions.
7. Publish the Bot
Click Version Management & Publishing on the left side of the Lark console to publish the bot.
You can then find your bot in Lark Workplace. Next, add the bot to a group or chat with it privately.
Send Reset (case-sensitive) in chat to start a fresh session; if the bot does not respond, check callback URLs, permissions, and conversation logs via App, Chat, and Plugin FAQ.
Last updated