Sending customized Slack alerts with webhooks

If you're using Mode to track key metrics like conversion rates or daily purchases, you might want to be alerted if those metrics fall above or below certain thresholds. Or, you might need to keep track of what's happening in your Mode organization, like when a report run begins or ends, a definition is created or updated, or a new member is added.

Using webhooks with the Mode API, you can programmatically track these kinds of events. You can then trigger alerts that send emails, Slack messages, PagerDuty alerts, or other types of notifications to the people on your team who need to be in the know.

We've written some sample code showing one way you might go about triggering an alert in Slack.

Since we used AWS Lamba in this example, the code is tailored to that environment, but you can adapt it to the environment of your choice. As you'll see in the code, you'll also need to configure it with your own API tokens.

Reply Oldest first
  • Oldest first
  • Newest first
  • Active threads
  • Popular
Like1 Follow
  • 1 Likes
  • 5 mths agoLast active
  • 737Views
  • 1 Following

Create A New Discussion

Share your thoughts