Confirm Card Setup
POST/api/customers/:customer/payment-methods/confirm-setup
Saves the card the browser just set up (see Create Card Setup Token). The card's brand, last four and expiry are read back from the processor, never taken from the request. Requires explicit, affirmative customer consent, recorded with the requesting user and their IP address. Saving the same card twice returns the existing card.
customers:writeGrant this scope to your token under Settings → Developer → Personal Access Tokens.
- Stripe: send the confirmed
setup_intent_id. - Authorize.net: send
processor: authorize_netand the hosted form'sopaque_data. The card is saved to the customer's Authorize.net customer profile (created on first use assku-{customer id}) and verified with Authorize.net now (a $0/$1 validation in live mode; test mode in sandbox), so a bad card is refused here, not at the first charge.
Authentication: Requires Bearer token (PAT).
Permission: customers.update.
Request body fields:
processor(string, nullable:stripe|authorize_net, defaultstripe).setup_intent_id(string, required unless processor isauthorize_net, starts withseti_, max 255) — the confirmed Stripe SetupIntent.opaque_data.data_descriptor(string, required forauthorize_net, max 100) — e.g.COMMON.ACCEPT.INAPP.PAYMENT.opaque_data.data_value(string, required forauthorize_net, max 8192) — the single-use card nonce (expires 15 minutes after the card was entered).consent(required, must be accepted —true,1,"yes", or"on") — the customer authorized saving this card.is_default(boolean, nullable) — make this the customer's default card. Defaults to false.integration_instance_id(integer, nullable) — the account the setup was created on, when there is more than one.cardholder_name(string, nullable, max 255) — used only when the processor holds no name for the card.
Card fields: id, processor (square, stripe or authorize_net), brand, last_four, exp_month, exp_year, cardholder_name, is_default, is_expired, label, consent_given_at, consent_ip, consent_user_name, added_by_name and created_at.
Returns 201 with the card. Returns 422 when consent is missing, opaque_data is missing ("Enter the card in the Authorize.net form first.") or expired ("The card form timed out — enter the card again."), the card was declined during verification, Stripe hasn't confirmed the setup, or the processor can't be reached / rejected SKU.io's credentials.
Request
Responses
- 201
- 401
- 403
- 404
- 422
- 429
Created
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not found — no record with the given identifier (or the route does not exist). Verify the ID before retrying.
Unprocessable Entity
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.