MCP server for accessing the Slack API

MCP server for accessing the Slack API

slack-mcp-server-ubie-oss•byubie-oss

An MCP server that lets AI assistants interact with the Slack API through a standardized interface, supporting stdio and Streamable HTTP transports.

License: Not specified•Runtime: Awaiting documentation review•Category: communication social

WHAT IT DOES

  • •Exposes tools to list public channels with pagination, post messages, and reply to message threads in Slack.
  • •Provides tools to add reactions to messages and retrieve recent channel history or all replies in a thread.
  • •Offers tools to retrieve basic profile information of workspace users and to get multiple users' profiles in bulk.
  • •Includes message search with filters for channel location, user, dates, content types, and sorting options.

BEST FOR

  • •AI assistants that need to read and post Slack messages through MCP tools.
  • •Workflows requiring filtered Slack message searches by channel, user, date, or content.
  • •Deployments that need local process-based or HTTP-based MCP transport for Slack access.

ABOUT SLACK-MCP-SERVER-UBIE-OSS

MCP server for accessing the Slack API is cataloged as an MCP server attributed to ubie-oss. An MCP server that lets AI assistants interact with the Slack API through a standardized interface, supporting stdio and Streamable HTTP transports. It is categorized under communication social. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.

HOW TO INSTALL

Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.

LICENSE

Catalog license label: Not specified. Check the source repository's current license and terms before using, modifying or distributing this software.

能力检查器

能力定义尚未审核。未核验的采集内容不会作为可信接口展示。

Tools (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Resources (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Prompts (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

NEWSLETTER - COMING LATER

Newsletter subscriptions are not open yet

Email delivery is not connected. This page does not collect email addresses or create subscriptions.

Browse the registry for current listings instead.

Community Reviews

Coming later

Reviews for MCP server for accessing the Slack API are not available yet

Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.

FREQUENTLY ASKED QUESTIONS

What transport methods does this MCP server support?

It supports Stdio transport as the default for local integration and Streamable HTTP transport for web applications and remote clients.

What does the optional SLACK_SAFE_SEARCH setting change?

When set to true, message searches use Slack's Real-time Search API restricted to public channels, requiring the search:read.public scope; it affects only message search.

上游原版 README

在 GitHub 查看同一版本原文

README.md · f7ccccdbd987 · 采集于 2026-11-13 09:30:26 UTC

保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。

当前显示最后一次成功采集的文档快照,请以来源页面为准。

slack-mcp-server

A MCP(Model Context Protocol) server for accessing Slack API. This server allows AI assistants to interact with the Slack API through a standardized interface.

Transport Support

This server supports both traditional and modern MCP transport methods:

  • Stdio Transport (default): Process-based communication for local integration
  • Streamable HTTP Transport: HTTP-based communication for web applications and remote clients

Features

Available tools:

  • slack_list_channels - List public channels in the workspace with pagination
  • slack_post_message - Post a new message to a Slack channel
  • slack_reply_to_thread - Reply to a specific message thread in Slack
  • slack_add_reaction - Add a reaction emoji to a message
  • slack_get_channel_history - Get recent messages from a channel
  • slack_get_thread_replies - Get all replies in a message thread
  • slack_get_users - Retrieve basic profile information of all users in the workspace
  • slack_get_user_profiles - Get multiple users' profile information in bulk (efficient for batch operations)
  • slack_search_messages - Search for messages in the workspace with powerful filters:
    • Basic query search
    • Location filters: in_channel
    • User filters: from_user, with
    • Date filters: before (YYYY-MM-DD), after (YYYY-MM-DD), on (YYYY-MM-DD), during (e.g., "July", "2023")
    • Content filters: has (emoji reactions), is (saved/thread)
    • Sorting options by relevance score or timestamp

Quick Start

Installation

npm install @ubie-oss/slack-mcp-server

NOTE: Its now hosted in GitHub Registry so you need your PAT.

Configuration

You need to set the following environment variables:

  • SLACK_BOT_TOKEN: Slack Bot User OAuth Token
  • SLACK_USER_TOKEN: Slack User OAuth Token (required for some features like message search)
  • SLACK_SAFE_SEARCH (optional): When set to true, message searches use Slack's Real-time Search API with channel_types: ["public_channel"]. The user token must have the search:read.public scope. The public-channel restriction applies before results are selected and paginated; clients cannot override it. This option affects message search, not the permissions of other tools.

You can also create a .env file to set these environment variables:

SLACK_BOT_TOKEN=xoxb-your-bot-token
SLACK_USER_TOKEN=xoxp-your-user-token
SLACK_SAFE_SEARCH=true  # Optional: Enable safe search mode

With SLACK_SAFE_SEARCH=true, slack_search_messages calls assistant.search.context using the user token, public channels only, message results only, and keyword search. It does not call legacy search.messages, including when the new API is unavailable or the token lacks a required scope.

The search tool keeps the existing keyword, channel, user, date and sorting fields. Public mode uses limit (1–20, default 20) and cursor instead of count and page. Pass next_cursor back with the same query and filters to read another page. An empty cursor marks the end of the results.

{"query":"project update","limit":20,"cursor":"cursor-from-the-previous-response"}

Each successful MCP call returns a single text content block containing this JSON contract. It has no total counts, page numbers, ranking metadata, contextual messages or other result types. channel.name and user may be omitted; next_cursor is always a string.

{
  "contract": "slack-public-search-v1",
  "messages": {
    "matches": [{
      "channel": {"id": "C1234567", "name": "general"},
      "text": "Public project update",
      "ts": "1234567890.123456",
      "user": "U1234567",
      "permalink": "https://example.slack.com/archives/C1234567/p1234567890123456"
    }]
  },
  "next_cursor": ""
}

To upgrade an existing safe-search deployment:

  1. Add the search:read.public user scope to the Slack app and reauthorize it. A token with only legacy search:read is insufficient. Do not share tokens in configuration examples or logs.
  2. Deploy this server with safe search enabled. Verify a public query and a subsequent cursor request. A missing_scope error explains the required scope; other API failures do not trigger a legacy fallback.
  3. Upgrade clients to accept the slack-public-search-v1 response and cursor input. Clients that depend on a public-only boundary should reject legacy responses instead of forwarding their metadata.

When SLACK_SAFE_SEARCH is unset or false, the existing legacy search API, count/page inputs and response shape remain unchanged.

Usage

Start the MCP server

Stdio Transport (default):

npx @ubie-oss/slack-mcp-server

Streamable HTTP Transport:

npx @ubie-oss/slack-mcp-server -port 3000

You can also run the installed module with node:

# Stdio transport
node node_modules/.bin/slack-mcp-server

# HTTP transport  
node node_modules/.bin/slack-mcp-server -port 3000

Command Line Options:

  • -port <number>: Start with Streamable HTTP transport on specified port
  • -h, --help: Show help message

Client Configuration

For Stdio Transport (Claude Desktop, etc.):

{
  "slack": {
    "command": "npx",
    "args": [
      "-y",
      "@ubie-oss/slack-mcp-server"
    ],
    "env": {
      "NPM_CONFIG_//npm.pkg.github.com/:_authToken": "<your-github-pat>",
      "SLACK_BOT_TOKEN": "<your-bot-token>",
      "SLACK_USER_TOKEN": "<your-user-token>",
      "SLACK_SAFE_SEARCH": "true"
    }
  }
}

For Streamable HTTP Transport (Web applications):

Start the server:

SLACK_BOT_TOKEN=<your-bot-token> SLACK_USER_TOKEN=<your-user-token> npx @ubie-oss/slack-mcp-server -port 3000

Connect to: http://localhost:3000/mcp

See examples/README.md for detailed client examples.

Implementation Pattern

This server adopts the following implementation pattern:

  1. Define request/response using Zod schemas

    • Request schema: Define input parameters
    • Response schema: Define responses limited to necessary fields
  2. Implementation flow:

    • Validate request with Zod schema
    • Call Slack WebAPI
    • Parse response with Zod schema to limit to necessary fields
    • Return as JSON

For example, the slack_list_channels implementation parses the request with ListChannelsRequestSchema, calls slackClient.conversations.list, and returns the response parsed with ListChannelsResponseSchema.

Development

Available Scripts

  • npm run dev - Start the server in development mode with hot reloading
  • npm run build - Build the project for production
  • npm run start - Start the production server
  • npm run lint - Run linting checks (ESLint and Prettier)
  • npm test - Run the message-search boundary tests with Node's test runner
  • npm run fix - Automatically fix linting issues

Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Run tests and linting: npm run lint
  4. Commit your changes
  5. Push to the branch
  6. Create a Pull Request

Install configuration

Are you the maintainer?

Claim this server with your GitHub account to request manual ownership verification.

README Embed Badge
Markdown

Link to the catalog listing for MCP server for accessing the Slack API from your README. This badge does not certify ownership, compatibility or security.

[![MCP catalog listing](https://img.shields.io/badge/MCP-awesome--mcp-orange?style=flat-square)](https://awesome-mcp.com/servers/slack-mcp-server-ubie-oss)

REPOSITORY STATS

GitHub StarsUnavailable
ForksUnavailable

Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.

下载与拉取统计

来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。

尚无已审核的包 / 镜像标识,暂不展示下载统计。

Related communication social MCP Servers

Alternative and complementary servers in the same category

View all in communication social →

An AI receptionist platform with an MCP server for accessing business calls, contacts and appointments from AI assistants.

52
Communication

Pidgeon provides an MCP server and an email inbox API that gives AI agents their own addresses for sending, awaiting, and replying to email.

Repository stats unavailable
Communication