Skip to main content
GET
/
v1
/
maintenance_windows
List
curl --request GET \
  --url https://api.incident.io/v1/maintenance_windows \
  --header 'Authorization: Bearer <token>'
{
  "maintenance_windows": [
    {
      "alert_condition_groups": [
        {
          "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"
              }
            }
          ]
        }
      ],
      "archived_at": "2021-08-17T13:28:57.801578Z",
      "created_at": "2021-08-17T13:28:57.801578Z",
      "end_at": "2021-08-17T14:28:57.801578Z",
      "escalation_targets": [
        {
          "escalation_paths": {
            "array_value": [
              {
                "label": "Lawrence Jones",
                "literal": "SEV123",
                "reference": "incident.severity"
              }
            ],
            "value": {
              "label": "Lawrence Jones",
              "literal": "SEV123",
              "reference": "incident.severity"
            }
          },
          "users": {
            "array_value": [
              {
                "label": "Lawrence Jones",
                "literal": "SEV123",
                "reference": "incident.severity"
              }
            ],
            "value": {
              "label": "Lawrence Jones",
              "literal": "SEV123",
              "reference": "incident.severity"
            }
          }
        }
      ],
      "id": "01FCNDV6P870EA6S7TK1DSYDG0",
      "incident_id": "01FCNDV6P870EA6S7TK1DSYDG0",
      "lead": {
        "alert": {
          "id": "01GW2G3V0S59R238FAHPDS1R66",
          "title": "*errors.withMessage: PG::Error failed to connect"
        },
        "api_key": {
          "id": "01FCNDV6P870EA6S7TK1DSYDG0",
          "name": "My test API key"
        },
        "user": {
          "email": "lisa@incident.io",
          "id": "01FCNDV6P870EA6S7TK1DSYDG0",
          "name": "Lisa Karlin Curtis",
          "role": "viewer",
          "slack_user_id": "U02AYNF2XJM"
        },
        "workflow": {
          "id": "01FCNDV6P870EA6S7TK1DSYDG0",
          "name": "My little workflow"
        }
      },
      "name": "Planned database migration",
      "notification_message": "Scheduled downtime for database migration",
      "notify_channels": [
        {
          "channel_id": "C0ACTHQMHS8",
          "channel_name": "general",
          "channel_type": "public",
          "is_private": false
        }
      ],
      "notify_end_minutes_before": 5,
      "notify_start_minutes_before": 15,
      "reroute_on_end": false,
      "resolve_on_end": false,
      "show_in_sidebar": true,
      "start_at": "2021-08-17T13:28:57.801578Z",
      "updated_at": "2021-08-17T13:28:57.801578Z"
    }
  ],
  "pagination_meta": {
    "after": "01FCNDV6P870EA6S7TK1DSYDG0",
    "page_size": 25
  }
}

Authorizations

Authorization
string
header
required

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

Query Parameters

page_size
integer<int64>
default:25

Number of maintenance windows to return per page

Required range: 1 <= x <= 50
Example:

25

after
string

The ID of the last maintenance window on the previous page

Example:

"01FCNDV6P870EA6S7TK1DSYDG0"

status
enum<string>

Filter by window status: active (start_at <= now < end_at), upcoming (now < start_at), or past (end_at <= now)

Available options:
active,
upcoming,
past
Example:

"active"

Response

200 - application/json

OK response.

maintenance_windows
object[]
required
Example:
[
  {
    "alert_condition_groups": [
      {
        "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"
            }
          }
        ]
      }
    ],
    "archived_at": "2021-08-17T13:28:57.801578Z",
    "created_at": "2021-08-17T13:28:57.801578Z",
    "end_at": "2021-08-17T14:28:57.801578Z",
    "escalation_targets": [
      {
        "escalation_paths": {
          "array_value": [
            {
              "label": "Lawrence Jones",
              "literal": "SEV123",
              "reference": "incident.severity"
            }
          ],
          "value": {
            "label": "Lawrence Jones",
            "literal": "SEV123",
            "reference": "incident.severity"
          }
        },
        "users": {
          "array_value": [
            {
              "label": "Lawrence Jones",
              "literal": "SEV123",
              "reference": "incident.severity"
            }
          ],
          "value": {
            "label": "Lawrence Jones",
            "literal": "SEV123",
            "reference": "incident.severity"
          }
        }
      }
    ],
    "id": "01FCNDV6P870EA6S7TK1DSYDG0",
    "incident_id": "01FCNDV6P870EA6S7TK1DSYDG0",
    "lead": {
      "alert": {
        "id": "01GW2G3V0S59R238FAHPDS1R66",
        "title": "*errors.withMessage: PG::Error failed to connect"
      },
      "api_key": {
        "id": "01FCNDV6P870EA6S7TK1DSYDG0",
        "name": "My test API key"
      },
      "user": {
        "email": "lisa@incident.io",
        "id": "01FCNDV6P870EA6S7TK1DSYDG0",
        "name": "Lisa Karlin Curtis",
        "role": "viewer",
        "slack_user_id": "U02AYNF2XJM"
      },
      "workflow": {
        "id": "01FCNDV6P870EA6S7TK1DSYDG0",
        "name": "My little workflow"
      }
    },
    "name": "Planned database migration",
    "notification_message": "Scheduled downtime for database migration",
    "notify_channels": [
      {
        "channel_id": "C0ACTHQMHS8",
        "channel_name": "general",
        "channel_type": "public",
        "is_private": false
      }
    ],
    "notify_end_minutes_before": 5,
    "notify_start_minutes_before": 15,
    "reroute_on_end": false,
    "resolve_on_end": false,
    "show_in_sidebar": true,
    "start_at": "2021-08-17T13:28:57.801578Z",
    "updated_at": "2021-08-17T13:28:57.801578Z"
  }
]
pagination_meta
object
required
Example:
{
  "after": "01FCNDV6P870EA6S7TK1DSYDG0",
  "page_size": 25
}