---
title: "Pages a product's customers."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.sherpo.io/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Sherpo merchant API › customer

`GET /v1/stores/{store}/products/{product}/customers`

## Authentication

- `bearer`, http, header `Authorization`, scopes: `customer:read`

## Path parameters

- `store` (`listProductCustomers.path.store`; string, required) — The store's id.
- `product` (`listProductCustomers.path.product`; string, required) — An id, or `slug:<slug>`.
  - minLength 1

## Query parameters

- `filter` (`listProductCustomers.query.filter`; object, optional) — `filter[<field>]=<value>` is an equality, `filter[<field>][<op>]=<value>` names the operator; `in` repeats the parameter.
- `sort` (`listProductCustomers.query.sort`; string, optional) — Sorted by name, rows without a value come last either way.
  - one of `"started"`, `"date"`, `"name"`
- `direction` (`listProductCustomers.query.direction`; string, optional)
  - one of `"asc"`, `"desc"`
- `limit` (`listProductCustomers.query.limit`; integer, optional)
  - min 1; max 1000
- `cursor` (`listProductCustomers.query.cursor`; string, optional)
  - maxLength 8192
- `count` (`listProductCustomers.query.count`; boolean, optional)
- `search` (`listProductCustomers.query.search`; string, optional)
  - minLength 1; maxLength 200
- `facets` (`listProductCustomers.query.facets`; array<string>, optional)

## Code samples

### cURL

```bash
curl --request GET \
  --url 'https://api.sherpo.io/merchant/v1/stores/<store>/products/<product>/customers' \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://api.sherpo.io/merchant/v1/stores/<store>/products/<product>/customers';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.sherpo.io/merchant/v1/stores/<store>/products/<product>/customers"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

Pages a product's customers.

#### Example

```json
{
  "items": [
    {
      "started_at": "string",
      "ends_at": "string",
      "progress": {
        "completed": 0,
        "total": 0
      },
      "answers": [
        {
          "question_id": "string",
          "value": true
        }
      ],
      "actions": {
        "cancel": {
          "period_end": true,
          "now": true
        },
        "resume": true
      },
      "next_event": {
        "kind": "string",
        "at": "string"
      },
      "id": "string",
      "kind": "string",
      "source_kind": "string",
      "customer_id": "string",
      "customer": {
        "id": "string",
        "name": "string",
        "email": "string",
        "phone": "string",
        "erased": true
      },
      "price_id": "string",
      "order_id": "string",
      "cancel_reason": "string",
      "status": "string"
    }
  ],
  "cursor": "string",
  "total": 0,
  "facets": {
    "property1": {
      "property1": 0,
      "property2": 0
    },
    "property2": {
      "property1": 0,
      "property2": 0
    }
  }
}
```

- `items` (`listProductCustomers.response.200.items`; array<object>, required)
  - `started_at` (`listProductCustomers.response.200.items.started_at`; string, required)
  - `ends_at` (`listProductCustomers.response.200.items.ends_at`; any of, required)
    - any of: `string`, `null`
  - `progress` (`listProductCustomers.response.200.items.progress`; object, required)
    - `completed` (`listProductCustomers.response.200.items.progress.completed`; number, required)
    - `total` (`listProductCustomers.response.200.items.progress.total`; number, required)
  - `answers` (`listProductCustomers.response.200.items.answers`; array<object>, required) — Their answers to the product's registration questions, in the questions' order.
    - `question_id` (`listProductCustomers.response.200.items.answers.question_id`; string, required)
    - `value` (`listProductCustomers.response.200.items.answers.value`; any of, required)
      - any of: `boolean`, `string`, `array<string>`
  - `actions` (`listProductCustomers.response.200.items.actions`; any of, required) — A subscription's moves, as `getSubscription` answers them; null for a grant.
    - any of: `object`, `null`
  - `next_event` (`listProductCustomers.response.200.items.next_event`; any of, required) — A subscription's next event, as `getSubscription` answers it; null for a grant.
    - any of: `object`, `null`
  - `id` (`listProductCustomers.response.200.items.id`; string, required)
  - `kind` (`listProductCustomers.response.200.items.kind`; string, required)
  - `source_kind` (`listProductCustomers.response.200.items.source_kind`; any of, required)
    - any of: `string`, `null`
  - `customer_id` (`listProductCustomers.response.200.items.customer_id`; string, required)
  - `customer` (`listProductCustomers.response.200.items.customer`; any of, required)
    - any of: `object`, `null`
  - `price_id` (`listProductCustomers.response.200.items.price_id`; any of, required)
    - any of: `string`, `null`
  - `order_id` (`listProductCustomers.response.200.items.order_id`; any of, required)
    - any of: `string`, `null`
  - `cancel_reason` (`listProductCustomers.response.200.items.cancel_reason`; any of, required)
    - any of: `string`, `null`
  - `status` (`listProductCustomers.response.200.items.status`; string, required)
- `cursor` (`listProductCustomers.response.200.cursor`; any of, required)
  - any of: `string`, `null`
- `total` (`listProductCustomers.response.200.total`; number, optional)
- `facets` (`listProductCustomers.response.200.facets`; map<map<number>>, optional)

### default

A problem; see https://api.sherpo.io/merchant/docs/errors.

#### Example

```json
{
  "type": "http://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "string",
  "context": {},
  "reached_core": true,
  "core_answer": "string"
}
```

- `type` (`listProductCustomers.response.default.type`; string, required)
  - format `uri`
- `title` (`listProductCustomers.response.default.title`; string, required)
- `status` (`listProductCustomers.response.default.status`; integer, required)
- `detail` (`listProductCustomers.response.default.detail`; string, required)
- `code` (`listProductCustomers.response.default.code`; string, optional)
- `context` (`listProductCustomers.response.default.context`; object, optional)
- `reached_core` (`listProductCustomers.response.default.reached_core`; boolean, optional)
- `core_answer` (`listProductCustomers.response.default.core_answer`; string, optional)


Source: https://docs.sherpo.io/merchant-api/reference/list-product-customers/index.md
