Create a webhook
POST/v1/projects/:project_id/webhooks
Register an endpoint and subscribe it to one or more event types.
The response carries secret — the signing key, in plaintext. This is the only time it is returned. Store it where your receiver can read it; if you lose it, rotate rather than re-create, so the endpoint keeps its delivery history. Send secret yourself to sign with a key your receiver already holds; the response then returns that one.
A project holds at most 20 webhooks, inactive ones included; the 21st is refused with 409 WEBHOOK_LIMIT_REACHED.
Returns 501 on a deployment with no credential-sealing key configured, since the secret could not then be stored safely.
Request
Responses
- 201
- 400
- 401
- 403
- 404
- 409
- 501
Webhook created. The signing secret is included, once.
The request was malformed or failed validation.
Missing or invalid credentials.
The credential is scoped to a different project, or the caller's role in the project does not carry this action.
The resource does not exist (existence is not leaked).
The project already holds 20 webhooks (WEBHOOK_LIMIT_REACHED); meta.limit carries the ceiling.
The requested path is not enabled on this deployment — a webhook secret cannot be stored where no credential-sealing key is configured.