Escalation
Update Escalation Config
Updates the escalation config. The :id parameter is the organization ID. If no config exists, one is upserted.
PATCH /api/escalation-config/:id
Request Body (all optional)
| Field | Type | Description |
|---|---|---|
webhookUrl | string|null | Webhook URL. Set to null to deactivate the webhook channel. |
webhookMethod | string | HTTP method: POST, PUT, or PATCH |
webhookHeaders | object|string | JSON headers object |
webhookBodyTemplate | string | JSON body template with {{variables}} |
webhookTimeout | integer | Timeout in seconds |
webhookRetryAttempts | integer | Number of retries |
webhookRetryDelay | integer | Seconds between retries |
expectedStatusCodes | string | Comma-separated expected status codes |
isActive | boolean | Enable or disable the webhook |
defaultEmail | string | Side-effect: creates/updates an org-level email notification channel |
defaultPhoneNumber | string | Side-effect: creates/updates an org-level SMS notification channel |
Example (cURL)
curl -X PATCH "$BASE_URL/api/escalation-config/1" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"webhookUrl": "https://example.com/webhook",
"webhookMethod": "POST",
"webhookHeaders": { "Content-Type": "application/json" },
"webhookTimeout": 30,
"webhookRetryAttempts": 3,
"isActive": true,
"defaultEmail": "alerts@example.com"
}'Common errors
401 Unauthorizedwhen not authenticated403 Forbiddenwith insufficient permissions
Response
Returns the updated escalation config object. See Error Codes for error responses.
Test Escalation Config
Tests the escalation config by sending a test webhook, PagerDuty event, or Pushover notification. All body fields are optional and override DB values for testing.
API Tokens
API tokens allow programmatic access to the Uptimeify API. Tokens are prefixed with wsm_ and can be scoped to a specific customer or organization-wide.