> For a complete page index of the Captain API documentation, fetch https://docs.captain.dev/llms.txt?excludeSpec=true

# List Filter Values

GET https://acme.captain.dev/v1/indexes/{index}/analytics/filters/{attribute}

List the values searches filtered one field by most often.

Reference: https://docs.captain.dev/reference/product-search/analytics/list-filter-values

## Authentication

- `Authorization` header (bearer token, required) — A search key, issued by Captain. Sent as Authorization: Bearer \<key>.

## Request

### Path parameters

- `index` (string, required) — index name
- `attribute` (string, required)

### Query parameters

- `limit` (integer, optional, default: 10) — list rows to return (the list only: counts and rates cover every row)
- `offset` (integer, optional, default: 0)
- `start_date` (string, optional) — first day, UTC, inclusive (YYYY-MM-DD). Default: 6 days before end_date (a 7-day window)
- `end_date` (string, optional) — last day, UTC, inclusive (YYYY-MM-DD). Default: today. At most 366 days from start_date
- `start_time` (string, optional) — an exact start instead of start_date: unix seconds, or ISO 8601 in UTC (2026-10-10T10:00:00Z). start_date and end_date in the reply are then the UTC days the window touches
- `end_time` (string, optional) — an exact end (exclusive): unix seconds or ISO 8601 with Z. Default: now; never later than now. Must be after start_time

## Response

### 200

report

- `start_date` (string, required)
- `end_date` (string, required)
- `values` (list of V1IndexesIndexAnalyticsFiltersAttributeGetResponsesContentApplicationJsonSchemaValuesItems, required)
- `partial` (boolean, optional) — true when the search log was too large to read whole within one request's budget: the numbers cover what was counted
- `partial_reason` (enum, optional) — row_budget: more searches than one request holds (500,000); time_budget: more than about 3.5 seconds of reading; counting (usage): days still being counted
  - Allowed values: `row_budget`, `time_budget`, `counting`
- `counted_through` (double, optional, nullable) — the time (unix seconds) of the last record counted, when partial

## Types

### V1IndexesIndexAnalyticsFiltersAttributeGetResponsesContentApplicationJsonSchemaValuesItems

- `attribute` (string, required)
- `operator` (string, required) — as written: = != \< \<= > >= BETWEEN IN NOT IN WITHIN EXISTS, with NOT prefixed under a NOT
- `value` (string, required, nullable) — the value as written ("10 AND 20" for BETWEEN, a unit kept: "5 kg"); null for EXISTS and WITHIN (no location is kept). Redacted like the query text on an access-controlled index
- `count` (integer, required) — searches that used it

## Examples

**Response**

```json
{
  "start_date": "2026-09-22",
  "end_date": "2026-09-28",
  "values": [
    {
      "attribute": "brand",
      "operator": "=",
      "value": "Merrell",
      "count": 402
    },
    {
      "attribute": "brand",
      "operator": "=",
      "value": "Salomon",
      "count": 311
    },
    {
      "attribute": "brand",
      "operator": "=",
      "value": "KEEN",
      "count": 188
    }
  ]
}
```

**SDK Code**

```python Python REST
import json
import requests

BASE_URL = "https://acme.captain.dev"
API_KEY = "your_search_key"
INDEX = "products"
ATTRIBUTE = "brand"

headers = {
    "Authorization": f"Bearer {API_KEY}",
}

response = requests.get(
    f"{BASE_URL}/v1/indexes/{INDEX}/analytics/filters/{ATTRIBUTE}",
    headers=headers,
    params={"start_date": "2026-09-22", "end_date": "2026-09-28", "limit": 3},
    timeout=30.0,
)

print(json.dumps(response.json(), indent=2))
```

```typescript TypeScript REST
const BASE_URL = "https://acme.captain.dev";
const API_KEY = "your_search_key";
const index = "products";
const attribute = "brand";

const params = new URLSearchParams({ start_date: "2026-09-22", end_date: "2026-09-28", limit: "3" });

const response = await fetch(`${BASE_URL}/v1/indexes/${index}/analytics/filters/${attribute}?${params}`, {
  method: "GET",
  headers: {
    Authorization: `Bearer ${API_KEY}`,
  },
});

const result = await response.json();
console.log(JSON.stringify(result, null, 2));
```