Slack
The Slack connector allows AI agents to read workspace messages, post to channels, search content, and manage basic channel settings. It uses a Slack OAuth app under the hood — your workspace credentials are stored encrypted in MCPGate's vault.
Bot vs. user token
Tool reference#
The Slack connector exposes 8 tools across two categories: read (4 tools) and write (4 tools).
| Tool | Category | Description |
|---|---|---|
| slack_list_channels | read | List all channels the bot is a member of |
| slack_read_messages | read | Read messages from a channel or DM thread |
| slack_search | read | Full-text search across messages and files |
| slack_list_users | read | List workspace users and their profiles |
| slack_post_message | write | Post a message to a channel or DM |
| slack_set_topic | write | Update a channel topic or purpose |
| slack_add_reaction | write | Add an emoji reaction to a message |
| slack_upload_file | write | Upload a file to a channel |
Common guardrail recipes#
Read-only access#
Enable only the four read tools (slack_list_channels, slack_read_messages, slack_search, slack_list_users) and deny the write tools. This prevents the agent from posting any messages or modifying channels.
Block mass mentions#
Apply the block_mass_mentions template to slack_post_message. This prevents the AI from posting messages that include @channel, @here, or @everyone — reducing accidental noise in active channels.
Restrict to specific channels#
Apply the allow_values template to slack_post_message and target the channel field. Provide a list of channel IDs the agent is permitted to post to. Any attempt to post elsewhere will be denied.
Troubleshooting#
- Channel not found — The agent can only access channels you are a member of. Ensure your Slack account has joined the target channel before calling
slack_read_messages. - Search returns no results — Slack search requires at least one character. Empty queries return an error rather than all messages.
- File upload fails —
slack_upload_fileaccepts content as a base64 string. Ensure the AI client is encoding the file correctly before passing it to the tool.