Rotate a webhook endpoint's signing secret

Generates a new signing secret for a webhook endpoint and returns it. Two keys come back: id and secret.

Requires the webhooks:write ability. Any key of the account can rotate any endpoint of the account — including one it did not create, whose new secret the creator will never learn.

This is the last time the new secret is shown. Store it immediately; no later request can retrieve it. It has the same shape as the one create returned: 64 lowercase hexadecimal characters, no prefix.

Rotating does not touch deliveries already in flight, and the two send paths do not read the secret from the same place. A first attempt is signed with the secret that was current when the delivery was queued, so a delivery queued just before you rotate arrives signed with the pre-rotation secret. Every retry is signed with the endpoint's secret as it stands when that retry is sent, so retries carry the new one. The same event can therefore arrive twice, under two different signatures.

The window in which the old secret can still arrive is however long the already-queued deliveries take to drain — ordinarily seconds or minutes, not hours. Only a first attempt can carry the pre-rotation secret; every retry re-reads the endpoint's secret as it stands, so once a delivery has failed once it is on the new secret for good. Size your risk against queue latency, not against a retry deadline.

A separate 24-hour figure governs something else, and is easy to mistake for this one. A delivery stops being re-queued once its next attempt is more than 24 hours overdue. That bounds how long a failing delivery goes on being retried; it does not widen the window in which the old secret can appear, and it is not the ~4.4 hours the retry backoff itself spans.

What your verifier should do while that drain is happening — accept both secrets, or accept only the new one and expect drops — is a security decision, not a formatting one, and the guidance for it lives with the signature-verification documentation rather than here.

The request takes no body.

Refusals past the shared ones: 404 WEBHOOK_NOT_FOUND, 404 RESOURCE_NOT_FOUND and 500 SYSTEM_DATABASE_ERROR.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
uuid
required

The resource's unique identifier.

Responses

Language
Credentials
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json