Real-time notifications
Stay informed about payment events with real-time webhooks. Automate your order processing, and more.
Overview
Webhooks allow you to receive real-time notifications about events that occur in your Reservepay account. Instead of polling our API to check for updates, your server can listen for incoming requests from Reservepay.
Setting up webhooks
To start receiving webhook notifications, you need to connect a webhook endpoint to your account. You can manage your webhooks either through our API or directly from your merchant dashboard under the Developer Settings section.
Currently supported events
| Event | Description |
|---|---|
PAYMENT_AUTHORIZED |
Triggered when a payment status transitions to AUTHORIZED. |
PAYMENT_COMPLETED |
Triggered when a payment status transitions to SUCCESSFUL or FAILED. |
PAYMENT_VOIDED |
Triggered when a payment status transitions to VOIDED. |
PAYMENT_REVERSED |
Triggered when a payment status transitions to REVERSED. |
PAYOUT_COMPLETED |
Triggered when a payout status transitions to SUCCESSFUL or FAILED. |
If you have other needs or require additional event types, please contact our support team and we'll be happy to add them for you.
Handling webhook requests
When an event occurs, Reservepay will send a POST request to your destination URL with a JSON payload containing the event details.
Verifying signatures
To ensure that the request genuinely came from Reservepay, you must verify the signature included in the X-Webhook-Signature header. Use your webhook endpoint's verification key (available in your dashboard) and a libsodium compatible library for verification.
Responding to webhooks
Your server should respond with a 200 OK status code to acknowledge receipt of the webhook. If your server returns an error or fails to respond, Reservepay will retry the notification with exponential backoff.
Summary of best practices
- Idempotency: Ensure that your webhook handler can handle duplicate notifications gracefully.
- Security: Always verify the webhook signature before processing the request.
- Speed: Process webhooks asynchronously to avoid delaying the response to Reservepay.
Dive deeper into these advanced integration topics to unlock Reservepay's full potential with our in-depth guides.
Issue refunds, void transactions before they settle, and reverse authorizations when needed.
Read the guideSeparate authorization from capture to hold funds without charging. Perfect for pre-orders or reservations
Read the guideSubmit orders to unlock powerful analytics and strengthen your case during disputes.
Build profiles by attaching customer data. Gain insights, reduce fraud risk, and create experiences that drive loyalty.
Read the guideSend payouts to your primary bank account or to your contacts via bank account, mobile number or national ID.
Read the guideStay informed about payment events with real-time webhooks. Automate your order processing, and more...
Read the guide