Skip to main content
POST
Create a saved report

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Idempotency-Key
string

Any unique string up to 255 characters, such as a UUID. A retry with the same key and body within 24 hours answers what the first call did, without writing again.

Required string length: 1 - 255

Path Parameters

site
string
required

The site: its domain as registered (example.com), or its site id.

Body

application/json
name
string
required

The tile's title.

Required string length: 1 - 100
type
enum<string>
required

trend charts the metric over time; list ranks the rows of one dimension.

Available options:
trend,
list
series
object[]
required

One to 3 series for a trend, each drawn as its own line of the same metric; exactly one for a list, whose filters narrow its rows. An events trend names its event on every series with event_name:is:<name> or goal.event:is:<name>.

Required array length: 1 - 3 elements
metric
enum<string>
default:visitors

What a trend charts per bucket. events counts the event each series names. A list ranks by its dimension's own count, as its dashboard card does.

Available options:
visitors,
sessions,
pageviews,
events,
bounceRate,
avgDuration,
revenue
dimension
enum<string> | null

A list's rows: a filter dimension a dashboard card lists (page_path, entry_page, exit_page, hostname, country, region, city, browser, os, device_type, referrer_source, referrer_channel, utm_*, event_name), or property. Null for a trend.

Available options:
page_path,
entry_page,
exit_page,
hostname,
country,
region,
city,
browser,
os,
device_type,
referrer_source,
referrer_domain,
referrer_channel,
utm_source,
utm_medium,
utm_campaign,
utm_content,
utm_term,
event_name,
goal,
property
propertyKey
string | null

The event property a list by property ranks the values of. Null otherwise.

Required string length: 1 - 200
period
any | null

The range the tile always reads: a calendar period (day, week, month, year), all, or a window of an hour or more (24h, 30d, 3mo). Null follows the Reports page's picker.

granularity
enum<string> | null

A trend's bucket size. Null follows the range's length, as the dashboard's chart does.

Available options:
hour,
day,
week,
month
showRevenue
boolean
default:true

Whether a list's tile shows its revenue column, once the site has sold. A display choice: the report's results carry each row's revenue either way.

Response

OK

data
object
required