# 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. ## Install Merge the JSON below into your `.mcp.json`: ## Quick Use ```bash # Minimal stdio run (see docs: Using npx): SLACK_MCP_XOXP_TOKEN=xoxp-... npx -y slack-mcp-server@latest --transport stdio # Or use browser session tokens: SLACK_MCP_XOXC_TOKEN=xoxc-... SLACK_MCP_XOXD_TOKEN=xoxd-... npx -y slack-mcp-server@latest --transport stdio # Inspect locally (README): npx @modelcontextprotocol/inspector go run mcp/mcp-server.go --transport stdio ``` ## Intro Slack MCP server for channels, DMs, search, and smart history fetch via stdio/SSE/HTTP transports; verified 1594★, pushed 2026-04-30. **Best for:** Teams who want Slack as an agent tool surface (read-first by default, with explicit opt-in for write tools) **Works with:** Claude Desktop / Cursor MCP configs using `npx` (stdio/SSE), plus Slack OAuth tokens or browser session tokens **Setup time:** 15-30 minutes ### Key facts (verified) - GitHub: 1594 stars · 315 forks · pushed 2026-04-30. - License: MIT · owner avatar + repo URL verified via GitHub API. - README-backed entrypoint: `npx -y slack-mcp-server@latest --transport stdio`. ## Main - Start read-only: keep message posting and “mark as read” disabled until you have clear internal policy and channel allowlists. - Use smart history fetch to keep context tight: fetch by date/count and paginate when you need deeper context. - Pick an auth mode that matches your environment: OAuth tokens (`xoxp`/`xoxb`) vs browser session (`xoxc`/`xoxd`) tradeoffs are documented in README. - Add it to your MCP client config once, then standardize tool naming + allowlists so agents don’t spam Slack by accident. ### Source-backed notes - README lists supported transports (stdio/SSE/HTTP) and multiple auth approaches (OAuth tokens and browser session tokens). - Docs show `npx -y slack-mcp-server@latest --transport stdio` examples for Claude Desktop configuration. - README notes write tools (posting / marking as read) are disabled by default and enabled via environment variables. ### FAQ - **Is message posting enabled by default?**: No — README says posting tools are disabled by default and must be enabled explicitly. - **Which token should I use?**: Docs show XOXP (user), XOXB (bot), or XOXC/XOXD (browser session) options; choose based on access needs. - **Can I run it without editing config files?**: Docs mention DXT/installer options for desktop clients; npx is the fastest manual path. ## Source & Thanks > Source: https://github.com/korotovsky/slack-mcp-server > License: MIT > GitHub stars: 1594 · forks: 315 --- ## Quick Use ```bash # Minimal stdio run (see docs: Using npx): SLACK_MCP_XOXP_TOKEN=xoxp-... npx -y slack-mcp-server@latest --transport stdio # Or use browser session tokens: SLACK_MCP_XOXC_TOKEN=xoxc-... SLACK_MCP_XOXD_TOKEN=xoxd-... npx -y slack-mcp-server@latest --transport stdio # Inspect locally (README): npx @modelcontextprotocol/inspector go run mcp/mcp-server.go --transport stdio ``` ## Intro slack-mcp-server 是 Slack 工作区 MCP:支持频道/DM、搜索、按时间或数量的 Smart History,并提供 stdio/SSE/HTTP 传输;已验证 1594★,更新于 2026-04-30。 **Best for:** 想把 Slack 作为 agent 工具面、并默认只读(写入能力需显式开启)的团队 **Works with:** Claude Desktop / Cursor 的 MCP 配置(`npx` + stdio/SSE),以及 Slack OAuth token 或浏览器会话 token **Setup time:** 15-30 minutes ### Key facts (verified) - GitHub:1594 stars · 315 forks;最近更新 2026-04-30。 - 许可证:MIT;作者头像与仓库链接均已通过 GitHub API 复核。 - README 中可对照的入口命令:`npx -y slack-mcp-server@latest --transport stdio`。 ## Main - 先默认只读:在团队策略明确之前,不要开启发消息或“标记已读”这类写操作(README 也强调默认关闭)。 - 用 Smart History 控制上下文体积:按时间/数量抓取并分页,避免把整个频道历史塞进上下文窗口。 - 根据环境选认证:README 提到 OAuth token(`xoxp`/`xoxb`)与浏览器会话 token(`xoxc`/`xoxd`)的差异与注意点。 - 把 MCP 配置标准化:一次接入后统一工具命名与 allowlist,避免 agent 误操作或刷屏。 ### Source-backed notes - README 说明它支持 stdio/SSE/HTTP 多种 transport,并支持 OAuth token 与浏览器会话 token 等认证方式。 - 文档给出 `npx -y slack-mcp-server@latest --transport stdio` 的示例用法(面向 Claude Desktop 等)。 - README 提到写操作默认关闭,需要通过环境变量显式开启。 ### FAQ - **默认能发消息吗?**:不能;README 表明发消息等写工具默认禁用,需要显式开启。 - **用哪种 token?**:文档提供 XOXP(用户)、XOXB(bot)或 XOXC/XOXD(浏览器会话)三种路径,按权限与合规需求选。 - **能不改配置文件就装吗?**:文档提到桌面客户端的 DXT/安装器方式;手动最快是用 npx。 ## Source & Thanks > Source: https://github.com/korotovsky/slack-mcp-server > License: MIT > GitHub stars: 1594 · forks: 315 --- Source: https://tokrepo.com/en/workflows/slack-mcp-server-slack-mcp-with-stealth-oauth Author: MCP Hub