Chat

Chat Update

POST
/chat.update

Updates a message.

Authorization

slackAuth chat:write:user, chat:write:bot
AuthorizationBearer <token>

In: header

Scope: chat:write:user, chat:write:bot

Header Parameters

token*string

Authentication token. Requires scope: chat:write

Content-Type*"application/x-www-form-urlencoded"

Value in

  • "application/x-www-form-urlencoded"

Request Body

application/x-www-form-urlencoded

as_user?string

Pass true to update the message as the authed user. Bot users in this context are considered authed users.

attachments?string

A JSON-based array of structured attachments, presented as a URL-encoded string. This field is required when not presenting text. If you don't include this field, the message's previous attachments will be retained. To remove previous attachments, include an empty array for this field.

blocks?string

A JSON-based array of structured blocks, presented as a URL-encoded string. If you don't include this field, the message's previous blocks will be retained. To remove previous blocks, include an empty array for this field.

channel*string

Channel containing the message to be updated.

link_names?string

Find and link channel names and usernames. Defaults to none. If you do not specify a value for this field, the original value set for the message will be overwritten with the default, none.

parse?string

Change how messages are treated. Defaults to client, unlike chat.postMessage. Accepts either none or full. If you do not specify a value for this field, the original value set for the message will be overwritten with the default, client.

text?string

New text for the message, using the default formatting rules. It's not required when presenting blocks or attachments.

ts*string

Timestamp of the message to be updated.

Response Body

application/json

application/json

curl -X POST "https://example.com/chat.update" \  -H "token: string" \  -H "Content-Type: application/x-www-form-urlencoded" \  -H "Content-Type: application/x-www-form-urlencoded" \  -d 'channel=string&ts=string'
{  "channel": "string",  "message": {    "attachments": [      {}    ],    "blocks": {},    "text": "string"  },  "ok": "True",  "text": "string",  "ts": "string"}