Skip to main content
POST

Authorizations

X-Auth-Client
string
header
required

Your workspace client id.

All calls must include four headers:

  • X-Auth-Client — your workspace client id
  • X-Auth-Timestamp — Unix seconds
  • X-Auth-Nonce — 16-byte random hex
  • X-Auth-Signature — hex(HMAC-SHA256( {client_id}:{timestamp}:{nonce}:{raw_body}, client_secret))

The playground computes the timestamp, nonce and signature for you.

X-Playground-Client-Secret
string
header
required

Your sandbox client secret. The playground uses it to sign the request in your browser and removes it before the request is sent. Never send your client secret as a header in your own integration.

Body

application/json
card_type
enum<string>
required

Form of the card.

Available options:
virtual,
physical
amount
integer<int64>

Initial funding, micro-units (1 USD = 1,000,000).

Required range: x >= 0
card_brand
enum<string>

Card network.

Available options:
visa,
mastercard
card_limits
object

Spending limits in micro-units (1 USD = 1,000,000). Card program rules (for example a single limit) are enforced by the service.

card_program
enum<string>

Defaults to the company's program when omitted.

Available options:
prepaid,
collateral,
collateral_business
contactless_payment
boolean

Whether the card allows contactless payments.

currency
string

Card currency.

customer
object

Inline customer for card creation.

customer_id
string<uuid>

Existing customer. Provide this or customer.

expiry
string

Requested expiry month, YYYY-MM. Refused on collateral programs.

Pattern: ^[0-9]{4}-(0[1-9]|1[0-2])$
idempotency_key
string

A UUID that makes a retry safe. One is generated if you leave it out.

name
string

Cardholder name. Required unless customer_id is given.

Maximum string length: 100
reference
string

Your unique reference for this card.

user_metadata
string

JSON object as a string, at most 5KB.

Maximum string length: 5120
webhook_url
string<uri>

HTTPS URL that receives webhooks for this card.

Response

Created

Successful responses are wrapped in this envelope, and so are errors a handler answers itself (request body and field validation, some not-found and conflict cases, ORG_NOT_ACTIVE): success is false and error carries a code and message. Errors raised by authentication and by the services behind a handler are a Problem instead.

success
boolean
required

true on success

timestamp
string<date-time>
required

When the response was written.

data
object

The payload; its shape is given per operation. Omitted when there is none.

error
object
message
string

Human-readable summary; omitted when empty.

metadata
object

List metadata. Page lists set page, per_page, total and total_pages; offset and cursor lists set limit, offset, has_more and next_cursor. Zero and empty fields are omitted, and metadata is absent when nothing is set.

request_id
string

Set on error envelopes: the request's correlation id (req_ followed by a UUID), the same value as the X-Correlation-ID response header. Quote it to support.