POST
Attach a payment method

Authorizations

Authorization
string
header
required

Developer session token from POST /v1/auth/login or POST /v1/auth/register. Valid 7 days.

Authenticates the developer control plane. It also reaches the server and build endpoints, which a dashboard has to drive and which no session can otherwise call: an API key's value is returned once, at mint, so nothing can read back a key for an existing project. On those endpoints a session names its project with project_id, or is resolved from the resource it addresses, and is always checked against the account that owns it.

It reaches no player-facing game endpoint.

Body

application/json

Attaches a card to the account. Send a Stripe payment method id obtained in the browser with Stripe.js. Raw card numbers are never accepted by this API and must never be sent to it.

payment_method_id
string
required

Stripe payment method id, e.g. pm_1234567890.

Example:

"pm_1234567890"

Response

The attached card, as reported by Stripe.

The card on file, as reported by Stripe. Simpl never stores or sees a card number.

brand
string
required
Example:

"visa"

last_four
string
required
Example:

"4242"

exp_month
integer
required
Required range: 1 <= x <= 12
Example:

12

exp_year
integer
required
Example:

2030