Callbacks & Webhooks
Mercuryo sends a POST request to your callback URL every time a transaction status changes.
Setup
- Sign in to the Dashboard.
- Go to Widgets → select your widget.
- Fill in the Callback URL field with your server endpoint.
- Copy the Sign Key — you'll need it to verify incoming callbacks.
Go to Widget Callbacks to browse callback history, resend a callback, or send a test callback.
Callback Payload
The callback uses the standard Mercuryo callback format — see Callback Reference for the full payload schema and examples. For a native Apple Pay transaction, the data object contains:
"type": "buy""payment_method": "mobile_pay""method_code": "apple"
data.merchant_transaction_id contains your identifier, if you sent it in the payment request.
The status field reflects the current state of the transaction. See Transaction Statuses for all statuses and which of them are final.
After a successful payment, Mercuryo sends the purchased crypto to the user's wallet in a separate withdraw transaction, which has its own callbacks — see Transaction Statuses.
Callback Delivery & Retry Logic
Mercuryo considers a callback delivered when your server responds with any 2xx status code within 30 seconds. Redirects are followed, but 301, 302 and 303 turn the request into a GET without a body. Set the Callback URL to the final endpoint. Any other response code (including 4xx), a timeout, or a connection error triggers an automatic retry. The delay doubles after each failed attempt:
| Attempt | Delay after the previous attempt |
|---|---|
| 1st | — |
| 2nd | 15 seconds |
| 3rd | 30 seconds |
| 4th | 1 minute |
| 5th | 2 minutes |
| 6th | 4 minutes |
| 7th | 8 minutes |
| 8th | 16 minutes |
| 9th | 32 minutes |
A callback gets up to 9 delivery attempts within about 1 hour. After the 9th attempt, the callback is no longer retried.
You can also manually resend callbacks from the Dashboard.
The same callback can arrive more than once, and callbacks for the same transaction can arrive out of order. Process them idempotently: use eventId to detect duplicates and data.updated_at to skip outdated statuses.
Callback Signature Verification
Each callback includes an X-Signature header. Verify it before processing the callback — see Signature.