auth
Interactive credential setup: walks through capturing Slack session tokens via a localhost helper. Tokens never leave this machine.
valueaction
io.github.aaronsb由 GitHub 账号 aaronsb 发布v2.8.1更新于 Oct 29, 2026
Read and write Slack with session tokens — no OAuth, no bot, no admin approval.
使用你自己的浏览器会话令牌让助手读写 Slack,支持收件箱整理、搜索、关系视图和发送安全闸门。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
参照 仓库 中的启动说明。
[License] [GitHub stars] [Latest Release]
MCP server that gives AI agents access to your Slack workspaces using session tokens. No OAuth apps, no bot permissions, no admin approval required.
Beyond reading and writing messages, it accumulates a durable picture of the workspace — every channel and user's state over time, departures kept as dated tombstones — and synthesizes a relationship graph from it on demand: estate view='about' person='X' answers "tell me about X" with their footprint, circle, and a ranked reading plan. The graph is never maintained as a store; it is computed per query from two small local ledgers that hold no message content (design note). Add render='graph' to draw one view as a static HTML page you open locally.
Slack MCP uses your existing browser session tokens (xoxc/xoxd) to interact with Slack on your behalf. It reads stealthily by default — only the mark-read tool triggers read receipts. Everything else is invisible to other users.
Token extraction is built into the binary. If you're logged into Slack in Chrome or Firefox, the setup flow can extract tokens automatically — no copy-pasting from DevTools.
You need an active Slack session in your browser. Log into your workspace at app.slack.com in Chrome, Chromium, Edge, or Firefox before running setup.
Then ask Claude to run the auth tool. It will guide you through browser selection, profile selection, and automatic token extraction.
Download the .mcpb file for your platform from the latest release:
Open the file (double-click or drag into Claude Desktop). When prompted for tokens, you can either:
auth tool after connectingDownload the binary for your platform from releases, then:
There are three ways to get your Slack tokens, from easiest to most manual:
The auth MCP tool or slack-mcp setup CLI command will:
Requires Chrome to be fully closed before extraction — your tabs will restore when you reopen it.
The setup flow writes a temporary browser extension to a temp directory, then guides you to load it in Firefox via about:debugging. The extension extracts tokens and sends them to the local callback server. It's removed automatically when Firefox closes.
Run slack-mcp setup or use the auth tool — if no browser is detected or automatic extraction fails, it falls back to a localhost web page with step-by-step DevTools instructions.
You can also set tokens directly via environment variables:
Settings come from the environment your MCP client config provides. A .env file in the working directory may set only SLACK_MCP_PERSONALITY and SLACK_MCP_NO_BROWSER, and never overrides a variable the environment already sets. If .env sets any other key the environment does not, the server refuses to start and names the key; set it in the client config instead.
Over stdio the server exits cleanly when its client is gone: stdin closes, a termination signal arrives (SIGTERM, SIGINT, SIGHUP), or its parent process exits. Each exit flushes the caches and releases the ledger locks, so the next instance is not left read-only. On Windows, the npm wrapper's child.kill terminates the server forcibly, so this graceful shutdown does not run there.
Remote deployment is experimental and has not been tested against a real SSH session. Whether the server supports remote use at all, and in what form, is still open (see #102). Nothing below applies unless you set SLACK_MCP_DEPLOYMENT=remote.
A wedged connection, such as a half-open SSH session, leaves the pipe open with nobody reading it. Only an idle timeout catches that, and it is valid only where it can happen, so the server ties the timeout to how it is deployed:
The deployment is local unless you declare it. The server does not detect it: SSH_CONNECTION only means some ancestor logged in over SSH (running claude in an SSH session, VS Code Remote-SSH), not that the MCP pipe crosses SSH. Only the MCP client config that launches the server knows, so declare remote there, in the entry that starts the server over SSH. ssh does not forward your environment, so pass the variable through the remote command line with env:
(ssh joins the arguments into one remote command line, so this runs env SLACK_MCP_DEPLOYMENT=remote slack-mcp on the host. Setting it in the client's env block does not work, because that only reaches the local ssh process.) A timeout set where it is not allowed, or a value that does not parse, stops the server at startup with the reason on stderr.
Verb encodes effect, noun encodes domain, parameter encodes scope (ADR-009); the batch executor encodes composition, never effect, and admits only the read nouns (ADR-010). Every noun echoes its effective parameters and pages every capped list.
Everything this server posts is attributed to your account, and the agent reads text anyone in the workspace can write. So every say passes a fixed order before any content reaches Slack or any DM is opened (ADR-013):
say and mark-read is refused until you clear it (CLI, or the unlock page).say and mark-read; reads keep working.strict) a file download took from another conversation, waits for you as a pending request. Nothing is sent until you approve it.Two settings in your MCP client config shape this (ADR-014); .env cannot set them:
A block posts the notice into the quarantined conversation, never to a destination outside your organization and never to a person with no DM. Blocks, pending requests, and sends trust let through are logged as outbound-safety: BLOCKED, PENDING, and TRUSTED lines (destination, IDs, class, counts; never content). When state needs you, inbox, messages, estate, and batch results open with a banner.
A block that cannot be written to the quarantine file holds every say and mark-read in that server process (in memory) and issues a lift request (lift=strikes). Fix the file, then approve the request or run slack-mcp quarantine clear strikes; either clears every recorded strike. The clear releases the hold only when the file was readable as the hold engaged and has not been replaced or edited since; otherwise approve the request. A restart also releases the hold, and the unrecorded strike is lost. A download whose provenance cannot be recorded fails and its file is deleted (the result says so if the deletion fails too); provenance that cannot be read, or has a malformed line, makes attachments with no record need approval in strict, and the request (and its PENDING log line, provenance=…) says to repair provenance.jsonl. Reaction names must be emoji names ([a-z0-9_+'-], optionally ::skin-tone-2…6).
You answer from a terminal:
A client on MCP protocol 2026-07-28 or later that declares elicitation on the call is also asked in-band to approve once, deny, or (in soft) approve and trust; every other client, and every SSE session, uses the CLI. Elicitation never lifts a quarantine or the lock.
Without a terminal (Claude Desktop and other desktop clients), ask the agent to clear a lock. It calls unlock, which opens a page on 127.0.0.1 in your browser listing each quarantined person or conversation and the strike lock, with what the scanner found (the kind of secret, the field, where it was going, and when; never the value). Check what to clear and press Clear, or press Done to close without clearing; either closes the page, and the link stops working. If the locks changed after you loaded the page, Clear applies nothing and shows them again. A page nobody loads or answers for fifteen minutes closes. Clears from the page are recorded as by=web, beside the CLI's by=cli. The agent never sees the page's link; if no browser can be opened (or SLACK_MCP_NO_BROWSER is set), unlock refuses and points at the CLI. It is also unavailable under SLACK_MCP_DEPLOYMENT=remote and over SSE, where the page would open on a host that need not be yours.
The page is friction, not a barrier: an agent that can drive your browser can click Clear. For an unattended agent, deny it the unlock tool and any browser automation in the client's permissions, so only the CLI clears.
The state lives beside the estate ledger, in $XDG_DATA_HOME/slack-mcp/ledger/<team>/ (quarantine.jsonl, pending.jsonl, trust.jsonl, provenance.jsonl, each 0600). They are append-only JSON lines, and a running server rereads them on every gated call, so editing or deleting a line takes effect at once; prefer the CLI, which keeps the history.
mark-read does~/.config/slack-mcp/config.json with 0600 permissions$XDG_STATE_HOME/slack-mcp/slack-mcp.log (default ~/.local/state/slack-mcp/), directory 0700, file 0600; set SLACK_MCP_LOG_FILE in your MCP client config to move it. It records workspace and user names, never tokens or cookies, and anything token- or cookie-shaped is redacted before it is written{user, conversation, day} encounters with a 90-day window; both live under XDG with 0600, and deleting them deletes the graphestate render='graph' writes a self-contained HTML page to $XDG_DATA_HOME/slack-mcp/reports/ (default ~/.local/share/slack-mcp/reports/), directory 0700, file 0600, one per view and person, replaced on each render. A report holds relationship data — the same names and counts the view shows, never IDs or colleagues' hours — so treat it like the ledgers; delete the directory to remove them. The page loads nothing from the network (bundled Cytoscape.js, strict Content-Security-Policy), and nothing is served or opened for yousay files= reads only from it and download and put write only into $XDG_DATA_HOME/slack-mcp/exchange/ (default ~/.local/share/slack-mcp/exchange/, or SLACK_MCP_EXCHANGE_DIR set in the MCP client config), directory 0700, files 0600, never overwriting. File parameters take bare names, never paths, so injected text cannot point a tool at ~/.ssh or an autostart folder; copy a file in to attach it, and out after downloading it, with your own tools; a client whose tools cannot reach the directory (a sandbox on another machine) writes a file in with put, which never overwrites, reads, lists, or deletes (ADR-012)slack.com and *.slack.com); an upload address or redirect to any other host is refused before a byte is sentMIT
来源:README.md,提交 797bd8a
Interactive credential setup: walks through capturing Slack session tokens via a localhost helper. Tokens never leave this machine.
valueactionExecute a held plan in one call: an ordered commands array of reads (inbox, messages, estate — nothing else), rendered as one document under each item's own output laws. Items are independent — an item cannot read an earlier item's results, so a plan with data dependencies stays multi-turn. An item that fails renders its error in place; the rest still run. Playbooks: save='name' commands=[...] stores a named sequence, run='name' executes it, list=true shows them, delete='name' removes one.
runlistsavedeletecommandsMark inbox items as handled — privately. Advances your local watermark so inbox view='new' stops reporting them. Invisible to Slack: no read receipts, no presence signal. (mark-read is the public counterpart.)
scopehandlehandlesDownload a file shared in Slack into the exchange directory, the one local directory file parameters can name. filename= is a bare name, not a path; a taken name is saved with a ' (n)' suffix and the result says so.
fileId必填filenameRelationship views over the accumulated estate. view='about' answers "tell me about X" whole: founder plane, activity plane, circle, and a ranked reading plan. Other views: 'families' (engagement channels by stem), 'person' (footprint + counterparts), 'initiatives' (what moved, by creator), 'convergence' (where a group co-occurs). Fold-first at zero Slack calls; bounded compiled searches only when coverage requires. about/person take render='graph' to also write the view as a static HTML graph page under the server's data directory.
daysview必填limitdeeperfilteroffsetpeoplepersonrendersearchforceRefreshincludeDeleted另有 1 个What needs you. view='new' reports what changed since your last dismiss (conversations and threads, watermark-tracked). view='unreads' scans unread DMs and channels. view='mentions' collects your @-mentions by urgency. Read-only; nothing here marks anything read.
view必填focuslimitscopecursortimeframeMark channels, threads, or messages as read - helps manage your Slack inbox
scopefiltertargetchanneltimestampConversation content, addressed four ways, plus scheduled=true for what you have scheduled to send (precedence: query and filters beat target-less modes and refuse target; around beats since): target alone reads it in full (a handle, '#channel', '@person', or a description); target+around fetches context around a timestamp; target+since renders a time window with triage; query searches (raw Slack syntax passes through as written; in=, from=, after=, before=, has=, thread= are resolved filters composed onto it). Read-only; never marks anything read.
inhasfromafterlimitquerysincearoundbeforecursortargetthread另有 2 个Write a new file into the exchange directory for say files= to attach, for clients whose own file tools cannot reach the server's filesystem (a sandbox on another machine, a remote server). name is a bare name, not a path; pass the content as text in content= or as standard base64 in base64=, exactly one. Never overwrites: a taken name is saved with a ' (n)' suffix and the result says so. At most 5 MiB.
name必填base64contentContribute content, Slack-visible: text posts a message (to a channel, DM, or thread — a thread reply can also go to the channel); text+at schedules it for Slack to send later, and cancel withdraws a scheduled one; files attaches up to 10 files from the exchange directory to one message, with text as its comment; emoji+messageTs adds or removes a reaction — a reaction is a small say. This is a write; everything it posts is attributed to your user. You are writing from this account's owner's account. Speak as yourself, the assistant, for this account's owner, in a way that suits the conversation. Don't commit this account's owner to substance they haven't given you. Everything say sends is scanned for secrets before anything is sent; a block can quarantine its destination. Never rework content (encode, split, rename, rephrase) to get it past the scanner.
attotextemojifilescancelremovethreadbroadcastmessageTsOpen a page in the operator's browser where they can review and clear the outbound-safety locks: quarantined people and conversations, and the strike lock. The operator does the clearing there; this tool clears nothing, returns no link, and does not report what they clear. Call it when the operator asks to clear a lock.
无需输入参数。
已满足适用检查项的 90%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
claude mcp add slack-mcp -- npx -y @aaronsb/slack-mcp# Extract tokens from your browser (interactive)./slack-mcp setup
# Run as MCP server (stdio, default)./slack-mcp
# Run as MCP server (SSE, for remote/shared access)./slack-mcp --transport ssenpm install -g @aaronsb/slack-mcpslack-mcp setupexport SLACK_MCP_XOXC_TOKEN="xoxc-..."export SLACK_MCP_XOXD_TOKEN="xoxd-..."./slack-mcp{ "mcpServers": { "slack": { "command": "ssh", "args": ["host", "env", "SLACK_MCP_DEPLOYMENT=remote", "slack-mcp"] } }}slack-mcp approve # list pending requestsslack-mcp approve p7k2 # let the next matching call through onceslack-mcp deny p7k2slack-mcp quarantine listslack-mcp quarantine clear '#general' # or @handle, or strikesslack-mcp trust add '#partner' --case external --for 30dslack-mcp trust listslack-mcp trust remove '#partner'make build # Build for current platformmake test # Run testsmake build-all-platforms # Cross-compile (6 platforms)make release TAG=v2.1.1 # Tag and push (CI handles the rest)