Skip to main content
POST

Authorizations

Authorization
string
header
required

Organization API key (sl_…).

Headers

x-team-id
string<uuid> | null

Act as this team: rows are limited to what the team's roles reach instead of the caller's own. The caller must be a member of the team or hold the organization-wide permission the route requires.

x-tenant-id
string
required

The organization ID the request is scoped to.

Body

application/json

Aggregate Snowflake queries attributed to Looker.

new_in_period_start
string<date> | null

The date the new_in_period dimension measures from. Omit to take it from the earliest date the query's own filters allow.

usage_group_sets
UsageGroupSetDefinitionV2 · object[] | null

Categorize against these set definitions instead of the organization's saved usage group sets, for evaluating a set before saving it. Omit to use the saved sets, which is what every other surface reports against.

measures
(SemiStructuredMeasure[OrgLookerQueryDimensions] · object | enum<string>)[]

Aggregates to compute over the matching rows.

dimensions
(SemiStructuredDimension[OrgLookerQueryDimensions] · object | enum<string>)[]

Columns to group the aggregates by. Each is returned on every row.

filter_expression
FilterExpression[Union[SemiStructuredDimension[OrgLookerQueryDimensions], OrgLookerQueryDimensions]] · object | null

An and/or tree of predicates over dimensions, applied before aggregation. Omit to match every row the caller can see.

measure_filters
(InFilter[OrgLookerQueryMeasures] · object | ArrayContainsFilter[OrgLookerQueryMeasures] · object | IsFilter[OrgLookerQueryMeasures] · object | LikeFilter[OrgLookerQueryMeasures] · object | MultiLikeFilter[OrgLookerQueryMeasures] · object | EqFilter[OrgLookerQueryMeasures] · object | FilterExpression[OrgLookerQueryMeasures] · object | InRelativeDateRangeFilter[OrgLookerQueryMeasures] · object)[]

Predicates over measures, applied after aggregation.

sort
Sort[OrgLookerQueryMeasures, OrgLookerQueryDimensions] · object[]

Ordering applied to the aggregated rows.

limit
integer | null

Maximum rows to return. Omit for no limit. An aggregation that produces more rows than this is silently cut short at the limit.

Required range: x >= 1
return_sql
boolean
default:false

Return the SQL that produced the rows alongside them, for inspecting how a result was computed. Not every query endpoint publishes its SQL; where it does not, the field stays null.

pivot
PivotConfig · object | null

Reshape the result so the named dimensions become columns rather than rows. Each remaining dimension yields one row, carrying a pivot_data object keyed by the pivoted dimension values. Every name in pivot.on must also appear in dimensions.

rollup
GroupRollupConfig · object | null

Return the result as a tree rather than a flat list, grouping the named dimensions into one level per tree depth. One request fetches the top level; a follow-up naming rollup.parent_paths fetches the children of the nodes expanded so far, so a deep hierarchy is read a level at a time. Every name in rollup.dimensions must also appear in dimensions.

aggregate
boolean
default:true

Aggregate the matching rows. Set false to return the underlying rows as they are, projecting the requested dimensions with no grouping — a listing rather than an aggregation. It is honored only for a request that asks for no measures and no measure_filters, since an aggregate has to group to be computable; limit, when set, bounds the rows returned either way.

Response

Successful Response

items
Items · object[]
required
page_token
string | null

Opaque cursor for the next page; empty/absent on the last page.

row_count
integer | null

Best-effort total for the filtered result set; may be null when expensive.

sql
string | null

The SQL that produced these rows, returned only when the request asks for it. Database and schema names are left as placeholders. Null when the request did not ask for it, or when this endpoint does not publish its SQL.