Sample - Slack Web API
POST/conversations.setPurpose

Set a conversation purpose

Sets the purpose of an existing conversation. Provide the conversation in channel and the new purpose in purpose, using an authentication token with the conversations:write scope when authorization is required.

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

1 parameter · 2 body fields
tokenstringoptional
Authentication token for the request; it must provide the `conversations:write` scope.

Optional form-encoded conversation purpose details.

channelstringoptional
Conversation to set the purpose of
purposestringoptional
A new, specialer purpose

2 status codes
200Returns a success object with `ok` set to true and the updated conversation in `channel`.
channelarrayrequired
okbooleanrequired
Allowed:true
defaultTypical error response
callstackstringoptional
Note: PHP callstack is only visible in dev/qa
errorstringrequired
Allowed:method_not_supported_for_channel_typemissing_scopechannel_not_foundnot_in_channelis_archivedtoo_longuser_is_restrictednot_authedinvalid_authaccount_inactiveinvalid_arg_nameinvalid_array_arg
neededstringoptional
okbooleanrequired
Allowed:false
providedstringoptional

Error handling

channel must identify a conversation whose purpose the authenticated user can change, and purpose must contain the new purpose text. The token must provide the conversations:write scope when supplied for authentication.