v1

latestOpenAPI 3.0.02026-07-24103118224.7 KB
Customer

List all active payment methods for a customer

Returns all active payment methods saved for the given customer. Results are sorted with the default payment method first, then by most recent. Each item includes card details (brand, last4, expiration), the currency, whether it is the isDefault method, and the list of paymentIds of payments that used this method. Optionally filter by currency query parameter (EUR or USD).

get/api/customer/{customerId}/payment-methods

Path parameters

customerIdstring required
Example:cus_abc123

Unique identifier of the customer (e.g. cus_abc123)

Query parameters

currency'EUR' | 'GBP' | 'USD'

Filter payment methods by currency (EUR or USD).

Response

List of active payment methods for the customer, sorted by default first then most recent.

idstring required

Unique ID of the setup request.

statusstring required

Current status of the setup request (pending, completed, failed, requires_3ds).

currencystring required

Currency of the setup request (EUR or USD).

createdAtstring date-time required

When the request was created.

updatedAtstring date-time required

When the request was last updated.

completedAtstring date-time nullable required

When the request completed (success or failure), or null.

errorCodestring nullable required

Error code if the request failed, or null.

errorMessagestring nullable required

Error message if the request failed, or null.

paymentMethodIdstring nullable required

ID of the payment method created by this request, or null if not yet completed.

Example response

[
  {
    "id": "setup_pm_req_abc123",
    "status": "completed",
    "currency": "EUR",
    "paymentMethodId": "cpm_xyz789"
  }
]