---
updatedAt: 2026-09-11T20:23:16.000Z
agentTools:
  projectIndex: https://docs.staxpayments.com/llms.txt
---

# Get all Payment Methods for a Customer

Retrieves a non-paginated data array of all non-deleted payment methods associated with a customer.

Retrieve a list of all non-deleted payment methods associated with a specific customer. This endpoint is essential for displaying saved payment options and managing customer payment methods effectively.

<Tabs>
  <Tab title="Overview">
    <Cards columns="3">
      <Card title="Fetch Payment Methods" icon="fa-credit-card">
        Retrieve all payment methods for a specific customer with detailed information.
      </Card>
      <Card title="Secure Data Handling" icon="fa-shield-alt">
        Access payment method details without exposing sensitive information.
      </Card>
      <Card title="Account Management" icon="fa-user-cog">
        Perfect for customer account management and payment option displays.
      </Card>
    </Cards>
  </Tab>
  
  <Tab title="Implementation">
    <Accordion title="Usage Guidelines" icon="fa-list-check">
      **Customer Validation:** Ensure the customer_id provided corresponds to an existing customer.

      **Ordering:** Payment methods are ordered by created_at in descending order.

      **Non-Paginated Response:** This endpoint returns all payment methods without pagination.
    </Accordion>

    <Accordion title="Important Considerations" icon="fa-exclamation-triangle">
      **Data Privacy:** Ensure compliance with privacy laws when accessing customer payment methods.

      **Error Handling:** Implement error handling for scenarios where the customer does not exist or has no payment methods.

      **Security:** Do not expose sensitive payment method details to unauthorized parties.
    </Accordion>
  </Tab>
  
  <Tab title="Response Reference">
    ## Response Structure

    | Code | Response              | Reason                                                                   |
    | :--- | :-------------------- | :----------------------------------------------------------------------- |
    | 200  | Success               | Returns an array of payment method objects associated with the customer. |
    | 400  | Bad Request           | Invalid `customer_id` format.                                            |
    | 401  | Unauthorized          | Authentication failed.                                                   |
    | 404  | Not Found             | The customer does not exist.                                             |
    | 500  | Internal Server Error | An unexpected error occurred on the server.                              |
  </Tab>
</Tabs>

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "stax-api",
    "version": "0.1"
  },
  "servers": [
    {
      "url": "https://apiprod.fattlabs.com/"
    }
  ],
  "components": {
    "securitySchemes": {
      "ApiKeyAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "API key for merchant-level operations. Provides access to merchant-specific endpoints including transactions, payments, customer management, and merchant account settings. This key is scoped to a single merchant account and cannot access partner-level functionality."
      }
    }
  },
  "security": [
    {
      "ApiKeyAuth": []
    }
  ],
  "paths": {
    "/customer/{customerId}/payment-method": {
      "get": {
        "summary": "Get all Payment Methods for a Customer",
        "description": "Retrieves a non-paginated data array of all non-deleted payment methods associated with a customer.",
        "operationId": "get-all-payment-methods-for-a-customer",
        "parameters": [
          {
            "name": "customerId",
            "in": "path",
            "schema": {
              "type": "string"
            },
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "[\n  {\n    \"id\": \"7e3a83ea-6770-41f7-9b28-7ea1a3ae33e7\",\n    \"customer_id\": \"35e4cfa9-d87e-45fc-84da-a6bdce2c3330\",\n    \"merchant_id\": \"85c58c65-4da7-4f99-acb0-afa885874572\",\n    \"user_id\": \"hosted-payments\",\n    \"nickname\": \"VISA: Bob Smithers (ending in: 1111)\",\n    \"has_cvv\": 0,\n    \"is_default\": 0,\n    \"method\": \"card\",\n    \"person_name\": \"Bob Smithers\",\n    \"card_type\": \"visa\",\n    \"card_last_four\": \"1111\",\n    \"card_exp\": \"032022\",\n    \"bank_name\": null,\n    \"bank_type\": null,\n    \"bank_holder_type\": null,\n    \"address_1\": null,\n    \"address_2\": null,\n    \"address_city\": null,\n    \"address_state\": null,\n    \"address_zip\": \"999999\",\n    \"address_country\": null,\n    \"purged_at\": null,\n    \"deleted_at\": null,\n    \"created_at\": \"2018-08-03 17:59:10\",\n    \"updated_at\": \"2018-08-03 17:59:10\",\n    \"card_exp_datetime\": \"2022-03-31 23:59:59\",\n    \"is_usable_in_vt\": true,\n    \"is_tokenized\": true,\n    \"customer\": {\n      \"id\": \"35e4cfa9-d87e-45fc-84da-a6bdce2c3330\",\n      \"firstname\": \"John\",\n      \"lastname\": \"Smith\",\n      \"company\": \"ABC INC\",\n      \"email\": \"webpaymentstest@test.com\",\n      \"cc_emails\": [],\n      \"cc_sms\": null,\n      \"phone\": \"1234567898\",\n      \"address_1\": \"123 Rite Way\",\n      \"address_2\": \"Unit 12\",\n      \"address_city\": \"Orlando\",\n      \"address_state\": \"FL\",\n      \"address_zip\": \"32801\",\n      \"address_country\": \"USA\",\n      \"notes\": null,\n      \"reference\": \"\",\n      \"options\": null,\n      \"created_at\": \"2018-07-27 19:08:48\",\n      \"updated_at\": \"2018-07-27 19:08:48\",\n      \"deleted_at\": null,\n      \"allow_invoice_credit_card_payments\": true,\n      \"gravatar\": \"//www.gravatar.com/avatar/18dd69e3959903c248ac613b51bc7f8e\"\n    }\n  },\n  {\n    \"id\": \"403e043d-2971-4062-adc7-7e64f7882786\",\n    \"customer_id\": \"35e4cfa9-d87e-45fc-84da-a6bdce2c3330\",\n    \"merchant_id\": \"85c58c65-4da7-4f99-acb0-afa885874572\",\n    \"user_id\": \"a01a5f74-cbdb-4704-9e9b-56fd5a8ee7b8\",\n    \"nickname\": \"personal savings, BANK INC (ending in: 3210)\",\n    \"has_cvv\": 0,\n    \"is_default\": 1,\n    \"method\": \"bank\",\n    \"person_name\": \"Bob Smith\",\n    \"card_type\": null,\n    \"card_last_four\": \"3210\",\n    \"card_exp\": null,\n    \"bank_name\": \"Bank INC\",\n    \"bank_type\": \"savings\",\n    \"bank_holder_type\": \"personal\",\n    \"address_1\": null,\n    \"address_2\": null,\n    \"address_city\": null,\n    \"address_state\": null,\n    \"address_zip\": null,\n    \"address_country\": null,\n    \"purged_at\": null,\n    \"deleted_at\": null,\n    \"created_at\": \"2018-08-02 21:06:04\",\n    \"updated_at\": \"2018-08-02 21:06:04\",\n    \"card_exp_datetime\": [],\n    \"is_usable_in_vt\": true,\n    \"is_tokenized\": true,\n    \"customer\": {\n      \"id\": \"35e4cfa9-d87e-45fc-84da-a6bdce2c3330\",\n      \"firstname\": \"John\",\n      \"lastname\": \"Smith\",\n      \"company\": \"ABC INC\",\n      \"email\": \"webpaymentstest@test.com\",\n      \"cc_emails\": [],\n      \"cc_sms\": null,\n      \"phone\": \"1234567898\",\n      \"address_1\": \"123 Rite Way\",\n      \"address_2\": \"Unit 12\",\n      \"address_city\": \"Orlando\",\n      \"address_state\": \"FL\",\n      \"address_zip\": \"32801\",\n      \"address_country\": \"USA\",\n      \"notes\": null,\n      \"reference\": \"\",\n      \"options\": null,\n      \"created_at\": \"2018-07-27 19:08:48\",\n      \"updated_at\": \"2018-07-27 19:08:48\",\n      \"deleted_at\": null,\n      \"allow_invoice_credit_card_payments\": true,\n      \"gravatar\": \"//www.gravatar.com/avatar/18dd69e3959903c248ac613b51bc7f8e\"\n    }\n  }\n]"
                  }
                },
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "example": "7e3a83ea-6770-41f7-9b28-7ea1a3ae33e7"
                      },
                      "customer_id": {
                        "type": "string",
                        "example": "35e4cfa9-d87e-45fc-84da-a6bdce2c3330"
                      },
                      "merchant_id": {
                        "type": "string",
                        "example": "85c58c65-4da7-4f99-acb0-afa885874572"
                      },
                      "user_id": {
                        "type": "string",
                        "example": "hosted-payments"
                      },
                      "nickname": {
                        "type": "string",
                        "example": "VISA: Bob Smithers (ending in: 1111)"
                      },
                      "has_cvv": {
                        "type": "integer",
                        "example": 0,
                        "default": 0
                      },
                      "is_default": {
                        "type": "integer",
                        "example": 0,
                        "default": 0
                      },
                      "method": {
                        "type": "string",
                        "example": "card"
                      },
                      "person_name": {
                        "type": "string",
                        "example": "Bob Smithers"
                      },
                      "card_type": {
                        "type": "string",
                        "example": "visa"
                      },
                      "card_last_four": {
                        "type": "string",
                        "example": "1111"
                      },
                      "card_exp": {
                        "type": "string",
                        "example": "032022"
                      },
                      "bank_name": {},
                      "bank_type": {},
                      "bank_holder_type": {},
                      "address_1": {},
                      "address_2": {},
                      "address_city": {},
                      "address_state": {},
                      "address_zip": {
                        "type": "string",
                        "example": "999999"
                      },
                      "address_country": {},
                      "purged_at": {},
                      "deleted_at": {},
                      "created_at": {
                        "type": "string",
                        "example": "2018-08-03 17:59:10"
                      },
                      "updated_at": {
                        "type": "string",
                        "example": "2018-08-03 17:59:10"
                      },
                      "card_exp_datetime": {
                        "type": "string",
                        "example": "2022-03-31 23:59:59"
                      },
                      "is_usable_in_vt": {
                        "type": "boolean",
                        "example": true,
                        "default": true
                      },
                      "is_tokenized": {
                        "type": "boolean",
                        "example": true,
                        "default": true
                      },
                      "customer": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "example": "35e4cfa9-d87e-45fc-84da-a6bdce2c3330"
                          },
                          "firstname": {
                            "type": "string",
                            "example": "John"
                          },
                          "lastname": {
                            "type": "string",
                            "example": "Smith"
                          },
                          "company": {
                            "type": "string",
                            "example": "ABC INC"
                          },
                          "email": {
                            "type": "string",
                            "example": "webpaymentstest@test.com"
                          },
                          "cc_emails": {
                            "type": "array"
                          },
                          "cc_sms": {},
                          "phone": {
                            "type": "string",
                            "example": "1234567898"
                          },
                          "address_1": {
                            "type": "string",
                            "example": "123 Rite Way"
                          },
                          "address_2": {
                            "type": "string",
                            "example": "Unit 12"
                          },
                          "address_city": {
                            "type": "string",
                            "example": "Orlando"
                          },
                          "address_state": {
                            "type": "string",
                            "example": "FL"
                          },
                          "address_zip": {
                            "type": "string",
                            "example": "32801"
                          },
                          "address_country": {
                            "type": "string",
                            "example": "USA"
                          },
                          "notes": {},
                          "reference": {
                            "type": "string",
                            "example": ""
                          },
                          "options": {},
                          "created_at": {
                            "type": "string",
                            "example": "2018-07-27 19:08:48"
                          },
                          "updated_at": {
                            "type": "string",
                            "example": "2018-07-27 19:08:48"
                          },
                          "deleted_at": {},
                          "allow_invoice_credit_card_payments": {
                            "type": "boolean",
                            "example": true,
                            "default": true
                          },
                          "gravatar": {
                            "type": "string",
                            "example": "//www.gravatar.com/avatar/18dd69e3959903c248ac613b51bc7f8e"
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "422": {
            "description": "422",
            "content": {
              "application/json": {
                "examples": {
                  "Invalid ID": {
                    "value": "{\n  \"id\": [\n    \"The selected id is invalid.\"\n  ]\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "example": "The selected id is invalid."
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```