# Analytics API

The Analytics area publishes 1 REST endpoint. Paths are relative to `https://api.lessly.com`; see [Authentication](/reference/openapi#authentication) for the required header.

### `POST` `/analytics/query`

Answer a natural-language analytics question for the current product.

MCP tool: `analytics_query_run`

**Parameters**

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| q | body | string | • | Natural-language analytics question |

**Response**

| Field | Type | Always | Description |
| --- | --- | --- | --- |
| sql | string | • | — |
| rows | array | • | — |
| answer | string | • | — |
| truncated | boolean | • | — |
| explanation | string | • | — |
