Webhooks API
Avocazo supports Webhooks to notify your system about important events in the document lifecycle.
Instead of polling the Track API, you can register a webhook URL in your dashboard, and Avocazo
will send an HTTP POST request whenever a relevant event occurs.
Endpoint
Each client can configure their webhook endpoint in the dashboard. Avocazo will send a POST request to this URL with the event payload.
Events
The following webhook events are currently supported:
document.finished– Triggered when a document is fully generated and (if applicable) signed.document.failed– Triggered when document generation fails or when any signer rejects the signing process.
Request Format
Each webhook request includes:
- An HTTP header
X-Avocazo-Eventwith the event name. - An HTTP header
X-Avocazo-Signaturewith the SHA-256 signature of the payload (for verification). - A JSON body containing the same structure as the Track API response, wrapped in a
dataobject witheventandtimestamp.
Example Request
{
"status": Finished",
"document": {
"id": "A.YDUMPIMAGQ8JJNE",
"title": "Employee Join Request",
"header_template": "HEADER_1",
"footer_template": "BLANK",
"page_template": "BOXED_SECTIONS",
"service": "Structured Form Document Generation"
},
"generated_pdf": {
"status": "Completed",
"progress": 100,
"generated_at": "2025-09-03T13:24:49.000000Z",
"file_url": "https://avocazo.com/api/file/..."
},
"signing_process": {
"status": "In Progress",
"started_at": "2025-09-03T13:24:49.000000Z",
"completed_at": null,
"signers": [
{
"name": "Omar Alkattan",
"email": "omaralkattan@outlook.com",
"status": "Signed",
"signed_at": "2025-09-03T13:30:00.000000Z"
}
]
},
"final_pdf": {
"status": "Finished",
"file_url": "https://avocazo.com/api/file/...",
"completed_at": "2025-09-03T13:30:00.000000Z"
}
}
Notes
- You can configure your webhook endpoint in the dashboard under Webhooks.
- Always verify the
X-Avocazo-Signatureto ensure authenticity of the webhook. - Avocazo expects a
200 OKresponse from your server. If not received, it will retry delivery multiple times with exponential backoff. - The webhook payload mirrors the Track API response format for consistency.