Skip to main content
GET
Typescript (SDK)

Authorizations

Authorization
string
header
required

API key in the format: Bearer {api_token}

Path Parameters

id
string
required

The resource ID (e.g., "prod_abc123") or slug (e.g., "my-product")

Query Parameters

start_date
string<date>

Start of the date range (inclusive), as an ISO-8601 date (YYYY-MM-DD). Defaults to 30 days before end_date.

end_date
string<date>

End of the date range (inclusive), as an ISO-8601 date (YYYY-MM-DD). Defaults to today.

Response

Site analytics for the requested period

object
enum<string>
required
Available options:
site_analytics
site_id
string
required

Prefix id of the site (e.g. site_abc123).

period
object
required

The resolved date range the metrics cover.

totals
object
required

Aggregate pageviews and unique visitors over the period.

new_vs_returning
object

Visitors active in the period split by whether their first-ever visit was before the period started.

funnel
object[]

Ordered conversion funnel; each stage counts visitors who reached it within 24h of the first stage.

by_day
object[]

Per-day pageviews and visitors time series.

top_pages
object[]

Top 20 pages by pageviews.

top_referrers
object[]

Top 20 referrer hosts by visitors.

custom_events
object[]

Top 20 custom events by hit count, with unique visitors and any associated revenue.

by_device
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_browser
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_os
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_country
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_region
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_city
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_utm_source
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_utm_medium
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.

by_utm_campaign
object[]

Top 20 values for a single analytics dimension, ranked by unique visitors.