Customers

Payment Methods

A PaymentMethod represents a customer's payment method, such as a card or direct debit.

The PaymentMethod object

Attributes

  • iduuidrequired

    The ID of the payment method

  • payment_method_idstringrequired

    The processor's ID for the payment method

  • namestringrequired

    The name of the payment method

  • typestringrequired

    The type of payment method

    Possible values:carddirect_debit
  • statusstringrequired

    When the payment method is a Direct Debit mandate, the status shows whether the mandate is usable or not

  • cardholder_namestringrequired

    The cardholder name, or for direct debits, the name of the account holder

  • card_brandstringrequired

    The brand of the card

  • card_countrystringrequired

    The country where the card was issued

  • card_fundingstringrequired

    The type of funding for this card

  • card_expirystringrequired

    The expiry month and year for this card

  • last_4stringrequired

    The last 4 digits of the long card number, or for direct debits, the last 4 digits of the account number

  • processorstringrequired

    The ID of processor where this payment method is stored

  • created_atdate-timerequired

    The datetime which the payment method was created

  • updated_atdate-timerequired

    The datetime which the payment method was last updated

  • revoked_atdate-timeoptional

    The datetime which the payment method was revoked

{
  "id": "00000000-0000-0000-0000-000000000000",
  "payment_method_id": "pm_3K6a0RGysTOePye00nkob5Pi",
  "name": "My debit card",
  "type": "card",
  "status": "revoked",
  "cardholder_name": "Jane Doe",
  "card_brand": "amex",
  "card_country": "gb",
  "card_funding": "credit",
  "card_expiry": "08/22",
  "last_4": "1234",
  "processor": "stripe",
  "created_at": "2025-01-01T00:00:00+00:00",
  "updated_at": "2025-01-01T00:00:00+00:00",
  "revoked_at": "2025-01-01T00:00:00+00:00"
}
get/customers/payment-methods

List Payment Methods

listPaymentMethods

This endpoint retrieves a list of all payment methods.

Query parameters

  • customer_iduuidoptional

    Filter payment methods that belong to the given customer ID

  • typestringoptional

    Filter payment methods by type (e.g., card, direct_debit)

    Possible values:carddirect_debit
  • processorstringoptional

    Filter payment methods by the processor that issued them. Most integrators don't need this filter — payment-method handling is abstracted at the order-payment layer.

    Possible values:stripeadyenmanual
  • statusstringoptional

    Filter payment methods by status (e.g., active, revoked)

    Possible values:pendingactiverevoked
  • Filter payment methods that are used for memberships

  • for_barcodebooleanoptional

    Filter payment methods that are associated with barcodes (wearable devices)

  • pageintegeroptional

    The page to retrieve results from

  • per_pageintegeroptional

    The number of results to return per page

Responses

  • 200

    The PaymentMethods were successfully retrieved

  • 401

    The user is unauthenticated

get/customers/payment-methods/{paymentMethodId}

Get a payment method

getPaymentMethod

Returns the stored details for the given payment method — processor, type, masked last-4, status, and timestamps. The bearer token must have CUSTOMERS_VIEW for the brand that owns the underlying customer.

Path parameters

Responses

  • 200

    The PaymentMethod was successfully retrieved.

  • 401

    The user is unauthenticated

  • 404

    The resource couldn't be found

delete/customers/payment-methods/{paymentMethodId}

Delete a payment method

deletePaymentMethod

Deletes a payment method belonging to a customer. Once deleted, the payment method can no longer be used for new charges.

Path parameters

Responses

  • 204

    The payment method was successfully deleted.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found