Run an analytics query
Execute a measures-and-dimensions query against your event stream. Mirrors the in-app query builder.
Required scope: analytics:read.
See Querying Data for a guided walkthrough.
Authorizations
Your Upstack API key. Starts with upstack_.
The pixel id the request targets.
Body
Must match the x-pixel-id header (403 if it doesn't).
none, second, minute, hour, day, week, month, quarter, year 1 - 30 elements5Dimension id (see Measures & Dimensions).
Canonical filter applied to the query. Discover valid
fields with GET /api/filters.
- Option 1
- Option 2
- Option 3
Optional comparison period. Must not overlap dateRange; the server picks the preceding period if omitted (and granularity ≠ none).
IANA timezone (e.g. America/New_York).
Order-level query settings — exclusion filters, pending/voided handling.
Response
Query results.