Verify Payments (Client-side callback)

SeerBit’s inline script (SeerbitPay({...}, callback)) includes a callback function you can define when initiating the payment. SeerBit will call that function with a response object after the user completes (or closes) the checkout modal. You can inspect that response to see the payment result in real-time.After a payment has been completed, verify the payment with the payment status check endpoint. To verify a payment make a GET request to the status check endpoint using the transaction reference.
To call this endpoint, get your 'Bearer Token'
1function callback(response, closeModal) { 
2
3console.log(response) //response of transaction 
4
5}, 
6
7function close(close) { 
8
9console.log(close) //transaction close 
10
11}) 
This is useful for showing immediate UI feedback, but you should not rely on it alone to finalize the order on your backend.

Verify Payments (Server-side status verification)

After a transaction, you can verify the payment server-side using SeerBit’s status check API. This gives the definitive payment result.
How this works:
  • After payment, save the transaction reference (tranref/paymentReference) you generated.
  • Call the SeerBit status query endpoint with your server’s Bearer Token:
SeerBit will return structured details showing whether the payment succeeded (e.g., gatewayMessage: "Successful", success codes, amount, etc.). You can then update your order or database based on this verified result.
Response Sample
The code snippet below shows an example response for verifying a payment
1{
2    "status": "SUCCESS",
3    "data": {
4        "code": "00",
5        "message": "Successful",
6        "payments": {
7            "redirectLink": "https://checkout.seerbitapi.com/#/",
8            "amount": 10.15,
9            "fee": "0.15",
10            "mobilenumber": "404",
11            "publicKey": "MERCHANT_PUBLIC_KEY",
12            "paymentType": "CARD",
13            "productId": "",
14            "productDescription": "Goods and services",
15            "maskedPan": "4187-45XX-XXXX-3456",
16            "gatewayMessage": "Successful",
17            "gatewayCode": "00",
18            "gatewayref": "SEERBIT1303494716633",
19            "businessName": "Test Business",
20            "mode": "live",
21            "callbackurl": "https://seerbit.com",
22            "redirecturl": "https://checkout.seerbitapi.com/#/",
23            "channelType": "VISA",
24            "sourceIP": "",
25            "deviceType": "Desktop",
26            "cardBin": "418745",
27            "lastFourDigits": "3456",
28            "country": "NG",
29            "currency": "NGN",
30            "paymentReference": "TestReference",
31            "paymentBreakdown": {
32                "amount": 10.00,
33                "fee": 0.15,
34                "total": 10.15
35            },
36            "reason": "Successful",
37            "transactionProcessedTime": "2024-12-06 15:18:36.404709127"
38        },
39        "customers": {
40            "customerId": "SBTb77e16b073ea491",
41            "customerName": "John Doe",
42            "customerMobile": "404",
43            "customerEmail": "ts@emaildomain.com",
44            "fee": "0.15"
45        }
46    }
47}

Webhooks (real-time server notifications)

For fully automated backend processing, set up webhooks in your SeerBit merchant dashboard. SeerBit will send POST notifications to your webhook endpoint whenever events, including payment completion, occur.
Webhook benefits:
  • You don’t need to poll the status API.
  • Your system gets notified automatically when a transaction is confirmed.
  • Looser coupling between frontend and backend.
Typical setup:
  1. Create a secure HTTP endpoint on your server.
  2. Register its URL in Account Settings → Webhooks in the SeerBit merchant dashboard.
  3. Handle incoming POSTs (look at eventType to check for transaction success).
  4. Reply with HTTP 200 OK to acknowledge receipt.

Verify Recurrent Subscriptions

This operation allows you to check the status of a subscription via the subscription status check api. This is done by making a GET request to the endpoint below with the transaction's billingId.
Response Sample
The code snippet below shows an example response for verifying a subscription
1{
2    "status": "SUCCESS",
3    "data": {
4        "subscriptions": {
5            "publicKey": "SBTEST**********************ZYviTF", 
6            "amount": "20",
7            "country": "NG",
8            "customerId": "651d33a62ad69c9f37c4",
9            "cardName": "Bola Olat",
10            "cardNumber": "2223-00xx-xxxx-0007",
11            "plan": "ae702f51220000722dca",
12            "status": "ACTIVE",
13            "billingId": "WQ6676yPOpr12348o",
14            "authorizationCode": "2beb0ccdd347e604552a",
15            "startDate": "2019-01-11 00:00:00",
16        }
17      }
18    };
Need something else?
If you have any questions or need general help, visit our support page
Signup for developer update
You can unsubscribe at any time. Read our privacy policy.