Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
General format:
curl -X POST --data-urlencode 'payload={"channel": "#sense-notification", "username": "webhookbot", "text": "This is posted to #sense-notification and comes from a bot named sensebot.", "icon_emoji": ":ghost:"}'<....enter_your_key_here....>
More formatting formatting:
Slack API docs:
Available emojis:
Sub PostToSlack(vToSlackChannel, vFromUser, vMessage, vIconEmoji)
let vSlackURL = '<....enter_your_key_here....>';
execute c:\cygwin64\bin\curl -X POST --data-urlencode 'payload={"channel": "$(vToSlackChannel)", "username": "$(vFromUser)", "text": "$(vMessage)", "icon_emoji": "$(vIconEmoji)"}' $(vSlackURL);
end sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment