Webhook & Redirect URL
Webhooks are used so that anytime an event occurs on your account, your application can be notified with instant, real-time notifications by Squad.
Squad webhooks are HTTP calls that are triggered by specific events. It is necessary only for behind-the-scenes transactions.
This can be set up on your Squad Dashboard by specifying a URL we would send POST requests to whenever a successful transaction occurs.
To process notifications, you need to:
Paste your redirect andCallback/Webhook URL
in the space provided on your dashboard by following the steps below:
Login to your Squad dashboard.
Go to Profile > API & Webhook.
In the Webhook URL field, enter your Notification URL.
In the redirect URL field, enter your redirect URL- and on completion of payment, the customer will be redirected to the URL with the transaction reference passed as a query param.
Enter a redirect URL for your customers to be redirected after they complete payment. Note: The Redirect URL is optional.
KINDLY ENSURE YOU HAVE A TRANSACTION REFERENCE CHECKER WHEN IMPLEMENTING WEBHOOKS TO AVOID GIVING DOUBLE VALUE ON TRANSACTIONS.
Sending IP: 18.133.63.109
Webhook Validation
To configure webhook notifications: go to dashboard > profile > Api & Webhooks.
The Webhook is a post request that is triggered whenever a transaction is successful
POST
Headers
x-squad-encrypted-body*
Hash
This is the encrypted payload which serves as a test of truth for all transactions. This should be compared against the body sent via the webhook by encrypting the body of data and comparing the value with this value
Content-type*
JSON
application/json
Sample POST request to be sent via webhook upon successful transaction
Sample Webhook for Card Transactions
Sample Webhook for Bank Transfer Option
SAMPLE WEBHOOK FOR USSD PAYMENT OPTION
Sample Webhook for Merchant USSD (USSD CODE ON THE DASHBOARD)
Please Note that the encrypted body (x-squad-encrypted-body) is usually sent via the header
Last updated