get_viewed_minutes

Gets the viewing time for a given tracker, publisher or video ID. This includes statistics aggregated over the specified timeframe, plus optional per-day, week or month totals.

Explorer

Explore this method

Request URL

http://api.tubemogul.com/api/v3/

HTTP method

GET

Arguments

scope (string)
The scope of the method being called. Valid values are tracker or publisher.
id (string)
The ID corresponding to the scope of the report.
start (string)
The start date for the report. Format is YYYY-MM-DD.
end (string)
The end date for the report. Format is YYYY-MM-DD.
site_id (string) — Optional
The ID for your site. This is required for publisher-scoped queries but not for trackers. Contact us if you do not know your site_id.
interval (string) — Optional
Determines the granularity of list values in the detailed response list. Valid values include perday or none. A value of none will omit the detail list. Defaults to none.
video_id (string) — Optional
The identifier provided for this video in the video player. This must be unique for every distinct video, and must not change over time. This will scope the response to include stats for this video only.

Response Parameters

viewed_minutes (integer)
The total viewed minutes over the specified date range.
daily_avg (integer)
The average number of viewed minutes per day over the specified date range.
daily_max (integer)
The maximum number of viewed minutes on any single day over the specified date range.
pct_completions_25 (number)
The percentage of views that watched at least 25% of the video.
pct_completions_50 (number)
The percentage of views that watched at least 50% of the video.
pct_completions_75 (number)
The percentage of views that watched at least 75% of the video.
pct_completions_100 (number)
The percentage of views that watched at least 100% of the video.
details (list)
A list of per-day viewed minutes with the following parameters: date, viewed_minutes, pct_completions_25, pct_completions_50, pct_completions_75 and pct_completions_100. The entries will scoped based on the arguments provided in the request.

Example Response

http://api.tubemogul.com/api/v3?date=1230109922&user_id=123456
&scope=tracker&id=TD-PEX-29D&method=get_viewed_minutes&interval=perday
&start=2008-12-10&end=2008-12-31&index=1&max_results=20
&auth=aa6fb416b3cac7861be9c9db2ebeef564b70f2e4

<response name="get_viewed_minutes" status="ok">
  <viewed_minutes>3030821</viewed_minutes>
  <daily_avg>137764</daily_avg>
  <daily_max>214999</daily_max>
  <pct_completions_25>75.32</pct_completions_25>
  <pct_completions_50>61.64</pct_completions_50>
  <pct_completions_75>52.62</pct_completions_75>
  <pct_completions_100>33.48</pct_completions_100>
  <details interval="perday" has_more_items="true" list_size="22" count="20">
    <entry>
      <date>2008-12-10</date>
      <viewed_minutes>158901</viewed_minutes>
      <pct_completions_25>72.47</pct_completions_25>
      <pct_completions_50>60.28</pct_completions_50>
      <pct_completions_75>54.39</pct_completions_75>
      <pct_completions_100>35.84</pct_completions_100>
    </entry>
    ...
    <entry>
      <date>2008-12-29</date>
      <viewed_minutes>106907</viewed_minutes>
      <pct_completions_25>61.81</pct_completions_25>
      <pct_completions_50>52.0</pct_completions_50>
      <pct_completions_75>45.06</pct_completions_75>
      <pct_completions_100>27.9</pct_completions_100>
    </entry>
  </details>
</response>

Error Codes

Standard error codes