How They Work
Register an endpoint
Register a webhook for each
merchant_code + secret key pair. The environment is determined by the key you register with: a production key (sk_...) registers webhooks for production payments, a test key (sk_test_...) — for test payments. Each pair can have up to 4 webhooks. An optional auth header can sign the requests so you can verify their authenticity.Receive notifications
Tabby sends a POST request to your URL whenever the payment status changes.
Acknowledge with 200
Respond with a
200 HTTP status code to confirm the reception, and check the auth header to verify the request. Any other response (or no response) counts as a delivery error and triggers retries.Payload
Webhooks are POST requests with a JSON body:Supported Events
The payload content depends on the event:| Event | Webhook payment status | Payload update |
|---|---|---|
| Authorize | authorized | ”status”: “authorized” |
| Capture | authorized | capture info is added to captures.[] array |
| Close | closed | ”status”: “closed” and “closed_at” updated |
| Reject | rejected | ”status”: “rejected” |
| Expire (Optional) | expired | ”status”: “expired”, “expired_at” and “is_expired” updated |
| Refund | closed | refund info is added to refunds.[] array |
| Update | the same as before the Update Request | order.reference_id updated |
A Typical Payment
For a regular successful order you will receive three notifications:- Payment authorized — the payload status is
authorized. Check the order and process it in your OMS if it wasn’t processed yet, then send the Capture Request. - Payment captured — the payload status is still
authorized, with your capture added to thecapturesarray. No action is required. - Payment closed — the payload status is
closed: the payment is completed and confirmed from both sides. No action is required.
Best Practices
Webhooks are asynchronous: the delivery order is not guaranteed, and the same event may occasionally be delivered twice.
-
Respond fast. Acknowledge the webhook with
200right away and process it asynchronously, instead of holding the response until processing is done. - Handle out-of-order delivery. A capture event may arrive before an authorization event — use a finite state machine or similar logic instead of assuming the order.
- Deduplicate. Ignore a webhook if the same notification was already processed.
- Filter events. You receive notifications for all payment events — process only the ones you need.
-
Allowlist Tabby server IPs:
Retry Attempts
A webhook request times out after 1 minute. If it times out or gets any response other than200, Tabby resends it up to 4 more times with an exponential interval between attempts (1–4 minutes). Retries don’t block other notifications — Tabby keeps sending webhooks for other payment events as they occur.