mathk
mathk

Reputation: 8133

Send a message in a channel "only visible to you"

I can not see in the slack API documentation the way for a bot to send a message in a channel that response to a user.

The same way slackbot does reply when doing /help.

Anyone can let me know if that is possible?

enter image description here

Notice the "Only visible to you". In the RTM manual they say that the messsage is of the same type as the event message. I don't see any attributes that would say it is visible only to a certain user.

Upvotes: 22

Views: 25655

Answers (1)

Pangolin
Pangolin

Reputation: 7444

Sending private messages in channels with the "Only visible to you" tag is called "ephemeral" and is now possible through the Slack API.

https://api.slack.com/methods/chat.postEphemeral

(I'm not sure since when)

Upvotes: 22

Related Questions