Update an escalation policy

Update an existing escalation policy. Send only the parameters you wish to change (eg. url).

POST https://betteruptime.com/api/v2/policies/{policy_id}

URL parameters

policy_id
required integer

Headers

Authorization
required string
Content_Type
string

Body parameters

name
string
repeat_count
integer
repeat_delay
integer
steps
Array of PolicyStep
200

Response body

{
  "data": {
    "id": "456",
    "type": "policy",
    "attributes": {
      "name": "Policy A",
      "repeat_count": 5,
      "repeat_delay": 0,
      "incident_token": "8nEiLj2gfqjfQRK6vzkFuGC25"
    },
    "steps": [
      {
        "type": "escalation",
        "wait_before": 0,
        "urgency_id": 12345,
        "step_members": [
          {
            "type": "all_slack_integrations"
          },
          {
            "type": "current_on_call"
          }
        ]
      }
    ]
  }
}

Example cURL

curl -X "PATCH" "https://betteruptime.com/api/v2/policies/456" \
-H 'Authorization: Bearer YOUR_API_TOKEN' \
-H 'Content-Type: application/json; charset=utf-8' \
-d $'{ "name": "New name" }'
Copied!