4. Incoming Web Hooks
• Unique URLs • JSON Payloads
• Custom Names/
Icons/Chan
curl -X POST —data-urlencode
'payload={
"text": "This is posted to <#general> and comes from *monkey-bot*.",
"channel": "#general",
"username": "monkey-bot",
"icon_emoji": “:monkey_face:"}'
https://hooks.slack.com/services/T00/B000/XXXXXX
5. Outgoing Web Hooks
• Channel and/or Trigger Words
(Public-Only)
• HTTP Post, JSON Resp
token=XXXXXXXXXXXXXXXXXX
team_id=T0001
team_domain=example
channel_id=C2147483705
channel_name=test
timestamp=1355517523.000005
user_id=U2147483697
user_name=Steve
text=googlebot: What is the
air-speed velocity of an
unladen swallow?
trigger_word=googlebot:
{ "text": "African or European?” }
6. /Slash Commands
• POST or GET • Response Only Shown to User
It’s San Francisco, ergo cold.
token=gIkuvaNzQIHg97ATv
team_id=T0001
team_domain=example
channel_id=C2147483705
channel_name=test
user_id=U2147483697
user_name=Steve
command=/weather
text=94103
8. The Slack Real Time Messaging API
• WebSockets
• Used by all Slack Clients
• Pushed All Messages in All Channels
• Commonly Used with Bot Users
• Can’t Join Channels
• Always Active (Unless set)