MCP Gateway · OpenCode
Connect Slack to OpenCode
OpenCode can look things up in Slack and post updates while you stay in the terminal. You add the Slack server to the mcp block of your OpenCode config as a remote server, sign in when prompted, and from then on every Slack tool call passes through the Speakeasy gateway under your role.
- Category
- Communication
- Tools
- 13
- Authentication
- OAuth
- OpenCode
- Terminal
Behind the MCP Gateway
Run Slack MCP behind the MCP Gateway
One URL for every agent, sign-in through your IdP, RBAC down to the tool, and every Slack call inspected and logged.
Before you start
What Slack needs first
A user who can create or manage a Slack app, plus any required workspace-admin approval does the Slack side of the setup.
- You need permission to create or manage the app and any required workspace-admin approval.
- Only internal apps and Slack Marketplace apps can use the MCP server.
- Each user authorizes with their own Slack account. No bot token or API key is used.
In Slack
- Create the app from Speakeasy's prefilled manifest link, or enable MCP on an existing app.
- Remove any user scopes you do not want to grant.
- Copy the app's client credentials.
Set up
Add Slack to OpenCode in 4 steps
- 01
Add Slack from the catalog
An admin finds Slack in the MCP Catalog (MCP Gateway > MCP > Catalog) and clicks Add. Speakeasy registers the vendor's server as a remote MCP server and proxies sessions to it. Nothing is copied or re-hosted.
Slack uses OAuth. Servers that support dynamic client registration get their OAuth configuration applied automatically.
Where MCP-scoped policies are enabled, the install offers a recommended risk policy for the new server that detects secrets and PII and inspects tool requests and responses.
- 02
Choose who can use Slack
Give teams the
mcp:connectscope on the Slack server through team access or a role. OpenCode connects to the Slack server's own URL, and the server's authorization decides who can connect and which tools they can call. - 03
Connect OpenCode
Add the server to OpenCode's own mcp config block as a remote server.
Copy the server's URL from its hosted install page in Speakeasy.
Add it to the
mcpblock of your OpenCode config withtypeset toremote.Restart OpenCode and sign in when prompted.
{ "mcp": { "<server slug>": { "type": "remote", "url": "<URL from the hosted install page>" } } } - 04
Sign in and use Slack from OpenCode
The first time OpenCode connects, it opens a browser so the person can sign in to Speakeasy through your identity provider.
Slack needs its own OAuth grant, so each person connects it once. Until they do, Slack calls fail while the rest of the gateway keeps working.
From then on, Slack's tools appear in OpenCode, limited to what the person's access allows, and every call lands in the gateway's tool logs.
OpenCode doesn't receive MCP servers from plugins. The observability package is installed separately, from a ZIP or with speakeasy-hooks install --provider=opencode, and the device agent can maintain it.
Use cases
What OpenCode users do with Slack
Ask for review in the right channel
When a branch is ready, OpenCode finds the team's review channel by name and posts the summary and pull request link there, then gives you the link to the message.
Find a decision made in private
If an approach was agreed in a private channel or a DM, OpenCode searches across all your channels to find it before you change the code it affects.
Follow an incident thread while fixing
Point OpenCode at the incident thread and it reads every reply, so the latest findings from on-call are in the session while you write the patch.
Tools
13 tools
Each Slack tool can be allowed or denied per team and role at the MCP Gateway before OpenCode sees it.
slack_send_message
Sends a message to a Slack channel or user. To DM a user, use their user_id as channel_id. Return the message link to the user.
slack_schedule_message
Schedules a message for future delivery to a Slack channel. Does NOT send immediately — use slack_send_message for that.
slack_create_canvas
Creates a Slack Canvas document from Canvas-flavored Markdown content. Return the canvas link to the user. Not available on free teams.
slack_update_canvas
Updates an existing Slack Canvas document with markdown content. Supports appending, prepending, or replacing content.
slack_search_public
Searches for messages, files in public Slack channels ONLY.
slack_search_public_and_private
Searches for messages, files in ALL Slack channels, including public channels, private channels, DMs, and group DMs.
Control
What Speakeasy can see and stop in OpenCode
The gateway covers every client the same way. The rest depends on what OpenCode exposes to Speakeasy.
Tool logs
Gateway
Every Slack call is logged with the person and the client that made it.
Access by role
Gateway
People reach only the Slack tools their team or role allows.
Request and response blocking
Gateway
A risk policy scoped to Slack can reject a tool request before it reaches the server, or withhold a result from OpenCode. MCP-scoped policies are enabled per organization.
Prompt and tool-call blocking
OpenCode
The OpenCode plugin sends each prompt and tool call to Speakeasy, which allows or denies it before it runs.
Usage telemetry
OpenCode
Token and cost totals flow through the plugin, reported per turn.
Device agent
OpenCode
The device agent installs and maintains the observability package.
- OpenCode has no OpenTelemetry exporter, so session data comes through the plugin.
- Tool output is blocked at the gateway rather than in OpenCode's hooks.
Questions
Frequently asked questions
Does Slack reach OpenCode through a Speakeasy plugin?
Can Speakeasy block Slack tool output in OpenCode?
How do OpenCode users get Slack?
Are Slack calls from OpenCode logged?
Connect more