Brightcove Video Tracking Tag Plugin

The Brightcove video tracking plugin for the Oracle Infinity Tag provides the following features:

  • Track a Brightcove player hosted on your site.
  • Track multiple video objects on a page.
  • Dynamically attach to any video object that is inserted into the markup.
  • Extensive configuration options, including events such as clip views, view duration, pause, play, next, and previous clip clicks for embedded videos
  • Extensive debug messaging via _ora.debug=vvv in the browser console

Requirements

  • Use the latest version of the Brightcove player.
  • Use Brightcove's default video object names, which are set in the configurable playerId option. Modifying Brightcove's default video object names is the most common reason for video tracking to fail.
Note: For more details about this implementation, contact your Oracle Infinity solutions consultant.

Modes

The Brightcove tag plugin has the following modes:

  • Dynamic: Dynamically insert videos into the markup.
  • Standard: Videos to be tracked are in the markup when the page loads. Use Standard mode if you are not dynamically inserting videos into the markup. Standard mode is not recommended for implementations where dynamic video insertions are used, because it will not reliably bind to the videos if they are dynamically inserted after the tag has loaded.

Dynamic mode example

Dynamic mode video insertion should be used if the video is dynamically inserted into the DOM. The Brightcove tag plugin scans the markup on a regular basis and binds to any new videos.

Standard mode example

When the page loads in standard mode, the Brightcove tag plugin scans the page for any video that is in the markup and binds to it.

Parameters

The Brightcove tag plugin can send the following Oracle Infinity parameters:

ParameterNameDescription
wt.clip_accountidBrightcove account IDwt.clip_accountid provides the unique ID of the Brightcove account.
wt.clip_ctVideo content typewt.clip_ct indicates the video's content type, such as MOV.
wt.clip_durationDuration in secondswt.clip_duration indicates the video duration in seconds.
wt.clip_duration_minDuration in minuteswt.clip_duration_min indicates the video duration in minutes.
wt.clip_duration_nDuration based on rangewt.clip_duration_n indicates the range of the video duration in seconds.
wt.clip_evMedia event identifierwt.clip_ev identifies the type of media-related event that has occurred, such as v for a view event.
wt.clip_idVideo identifierwt.clip_id indicates the unique ID of the video asset.
wt.clip_minsPlayhead in minuteswt.clip_mins indicates the video's playhead position in minutes.
wt.clip_modeMode typewt.clip_mode identifies the mode type of video, such as fixed, streaming, FullScreenOn, or FullScreenOff.
wt.clip_nVideo namewt.clip_n identifies the name of the video that was accessed.
wt.clip_percPercentage playedwt.clip_perc identifies the percentage of the video that the viewer has played.
wt.clip_playerPlayer namewt.clip_player identifies the name of the video player.
wt.clip_player_resPlayer resolutionwt.clip_player_res indicates the video player's resolution in pixel height x width.
wt.clip_providerVideo providerWT.clip_provider indicates the host on which the video is located
wt.clip_resVideo resolutionwt.clip_res indicates the resolution of the video expressed as height x width in pixels.
wt.clip_secsPlayhead in secondswt.clip_secs indicates the video's playhead position in seconds.
wt.clip_srcVideo URLwt.clip_src provides the URL of the video.
wt.clip_tMedia typewt.clip_t identifies the type of media, such as Flash or HTML5, depending on what type of player is being used.
wt.clip_tag_tagNameVideo tag namewt.clip_tag_tagName provides the video tag name.
wt.clip_tagsVideo tagswt.clip_tags provides a list of one or more semicolon-delimited video tags.
wt.clip_tvVideo tag plugin versionwt.clip_tv provides the version of the video tag plugin.
wt.clip_video_idBrightcove video IDwt.clip_video_id provides the unique ID of the Brightcove video.
wt.clip_volVolume levelwt.clip_vol provides the volume of the video on a scale from 1 through 100.
wt.dlEvent trackingwt.dl specifies a numeric identifier for the kind of event tracked, which are used for event-level filtering and reporting.
wt.player_idBrightcove playlist IDwt.player_id provides the unique ID of the Brightcove playlist.

Configuration options

The default Brightcove tag plugin options are set to the most commonly requested configuration. However, you can customize the configuration for your needs when required.

Important: Video tracking can create a high volume of server calls depending on the configured events. For example, if you set the beacon rate to send every 10 seconds, the video is 10 minutes, and you have 100 users: 60 * 100 = 6000 server calls for one event.

Sample configuration block for the loader, which is visible in ODC.js:

"config" : { "ora-plugins" : { bc: {beacon:true,beaconRate:90,load:false,loadMeta:false} } }*

Optional configuration properties

OptionData typeDescription
beaconbooleanWhen set to true (the default), a time beacon event is sent every beaconRate seconds. If only quartile reporting is needed, set this option to false to disable beacon tracking. See a data output sample.
beaconCurvearrayAn array of values to use for curvilinear beaconing, such as the following default value:
{
	60:10,
	120:20,
	300:30,
	420:45,
	600:60,
	1800:150
}
beaconRateintegerThe interval between beacons in seconds values (from 0 through 65000). Set this value to the maximum granularity of the reporting you require to make business decisions. The default value is 60.
beaconTypestringThe type of beacon, which can be one of the following:
  • auto: for streaming will use beaconCurve, and for fix duration the beacon rate auto.
  • curve: For streaming media use the beacon curve. For curve always use curve.
For all other values use the beacon rate.
binsintegerSets a bin range for duration tracking in seconds (from 0 through 65000) for categorizing videos by time duration buckets or bins. The default value is 15. The parameter generated is wt.clip_duration_n.
enablebooleanEnables the Brightcove tag plugin when set to true (the default)
fixed Uses the beacon duration for all
loadbooleanWhen set to true, load events are tracked and wt.clip_ev:Load is generated.

The default value is false.

See a data output sample.
loadMetabooleanWhen set to true (the default), loaded meta events are generated:

When set to false, loaded metadata events are not tracked.

See a data output sample.
maxBindsintegerSets the maximum number of binds to video objects per page. The default value is 10.
mediaTagsstring

Used for sending custom media tag data. Brightcove supports a rich set of media tags that are sent with the video metadata, which can have two video tag formats:

  • tag=value: The Brightcove tag plugin will send the tags as wt.clip_tags values in a list.
  • tag: The Brightcove tag plugin dynamically generates wt.clip_tag_tagName parameters a key-value pairs.
nameCallbackstringCallback to set a custom video name generation method. The callback is passed the video node that is being tracked and expects a string (name) to be returned. You can use this configuration option to use an alternate naming collection or determination method. The default is null.

Example:

nameCallack:function(e){
    return e.getAttribute("data-name") || 'unknown';
} 

Note: HTML5 does not have a strong asset naming mechanism. The name attribute is not typically available in the meta content, so the plugin uses the name attribute in the <VIDEO> tag if it exists, then falls back to the file name.

pausebooleanWhen set to true (the default), pause and resume events are tracked and wt.clip_ev:Pause and wt.clip_ev:Resume parameters are generated. See a data output sample.
pctIncintegerSets the quartile tracking percentage increments, which is expressed as an integer from 0 through 100. For dectile tracking (every 10 percent), set this option to 10. The default value is 25.
playerIdstring

The Brightcove ID for the player, which sets the selector string to identify videos. The default value is:

div[id^='vjs_video']:not([id$='_api']):not([id*='_component'])

For custom player implementation, this selector string may need to be adjusted based on how you identify videos in the markup.
pollbooleanWhen set to true, the Brightcove tag plugin polls for videos that are dynamically inserted in the markup. The default value is false.
pollRateintegerSets the polling interval for a new video in milliseconds. The default value is 250.
postMessagebooleanWhen set to true, the Brightcove tag plugin sends data via postMessage instead of the tracking call. The default value is false.
preProcess Callback to preprocess the data before its sent to the tracking call
quartilebooleanWhen set to true (the default value), the Brightcove video tracking plugin uses quartile event tracking and the player will send data at quartile points defaulted to 25, 50, 75, and 100%. See a data output sample.

The calculation for quartile is:
(current position / video duration)*100

wt.clip_secs = (Math.floor(((e.currentTime) * 100) / 1) / 100);
wt.clip_perc = Math.floor((e.currentTime / e.duration ) * 100);
wt.clip_perc = Math.floor(WT.clip_perc / config.pctInc) * config.pctInc;
screenModeboolean

When set to true (the default value), the Brightcove video tracking tag plugin generates the wt.clip_ev:FullScreenOn event when the screen mode is changed.

seekbooleanWhen set to true (the default value), seek events are tracked and the Brightcove tag plugin generates wt.clip_ev:Seek parameters. See a data output sample.
trackCallbackstringModifies the tracking callback function from an Infinity ORA.click call to use a custom method. For details, see the samples.
transformCallback Adds in a transform so the data can be customized before sending (standard Oracle transform)
volumebooleanWhen set to true (the default value), volume events are tracked and the Brightcove tag plugin generates wt.clip_ev:Volume and wt.clip_vol:level parameters.

Sample implementations

trackCallback samples

To send data via Tealium:

trackCallback:function(s){
utag.data.event_type='video';
var mergedUDO=jQuery.extend(utag.data,states.data.wt);
utag.link(mergedUDO);
};

To send data via postMessage:

trackCallback: function (t) {
var payload = JSON.stringify({action: 'MultiTrack', data: [t.argsa]});
_window.parent.postMessage(payload, "*");
};

The following objects are passed to the callback function:

element: this,                       // current environment
argsa: tags,                         // Infinity tags to be sent
transform: config.transformCallback, // transform for legacy v10 tag
data: states.data.wt,                // raw tag data in form ["wt"].['clip_*] format
videoEle: e                          // video element reference that's created the event

Sample onload autoplay data output network call

Sample beacon values

Sample load values

Sample load meta values

Sample pause values

Sample play values

Sample quartile values

Sample resume values

Sample seek values

Learn more

Infinity Module Plugins

Brightcove player API documentation

brightcove video tracking, tag plugin