Skip to main content
Webhooks avoid polling every generation. Fanify Hub sends generation.running when execution actually starts. It sends generation.completed for every final state: success, failure, or cancellation. A generation canceled or failed while waiting in the queue does not emit generation.running.

Register an endpoint

The 201 response contains a secret only once. The URL must use HTTPS and be publicly reachable. An account can register up to 5 active endpoints.

Verify a delivery

Each request includes:
The JSON body uses this envelope:
data contains the complete generation object. The envelope id is identical to the X-Fanify-Delivery header. Compute HMAC-SHA256(secret, raw body) and compare the result with X-Fanify-Signature in constant time.
Verify the signature against the raw bytes before parsing JSON. Re-serializing the body changes the signature.
A successful delivery can be repeated and ordering is not guaranteed. Deduplicate requests with X-Fanify-Delivery. Fanify Hub retries after a 429 response, a 5xx response, a timeout, or a connection failure. Other 4xx responses immediately abandon the delivery. A retried delivery makes at most 8 attempts, delayed by 30 seconds, 2 minutes, 10 minutes, 1 hour, 6 hours, 24 hours, then 72 hours. The final failure is exposed as last_error by GET /api/v1/hub/webhooks. GET /api/v1/hub/webhooks lists endpoints without their secrets. DELETE /api/v1/hub/webhooks/{id} revokes an endpoint.