QueryAnalyticsRequestBody - TypeScript SDK
QueryAnalyticsRequestBody - TypeScript SDK
QueryAnalyticsRequestBody type definition
QueryAnalyticsRequestBody - TypeScript SDK
The TypeScript SDK and docs are currently in beta. Report issues on GitHub.
1 import { QueryAnalyticsRequestBody } from "@openrouter/sdk/models/operations"; 2 3 let value: QueryAnalyticsRequestBody = { 4 metrics: [ 5 "request_count", 6 ], 7 };
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
dimensions | string[] | ➖ | N/A | |
filters | operations.Filter[] | ➖ | N/A | |
granularity | string | ➖ | Time granularity | day |
groupLimit | number | ➖ | Maximum rows per distinct combination of dimensions (ClickHouse LIMIT n BY). When omitted on time-series queries (granularity + dimensions), auto-computed to avoid truncating time windows. Explicit values override the default and may truncate time buckets if set lower than the number of buckets in the range. Ignored when no dimensions are specified. | 100 |
limit | number | ➖ | Maximum total rows returned. Defaults to 1000. On time-series queries with dimensions and no explicit group_limit, the server may raise this to accommodate the expected number of unique time-bucket/dimension combinations. | |
metrics | string[] | ✔️ | N/A | |
orderBy | operations.OrderBy | ➖ | N/A | |
timeRange | operations.TimeRange | ➖ | N/A |