Apply Cards

Endpoint:

Method: POST
Type: FORMDATA
URL: {{API_BASE_URL}}/cards/apply

Requires enough existing Card Caps. If more are needed, use Buy Card Cap before applying. This endpoint does not purchase Card Caps automatically.

Request Parameter

Parameter Required Type Default Description
num Y int number of cards to apply (1-30)
card_bin Y string card bin code, you can get the card bin code by api /cards/cardbins
card_type N string standard enumeration: standard, shared
request_id N string Optional, A unique request ID specified by the client. Requests with the same request_id will be ignored. This allows requests to be replayed if client is unsure of the outcome, e.g. due to network issues, system failures, etc. Note: Can be non-UUID as long as it is unique between requests.
every_card_top_up_amount N float top-up amount for each card
username N string assigning cards to user
auto_topup N int 0 when value is 1, means turn on auto top-up. when value is 0, means turn off auto top-up.
auto_topup_rule N object for standard card: {"min_balance":10,"topup_amount":10},means top-up $10 when balance is less than $10
for shared card: {"min_balance":10,"require_balance":10}, means update balance to $10 when balance is less than $1
shared_card_balance N float shared card only. set available balance of card (0-50000)
shared_card_balance_unlimit N int 1 shared card only. when value is 1, means balance unlimit. when value is 0, means balance is limit to "shared_card_balance"
single_transaction_limit N float the max single transaction amount limit
single_transaction_unlimit N int 1 when value is 1, means single transaction amount unlimit. when value is 0, means the max single transaction amount is limit to "single_transaction_limit"

Request Example (Standard Card):

{
    "num": 2,
    "card_type": "standard",
    "card_bin": "5:123456",
    "request_id": "unique_request_001",
    "every_card_top_up_amount": 50,
    "username": "test_username",
    "auto_topup": 1,
    "auto_topup_rule": {
        "min_balance": 10,
        "topup_amount": 50
    },
    "single_transaction_limit": 100,
    "single_transaction_unlimit": 0
}

Request Example (Shared Card):

{
    "num": 1,
    "card_type": "shared",
    "card_bin": "5:123456",
    "request_id": "unique_request_002",
    "auto_topup": 1,
    "auto_topup_rule": {
        "min_balance": 10,
        "require_balance": 100
    },
    "shared_card_balance": 100,
    "shared_card_balance_unlimit": 0,
    "single_transaction_limit": 50,
    "single_transaction_unlimit": 0
}

Response

Field Type Description
task_id integer task_id
Status: 200
Status: 422 (Validation Error)
Status: 403 (Permission Denied)
{
    "task_id": 12001
}