Sample - Slack Web API
POST/chat.meMessage

Send a me message

Sends a me message to a channel, private group, or direct message channel. Supply channel and text to identify the destination and message content, and use thread_ts to post within an existing thread. Use as_user, icon_emoji, icon_url, or username to control the message authorship and appearance when permitted.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

1 parameter · 2 body fields
tokenstringoptional
Authentication token with the `chat:write` scope.

The destination, content, threading, and optional authorship settings for the me message.

channelstringoptional
Channel to send message to. Can be a public channel, private group or IM channel. Can be an encoded ID, or a name.
textstringoptional
Text of the message to send.

2 status codes
200Returns a success response containing the message channel and timestamp.
channelstringoptional
okbooleanrequired
Allowed:true
tsstringoptional
defaultReturns `ok: false` with an error when the channel is unavailable, the message cannot be sent, authentication or permission checks fail, or the content is invalid.
callstackstringoptional
Note: PHP callstack is only visible in dev/qa
errorstringrequired
Allowed:channel_not_foundnot_in_channelis_archivedmsg_too_longno_textrate_limitednot_authedinvalid_authaccount_inactivetoken_revokedno_permissionorg_login_required
okbooleanrequired
Allowed:false

Error handling

Use channel to identify a public channel, private group, or IM channel, and provide the message in text. If you use thread_ts, the value must identify an existing thread in the destination channel.