Update a webhook
PATCH
/api/webhooks/endpoints/:webhookIdChange a webhook's URL, events or description, turn it on or off, or rotate its secret (the response then has the new secret, the only time it is shown).
- While a webhook is off no events are queued for it.
- Turning it back on resets its failure count; events it missed are not sent, so resend the ones you need with webhooks_redeliver.
- A webhook turned off because its key or app was revoked (
disabledReason: "key_revoked") can only be turned on in the dashboard. - Changing the URL or rotating the secret ties the webhook to the calling key or app.
- Key scope
- webhooks:write
- MCP tool
- webhooks_update
Headers
AuthorizationstringrequiredBearer <API key>. Create a key in the dashboard under API keys.
Path parameters
webhookIdstringrequiredWebhook id (UUID):
idfrom webhooks_list or webhooks_create
Body
urlstringPublic https URL that receives the events. Private, loopback, internal and Ampost's own hosts are rejected.
events(post.scheduled | post.unscheduled | post.discarded | post.published | post.partial | post.failed | post.platform.published | post.platform.failed | post.platform.deleted | post.platform.edited | post.approval_requested | post.approved | post.rejected | account.connected | account.disconnected | account.needs_reconnect | analytics.synced)[]Events to send to this URL
descriptionstring | nullYour note for this webhook, at most 200 characters
enabledbooleanTurn the webhook on or off. Turning it on clears
disabledReasonand the failure count.rotateSecretbooleanTrue: replace the signing secret. The old one stops working at once.
Errors return { error: { code, message } }; every code is in Error codes.