For the complete documentation index, see llms.txt. This page is also available as Markdown.

Authentication and query parameters

Authenticate requests and build metric and session queries.

Authenticate every request with your API key.

X-API-Key: <your-api-key>

Contact MediaMelon support or your account team to obtain your API key.

Example API request

This example uses the metric query endpoint with shared query parameters:

  • period=start=1775749920,end=1775836379

  • metrics=latency,viewercount

  • aggby=timestamp

  • granularity=hour

  • orderby=timestamp

  • order=asc

curl --request GET \
  --url 'https://smartsight3.mediamelon.com/mm-apis/metricquery/199493832?period=start=1775749920,end=1775836379&metrics=latency,viewercount&aggby=timestamp&granularity=hour&orderby=timestamp&order=asc' \
  --header 'X-API-Key: <your-api-key>'

Getting started

  1. Get your customer ID from your SmartSight profile.

  2. Obtain your API key.

  3. Choose an endpoint.

  4. Build a query with period and metrics.

  5. Send the request with the X-API-Key header.

Common query parameters

Parameter
Required
Description

period

Yes

start=<epoch_seconds>,end=<epoch_seconds>

metrics

Yes

Comma-separated metric field names

aggby

No

Breakdown by a combination of dimension or timestamp for time-series

filter

No

Dimension filters, such as [country=US|Canada][platform=Android]

qoefilter

No

Metric-level conditions to filter, such as latency>3 AND bufferingratio>5

orderby

No

Sort by metric or dimension name

order

No

Sorting order - asc or desc

limit

No

Number of records to include in the response, aka Page size. Default is 1000

offset

No

Record offset to include from in the response. Default is 0

Use aggby=timestamp with granularity for time-series queries. Use aggby=<dimension> for breakdown tables.

Response structure

Field
Description

totalcount

Number of records in the current response

pagecount

Total number of pages in the full result set

totalrecords

Total matching records across all pages

response

Array of result objects

Last updated