Skip to content

Change a webhook subscription

PATCH
/event-subscriptions/{id}
curl --request PATCH \
--url https://app.surveyrock.com/api/v1/event-subscriptions/example \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "name": "example", "url": "example", "event_types": [ "response.completed" ], "status": "active" }'

Change name, url (webhooks only), event_types, or status. Set status to active to resume a paused or disabled subscription (its failure count is cleared and its destination is checked again) or to paused to stop sending without losing what is queued. A subscription’s mode cannot change.

Changing the URL emails the workspace’s owners and admins.

id
required
string
Idempotency-Key
string
>= 1 characters <= 128 characters

1 to 128 characters, chosen by the caller. A retry with the same key and body replays the first response

Media typeapplication/json
object
name
string
<= 100 characters
url
string
<= 2048 characters
event_types
Array<string>
Allowed values: response.completed
status
string
Allowed values: active paused

The subscription as it now is

The plan does not include webhooks (feature_locked), or the token lacks events:write

subscription_not_found

duplicate_subscription

validation_failed: each error names the field