Configure Grafana IRM for Alerting

This is documentation for the next version of Grafana. For the latest stable release, go to the latest version.

Open source Enterprise

Configure Grafana IRM for Alerting

In Grafana OSS and Grafana Enterprise, you can use a webhook contact point to send alerts to Grafana IRM. Grafana IRM can then route alerts based on escalation chains for your team’s workflows.

The alert notification flow is as follows:

* Grafana OSS/Enterprise (send webhook alerts)->Grafana Cloud IRM (route via escalation chains)

Note

The Free Forever plan in Grafana Cloud IRM includes 3 IRM active users per month.

These instructions apply only to Grafana OSS and Grafana Enterprise. To configure IRM for Grafana Cloud Alerting, refer to the Grafana Cloud documentation.

Configure an integration in Grafana IRM

First, enable an integration in IRM to accept alerts from Grafana Alerting. You can either create a new integration or use an existing Alertmanager or Webhook integration in IRM.

To create the integration, follow the same steps as described in Configure an OnCall integration in IRM:

  1. Navigate to Alerts & IRM -> IRM -> Integrations.

  2. Click + New integration.

  3. Select either Alertmanager or Webhook integration from the list.

    • Alertmanager integration – Includes preconfigured IRM templates for processing Grafana and Prometheus alerts.

    • Webhook integration – Uses default IRM templates for general alert processing.

  4. Provide a title, description, and assign it to a team, then click Create Integration.

  5. On the integration details page, copy the HTTP Endpoint URL to use in the next section.

Configure a webhook contact point in Grafana Alerting

Next, configure the contact point in Grafana Alerting to send alert notifications to Grafana IRM.

In Grafana OSS and Grafana Enterprise, you need to create a Webhook contact point using the HTTP endpoint URL you copied in the previous step.

  1. Navigate to Alerts & IRM -> Alerting -> Contact points.
  2. Click + Add contact point.
  3. Enter a name for the contact point.
  4. From the Integration list, select Webhook.
  5. In the URL field, enter the HTTP endpoint URL of the IRM integration.
  6. Click Save contact point.

After configuring the contact point in Grafana Alerting and the integration in Grafana IRM, you can start testing the Alerting-to-IRM integration.

Example of a test alert group in Grafana IRM
Example of a test alert group in Grafana IRM

For more information, see:

Enable heartbeat monitoring in Grafana IRM (optional)

Enabling the heartbeat in the IRM integration acts as a monitoring for your Grafana Alerting setup. If Grafana Alerting stops sending alerts—due to downtime or misconfiguration—Grafana IRM creates a new alert group to notify you.

To set up heartbeat monitoring, you must enable the heartbeat in IRM and create an alert rule that continuously sends alerts to the heartbeat endpoint.

Enable the heartbeat for the IRM integration

  1. In IRM, select the IRM integration you configured earlier.
  2. Click the ⋮ (three dots) on top right, then select Heartbeat Settings.
  3. Copy the Endpoint URL—this will be used in a new contact point in Grafana Alerting.
  4. Set the heartbeat interval, time period after which Grafana IRM starts a new alert group if it doesn’t receive a heartbeat.

Create another Webhook contact point in Grafana Alerting

Follow the same steps as before to create a webhook contact point in Grafana Alerting:

  1. Navigate to Alerts & IRM -> Alerting -> Contact points.
  2. Click + Add contact point.
  3. Enter a name for the contact point.
  4. From the Integration list, select Webhook.
  5. In the URL field, enter the endpoint URL of the heartbeat.
  6. Click Save contact point.

You can now click the Test button to send an alert to the heartbeat endpoint. In IRM, verify the heartbeat status in the Hearbeat column on the Integrations page.

Heartbeat status column in the Grafana IRM Integrations page
Heartbeat status column in the Grafana IRM Integrations page

Create an alert rule in Grafana Alerting

Create a Grafana-managed alert rule with the following settings:

  • Always firing – Use a query and alert condition that constantly fire. For example, select a Prometheus data source and set the query to vector(1) > 0.
  • Configure a pending period that is shorter than the hearbeat interval.
  • Choose the webhook contact point you created for the heartbeat to forward alerts.
  • Adjust timing options in the alert rule or notification policy to ensure alerts are forwarded before the heartbeat interval elapses:
    • Group wait: 0s
    • Group interval: 1s
    • Repeat interval: shorter than the hearbeat interval.

After it’s created, the alert rule acts as a heartbeat, verifying that Grafana Alerting is running and sending alerts to Grafana IRM.