---
page_title: List Customer Accounts
product: API Reference
page_source: https://juspay.io/in/docs/api-reference/docs/express-checkout/list-customer-accounts
openapi: https://juspay.io/in/docs/api/swagger?document=https%3A%2F%2Fjuspay.io%2Fin%2Fdocs%2Fapi-reference%2Fdocs%2Fexpress-checkout%2Flist-customer-accounts
llms_txt: https://juspay.io/in/docs/llms.txt
product_llms_txt: https://juspay.io/in/docs/api-reference/llms.txt
---

## API Version: default


# List Customer accounts



**List Bank Accounts** API which lists all the customer account IDs linked for a given customer ID. This API retrieves all customer’s bank account related information, including account details, bank account id creation date and the last validated date of the customer account details.## Endpoints:
- Sandbox: https://sandbox.juspay.in/customers/{customer_id}/customer-accounts/list

- Production: https://api.juspay.in/customers/{customer_id}/customer-accounts/list

## Request Type: 
GET

## Authorization:

#### Basic Auth:
Consists of two parts.

* Username: API Key obtained from Juspay dashboard
* Password: Empty string

Example:- Basic MUQ2QUxxxxxxxxxxxxU5QTIxQzNFNTQwNkFDMEZCOg==
- Tags: Base64 Encoded Username:Password, Mandatory
## Headers:

#### Content-Type:
application/x-www-form-urlencoded
- Tags: String

#### x-routing-id:
We recommend passing the customer_id as the x-routing-id. If the customer is checking out as a guest, you can pass an alternative ID that helps track the payment session lifecycle. For example, this could be an Order ID or Cart ID.

> **Warning**
> This ID is associated with the customer. It plays a key role in ensuring consistency and maintaining connections across different systems. If you fail to pass the same x-routing-id for the same customer in all related API calls, it could lead to issues with API functionality. Therefore, it’s crucial that you use the same x-routing-id for all requests tied to the same customer.


- Value: customer_1122
- Tags: String, Required
## Sample Code Snippets:
### Sample Request:

#### Request Code Snippet:

```request
curl -X GET \ 
https://api.juspay.in/customers/cst_zqqmw0v4exbhvv2l/customer-accounts/list' \
--header 'Authorization: Basic QTA0QT*******ODg1Og==' \
--header 'x-routing-id: customer_1122'\
--header 'Content-Type: application/x-www-form-urlencoded' 
```

### Sample Response:

#### 200 - Success:
```json
{
    "list": [
        {
            "last_validated": "2023-06-06T13:29:53Z",
            "customer_id": "cst_zqqmw0v4exbhvv2l",
            "account_details": {
                "vpa": "4225246777@yesg"
            },
            "currency": "INR",
            "object": "customer_account",
            "validation_status": "ACTIVE",
            "customer_account_id": "banh_7BQaxZdn3UnC8CoF",
            "validation_amount": 1,
            "date_created": "2023-06-06T13:29:49Z"
        },
        {
            "last_validated": "2023-06-06T13:28:59Z",
            "customer_id": "cst_zqqmw0v4exbhvv2l",
            "account_details": {
                "vpa": "8668757911@ffsk"
            },
            "currency": "INR",
            "object": "customer_account",
            "validation_status": "PENDING",
            "customer_account_id": "banh_uninwyie1d85C5cQ",
            "validation_amount": 1,
            "date_created": "2023-06-06T13:28:55Z"
        }
    ],
    "offset": 0,
    "count": 2,
    "total": 2,
    "object": "list"
}
```

#### 401 - Unauthorized:
```plaintext
{
    "status": "error",
    "error_code": "access_denied",
    "error_info": {
        "user_message": "Unauthorized.",
        "request_id": "b2e0fd33-7655-4778-83a8-5179ed21b0b7",
        "href": "NA",
        "developer_message": "Invalid API Key. Please pass a valid and active api key.",
        "code": "UNAUTHORIZED",
        "category": "USER_ERROR"
    }
}
```

#### 404 - Not Found:
```plaintext
{
    "error_message": "Cannot find what you are looking for",
    "status": "invalid_request_error",
    "error_code": "object_not_found",
    "error_info": {
        "user_message": "Cannot process your request as customer account not found.",
        "request_id": "bfd8b9e6-45a8-4b41-a554-de6e435ffc36",
        "href": "NA",
        "developer_message": "Customer account not found.",
        "code": "RESOURCE_NOT_FOUND",
        "category": "USER_ERROR"
    }
}
```

## Path Parameters:

#### customer_id:
Customer Id
- Value: Example:- cst_weoridsfdkl
- Tags: String, Mandatory
## API Responses:
### 200:

#### list:
- Description: List the linked customer account ID details
- Value:
  - **Last_validated**:
    - Description: Recent modified date of the customer account ID
    - Value: 2023-06-06T13:28:59Z
    - Tags: String
  - **Customer_id**:
    - Description: Customer ID
    - Value: cst_zqqmw0v4exbhvv2l
    - Tags: String
  - **Account_details**:
    - Description: Account details with which customer account ID created
    - Value:
      - **Vpa**:
        - Description: VPA details
        - Value: 8668757911@ffsk
        - Tags: String
      - **Bank_account**:
        - Description: Bank account details
        - Value:
          - **Account**:
            - Description: Bank account number
            - Value: 026291800001191
            - Tags: String
          - **Name**:
            - Description: Beneficiary name
            - Value: test
            - Tags: String
          - **Ifsc**:
            - Description: IFSC Code
            - Value: AABF0008032
            - Tags: String
          - **Juspay_bank_code**:
            - Description: Bank code
            - Value: 12
            - Tags: String
          - **Bank_name**:
            - Description: Beneficiary account bank name
            - Value: SBI
            - Tags: String
        - Tags: String
    - Tags: Object
  - **Currency**:
    - Description: Currency of the Validation amount
    - Value: INR
    - Tags: String
  - **Validation_status**:
    - Description: Validation status of customer account ID**Possible values:** `CREATED` - Customer account has been created, validation has not yet been completed
      
      `ACTIVE` - validation is successful at gateway with provided customer bank details
      
      `PENDING` - Awaiting transaction status on the penny drop transaction
      
      `FAILURE` - Provided account validation is failure
    - Value: PENDING
    - Tags: String
  - **Customer_account_id**:
    - Description: ID created at Juspay’s end during Customer account creation
    - Value: banh_uninwyie1d85C5cQ
    - Tags: String
  - **Validation_amount**:
    - Description: Penny drop amount
    - Value: 1
    - Tags: String
  - **Date_created**:
    - Description: Creation date of the custmer account ID
    - Value: 2023-06-06T13:28:55Z
    - Tags: String
- Tags: Array

#### offset:
- Value: 0
- Tags: String

#### count:
- Description: Number of linked customer account ID for the provided customer
- Value: 2
- Tags: String

#### total:
- Description: Total number of linked customer account ID
- Value: 2
- Tags: String

#### object:
- Value: list
- Tags: String
### 400:

#### object:
- Description: {}
- Tags: JSON
### 401:

#### status:
- Description: Status of the get customer api response
- Value: Response: error
- Tags: String

#### error_code:
- Description: error code information
- Value: Sample response: access_denied
- Tags: String

#### error_info:
- Description: Detailed information of the error
- Value:
  - **User_message**:
    - Description: User error message
    - Value: Response: Unauthorized.
    - Tags: String
  - **Developer_message**:
    - Description: Provide accurate details on the error message
    - Value: Sample Response: Invalid API Key. Please pass a valid and active api key.
    - Tags: String
  - **Category**:
    - Description: Denotes the category of the error
    - Value: Sample Response: USER_ERROR
    - Tags: String
- Tags: JSON


---

## See Also

- [Create with Validate Customer Account](https://juspay.io/in/docs/api-reference/docs/express-checkout/create-with-validate-customer-account)
- [Get Customer Account](https://juspay.io/in/docs/api-reference/docs/express-checkout/get-customer-account)
