PagerDuty and Prometheus Alert Manager Custom Details

I’ve set up a PagerDuty and Prometheus Alert Manager integration.

The integration is successfully raising alerts. however, the formatting of the alerts when viewed in PagerDuty is not very readable or user-friendly.

The alert information is under the Custom Details inside a table.

I’m looking for support on how to properly format this information.

1 Like

Hi David,

The information you are seeing is currently formatted to match our Custom Details settings. Could you share more about what you would like to see regarding this? I can submit a Feature Request for you regarding updating this section.


Abbott Brannon
Technical Support Specialist

1 Like

Yep, the examples the Prometheus Alert Manager community provides are less than ideal and not best practices. Here’s a better example you can use. You can map anything you want into the details section for use in PD event enrichment and routing as well as in other downstream systems like ServiceNow or Jira.

  enabled: true
      pager_service: "service_key"
      group_by: ['...']
      group_wait: 30s
      group_interval: 5m
      repeat_interval: 12h
      receiver: 'pager_duty_service'
      - receiver: 'pager_duty_service'
          receiver: 'staging'
    - name: 'null'
    - name: 'pager_duty_service'
        - url: ''
      - routing_key: {{ global.pager_service }}
        class: "{{ range .Alerts }}{{ .Labels.alertname }}{{ end }}"
        group: "{{ range .Alerts }}{{ .Labels.namespace }}{{ end }}"
        component: "{{ range .Alerts }}{{ .Labels.pod }}{{ end }}"
          container: "{{ range .Alerts }}{{ .Labels.container }}{{ end }}"
          region: "{{ range .Alerts }}{{ .Labels.region }}{{ end }}"
          severity: "{{ range .Alerts }}{{ .Labels.severity }}{{ end }}"
          ownership: "{{ range .Alerts }}{{ .Annotations.ownership }}{{ end }}"
          summary: "{{ range .Alerts }}{{ .Annotations.summary }}{{ end }}"
          runbook_url: "{{ range .Alerts }}{{ .Annotations.runbook_url }}{{ end }}"
          description: "{{ range .Alerts }}{{ .Annotations.description }}{{ end }}"