uptimeify_im_routing_rule
An Incident Management routing rule: incidents whose alert matches go to team_id. Rules run in ascending priority. Incident Management must be active for the organization. Import with the numeric id.
An Incident Management routing rule: incidents whose alert matches go to team_id. Rules run in ascending priority. Incident Management must be active for the organization. Import with the numeric id.
Example Usage
# Critical database alerts from Grafana go to the DBA team as sev1.
resource "uptimeify_im_routing_rule" "db" {
team_id = 9
priority = 10
match = {
source_ids = [tonumber(uptimeify_im_alert_source.grafana.id)]
severity = ["sev1", "sev2"]
tags = ["db"]
field_matches = { env = "prod" }
}
severity_override = "sev1"
}
# Catch-all at the end.
resource "uptimeify_im_routing_rule" "default" {
team_id = 7
priority = 1000
}Schema
Required
team_id(Number) The team that receives matching incidents.
Optional
match(Attributes) What the rule matches; all set fields must match. Unset or{}= catch-all. All ids must belong to the organization. (see below for nested schema)priority(Number) Lower runs first. Default100.severity_override(String) Unset = keep the mapped severity.
Read-Only
created_at(String)id(String) Numeric rule id.organization_id(Number)updated_at(String)
Nested Schema for match
Optional:
customer_ids(List of Number) Customer ids. At most 500.field_matches(Map of String) Payload field -> expected value, at most 50 entries.monitor_ids(List of Number) Ids of any monitor type (website, DNS, ICMP, ...). At most 500.severity(List of String)sev1tosev4.source_ids(List of Number) Alert source ids. At most 500.tags(List of String) Alert tags. At most 200.
Import
Import is supported using the following syntax:
The terraform import command can be used, for example:
terraform import uptimeify_im_routing_rule.db 17uptimeify_im_outbound_integration
An Incident Management outbound integration: forwards incident events to Slack, Microsoft Teams, Discord, Jira, PagerDuty (Events v2), Opsgenie or a generic webhook. Incident Management must be active for the organization. URLs, tokens, keys and header values are secrets the API never returns, so they are write-only here; has_* tells whether one is stored. Import with the numeric id.
uptimeify_im_schedule
An on-call schedule on an escalation tier (created via POST /api/im/tiers/{tierId}/schedules). Rotation members must be members of the tier's team. The tier's own default schedule belongs to uptimeify_im_escalation_tier. Import with the numeric schedule id.