Webhooks

Introduction

Bitnob emits real-time webhook events that inform your system of all important activities and lifecycle events related to your virtual cards.

Each webhook provides structured data about:

Transaction outcomes (approved, failed, reversed, refunded),

Card lifecycle changes (created, terminated, frozen),

Operational risk events (failed authorizations, fraud flags, cross-border activity).

Webhooks are delivered to your registered callback URL via HTTPS POST requests.

Webhook Structure

All webhook payloads follow the same top-level format:

Webhook Payload Structure

Webhook Categories

CategoryDescription
Card LifecycleWhen a card is created, fails to create, or is terminated
Top-Ups & WithdrawalsWhen a card is loaded or funds are withdrawn
Transaction ActivityPurchases, refunds, declines, reversals, authorization failures
Risk EventsAutomated freezes, terminations, MCC restrictions, cross-border use
Refunds on Terminated CardsHandling of funds after a card is closed
1.

Card Lifecycle Webhooks

virtualcard.created.success

Fired when a virtual card is successfully created.

virtualcard.created.success Payload

virtualcard.created.failed

Fired when card creation fails.

virtualcard.created.failed Payload
2.

Card Funding Webhooks

virtualcard.topup.success

Card top-up (load funds) succeeded.

virtualcard.topup.failed

Top-up failed (e.g. insufficient balance, card status invalid).

virtualcard.topup.success Payload
3.

Card Withdrawal Webhooks

virtualcard.withdrawal.success

A successful withdrawal was made (if enabled).

virtualcard.withdrawal.failed

Withdrawal attempt failed (e.g. below minimum balance, card status invalid).

4.

Transaction Webhooks

virtualcard.transaction.debit

Successful spend or purchase transaction.

virtualcard.transaction.reversed

An authorized transaction was reversed (merchant canceled before settlement).

virtualcard.transaction.refund

Merchant refund after settlement.

Charge related to cross-border transaction applied to the card.

virtualcard.transaction.authorization.failed

Authorization attempt failed due to insufficient funds or card configuration.

5.

Declines & Risk Event Webhooks

virtualcard.transaction.declined

A purchase attempt was declined.

virtualcard.transaction.declined.frozen

Transaction declined due to card being frozen, usually from a fraud rule.

virtualcard.transaction.declined.terminated

Card was auto-terminated after repeated failed attempts (see risk rules in status management).

6.

Refunds After Termination

virtualcard.transaction.terminated.refund

Refund processed for a card that was already terminated. Funds returned to the float or master account.

Best Practices for Handling Webhooks

PracticeWhy It Matters
Acknowledge with HTTP 200Prevent retries and duplication
Log and verify every eventEnables reconciliation and debugging
Use event type (event) to route logicCleanly separate card creation, spend, and risk events
Secure your webhook endpointUse HMAC signature verification (Bitnob will provide guide)
Make it idempotentReplaying the same webhook shouldn’t create duplicate logic

Virtual Card Webhooks – Reference Table

Event NameCategoryDescription
virtualcard.created.successCard LifecycleCard was successfully created and is now active.
virtualcard.created.failedCard LifecycleCard creation failed. Check reason in payload.
virtualcard.topup.successTop-UpCard was funded successfully from float/wallet.
virtualcard.topup.failedTop-UpCard funding attempt failed.
virtualcard.withdrawal.successWithdrawalCash withdrawal from card succeeded (if supported).
virtualcard.withdrawal.failedWithdrawalWithdrawal failed (e.g. limit, balance, status).
virtualcard.transaction.debitTransactionA purchase or spend was successful.
virtualcard.transaction.reversedTransactionAn authorized transaction was canceled by the merchant.
virtualcard.transaction.refundTransactionMerchant refunded a completed transaction.
virtualcard.transaction.crossborderFee/ChargeCross-border charge occurred during international use.
virtualcard.transaction.authorization.failedTransactionAuthorization request failed (e.g. insufficient funds).
virtualcard.transaction.declinedDeclineTransaction declined (generic failure reason provided).
virtualcard.transaction.declined.frozenRiskCard was frozen due to flagged activity (fraud rule).
virtualcard.transaction.declined.terminatedRiskCard was auto-terminated due to multiple failed attempts.
virtualcard.transaction.terminated.refundRefundA terminated card received a refund. Funds returned to float.

Next Steps

You can test webhook delivery via the Bitnob API or by manually triggering test events from your dashboard.

Subscribe to sandbox events first to validate your implementation.

For production use, make sure to log all failed deliveries and monitor retry queues.

Did you find this page useful?