# Retrieving customer details

You can use the [`GET /v1/customers/{customerId}`](https://docs.digitalriver.com/commerce-api-references/admin-apis/customer-management/retrieve-a-customer-synchronous-api#v1-customers-customerid) resource to get a customer's details. You must provide either a `customerId` or `ERID` in the path.&#x20;

{% hint style="info" %}
The value of the `customerId` in the Admin API is exactly the same as the `shopperId` in the Shopper API.
{% endhint %}

{% tabs %}
{% tab title="cURL" %}
The following example gets the details for a specific customer with a `customerId`.

```html
curl --location --request GET 'https://api.digitalriver.com/v1/customers/{customerId}' \
--header 'Authorization: Basic <API_key>' \
...
```

The following example gets the details for a specific customer with an `ERID` and requires the `x-erid-as-cid=true` header.The following example gets the details for a specific customer with an `ERID` and requires the `x-erid-as-cid=true` header.

```html
curl --location --request GET 'https://api.digitalriver.com/v1/customers/{ERID}' \
--header 'Authorization: Basic <API_key>' \
--header 'header x-erid-as-cid=true' \
...
```

{% endtab %}

{% tab title="customerId and ERID 200 OK response" %}

```
{
  "shopper": {
    "id": "1067669580082",
    "loginType": "anonymous",
    "username": "jswanson@digitalriver.com",
    "externalReferenceId": "ABC123456789ABC",
    "firstName": "Automation",
    "lastName": "Tester",
    "emailAddress": "jswanson@digitalriver.com",
    "requestToBeForgotten": {
      "offset": {
        "totalSeconds": 0,
        "id": "Z",
        "rules": {
          "fixedOffset": true,
          "transitions": [],
          "transitionRules": []
        }
      },
      "nano": 0,
      "year": 2023,
      "monthValue": 2,
      "dayOfMonth": 27,
      "hour": 20,
      "minute": 36,
      "second": 2,
      "month": "FEBRUARY",
      "dayOfWeek": "MONDAY",
      "dayOfYear": 58
    }
  }
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.digitalriver.com/commerce-api/admin-apis/customer-management/retrieving-customer-details.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
