251
All tools
SlackS

by Slack

Post a message

Posts a message to a channel, DM or thread and returns the channel ID and the message timestamp.

Updated Oct 28, 2026

post-message.md

Post a message

Posts a message to a channel, DM or thread and returns the channel ID and the message timestamp.

Note: Needs the chat:write scope. Over MCP it posts as the signed-in user; the API and CLI post as the app's bot.

Set up

Use the first option your agent supports.

MCP (official, remote)

Add this server to your agent's MCP settings, then sign in when asked.

{ "mcpServers": { "slack": { "url": "https://mcp.slack.com/mcp" } } }

Call the MCP tool slack_send_message.

Server URL: https://mcp.slack.com/mcp

CLI (official)

Install the command, then confirm it runs.

curl -fsSL https://downloads.slack-edge.com/slack-cli/install.sh | bash
slack --version

Run slack api chat.postMessage.

Set $SLACK_BOT_TOKEN in your environment first (get a key: https://api.slack.com/apps).

API (official)

Before anything else, confirm access with the cheapest read-only call, like a list or a search. Never send or change anything to test access.

Rules

  • Ask the user before anything that sends messages, costs money, or changes data, and say how many records it touches. One approval covers a batch the user has seen.
  • Never print API keys.

Ways in

RouteSourceCallRequiredDocs
MCPOfficial · remoteslack_send_messageOAuthDocs
CLIOfficialslack api chat.postMessageAPI key in $SLACK_BOT_TOKENDocs
APIOfficialPOST /chat.postMessageAPI key in $SLACK_BOT_TOKENDocs

Workflows using Post a message