Webhook Error Handling
Vocobase automatically retries webhook deliveries that fail. This page explains the retry policy and best practices for building a reliable webhook handler.Retry policy
When a webhook delivery fails, Vocobase retries up to 3 times (4 total delivery attempts) with exponential backoff:| Attempt | Delay before attempt |
|---|---|
| Initial delivery | Immediate |
| 1st retry | 1 second |
| 2nd retry | 2 seconds |
| 3rd retry | 4 seconds |
GET /calls/{id} to fetch call details including the transcript and recording URL.
What counts as a failure
A webhook delivery is considered failed if:- Your endpoint returns a non-2xx status code (e.g., 400, 500)
- The request times out (no response within 10 seconds)
- A network error occurs (DNS resolution failure, connection refused, TLS error)
2xx response (200, 201, 202, 204, etc.) is treated as a successful delivery regardless of the response body.
Timeout
Each webhook request has a 10-second timeout. If your server does not respond within 10 seconds, the delivery is marked as failed and retried.Best practices
Respond immediately
Return a200 OK response as soon as you receive the webhook. Do not perform heavy processing before responding.
Handle duplicates (idempotency)
Due to retries, your endpoint may receive the same event more than once. Use thesession_id as an idempotency key:
Verify signatures
Always verify theX-Webhook-Signature header in production to ensure the request is from Vocobase. See Webhook Setup for implementation details.
Use a message queue
For high-volume integrations, push webhook events into a message queue (e.g., Redis, RabbitMQ, SQS) and process them with workers:Monitor failures
If webhooks fail repeatedly, check:- Your endpoint is reachable — Verify the URL is publicly accessible and not behind a firewall
- TLS certificate is valid — Expired or self-signed certificates cause connection failures
- Response time is under 10 seconds — Profile your handler to find bottlenecks
- Your server is running — Check logs for crashes or out-of-memory errors
Fallback: poll the API
If you miss webhook events, you can always fetch call data directly:Next steps
Webhook Payloads
See the full payload structure for each event type.
Webhook Setup
Configure your webhook URL and verify signatures.