Slack
The Slack integration allows your Vapi assistant to send messages to a pre-configured Slack channel during phone calls. This enables your assistant to notify team members, send updates, or share information directly through Slack.
Prerequisites
Before you can use the Slack integration, you need to:
- Have a Slack workspace
- Have access to the Vapi Dashboard
- Have an assistant created in Vapi
- Have a Slack channel created where messages will be sent
Setup Steps
1. Connect Slack Account
First, you need to connect your Slack workspace to Vapi:
- Open the Vapi Dashboard and select Integrations.
- Under Tool Providers, select Slack.
- Select Connect and complete the Slack authorization prompts.
The authorization process will request access to send messages to your Slack workspace.
2. Create Slack Tool
After connecting your Slack workspace, create the tool:
- Select Tools in the Dashboard, then select Create Tool and Slack.
- Provide a name and description explaining when the tool should be invoked.
- In the description, specify the Slack channel where messages should be sent (for example, “Send urgent notifications to the #customer-support channel”).
The description field is crucial as it helps the AI model understand when and how to use the tool, and also specifies which channel to send messages to. Be specific about the scenarios, conditions, and target channel when the tool should be invoked.
3. Add Tool to Assistant
Now, add the Slack tool to your assistant:
- Select Assistants in the Dashboard and open your assistant.
- Open the Tools tab, select Add tool, then choose the Slack tool.
- Select Publish, review the changes, select Next, then select Publish to apply the draft.
Tool Configuration
Slack Send Message Tool
This tool sends messages to Slack channels based on the configuration specified in the tool’s description:
- The target channel is specified in the tool’s description field
- The message content is dynamically generated by the AI based on the conversation context
The channel name should be specified in the description in the format “#channel-name”. Make sure the bot has been added to the channel before sending messages.
Example Usage
Here’s how the tool can be used in your assistant’s configuration:
Best Practices
- Channel Selection: Always verify the correct channel name before sending messages
- Message Formatting: Use clear and concise language in your Slack messages
- Error Handling: Include fallback responses for cases where the tool fails
- User Confirmation: Always confirm with the user before sending notifications to Slack
- Channel Access: Ensure the Slack bot has been added to the target channel