APIWebhooks

Webhooks_rotate Secret

Rotate the signing secret. The previous secret co-signs deliveries for 24h. Returns the new secret once.

POST
/webhooks/{webhook_id}/rotate-secret

Rotate the signing secret. The previous secret co-signs deliveries for 24h. Returns the new secret once.

Authorization

ApiKeyAuth
headerAuthorizationBearer <token>

Bearer token authentication. Send an API key (a saai_api_-prefixed token) as Authorization: Bearer <token>.

Required permission

manage_webhooks

Path Parameters

webhook_id*string
Formatuuid

Response Body

The request has succeeded.

application/json
  1. response

Create/rotate response. secret is shown only once, here.

webhook*

A configured webhook. The signing secret, the endpoint URL, custom header values, and variable values are never returned.

secret*string

The whsec_ signing secret. Shown only once.

curl -X POST "https://example.com/webhooks/497f6eca-6276-4993-bfeb-53cbbbba6f08/rotate-secret"
{  "webhook": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "name": "string",    "url_hint": "string",    "events": [      "string"    ],    "status": "active",    "disabled_reason": "circuit_breaker",    "failing_since": "2019-08-24T14:15:22Z",    "last_delivery_status": "pending",    "last_delivery_at": "2019-08-24T14:15:22Z",    "format": "single",    "max_events": 0,    "has_custom_headers": true,    "header_keys": [      "string"    ],    "template": "string",    "condition": "string",    "destination": "string",    "var_keys": [      "string"    ],    "created_at": "2019-08-24T14:15:22Z",    "updated_at": "2019-08-24T14:15:22Z"  },  "secret": "string"}