Skip to main content
POST
/
cards
Create a card
curl --request POST \
  --url https://api-dev.paygen.online/cards \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "debitAccountId": "account_id",
  "cardHolderId": "card_holder_id",
  "type": "virtual",
  "brand": "Visa",
  "status": "active"
}
'
{
  "statusCode": 123,
  "message": "<string>",
  "data": {
    "_id": "<string>",
    "debitAccountId": "<string>",
    "cardHolderId": "<string>",
    "type": "virtual",
    "brand": "Mastercard",
    "currency": "NGN",
    "metadata": {},
    "status": "<string>",
    "spendingControls": {
      "channels": {
        "atm": true,
        "pos": true,
        "web": true,
        "mobile": true
      },
      "allowedCategories": [
        "<string>"
      ],
      "blockedCategories": [
        "<string>"
      ],
      "spendingLimits": [
        {
          "amount": 123,
          "interval": "<string>",
          "categories": [
            "<string>"
          ]
        }
      ]
    },
    "enable2FA": true,
    "disposable": true
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
debitAccountId
string
required
cardHolderId
string
required
type
enum<string>
required
Available options:
virtual,
physical
brand
enum<string>
required
Available options:
Mastercard,
Visa
status
enum<string>
required
Available options:
active,
inactive
currency
enum<string>
default:USD
Available options:
NGN,
USD
metadata
object
spendingControls
object
enable2FA
boolean
default:true
amount
number
Required range: x >= 1
disposable
boolean
default:false

Response

201 - application/json

Card created successfully.

statusCode
integer
required
message
string
required
data
object