Query analytics totals and breakdowns
Returns aggregate engagement totals — page views, distinct visitors, visits, bounces, and total time in seconds — for a date range, optionally broken down by one dimension. Use it to answer "how much traffic did the site get" and "what are the top pages/referrers/countries" style questions; use the timeseries endpoint when you need values over time instead. startAt and endAt are Unix epoch milliseconds; optional filter parameters (path, referrer, country, event, UTM fields, ...) narrow the data. Without dimension the response carries the totals alone. With dimension (e.g. path for top pages, referrer for top referrers, country for top countries) the response also carries rows: up to limit (default 25, max 1000) values of that dimension ranked by page views, each with its own engagement totals. Requires a plan that includes analytics (403 otherwise); all-zero totals until the website is published and has traffic.
Request
- Base URL: https://api.cactal.ai/v1
- URL: https://api.cactal.ai/v1/websites/{websiteId}/analytics/query
- Auth: HTTP bearer
Path parameters
Query parameters
Break the range down by this dimension, e.g. path for top pages, referrer for top referrers, country for top countries. Omit for totals only.
Maximum number of dimension rows to return (default 25, max 1000). Only used when dimension is set.
Response
Engagement totals for the range, plus ranked rows when a dimension was requested.
Changes
No recorded changes to this operation across all 1 revision of this API.