Verify or webhooks?
Both tell you a payment’s outcome. The difference is who starts the conversation.
Use both. Webhooks are how you learn about a payment promptly without polling; verification is how you confirm the detail before you commit to it — and your fallback when a webhook never arrives, or a customer returns to your site before it does.
Authentication
Verification calls are authenticated with a bearer token, generated from your public and secret keys.Authentication
How to generate the token, and which credential every other SeerBit API expects.
Verify a payment
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:
Response Sample
The code snippet below shows an example response for verifying a paymentResponse fields
Before you fulfil an order
A200 OK from the status endpoint means the query succeeded — not that the payment did. Run all four checks below before you release goods or credit an account.
1. Check the status code
data.code is the authoritative field. gatewayCode reflects what the acquirer returned and reason is human-readable; neither should drive your fulfilment logic on its own.
Treat any code you do not explicitly recognise as unpaid.
2. Check the amount
Comparepayments.amount against the amount your own order expects. Never take the amount from the browser or from a callback parameter — a value that reaches you through the customer’s device can be altered before it gets to you.
This is not a theoretical concern: a card issuer can return SM_10 — approved for partial amount — in which case the transaction succeeded for less than you charged.
3. Check the currency
Comparepayments.currency against your order. An amount that matches numerically in the wrong currency is not a matching payment.
4. Check the reference belongs to this order
Confirmpayments.paymentReference is the reference you generated for this specific order, and that you have not already fulfilled it. Storing the reference and marking it fulfilled makes this check idempotent, so a repeated webhook or a customer refreshing the page cannot ship the same order twice.
Note: Apply these checks in your webhook handler as well as after a status query. Both paths lead to fulfilment, so both need the same guard.
The client-side callback is not proof
SeerBit’s inline scriptSeerbitPay({...}, callback) calls a function of yours with a response object once the customer completes or closes the checkout modal.
Webhooks
For automated processing, register a webhook URL in your dashboard and SeerBit will POST each event to you as it happens — no polling required. Apply the same fulfilment checks in your handler that you would after a status query.Webhooks
Setup, the acknowledgment contract your endpoint must satisfy, retries and event types.
Verify a subscription
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. GETResponse Sample
The code snippet below shows an example response for verifying a subscriptionNotes
- Verify with the reference you generated, not one returned to the browser. That is the only value you can trust to identify your own order.
- A
200 OKmeans the query worked, not that the payment did. The outcome is indata.code. - Verification is idempotent — call it as often as you need. Guard your fulfilment against repeats, not the query.
- A pending payment is not a failed one.
S20andS0mean the outcome is still open; query again rather than treating the order as dead. - Local payment methods resolve asynchronously, so pair verification with webhooks rather than polling in a loop.