Skip to main content
POST
/
api
/
action
/
card
/
{userId}
Create a virtual card
curl --request POST \
  --url https://sandbox.soleaspay.com/api/action/card/{userId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'x-sp-auth-token: <x-sp-auth-token>' \
  --data '
{
  "balance": "10",
  "currency": "USD",
  "card_type": "VISA",
  "category": "PERSONAL",
  "grade": "BASIC"
}
'
{
  "card_id": "<string>",
  "card_number": "<string>",
  "expiry": "<string>",
  "cvv": "<string>"
}

Authorizations

Authorization
string
header
required

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

Headers

x-sp-auth-token
string
required

Path Parameters

userId
string
required

Body

application/json
balance
string
required
Example:

"10"

currency
string
required
Example:

"USD"

card_type
enum<string>
required
Available options:
VISA,
MASTERCARD
category
enum<string>
required
Available options:
PERSONAL,
BUSINESS
grade
enum<string>
required
Available options:
BASIC,
PREMIUM

Response

201 - application/json

Card created successfully

card_id
string
card_number
string
expiry
string
cvv
string