Skip to content

Instantly share code, notes, and snippets.

@korzio
Created September 16, 2019 18:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save korzio/6f7b993ce0328d3f4e87e0c7b67c4467 to your computer and use it in GitHub Desktop.
Save korzio/6f7b993ce0328d3f4e87e0c7b67c4467 to your computer and use it in GitHub Desktop.
const { IncomingWebhook } = require('@slack/webhook')
const url = process.env.SLACK_WEBHOOK_URL
const webhook = new IncomingWebhook(url)
// Send the notification
(async () => {
await webhook.send({
text: 'I\'ve got news for you...',
})
})()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment