Setup
- Automatic configuration
- Manual configuration
You will need:
- In Botpress Studio, select Explore Hub in the upper-right corner.
- Search for the Slack integration, then select Install Integration.
- In the Configuration menu, select Authorize Slack.
- Follow the instructions to connect Botpress to your Slack account.
Options
The Slack integration’s Configuration menu offers a few additional options:Custom display name / avatar
- Fill in the Bot name field to display a custom name as the sender in Slack conversations.
- Fill in the Bot avatar URL field to set a custom image as the bot’s Slack avatar.
The image should be square, at least 512x512 pixels, and no larger than 1024x1024 pixels. The URL must be publicly accessible. Supported formats include GIF, PNG, JPG, JPEG, HEIC, and HEIF.
Typing indicator emoji
When the Typing indicator emoji option is enabled, the bot will react to incoming messages with an emoji to indicate that it’s processing the message.Reply threading
When the Reply Threading Enabled option is enabled, the bot will reply to incoming messages in threads. If you want the bot to only reply in a thread when mentioned, enable the Require Bot Mention for Reply Threading option.Limitations
Here are some limitations with the Slack integration:API rate limits
Standard Slack API limits apply to the Slack integration in Botpress. These include rate limits, message size restrictions, and other constraints imposed by the Slack platform. Ensure that your bot adheres to these limits to maintain optimal performance and reliability.For more information, check out the Slack API documentation.
Rich text processing
Slack uses a proprietary markup language, mrkdwn, to format rich text in messages. Since Botpress uses standard Markdown for rich text, we convert incomingmrkdwn
messages from Slack to Markdown. This is to ensure that:
- Studio’s interface can read them properly
- Botpress’ AI inference engine can understand them
Cards
Here’s a reference for all Cards available with the integration:Add Reaction
Input: Output: This Card has no output.Find Target
Input: Output:Get User Profile
Input: Output:Retrieve Message
Input: Output:Start DM Conversation
Input: Output:Start Typing Indicator
Input: Output: This Card has no output.Stop Typing Indicator
Input: Output: This Card has no output.Sync Members
Input: This Card has no input fields. Output:Update Channel Topic
Input: Output: This Card has no output.Triggers
Here’s a reference for all Triggers available with the integration:You can access data returned from any of these Triggers by reading
event.payload
after the Trigger fires.Member Joined Channel
Member Joined Workspace
Member Left Channel
Reaction Added
Reaction Removed
Workflow Webhook
Tags
You can read event tags to get information about an active Slack conversation:Slack conversation ID
To get the Slack conversation ID:event.tags.conversation["slack:id"]
Slack thread ID
To get the Slack conversation thread ID (if it’s a thread):event.tags.conversation["slack:thread"]
Slack user ID
To get the Slack user ID:event.tags.user["slack:id"]
Slack message ID
To get the Slack message ID:event.tags.message["slack:id"]