Harry Sadoyan
Harry Sadoyan

Reputation: 63

Slack Channel/User Ids and chat.postMessage

The Slack API documentation specifies that user_id is not globally unique here, and this post seems to state that channel_id isn't necessarily unique either.

Now my question is about the chat.postMessage API endpoint. It takes a channel_id or user_id for the channel, but has no way to specify a team. So can we as the caller still assume that those are effectively unique? The post above is over a year old, and I haven't found any updates, so I don't know if that assumption still holds.

Upvotes: 4

Views: 784

Answers (1)

Taylor Singletary
Taylor Singletary

Reputation: 2296

Yes, the team/workspace is implicit in the token you're using to execute the chat.postMessage request. All specified channel IDs and user IDs will be considered within the domain of that implicit team.

Upvotes: 2

Related Questions