Virtual Cards

Bitnob's Cards API allows you to programmatically issue and manage virtual and physical debit cards for your customers. Cards can be used for online purchases, subscriptions, and other payments worldwide.

Card API Endpoints

Create Card

Issue a new virtual or physical card for a customer. The card is created in an active state and can be used immediately after funding.

Create Card

Create Card Body Parameters
1
customer_idstringRequired

Customer ID to issue the card for. The customer must exist in your Bitnob account.

2
card_typestringRequired

The type of card to issue. Accepted values are virtual or physical.

3
card_brandstringRequired

The card network brand. Accepted values are visa or mastercard.

4
currencystringRequired

The currency denomination for the card (e.g., USD, NGN). All transactions on the card will be settled in this currency.

5
billing_addressobjectRequired

The billing address associated with the cardholder.

6
billing_address.line1stringRequired

Primary street address line (e.g., house number and street name).

7
billing_address.line2string

Secondary address line for additional information such as suite or apartment number.

8
billing_address.citystringRequired

City of the billing address.

9
billing_address.statestringRequired

State or province of the billing address.

10
billing_address.postal_codestringRequired

Postal or ZIP code of the billing address.

11
billing_address.countrystringRequired

Two-letter ISO 3166-1 alpha-2 country code (e.g., NG, US, GB).

12
spending_limitsobject

Optional spending limits to apply to the card. Includes single_transaction, daily, weekly, and monthly limit fields.

13
metadataobject

Custom key-value pairs you can attach to the card for internal tracking (e.g., department, cost center).

Body Parameters

Response
1
idstring

Unique identifier for the newly created card.

2
company_idstring

Identifier of the company that owns this card.

3
customer_idstring

Identifier of the customer the card was issued to.

4
card_typestring

The type of card issued — virtual or physical.

5
card_brandstring

The card network brand — visa or mastercard.

6
last_fourstring

The last four digits of the card number.

7
currencystring

The currency denomination for the card.

8
statusstring

Current card status. Newly created cards are active.

9
balancestring

Current balance on the card. Starts at 0.00 upon creation.

10
spending_limitsobject

Applied spending limits including single_transaction, daily, weekly, and monthly caps.

11
billing_addressobject

The billing address associated with the card.

12
metadataobject

Custom key-value pairs attached to the card.

13
created_atstring

ISO 8601 timestamp of when the card was created.

14
updated_atstring

ISO 8601 timestamp of the last update to the card.

Response Body

Get Card

Retrieve the details of a specific card by its ID. This returns general card information including balance and status, but not sensitive card data like the full card number or CVV.

Get Card

Path Parameters
1
cardIdstringRequired

The unique identifier of the card to retrieve.

Note

The response is identical to that of Create Card. Refer to the Create Card Response section for field explanations.

Response Body

Get Card Details (Sensitive)

Retrieve sensitive card data including the full card number, CVV, and expiry date. This endpoint returns PCI-sensitive information and should be used with extreme care.

Security Warning

Only call this endpoint when absolutely necessary. Never log or store the full card number or CVV. Display card details securely in the UI and consider implementing additional verification (e.g., 2FA) before showing details to end users.

Get Card Details

Path Parameters
1
cardIdstringRequired

The unique identifier of the card whose sensitive details are being retrieved.

Response Body

List Cards

Retrieve a paginated list of all cards. Use query parameters to filter by status, type, or customer.

List Cards

Query Parameters
1
statusstring

Filter cards by their current status (e.g., active, frozen, terminated).

2
card_typestring

Filter by card type. Accepted values are virtual or physical.

3
customer_idstring

Filter cards belonging to a specific customer.

4
limitinteger

Number of results to return per page. Defaults to 20, maximum 100.

5
offsetinteger

Number of results to skip before returning records. Used for pagination. Defaults to 0.

Response Body

Fund Card

Add funds to a card's balance. The currency must match the card's denominated currency.

Fund Card

Path Parameters
1
cardIdstringRequired

The unique identifier of the card to fund.

Body Parameters
1
amountstringRequired

The amount to add to the card balance as a decimal string (e.g., "500.00").

2
currencystringRequired

Currency code for the funding operation. Must match the card's currency.

3
descriptionstring

A human-readable description for this funding transaction.

4
referencestring

Your internal reference identifier for this transaction. Used for idempotency and reconciliation.

Body Parameters

Response
1
card_idstring

Identifier of the card that was funded.

2
operationstring

The operation type. Value is fund for this endpoint.

3
amountstring

The amount that was added to the card balance.

4
currencystring

Currency code of the funding operation.

5
new_balancestring

The updated card balance after the funding operation.

6
transaction_idstring

Unique identifier for this funding transaction.

7
referencestring

The reference identifier provided in the request.

8
created_atstring

ISO 8601 timestamp of when the funding transaction was created.

Response Body

Withdraw from Card

Remove funds from a card's balance back to your account. Useful for reclaiming unused funds or adjusting card balances.

Withdraw from Card

Path Parameters
1
cardIdstringRequired

The unique identifier of the card to withdraw funds from.

Body Parameters
1
amountstringRequired

The amount to withdraw from the card balance as a decimal string (e.g., "200.00").

2
currencystringRequired

Currency code for the withdrawal. Must match the card's currency.

3
descriptionstring

A human-readable description for this withdrawal transaction.

4
referencestring

Your internal reference identifier for this transaction.

Body Parameters

Response
Note

The response is identical to that of Fund Card. Refer to the Fund Card Response section for field explanations.

Response Body

Freeze Card

Temporarily suspend a card to prevent any new transactions. The card can be unfrozen later to restore its active state. Useful for responding to suspected fraud or temporary suspension needs.

Freeze Card

Path Parameters
1
cardIdstringRequired

The unique identifier of the card to freeze.

Body Parameters
1
reasonstring

An optional reason for freezing the card. Stored for audit purposes.

Body Parameters

Response
1
card_idstring

Identifier of the card that was frozen.

2
statusstring

Updated card status. Value is frozen after this operation.

3
frozen_atstring

ISO 8601 timestamp of when the card was frozen.

4
reasonstring

The reason provided for freezing the card, if supplied.

Response Body

Unfreeze Card

Restore a frozen card to an active state, allowing it to process new transactions again. No request body is required.

Unfreeze Card

Path Parameters
1
cardIdstringRequired

The unique identifier of the frozen card to restore.

Response Body

Terminate Card

Permanently terminate a card. This action is irreversible. Any remaining balance on the card will be returned to your account.

Terminate Card

Path Parameters
1
cardIdstringRequired

The unique identifier of the card to terminate.

Body Parameters
1
reasonstring

An optional reason for terminating the card. Stored for audit and compliance purposes.

Body Parameters

Response
1
card_idstring

Identifier of the card that was terminated.

2
statusstring

Updated card status. Value is terminated after this operation.

3
remaining_balancestring

The balance that was on the card at the time of termination.

4
balance_returnedboolean

Indicates whether the remaining balance was returned to your account.

5
terminated_atstring

ISO 8601 timestamp of when the card was terminated.

6
reasonstring

The reason provided for terminating the card, if supplied.

Response Body

Update Spending Limits

Update the spending limits and merchant restrictions on a card. All fields are optional — only the fields you include will be updated.

Update Spending Limits

Path Parameters
1
cardIdstringRequired

The unique identifier of the card whose spending limits are being updated.

Body Parameters
1
single_transactionstring

Maximum amount allowed per individual transaction as a decimal string.

2
dailystring

Maximum total spending allowed per day as a decimal string.

3
weeklystring

Maximum total spending allowed per week as a decimal string.

4
monthlystring

Maximum total spending allowed per month as a decimal string.

5
allowed_categoriesarray

List of allowed MCC (Merchant Category Code) categories. Transactions at merchants outside these categories will be declined.

6
blocked_categoriesarray

List of blocked MCC categories. Transactions at merchants in these categories will be declined.

7
allowed_merchantsarray

Whitelist of specific merchant IDs. When set, only transactions at these merchants are allowed.

8
blocked_merchantsarray

Blacklist of specific merchant IDs. Transactions at these merchants will be declined.

Body Parameters

Response
1
card_idstring

Identifier of the card whose spending limits were updated.

2
operationstring

The operation type. Value is update_spending_limits for this endpoint.

3
spending_limitsobject

The full set of updated spending limits, including single_transaction, daily, weekly, monthly, allowed_categories, blocked_categories, allowed_merchants, and blocked_merchants.

4
updated_atstring

ISO 8601 timestamp of when the spending limits were last updated.

Response Body

Get Cards by Customer

Retrieve all cards belonging to a specific customer.

Get Cards by Customer

Path Parameters
1
customerIdstringRequired

The unique identifier of the customer whose cards are being retrieved.

Response Body
Did you find this page useful?