thePlatform Plugin Browser: Difference between revisions
From Engineering Client Portal
(Plugin 5.1.0.10. Ways to pass custom data.) |
(Description of setup object. Notes added.) |
||
Line 13: | Line 13: | ||
|supportedAdFrameworks=Google IMA | |supportedAdFrameworks=Google IMA | ||
}} | }} | ||
<blockquote>'''Note''': The Plugin 5.1.0.10 is compatible with the thePlatform player version 5.7.7. | |||
ThePlatform player 5.7.8 through 5.7.15 handles ID3 tags incorrectly, which results in incorrect order of ID3 tags sent to the Plugin. | |||
ThePlatform player of these versions should not be used with the version 5.1.0.10 of the plugin due to the player issue. | |||
This issue is fixed in thePlatform player 5.7.16, but the same ID3 tags are being sent by the player multiple times, which impacts data traffic between the player and the plugin. | |||
== Plugin Implementation == | == Plugin Implementation == | ||
Line 107: | Line 112: | ||
== Global Parameters == | == Global Parameters == | ||
To initialize the Nielsen Browser SDK, you must pass | To initialize the Nielsen Browser SDK, you must pass one required global parameter, which will be created when configuring the plugin within thePlatform user interface. | ||
You can also pass optional parameters as described below. | |||
{| class="wikitable" | |||
|- | |||
! Keys !! Description !! Values !! Type !! Required | |||
|- | |||
| apid || unique Nielsen-assigned identifier for the application. Nielsen provides you with the following two apid values: | |||
'''Test apid''': used during development, test, and certification processes. | |||
'''Production apid''': used only after Nielsen has certified the implementation. | |||
|| 'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX' || string || Yes | |||
|- | |||
| apn || a user-defined string value for describing your player || e.g, "Client Name PrimeTime" || string || No | |||
|- | |||
| sfcode || collections location setting. The SDK uses the sfcode value to manage traffic routing. During the Nielsen Beta Period, set sfcode to 'dcr-cert' for testing & 'cert' for production. | |||
|| | |||
'''Development''': set sfcode to 'dcr-cert'. | |||
'''Production''': set sfcode to 'dcr'. | |||
|| string || No | |||
|- | |||
| nol_sdkDebug || Nielsen SDK console logging that should be used while testing. Make sure to disable before moving the implementation to production. | |||
Set 'DEBUG' for all levels of logging enabled. 'INFO', 'WARN', & 'ERROR' can also be used for specific levels of debugging. | |||
Leave blank to disable. | |||
|| <code>debug</code> || string || No | |||
|- | |||
| instanceName || Name of SDK instance || "any string" || string || No | |||
|} | |||
== Setup == | == Setup == | ||
Line 155: | Line 181: | ||
"plplugin$description": "apid", | "plplugin$description": "apid", | ||
"plplugin$defaultValue": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" | "plplugin$defaultValue": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" | ||
}, | |||
{ | |||
"plplugin$name": "sfcode", | |||
"plplugin$type": "string", | |||
"plplugin$label": "sfcode", | |||
"plplugin$visibility": "basic", | |||
"plplugin$description": "sfcode", | |||
"plplugin$defaultValue": "dcr-cert" | |||
}, | }, | ||
{ | { | ||
Line 163: | Line 197: | ||
"plplugin$description": "nol_sdkDebug", | "plplugin$description": "nol_sdkDebug", | ||
"plplugin$defaultValue": "DEBUG" | "plplugin$defaultValue": "DEBUG" | ||
} | }, | ||
{ | |||
"plplugin$name": "apn", | |||
"plplugin$type": "string", | |||
"plplugin$label": "apn", | |||
"plplugin$visibility": "basic", | |||
"plplugin$description": "apn", | |||
"plplugin$defaultValue": "defaultClientPlayerName" | |||
} | |||
] | ] | ||
}</syntaxhighlight> | }</syntaxhighlight> | ||
Line 180: | Line 222: | ||
=== SDK / GlobalParameter Plug-in Variables === | === SDK / GlobalParameter Plug-in Variables === | ||
* '''apid''': This value is given to you by your Nielsen Technical Account Manager. Example value: "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" | * '''apid''': This value is given to you by your Nielsen Technical Account Manager. Example value: "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" | ||
* '''sfcode''': During testing and QA this value should be "dcr-cert". In production this value should be "dcr". | |||
* '''apn''': This is the name of the Player and is editable within the plug-in creation / update | |||
* '''nol_sdkDebug''': Used in test environment for console logging: 'DEBUG'. | * '''nol_sdkDebug''': Used in test environment for console logging: 'DEBUG'. | ||
<blockquote>'''Note''': Make sure to disable before moving to production by leaving blank.</blockquote> | <blockquote>'''Note''': Make sure to disable before moving to production by leaving blank.</blockquote> | ||
=== Notes === | === Notes === | ||
When creating a plugin instance, the setup object is passed to the initialization function called by the player. | |||
Example of the setup object that is passed to the Plugin: <syntaxhighlight lang="json">{ | |||
"apid": "PXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX", | |||
"defaults": { | |||
"tv": true | |||
}, | |||
"custom_fields": { | |||
"assetid": "123456", | |||
"program": "myProgram" | |||
}, | |||
"nol_sdkDebug": "DEBUG" | |||
} | |||
</syntaxhighlight> | |||
The plugin obtains CMS data like assetid, program, length from the following sources: | |||
* '''setup.defaults''' | |||
* '''clip''' object with standard fields provided by the player: | |||
** title = the value returned in clip.title | |||
** nielsen_mediaid = the value returned in clip.contentID | |||
** mediaURL = the value returned in clip.URL | |||
** length = the value returned in timeObject.duration | |||
* '''setup.custom_fields''' | |||
* '''clip.contentCustomData''' object with the fields provided by the client while configuring custom fields in MPX console. | |||
The plugin takes these fields in the order specified above and puts them to one single object that is passed to the Browser SDK with "loadmetadata" events (3/15). | |||
Fields with the same name will be overwtitten. | |||
For example, parameter "mykey" is set in two objects: | |||
<code>setup.custom_fields.mykey="val1"</code> | |||
and | |||
<code>clip.contentCustomData.mykey="val2"</code>. | |||
As a result the value <code>"val2"</code> will be passed to the Browser SDK. | |||
Data from '''setup.defaults''' will be used for '''all videos''' and for '''all ads''' played in the session, e.g. for all videos in the playlist. | |||
Data from '''setup.custom_fields''' will be used for '''all videos''', but '''NOT for ads''' played in the session | |||
The plugin doesn't send events 3/15/49/7/57 to the Browser SDK if there is no custom field provided. In this case the plugin sends only events 55 if the video is ID3 tagged. | |||
There is one exception. The field '''length''' provided in custom fields is '''NOT''' considered as a parameter allowing the Plugin to send events 3/15/49/7/57. | |||
If custom fields are passed through the setup object, it requires initializing the plugin and the Browser SDK for each video. | |||
Revision as of 16:09, 7 December 2017
The Nielsen Browser SDK (Software Development Kit) is the Nielsen framework for measuring media consumption in browser environments. This SDK has the following features:
- Multiple product support: built-in capabilities to support Digital Content Ratings (DCR), VideoCensus (VC), IAG and Digital in TV Ratings (DTVR).
OS | Player Version | SDK Version | Supported Ad Frameworks | Download | |
---|---|---|---|---|---|
5.7.7 | 6.0.0.28 | Google IMA | Contact Nielsen |
Note: The Plugin 5.1.0.10 is compatible with the thePlatform player version 5.7.7.
ThePlatform player 5.7.8 through 5.7.15 handles ID3 tags incorrectly, which results in incorrect order of ID3 tags sent to the Plugin. ThePlatform player of these versions should not be used with the version 5.1.0.10 of the plugin due to the player issue. This issue is fixed in thePlatform player 5.7.16, but the same ID3 tags are being sent by the player multiple times, which impacts data traffic between the player and the plugin.
Plugin Implementation
Pre-requisites
- Nielsen App ID (apid): A Unique ID that Nielsen assigns to the site / player. The 'apid' will be provided by your Nielsen Technical Account Manager.
- thePlatform Plugin: Plugin URLs are provided in below section
- Test Environment Validation: Before moving the app into production, Nielsen must validate the Plugin's integration in a test environment.
Initial Configuration
Before integrating the plugin, perform the following
- Configure metadata
- Obtain Nielsen APID's
- Review the Nielsen plugin URLs for thePlatform video players
Configure Metadata
You must configure your Metadata to send to the SDK. The required values are highlighted in the table below, and will need to be supplied through the "Nielsen Keys".
Note: For more information on setting up your Nielsen Keys & Metadata, please reach out to your Nielsen Technical Account Manager.
Content Metadata
Keys Description Values Type Required type Type of asset 'content'
string Yes assetid Unique ID assigned to asset custom
string Yes program Program Name custom
string Yes title Episode title custom
string Yes airdate The original airdate for linear TV '20161013 20:00:00'
date No length Length of content in seconds 3600
(86400 for lives tream)integer Yes segB Custom Reporting Segment custom
string No segC Custom Reporting Segment custom
string No isfullepisode Full Episode Flag
'y'
- Full Episode
'n'
- Non Full Episodeboolean Yes adloadtype Distinguishes Dynamic vs Linear Ad Insertion
'1'
- Linear
'2'
- Dynamicinteger Yes crossId1 Standard Episode ID custom
string Yes crossId2 Content Originator ID custom
string No mediaURL URL location of the content being streamed custom
string Yes hasAds Distinguishes when content includes Ads
'0'
- No Ads
'1'
- Includes Ads
'2'
- Unknowninteger Yes Ad Metadata
Keys Description Values Type Required type Type of ad
'preroll'
'midroll'
'postroll'
string Yes assetid Unique ID assigned to ad custom
string Yes Note:There is a URL character limit of 2000 characters imposed due to browser limitations. Exceeding this value can impair data delivery on particular browsers.
Obtain the Nielsen Application ID (apid)
The Nielsen apid is required to enable SDK functionality. Your Technical Account Manager will provide two apids for each player configuration
- Test apid: use this apid during development and testing
- Production apid: use this apid in your production environment after Nielsen has tested and qualified the player.
The Platform Plugin URLs
The URL to be used for thePlatform Plugin is as below
Javascript: http://cdn-gl.imrworldwide.com/novms/tp/3/ggtp510.js
Note: Supports flash version of thePlatform Plugin.
Global Parameters
To initialize the Nielsen Browser SDK, you must pass one required global parameter, which will be created when configuring the plugin within thePlatform user interface. You can also pass optional parameters as described below.
Keys Description Values Type Required apid unique Nielsen-assigned identifier for the application. Nielsen provides you with the following two apid values: Test apid: used during development, test, and certification processes. Production apid: used only after Nielsen has certified the implementation.
'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX' string Yes apn a user-defined string value for describing your player e.g, "Client Name PrimeTime" string No sfcode collections location setting. The SDK uses the sfcode value to manage traffic routing. During the Nielsen Beta Period, set sfcode to 'dcr-cert' for testing & 'cert' for production. Development: set sfcode to 'dcr-cert'.
Production: set sfcode to 'dcr'.
string No nol_sdkDebug Nielsen SDK console logging that should be used while testing. Make sure to disable before moving the implementation to production. Set 'DEBUG' for all levels of logging enabled. 'INFO', 'WARN', & 'ERROR' can also be used for specific levels of debugging. Leave blank to disable.
debug
string No instanceName Name of SDK instance "any string" string No
Setup
In order to integrate the Nielsen plugin, you must create the plugin from thePlatform user interface, then integrate with your thePlatform video player.
The Platform Player Plugin Creation
- In order to create a plugin, go to the URL http://data.player.theplatform.com/player/client and login with valid credentials.
- Select the object as a 'Plugin' from the dropdown and check the option POST and type of FORM as 'json'.
- Create the body code similarly to the example body code provided below. You may refer the link for more help http://help.theplatform.com/display/plds/Updating+PlugIn+objects
Example in JSON form
- title : Title for plugin
- plplugin$jsUrl : URL for .js file which loads the plugin in
- plplugin$iconUrl : URL for showing icon of plugin
- plplugin$parameters: Parameters need to add with the Plugin
Integration file references
The URL for integration file references is as below
JavaScript: http://cdn-gl.imrworldwide.com/novms/tp/3/ggtp510.js
Note: The below body code uses the JavaScript Plugin reference
{ "$xmlns": { "plplugin": "http://xml.theplatform.com/player/data/PlugIn" }, "title": "NielsenDCRJS510Plugin", "plplugin$jsUrl": "http://cdn-gl.imrworldwide.com/novms/tp/3/ggtp510.js", "plplugin$type": "plugin", "plplugin$iconUrl": "http://yoursite/folder/nielsen.png", "plplugin$componentType": "tpPlayer", "plplugin$parameters": [ { "plplugin$name": "apid", "plplugin$type": "string", "plplugin$label": "apid", "plplugin$visibility": "basic", "plplugin$description": "apid", "plplugin$defaultValue": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" }, { "plplugin$name": "sfcode", "plplugin$type": "string", "plplugin$label": "sfcode", "plplugin$visibility": "basic", "plplugin$description": "sfcode", "plplugin$defaultValue": "dcr-cert" }, { "plplugin$name": "nol_sdkDebug", "plplugin$type": "string", "plplugin$label": "nol_sdkDebug", "plplugin$visibility": "basic", "plplugin$description": "nol_sdkDebug", "plplugin$defaultValue": "DEBUG" }, { "plplugin$name": "apn", "plplugin$type": "string", "plplugin$label": "apn", "plplugin$visibility": "basic", "plplugin$description": "apn", "plplugin$defaultValue": "defaultClientPlayerName" } ] }Plugin Integration with Player
- Select the player and click on the plug-ins tab on the right hand side of the MPX UI
- Select the required plug-in from the drop-down
- For example, the created plug-in 'NielsenDCRJSPlugin' should now be available under the plugin drop-down.
The variables associated with the plug-in are shown as below, and the user needs to enter the correct values. Refer to your Nielsen Technical Account Manager if you have questions.
SDK / GlobalParameter Plug-in Variables
- apid: This value is given to you by your Nielsen Technical Account Manager. Example value: "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
- sfcode: During testing and QA this value should be "dcr-cert". In production this value should be "dcr".
- apn: This is the name of the Player and is editable within the plug-in creation / update
- nol_sdkDebug: Used in test environment for console logging: 'DEBUG'.
Note: Make sure to disable before moving to production by leaving blank.
Notes
When creating a plugin instance, the setup object is passed to the initialization function called by the player.
Example of the setup object that is passed to the Plugin:
{ "apid": "PXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX", "defaults": { "tv": true }, "custom_fields": { "assetid": "123456", "program": "myProgram" }, "nol_sdkDebug": "DEBUG" }The plugin obtains CMS data like assetid, program, length from the following sources:
- setup.defaults
- clip object with standard fields provided by the player:
- title = the value returned in clip.title
- nielsen_mediaid = the value returned in clip.contentID
- mediaURL = the value returned in clip.URL
- length = the value returned in timeObject.duration
- setup.custom_fields
- clip.contentCustomData object with the fields provided by the client while configuring custom fields in MPX console.
The plugin takes these fields in the order specified above and puts them to one single object that is passed to the Browser SDK with "loadmetadata" events (3/15). Fields with the same name will be overwtitten.
For example, parameter "mykey" is set in two objects:
setup.custom_fields.mykey="val1"
and
clip.contentCustomData.mykey="val2"
.As a result the value
"val2"
will be passed to the Browser SDK.Data from setup.defaults will be used for all videos and for all ads played in the session, e.g. for all videos in the playlist. Data from setup.custom_fields will be used for all videos, but NOT for ads played in the session
The plugin doesn't send events 3/15/49/7/57 to the Browser SDK if there is no custom field provided. In this case the plugin sends only events 55 if the video is ID3 tagged. There is one exception. The field length provided in custom fields is NOT considered as a parameter allowing the Plugin to send events 3/15/49/7/57.
If custom fields are passed through the setup object, it requires initializing the plugin and the Browser SDK for each video.