Query metrics (GET)

Query one or more metrics via query parameters. The Metric API provides access to time series data for segments, streams, experiences, and other Lytics resources.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Query Params
string

The account ID. Defaults to the user's default account.

string

Friendly name to identify this metric request

string
enum
required

The dimension to query

string
required

The ID of the specific resource within the dimension (e.g. segment ID)

string
required

The metric type to retrieve (e.g. size, converted, conversionrate)

string
enum
required

Comma-separated aggregation methods to apply

Allowed:
string

Start of the query range. Supports friendly times (e.g. now-7d). Required if end_date is set; cannot be used with range.

string

End of the query range. Supports friendly times (e.g. now). Required if start_date is set.

string

Time range from now (e.g. 7d for last 7 days). Cannot be used with start_date or end_date.

string

Bucket size for time series grouping (e.g. 1d, 2h). Defaults to 2h.

boolean

Apply smoothing to the resulting metrics

boolean

Round start and end dates down to the nearest day

boolean

Include zero-value buckets in the response

boolean

Include a sum of all bucket values in the response

boolean

Bypass the cache and read fresh from the time-series store

Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json