Current version: (AGNO-JavaScript API)

Target

As you can see in the example below it's important to define a target. The target tells the player when to enable this feature and send the events to GA.

  • "webview" will push GA events when the player configuration value of webView is set to true
  • "inline-js" will push GA events when the player is integrated inline on a HTML page
  • "embed" will push GA events only when the player is loaded in the iFrame of the Embed feature
  • "all" means that all given options will be tracked

Script

// required parameters:
brand: "agnoplay",
videoId: "Mbdskc9KsAii",
url: window.location.href,
...
// add the following:
webView: true, // set this when player is loaded in webview
google_analytics: true,
google_analytics_id: "UA-99230196-1", // we also support v4
google_analytics_target: "webview", // other options: "inline-js", "embed", "all"

Events

These events are being exposed:

Google Analytics

This feature is a pre-integration of Google Analytics which means events are pushed to the configured GA id in the configuration.