Allma

Sign in

How to Integrate Grafana and Slack

Set up a custom app to get Grafana notifications in the channel of your choice

By Team Allma

Unlike a lot of other tools, Grafana doesn’t have an out-of-the-box Slack integration that you can connect through the Slack app directory. But Grafana does have a built-in Slack alert type, and Slack makes it very simple to set up a custom app in your workspace to receive those alerts. It’s not as easy as search, install, go—but with these straightforward steps, you’ll have Grafana alerts set up in Slack in no time.

What you’ll need

  • An active Slack workspace
  • Admin or Editor level permissions in your Grafana organization

Create a custom Slack app for your workspace

This can seem like a daunting task, but it’s actually pretty simple, and it requires minimal configuration to connect to Grafana.

As part of app setup you’ll be asked to select a slack channel to associate with the app. If you would like your Grafana alerts to go to a new channel, create that before proceeding.

Go to https://api.slack.com/apps and click Create an App.

image2.png

In the Create an app modal, choose From scratch.

image6.png

Name your app and select your workspace. Click Create App.

image4.png

Select the Incoming Webhooks option from the Add features and functionality menu.

image7.png

Toggle on webhooks.

Click Add New Webhook to Workspace at the bottom of the Webhook URLs for your Workspace section.

image9.png

Select the Slack channel you would like to connect the app to and click Allow.

image3.png

The page will refresh and you will see a webhook URL in the Webhook URLs for your Workspace section. You can click Copy now, or wait until you’re ready to paste the link. Either way, keep this window open for the next step so you can come back to it if you need to.

Create a Slack alert in Grafana

Now that we have the Slack app configured and ready to receive alerts from Grafana, all that’s left to do is create the alert from your Grafana dashboard.

Click the bell icon (Alerting) in the grafana side menu and select Notification channels.

image8.png

Click Add channel.

image1.png

Give your notification channel a Name and select Slack from the Type dropdown. Under Slack settings, paste the webhook URL provided by Slack during your app setup.

Configure any optional settings that fit your use case.

Click Save.

Optional, but a good best practice, click Send Test to test the integration. You should receive an example alert notification in your designated Slack channel.

incident
management
collaboration.

Allma– UI-less Incident Collaboration. Natively in Slack.

Get early access

our newsletter is cool

allma, inc © 2022