How it works
- You register a webhook endpoint via the API.
- When a subscribed event occurs, SimpleDocs sends an HTTP
POSTrequest to your URL with a JSON payload. - Your server processes the payload and responds with a
2xxstatus code to acknowledge receipt.
Supported events
New events may be added in the future. Your webhook handler should gracefully ignore unrecognized event types.
Creating a webhook
Use the Create webhook endpoint. You’ll need a token with thewrite scope.
No authentication
Basic authentication
Bearer token authentication
Webhook payloads
When an event fires, SimpleDocs delivers aPOST request to your URL with a JSON body. The exact payload structure depends on the event type.
execution_complete payload
questions key is only present for NDA-type workflows.
Responding to webhooks
Your endpoint must return an HTTP2xx status code within 30 seconds to indicate successful receipt. Any other status code or a timeout is treated as a delivery failure.
Best practices
- Respond quickly — Process webhook payloads asynchronously (e.g., enqueue a background job) and return
200immediately. - Handle duplicates — In rare cases a webhook may be delivered more than once. Design your handler to be idempotent.
- Ignore unknown events — As new events are added, your endpoint may receive event types you haven’t seen before. Return
200and ignore them.
Listing your webhooks
You can verify your registered webhooks at any time:Deleting a webhook
When you no longer want to receive events at an endpoint, delete its registration with the Delete webhook endpoint. You’ll need a token with thewrite scope.
204 No Content with an empty body. Deleting an unknown webhook ID returns 404.
After deletion, SimpleDocs stops sending events to the endpoint immediately — deliveries that were already queued for the webhook are discarded rather than retried.