pagerduty_priority

Use this data source to get information about a specific priority that you can use for other PagerDuty resources. A priority is a label representing the importance and impact of an incident. This feature is only available on Standard and Enterprise plans.

Example Usage

data "pagerduty_priority" "p1" {
  name = "P1"
}

resource "pagerduty_ruleset" "foo" {
  name = "Primary Ruleset"
}
resource "pagerduty_ruleset_rule" "foo" {
  ruleset  = pagerduty_ruleset.foo.id
  position = 0
  disabled = "false"

  conditions {
    operator = "and"

    subconditions {
      operator = "contains"
      parameter {
        value = "disk space"
        path  = "payload.summary"
      }
    }

    subconditions {
      operator = "contains"
      parameter {
        value = "db"
        path  = "payload.source"
      }
    }
  }

  actions {
    route {
      value = "P5DTL0K"
    }

    priority {
      value = data.pagerduty_priority.p1.id
    }
  }
}

Argument Reference

The following arguments are supported:

Attributes Reference