Webhooks
Webhooks
Webhooks let your systems react to booking events in real-time. When a booking is confirmed or cancelled, Slotflow sends an HTTP POST to your registered URL with the event details.
Supported events
Registering a webhook
- Each URL can only be registered once per organization (duplicates are rejected)
- You can register for one or both events
- The URL must be reachable from the internet
Webhook limits by plan
Payload format
Every webhook delivery is an HTTP POST with a JSON body:
The data object contains the full booking, including the metadata your agent passed when creating the booking. This is how you connect webhook events back to your agent’s workflow.
Delivery behavior
- Method: HTTP POST
- Content-Type:
application/json - Timeout: 10 seconds — your endpoint must respond within 10 seconds
- Success: Any 2xx response code
Retry schedule
If your endpoint fails (non-2xx response or timeout), Slotflow retries:
After 3 failed attempts, the delivery is marked as failed. No further retries are attempted.
Building a webhook handler
Express.js example
Python (Flask) example
Using metadata
Metadata is the bridge between your agent’s workflow and webhook events. Whatever JSON you pass in the booking’s metadata field appears in the webhook payload.
Common metadata patterns:
Your webhook handler reads data.metadata to route the event to the right system:
Managing webhooks
List webhooks
Delete a webhook
Best practices
-
Respond 200 immediately — do heavy processing asynchronously. Slotflow times out after 10 seconds and will retry, which could cause duplicate processing.
-
Make handlers idempotent — due to retries, you may receive the same event twice. Use
data.id(the booking ID) to deduplicate. -
Log webhook payloads — store the raw payload for debugging. If something goes wrong, you’ll want to see exactly what was delivered.
-
Use HTTPS — your webhook URL should use HTTPS in production to protect the payload in transit.
-
Monitor delivery — check the Slotflow dashboard for failed deliveries. Common causes: endpoint down, slow response (>10s timeout), non-2xx response codes.