Skip to Content
Get Subview Overall Values
get

Returns the total subview metric value across all views matching the given filters and timeframe.

Request path & query params
METRIC_ID
string
Possible values: "playing_time"

ID of the metric to compute over subviews. Additional metrics may be added over time.

SUBVIEW_TYPE
string
Possible values: "rendition""playback_mode"

The subview type to query.

timeframe[]
array

Timeframe window to limit results by. Must be provided as an array query string parameter (e.g. timeframe[]=).

Accepted formats are...

  • array of epoch timestamps e.g. timeframe[]=1498867200&timeframe[]=1498953600
  • duration string e.g. timeframe[]=24:hours or timeframe[]=7:days
filters[]
array

Filter results using key:value pairs. Must be provided as an array query string parameter.

The set of filterable dimensions is distinct from the main Data API's dimensions, and depends on the subview type — see the List Subview Dimensions endpoint for the valid names.

  • filters[]=dimension:value - Include rows where dimension equals value
  • filters[]=!dimension:value - Exclude rows where dimension equals value
  • filters[]=dimension:__empty__ - Include rows where the dimension has no value

Example: filters[]=country:US

get
200
https://api.mux.com/data/v1/subview-metrics/{METRIC_ID}/{SUBVIEW_TYPE}/overall
Response
(application/json)
{
  "data": {
    "metric_value": 186400000
  },
  "meta": {
    "subview_type": "rendition",
    "metric": "playing_time",
    "unit": "ms"
  },
  "total_row_count": null,
  "timeframe": [
    1617235200,
    1617321600
  ]
}