Set up a webhook
1
Log in to your dashboard
Go to app.zerocash.tech.
2
Open Webhooks
Find the Webhooks section in the sidebar.
3
Add your URL
Register an HTTPS endpoint. Sandbox and production are configured separately.
4
Verify signatures
Before trusting any payload, check the signature. See
Webhook secrets.
You can read back your currently configured webhook URLs for both environments through
Get User.
Delivery behaviour
Writing a reliable handler
Respond fast, process later
Respond fast, process later
Validate the signature, enqueue the payload, return
200. Anything else belongs in a worker.Make processing idempotent
Make processing idempotent
Retries mean the same event can arrive more than once, and events can arrive out of order. Key
your processing on
transactionId (or your externalReference) and ignore an event that would
move a transaction backwards from a terminal state.Never trust the payload alone for high-value actions
Never trust the payload alone for high-value actions
For anything irreversible, confirm against
Get Transaction before releasing value.
Return 2xx even for events you ignore
Return 2xx even for events you ignore
A non-2xx tells Zerocash the delivery failed and triggers a retry. If you receive an event type
you do not handle, acknowledge it anyway.
Inspecting and replaying deliveries
Next
Webhook secrets
Verify that a request genuinely came from Zerocash.
Event types & structures
The base envelope, event names, and transaction types.