VX Agents

OpenAPI Marketplace · Messaging & SMS

Slack Messaging

v1.0.1 · 12 endpoints · 0 connections · shared by vx.ai

Let an agent work in Slack through the Web API: find channels and people, read channel history and threads, open direct messages, post and edit messages, add reactions, and search messages. Curated from Slack's official OpenAPI specification.

Connect this API to an AI agent Browse all specs

What you can do with Slack Messaging via MCP

Every endpoint below becomes a governed tool your AI agent (Claude, ChatGPT, or a customer-facing VX agent) can call — with scoped permissions, sandbox testing, and audit logs.

MethodPathOperationDescription
GET /conversations.list listConversations List channels the token can see (public, private, DMs)
GET /conversations.info getConversationInfo Get details about one channel by id
GET /conversations.history getConversationHistory Read recent messages in a channel
GET /conversations.replies getThreadReplies Read all replies in a message thread
POST /conversations.open openDirectMessage Open (or find) a direct message with one or more users
GET /users.list listUsers List people in the workspace
GET /users.info getUserInfo Get a person's profile by user id
GET /users.lookupByEmail lookupUserByEmail Find a person by their email address
POST /chat.postMessage postMessage Send a message to a channel, DM or thread
POST /chat.update updateMessage Edit a message the app posted
POST /reactions.add addReaction Add an emoji reaction to a message
GET /search.messages searchMessages Search messages across the workspace (needs a user token)

Authentication

slackToken

API key — sent as the Authorization header

Slack OAuth token, sent as Authorization: Bearer xoxb-....

How to get a credential

  1. Go to https://api.slack.com/apps and click Create New App > From scratch; pick the workspace.
  2. Open OAuth & Permissions and add the Bot Token Scopes from the table below.
  3. Click Install to Workspace (an admin may need to approve), then copy the Bot User OAuth Token (xoxb-...).
  4. Invite the bot to each channel it should read or post in (/invite @your-app); bots only see channels they are members of.
  5. Optional: for searchMessages add the User Token Scope search:read and use the User OAuth Token (xoxp-...) instead, because search does not accept bot tokens.

Permissions used

Scope Operations
channels:read, groups:read listConversations, getConversationInfo
channels:history, groups:history getConversationHistory, getThreadReplies
im:write openDirectMessage
users:read listUsers, getUserInfo
users:read.email lookupUserByEmail
chat:write postMessage, updateMessage
reactions:write addReaction
search:read (user token) searchMessages

Common errors

Slack usually answers HTTP 200 with ok: false and an error code: always check ok.

  • not_authed / invalid_auth (like a 401): missing or revoked token, or the token was sent without the Bearer prefix.
  • missing_scope (like a 403): add the scope named in needed, then reinstall the app and copy the new token.
  • not_in_channel / channel_not_found: invite the bot to the channel, or use the channel id (C...), not its name.
  • invalid_arguments / invalid_blocks (like a 400): fix the named field.
  • HTTP 429 ratelimited: wait the Retry-After seconds before retrying.

Store the token as a VX Agents credential for this spec; never paste it into chat.

Usage guide

Setup

  • Credential: a Bot User OAuth Token (xoxb-...) with the scopes in the auth docs. Invite the bot to every channel it should read or post in.
  • searchMessages only works with a user token (xoxp-..., scope search:read); with a bot token, find messages with getConversationHistory instead.
  • Worth pinning: the channel id (C...) the agent posts to most, found once with listConversations.

Read and reply in a channel

  1. listConversations with types=public_channel,private_channel, exclude_archived=true, limit=200 to map channel names to ids. Follow response_metadata.next_cursor with cursor until it is empty.
  2. getConversationHistory with channel and limit (and oldest / latest as Unix timestamps) to read recent messages.
  3. getThreadReplies with channel and the parent message's ts to read a thread.
  4. Resolve people with lookupUserByEmail, getUserInfo or listUsers (user ids look like U...). Mention someone in text as <@U123ABC>.
  5. Draft the message and show it to the user with the target channel. After they confirm, call postMessage with channel, text, and thread_ts to reply inside a thread instead of the channel.
  6. updateMessage (channel, ts, text) fixes a message the app posted; addReaction (channel, timestamp, name without colons, e.g. white_check_mark) acknowledges one.

Direct messages

openDirectMessage with users=U123ABC returns a DM channel id (D...); post to it with postMessage after the user confirms.

Good to know

  • Every response has ok. HTTP 200 with ok: false is an error: read error (and needed for missing_scope) and do not report success.
  • ts is the message id (a string like 1729050000.123456); keep it as a string.
  • Message text uses Slack mrkdwn: *bold*, _italic_, <https://url|label>.
  • Most read methods are rate limited to about 50 calls per minute; postMessage to about 1 message per second per channel.
  • Messages are seen by real people immediately: always confirm before postMessage or updateMessage. Deleting messages, file uploads and admin methods are intentionally not available.

How to use this spec

  1. Create a free VX Agents account (sandbox tools included).
  2. Open the marketplace and connect “Slack Messaging” to an agent.
  3. Expose it as an MCP server for Claude/ChatGPT, or chat with it directly.

Related APIs