---
title: "List search queries"
method: GET
path: "/v1/analytics/{projectId}/searches"
tags: ["Analytics"]
language: "en"
---

# List search queries

`GET /v1/analytics/{projectId}/searches`

## Request

- Base URL: `https://api.mintlify.com`
- URL: `https://api.mintlify.com/v1/analytics/{projectId}/searches`
- Auth: HTTP bearer

Lists documentation search terms for the date range, ordered by hit count descending, with pagination. Each row includes click-through rate, the most-clicked result path for that query (if any), and the last time the term was searched. `totalSearches` is the total number of search query events in the same date range (sum of all hits, not distinct queries).

Authenticate with an admin API key.

## Path parameters

- `projectId` string, required: Your project ID. Can be copied from the [API keys](https://app.mintlify.com/settings/organization/api-keys) page in your dashboard.

## Query parameters

- `dateFrom` string: Date in ISO 8601 or YYYY-MM-DD format
- `dateTo` string: Date in ISO 8601 or YYYY-MM-DD format. `dateTo` is an exclusive upper limit. Results include dates before, but not on, the specified date.
- `limit` number: Max search terms per page (ordered by hit count descending)
- `cursor` string: Opaque pagination cursor from the previous response

## Response `200`

Search term aggregates with pagination

- SearchesResponse
  - `searches` object[], required: Search terms ordered by hit count descending.
    - `searchQuery` string, required: The search term entered by users.
    - `hits` number, required: Number of times this term was searched.
    - `ctr` number, required: Percentage of searches for this term that resulted in a click on a specific search result (clicks ÷ hits × 100). A click includes selecting a result with the pointer or pressing Enter when a result is highlighted. Submitting a query by itself does not count as a click. Clicking the AI assistant in the search bar, or pressing Enter to use it, counts as a search with no click and is not tracked separately in this field.
    - `topClickedPage` string, nullable, required: The most-clicked result path for this query, if any.
    - `lastSearchedAt` string, required: Timestamp of the last time this term was searched.
  - `totalSearches` integer, required: Total count of search events in the requested date range (sum of all hits, not distinct queries).
  - `nextCursor` string, nullable, required: Opaque pagination cursor for the next page. Null if no more results.

## Other responses

- `400`: A query parameter or `cursor` is invalid, such as a malformed date or a `limit` outside the allowed range, or the project ID is malformed. The response body describes the error.
- `401`: The API key is missing or invalid, or your plan doesn't include API access.
- `403`: Your request came from an IP address that isn't on your API key's allowlist.
- `404`: The project doesn't exist or doesn't belong to your organization.
- `429`: You exceeded the rate limit for the analytics endpoints.
- `500`: An unexpected server error occurred. Retry the request. If the error continues, contact support.

## Changes

- **2026-10-30** `fe6381d657c3`: 4 info
  - added the non-success response with the status `401`
  - added the non-success response with the status `403`
  - added the non-success response with the status `404`
  - added the non-success response with the status `429`
- **2026-04-01** `47cc58cc3893`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/mintlify/apis/mintlify-analytics-export-api/changes/v1/analytics/:projectId/searches/get.md)

---

[API](https://skmtc.dev/mintlify/apis/mintlify-analytics-export-api.md) - [All operations](https://skmtc.dev/mintlify/apis/mintlify-analytics-export-api/llms.txt) - [OpenAPI document](https://skmtc.dev/mintlify/apis/mintlify-analytics-export-api/revisions/6d2c01bf8f5c?raw)
