Slack MCP Server — Slack Integration for AI
MCP server for Slack workspace integration. Read channels, post messages, search conversations, and manage threads from Claude Code or Cursor.
这个资产会安全暂存
这个资产会先安全暂存。复制的指令会要求 Agent 读取暂存文件,并在激活脚本、MCP 配置或全局配置前先确认。
npx -y tokrepo@latest install c35881e9-8330-40bc-a66c-ed34be4d8023 --target codex先暂存文件;激活前需要读取暂存 README 和安装计划。
What it is
This Slack MCP Server provides Slack workspace integration for AI tools via the Model Context Protocol. It lets AI assistants like Claude Code and Cursor read channels, post messages, search conversations, and manage threads within Slack workspaces. The server runs locally and communicates with the Slack API using a bot token.
This integration targets developers who want their AI coding tools to participate in team communication without switching to the Slack app. The AI agent reads context from channels and posts updates directly.
Why it saves time or tokens
Context switching between coding and team communication breaks focus. This MCP server keeps everything in one interface. The AI agent can search Slack history for past decisions, post code review summaries to channels, and notify teams about deployments without the developer leaving their editor.
How to use
- Create a Slack Bot with the necessary OAuth scopes in your Slack workspace settings
- Add the MCP server configuration to your AI tool's settings with the bot token
- Use natural language to instruct the agent to interact with Slack
Example
{
'mcpServers': {
'slack': {
'command': 'npx',
'args': ['-y', 'slack-mcp-server'],
'env': {
'SLACK_BOT_TOKEN': 'xoxb-your-bot-token',
'SLACK_TEAM_ID': 'T01234567'
}
}
}
}
Example agent commands:
- 'Read the last 10 messages in #engineering'
- 'Post to #releases: v3.2.0 deployed successfully'
- 'Search Slack for database migration discussions'
| Capability | Description |
|---|---|
| Read channels | Fetch recent messages and history |
| Post messages | Send to any channel the bot joined |
| Search | Full-text search across workspace |
| Threads | Reply to and manage threads |
| Users | Look up user profiles |
Related on TokRepo
- MCP Slack integration — dedicated Slack MCP page on TokRepo
- AI tools for automation — communication automation tools
Common pitfalls
- The bot must be explicitly invited to each channel it needs to access; it cannot read channels it has not joined
- Slack rate limits apply to bot API calls; rapid operations may be throttled
- Bot tokens with broad scopes can read sensitive channels; use the principle of least privilege when configuring OAuth scopes
常见问题
The bot needs channels:read and channels:history to read public channels, chat:write to post messages, search:read to search history, and users:read for user lookups. For private channels, add groups:read and groups:history. Configure only the scopes you need.
Yes, if the bot has groups:read and groups:history scopes and has been invited to the private channel. The bot cannot discover or access private channels without an explicit invitation from a channel member.
Yes. Any AI tool that supports the Model Context Protocol can use this server. Claude Code and Cursor both support MCP servers through their configuration files. Add the server entry and the tool automatically discovers Slack capabilities.
No. The MCP server runs locally on your machine. Slack data is fetched from the Slack API and passed to your AI tool locally. The only external communication is between the server and Slack's official API endpoints over HTTPS.
Yes. The MCP server supports thread operations. You can instruct the agent to reply to a specific message thread by referencing the thread timestamp. This keeps discussions organized and avoids cluttering the main channel.
引用来源 (3)
- MCP Specification— MCP servers connect AI tools to external services
- Slack API Docs— Slack Bot API for programmatic workspace access
- Slack Scopes— Slack OAuth scopes for bot permissions
来源与感谢
Created by Anthropic. Licensed under MIT. modelcontextprotocol/servers
讨论
相关资产
Slack MCP — Team Messaging Server for AI Agents
MCP server that connects AI agents to Slack workspaces. Send messages, read channels, search history, manage threads, and automate team communication via natural language. 1,500+ stars.
Notion MCP Server — Official Notion Integration
Official Notion MCP server. Search, read, create, and update Notion pages, databases, and blocks from Claude Code, Cursor, or any MCP client. By Notion. 4.1K+ stars.
slack-mcp-server — Slack MCP with Stealth/OAuth
Slack MCP server for channels, DMs, search, and smart history fetch via stdio/SSE/HTTP transports; verified 1594★, pushed 2026-04-30.
WhatsApp MCP Server — Chat with WhatsApp via AI Agents
MCP server connecting Claude and AI agents to your personal WhatsApp. Search contacts, read messages, send replies and media via natural language.