On this page
Set alert destinations
Set or clear the Slack webhook or PagerDuty routing key using the current revision.
Operation ID: alert_destinations.update.
Request
PATCH /api/v1/alert-destinations
- TypeScript SDK:
client.alert_destinations.update(path arguments usepath). - MCP tool:
sdk_client_callwithoperationId: "alert_destinations.update"(path arguments useinput.path). Legacy alias:alert_destinations_update. Connect to your authenticated/mcpendpoint with an API key for the same environment. - Minimum API key role: admin.
- Idempotency: No header required; the resource or revision identifies the change.
Read resource IDs from earlier responses and use a key for the same environment.
Request example
Read alert_destinations.get and copy the Slack destination’s revision before clearing it. This intentionally removes that workspace delivery destination; review affected rules first. Use change.kind replace with a private destination value to configure a new one.
Set CUMULUS_BASE_URL to your workspace API URL and CUMULUS_API_KEY to a key for that environment. Example values are synthetic.
cURL
curl --fail-with-body -sS -X PATCH "${CUMULUS_BASE_URL%/}/api/v1/alert-destinations" \
-H "Authorization: Bearer $CUMULUS_API_KEY" \
-H "Content-Type: application/json" \
--data '{
"changes": [
{
"destination": "slack",
"expected_revision": "66666666-6666-4666-8666-666666666666",
"change": {
"kind": "clear"
}
}
]
}'
TypeScript
import { Cumulus } from "@cumulus/sdk";
const baseUrl = process.env.CUMULUS_BASE_URL;
const apiKey = process.env.CUMULUS_API_KEY;
if (!baseUrl || !apiKey) throw new Error("Set CUMULUS_BASE_URL and CUMULUS_API_KEY");
const client = new Cumulus({ baseUrl, apiKey });
const response = await client.alert_destinations.update({
"body": {
"changes": [
{
"destination": "slack",
"expected_revision": "66666666-6666-4666-8666-666666666666",
"change": {
"kind": "clear"
}
}
]
}
});
Input schema
Path, query and header parameters
No path or query parameters.
JSON request body
| Field | Type or values | Required | Description and limits |
|---|---|---|---|
changes | array of object | Required | minItems: 1. maxItems: 2. |
changes[].destination | "slack" · "pagerduty" | Required | — |
changes[].expected_revision | string (uuid) or null | Required | Revision you last read. A stale revision is refused so another edit is not overwritten. pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$. |
changes[].change | object | Required | — |
| changes[].change · variant 1 | object | — | Fields for this schema branch. |
changes[].change.kind | "replace" | Required | — |
changes[].change.value | string | Required | minLength: 1. maxLength: 4096. |
| changes[].change · variant 2 | object | — | Fields for this schema branch. |
changes[].change.kind | "clear" | Required | — |
Complete OpenAPI schema
{
"parameters": [],
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AlertDestinationsUpdateRequest"
}
}
}
}
}
Responses
HTTP 200
Set or clear the Slack webhook or PagerDuty routing key (revision compare-and-set)
application/json
| Field | Type or values | Required | Description and limits |
|---|---|---|---|
scope | object | Required | — |
scope.owner_id | string | Required | minLength: 1. |
scope.environment | string | Required | minLength: 1. |
scope.tenant_id | string (uuid) | Required | pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$. |
destinations | object | Required | — |
destinations.slack | object | Required | — |
destinations.slack.revision | string (uuid) or null | Required | pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$. |
destinations.slack.configured | boolean | Required | — |
destinations.pagerduty | object | Required | — |
destinations.pagerduty.revision | string (uuid) or null | Required | pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$. |
destinations.pagerduty.configured | boolean | Required | — |
Error responses
| HTTP | Description |
|---|---|
| 4XX | Typed error (ApiError) |
| 5XX | Typed error (ApiError) |
Errors use the shared error envelope. Inspect error.code, retryable, outcome and details before retrying.
Complete OpenAPI schema
{
"200": {
"description": "Set or clear the Slack webhook or PagerDuty routing key (revision compare-and-set)",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AlertDestinationsGetResponse200"
}
}
}
},
"4XX": {
"description": "Typed error (ApiError)",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ApiError"
}
}
}
},
"5XX": {
"description": "Typed error (ApiError)",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ApiError"
}
}
}
}
}
Referenced schemas
Expand the complete OpenAPI definitions for integrations that generate their own clients.
Complete OpenAPI schema
{
"components": {
"schemas": {
"AlertDestinationsUpdateRequest": {
"type": "object",
"properties": {
"changes": {
"minItems": 1,
"maxItems": 2,
"type": "array",
"items": {
"type": "object",
"properties": {
"destination": {
"type": "string",
"enum": [
"slack",
"pagerduty"
]
},
"expected_revision": {
"nullable": true,
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
},
"change": {
"oneOf": [
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"replace"
]
},
"value": {
"type": "string",
"minLength": 1,
"maxLength": 4096
}
},
"required": [
"kind",
"value"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"clear"
]
}
},
"required": [
"kind"
],
"additionalProperties": false
}
]
}
},
"required": [
"destination",
"expected_revision",
"change"
],
"additionalProperties": false
}
}
},
"required": [
"changes"
],
"additionalProperties": false
},
"AlertDestinationsGetResponse200": {
"type": "object",
"properties": {
"scope": {
"type": "object",
"properties": {
"owner_id": {
"type": "string",
"minLength": 1
},
"environment": {
"type": "string",
"minLength": 1
},
"tenant_id": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
}
},
"required": [
"owner_id",
"environment",
"tenant_id"
],
"additionalProperties": false
},
"destinations": {
"type": "object",
"properties": {
"slack": {
"type": "object",
"properties": {
"revision": {
"nullable": true,
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
},
"configured": {
"type": "boolean"
}
},
"required": [
"revision",
"configured"
],
"additionalProperties": false
},
"pagerduty": {
"type": "object",
"properties": {
"revision": {
"nullable": true,
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
},
"configured": {
"type": "boolean"
}
},
"required": [
"revision",
"configured"
],
"additionalProperties": false
}
},
"required": [
"slack",
"pagerduty"
],
"additionalProperties": false
}
},
"required": [
"scope",
"destinations"
],
"additionalProperties": false
},
"ApiError": {
"type": "object",
"properties": {
"error": {
"type": "object",
"properties": {
"code": {
"type": "string",
"enum": [
"unauthenticated",
"forbidden",
"not_found",
"conflict",
"invalid_request",
"idempotency_conflict",
"policy_denied",
"capability_unavailable",
"provider_unavailable",
"knowledge_unavailable",
"publication_invalid",
"run_not_active",
"rate_limited",
"outcome_unknown",
"internal"
]
},
"message": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"outcome": {
"type": "string",
"enum": [
"none",
"unknown"
]
},
"details": {
"type": "object",
"additionalProperties": {}
}
},
"required": [
"code",
"message",
"retryable",
"outcome"
],
"additionalProperties": false
}
},
"required": [
"error"
],
"additionalProperties": false
}
}
}
}
Errors and recovery
See API error handling and Troubleshooting.