Acts in a Slack workspace as the authorized user: list channels, post and reply in threads, add reactions and look up users.
接入配置
选择客户端,复制配置,再按项目文档补齐环境变量。
claude mcp add slack-user --env SLACK_TEAM_ID='<SLACK_TEAM_ID>' --env SLACK_TOKEN='<SLACK_TOKEN>' -- npx -y @modelcontextprotocol/server-slack-user~/.codex/config.toml
[mcp_servers.slack-user]
command = "npx"
args = ["-y", "@modelcontextprotocol/server-slack-user"]
env = { SLACK_TEAM_ID = "<SLACK_TEAM_ID>", SLACK_TOKEN = "<SLACK_TOKEN>" }
# codex mcp add slack-user --env SLACK_TEAM_ID='<SLACK_TEAM_ID>' --env SLACK_TOKEN='<SLACK_TOKEN>' -- npx -y @modelcontextprotocol/server-slack-user~/.cursor/mcp.json
{
"mcpServers": {
"slack-user": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-slack-user"
],
"env": {
"SLACK_TEAM_ID": "<SLACK_TEAM_ID>",
"SLACK_TOKEN": "<SLACK_TOKEN>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"slack-user": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-slack-user"
],
"env": {
"SLACK_TEAM_ID": "<SLACK_TEAM_ID>",
"SLACK_TOKEN": "<SLACK_TOKEN>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"slack-user": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-slack-user"
],
"env": {
"SLACK_TEAM_ID": "<SLACK_TEAM_ID>",
"SLACK_TOKEN": "<SLACK_TOKEN>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"slack-user": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-slack-user"
],
"env": {
"SLACK_TEAM_ID": "<SLACK_TEAM_ID>",
"SLACK_TOKEN": "<SLACK_TOKEN>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"slack-user": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-slack-user"
],
"env": {
"SLACK_TEAM_ID": "<SLACK_TEAM_ID>",
"SLACK_TOKEN": "<SLACK_TOKEN>"
}
}
}
}需要的环境变量
SLACK_TEAM_IDSLACK_TOKEN
把占位值换成你自己的密钥;不要把密钥提交到代码仓库。