EdgeGateway webhooks deliver real-time payment status updates directly to your server. They are designed to provide reliable, server-to-server confirmation of transaction outcomes.
Overview
Webhooks are automatically triggered whenever a transaction status changes on EdgeGateway.
They should be treated as the primary source of truth for confirming payments, even if the customer is redirected back to your website.
⚠️ Client-side redirects can be interrupted or skipped.
Webhooks are always sent once the final transaction state is known.
When Webhooks Are Sent
A webhook is triggered in the following scenarios:
- ✅ Payment completed successfully
- ❌ Payment failed
- 🔄 Transaction status transitions
(created → scanning → success / failure)
Multiple webhook calls may be sent for a single transaction as its status progresses.
Webhook Endpoint
You must expose an HTTPS endpoint on your server to receive webhook callbacks.
Example endpoint:
- Webhooks are sent as HTTP POST
- Payload is sent in JSON format
- Your server must return HTTP 200 OK
Payload Structure
Each webhook request contains a JSON payload with:
- Transaction identifiers
- Final payment amount
- Current transaction status
- Customer details
- Bank reference numbers (UTR)
- Merchant-provided metadata (UDF fields)
Example Webhook Payload
Code

