Skip to main content
POST
/
v2
/
escalation_paths
Create
curl --request POST \
  --url https://api.incident.io/v2/escalation_paths \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "Urgent Support",
  "path": [
    {
      "delay": {
        "delay_interval_condition": "active",
        "delay_seconds": 300,
        "delay_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
      },
      "id": "01FCNDV6P870EA6S7TK1DSYDG0",
      "if_else": {
        "conditions": [
          {
            "operation": "one_of",
            "param_bindings": [
              {
                "array_value": [
                  {
                    "literal": "SEV123",
                    "reference": "incident.severity"
                  }
                ],
                "value": {
                  "literal": "SEV123",
                  "reference": "incident.severity"
                }
              }
            ],
            "subject": "incident.severity"
          }
        ],
        "else_path": [
          {}
        ],
        "then_path": [
          {}
        ]
      },
      "level": {
        "ack_mode": "all",
        "round_robin_config": {
          "enabled": false,
          "rotate_after_seconds": 120
        },
        "targets": [
          {
            "id": "lawrencejones",
            "schedule_mode": "currently_on_call",
            "type": "schedule",
            "urgency": "high"
          }
        ],
        "time_to_ack_interval_condition": "active",
        "time_to_ack_seconds": 1800,
        "time_to_ack_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
      },
      "notify_channel": {
        "targets": [
          {
            "id": "lawrencejones",
            "schedule_mode": "currently_on_call",
            "type": "schedule",
            "urgency": "high"
          }
        ],
        "time_to_ack_interval_condition": "active",
        "time_to_ack_seconds": 1800,
        "time_to_ack_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
      },
      "repeat": {
        "repeat_times": 3,
        "to_node": "01FCNDV6P870EA6S7TK1DSYDG0"
      },
      "type": "if_else"
    }
  ],
  "repeat_config": {
    "delay_repeat_on_activity": false,
    "repeat_after_seconds": 1800
  },
  "team_ids": [
    "01JPQA75EPNEES4479P16P4XAB"
  ],
  "working_hours": [
    {
      "id": "abc123",
      "name": "abc123",
      "timezone": "abc123",
      "weekday_intervals": [
        {
          "end_time": "17:00",
          "start_time": "09:00",
          "weekday": "monday"
        }
      ]
    }
  ]
}
'
{
  "escalation_path": {
    "current_responders": [
      {
        "email": "lisa@incident.io",
        "id": "01FCNDV6P870EA6S7TK1DSYDG0",
        "name": "Lisa Karlin Curtis",
        "role": "owner",
        "slack_user_id": "U02AYNF2XJM"
      }
    ],
    "id": "01FCNDV6P870EA6S7TK1DSYDG0",
    "name": "Urgent Support",
    "path": [
      {
        "delay": {
          "delay_interval_condition": "active",
          "delay_seconds": 300,
          "delay_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
        },
        "id": "01FCNDV6P870EA6S7TK1DSYDG0",
        "if_else": {
          "conditions": [
            {
              "operation": {
                "label": "Lawrence Jones",
                "value": "01FCQSP07Z74QMMYPDDGQB9FTG"
              },
              "param_bindings": [
                {
                  "array_value": [
                    {
                      "label": "Lawrence Jones",
                      "literal": "SEV123",
                      "reference": "incident.severity"
                    }
                  ],
                  "value": {
                    "label": "Lawrence Jones",
                    "literal": "SEV123",
                    "reference": "incident.severity"
                  }
                }
              ],
              "subject": {
                "label": "Incident Severity",
                "reference": "incident.severity"
              }
            }
          ],
          "else_path": [
            {}
          ],
          "then_path": [
            {}
          ]
        },
        "level": {
          "ack_mode": "all",
          "round_robin_config": {
            "enabled": false,
            "rotate_after_seconds": 120
          },
          "targets": [
            {
              "id": "lawrencejones",
              "schedule_mode": "currently_on_call",
              "type": "schedule",
              "urgency": "high"
            }
          ],
          "time_to_ack_interval_condition": "active",
          "time_to_ack_seconds": 1800,
          "time_to_ack_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
        },
        "notify_channel": {
          "targets": [
            {
              "id": "lawrencejones",
              "schedule_mode": "currently_on_call",
              "type": "schedule",
              "urgency": "high"
            }
          ],
          "time_to_ack_interval_condition": "active",
          "time_to_ack_seconds": 1800,
          "time_to_ack_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
        },
        "repeat": {
          "repeat_times": 3,
          "to_node": "01FCNDV6P870EA6S7TK1DSYDG0"
        },
        "type": "if_else"
      }
    ],
    "repeat_config": {
      "delay_repeat_on_activity": false,
      "repeat_after_seconds": 1800
    },
    "team_ids": [
      "01JPQA75EPNEES4479P16P4XAB"
    ],
    "working_hours": [
      {
        "id": "abc123",
        "name": "abc123",
        "timezone": "abc123",
        "weekday_intervals": [
          {
            "end_time": "17:00",
            "start_time": "09:00",
            "weekday": "monday"
          }
        ]
      }
    ]
  }
}

Authorizations

Authorization
string
header
required

API key from your incident.io dashboard (Settings → API keys)

Body

application/json
name
string
required

The name of this escalation path, for the user's reference.

Example:

"Urgent Support"

path
object[]
required

The nodes that form the levels and branches of this escalation path.

Example:
[
{
"delay": {
"delay_interval_condition": "active",
"delay_seconds": 300,
"delay_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
},
"id": "01FCNDV6P870EA6S7TK1DSYDG0",
"if_else": {
"conditions": [
{
"operation": "one_of",
"param_bindings": [
{
"array_value": [
{
"literal": "SEV123",
"reference": "incident.severity"
}
],
"value": {
"literal": "SEV123",
"reference": "incident.severity"
}
}
],
"subject": "incident.severity"
}
],
"else_path": [{}],
"then_path": [{}]
},
"level": {
"ack_mode": "all",
"round_robin_config": {
"enabled": false,
"rotate_after_seconds": 120
},
"targets": [
{
"id": "lawrencejones",
"schedule_mode": "currently_on_call",
"type": "schedule",
"urgency": "high"
}
],
"time_to_ack_interval_condition": "active",
"time_to_ack_seconds": 1800,
"time_to_ack_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
},
"notify_channel": {
"targets": [
{
"id": "lawrencejones",
"schedule_mode": "currently_on_call",
"type": "schedule",
"urgency": "high"
}
],
"time_to_ack_interval_condition": "active",
"time_to_ack_seconds": 1800,
"time_to_ack_weekday_interval_config_id": "01FCNDV6P870EA6S7TK1DSYDG0"
},
"repeat": {
"repeat_times": 3,
"to_node": "01FCNDV6P870EA6S7TK1DSYDG0"
},
"type": "if_else"
}
]
repeat_config
object
Example:
{
"delay_repeat_on_activity": false,
"repeat_after_seconds": 1800
}
team_ids
string[]

IDs of the teams that own this escalation path. This will automatically sync escalation paths with the right teams in Catalog. If you have an escalation paths attribute on your Teams, this attribute is required.

Example:
["01JPQA75EPNEES4479P16P4XAB"]
working_hours
object[]

The working hours for this escalation path.

Example:
[
{
"id": "abc123",
"name": "abc123",
"timezone": "abc123",
"weekday_intervals": [
{
"end_time": "17:00",
"start_time": "09:00",
"weekday": "monday"
}
]
}
]

Response

201 - application/json

Created response.

escalation_path
object
required