Skip to main content

Adding Slack as a Custom MCP

Adding Slack as a Custom MCP

Use this guide to connect Slack's hosted MCP server to Hatz through Workshop > Connections > Custom MCP Servers. This setup uses Slack's MCP endpoint and OAuth flow, so each Hatz user connects with their own Slack account.

Exact values to use

Copy the redirect URL exactly, including https and the full path, with no trailing slash.

How Slack MCP works

Slack exposes a hosted MCP server at https://mcp.slack.com/mcp. Hatz connects to that server with OAuth. After a user connects, Hatz can use the Slack MCP tools allowed by the Slack user token scopes granted during setup.

Who does what

  • Slack admin: Create one Slack app, set the redirect URL, choose User Token Scopes, install the app to the workspace, and share the Client ID and Client Secret through a secure channel.

  • Hatz admin: Make sure Custom MCP Servers are enabled for the tenant so users can open the Custom MCP Servers tab under Workshop > Connections.

  • Each Hatz user: Add the Slack MCP server, enter the Client ID and Client Secret, and complete OAuth in the browser as themselves.

Set up Slack

  1. Open api.slack.com/apps and click Create New App.

  2. Choose From scratch, enter an app name, select the Slack workspace, and create the app.

  3. Open OAuth & Permissions.

  4. Under Redirect URLs, add https://api.hatz.ai/v1/connections/oauth-callback and save the URL.

  5. Under User Token Scopes, add the scopes your team needs. Common scopes include search:read.public, search:read.private, channels:history, groups:history, im:history, mpim:history, chat:write, and users:read.

  6. Install or reinstall the app to the workspace and approve the requested permissions.

  7. Open Basic Information > App Credentials, then copy the Client ID and Client Secret. Treat the Client Secret like a password.

Slack's MCP setup requires confidential OAuth with a Client ID and Client Secret. In Hatz, choose I have credentials instead of Auto-detect for this Slack MCP flow. Slack also requires the app to be an internal workspace app or a Marketplace-published app, and workspace admins may need to approve MCP usage.

Connect Slack in Hatz

  1. In Hatz, open Workshop > Connections > Custom MCP Servers.

  2. Click Add Server.

  3. Enter a name such as Slack.

  4. Enter https://mcp.slack.com/mcp as the Server URL.

  5. Select OAuth as the authentication method.

  6. Choose I have credentials, then enter the Slack Client ID and Client Secret.

  7. Click Connect with OAuth and complete the Slack approval flow in your browser.

  8. After the server shows Connected, use Discover Tools if the tool count has not appeared yet.

  9. Open chat and select the Slack MCP server in the tool picker when you want to use it.

Troubleshooting

  • Redirect URI mismatch or Auth Failed: Confirm the redirect URL in Slack exactly matches https://api.hatz.ai/v1/connections/oauth-callback. Also confirm the Client ID and Client Secret in Hatz match the Slack app.

  • Not Connected: Use Connect, Authenticate, or Reconnect from the server card, then finish the Slack approval flow.

  • No tools appear: Confirm the Server URL is exactly https://mcp.slack.com/mcp, add any missing Slack User Token Scopes, reinstall the Slack app, and run Discover Tools again.

  • Custom MCP Servers tab is missing: Ask a Hatz admin to enable Custom MCP Servers for the tenant.

  • Auto-detect was selected: Delete the server entry and add it again using I have credentials.

Did this answer your question?