Difference between revisions of "DCR Italy Static Facebook Instant Articles Browser SDK"

From Engineering Client Portal

(Metadata for Reporting)
Line 13: Line 13:
 
</figure></syntaxhighlight>
 
</figure></syntaxhighlight>
  
For more information on the Analytics element, you can refer to the [https://developers.facebook.com/docs/instant-articles/analytics/overview | Insights and Analytics in Instant Articles] section of Facebook’s Instant Article Developer Documentation.
+
For more information on the Analytics element, you can refer to the [https://developers.facebook.com/docs/instant-articles/analytics/overview Insights and Analytics in Instant Articles] section of Facebook’s Instant Article Developer Documentation.
  
  
Line 36: Line 36:
 
   nSdkInstance.ggPM("staticstart", nielsenMetadata);
 
   nSdkInstance.ggPM("staticstart", nielsenMetadata);
 
</script></syntaxhighlight>
 
</script></syntaxhighlight>
 +
  
 
=== Configure Metadata ===
 
=== Configure Metadata ===
Line 51: Line 52:
 
| section || section of the site to be measured || <code>Entertainment</code> || ✓
 
| section || section of the site to be measured || <code>Entertainment</code> || ✓
 
|-
 
|-
| segC || Reserved custom segment for Instant Articles || <code>'Instant Articles'</code> || ✓
+
| segC || reserved custom segment for Instant Articles || <code>'Instant Articles'</code> || ✓
 
|}
 
|}
  
Line 65: Line 66:
 
| Sub-brand || apid || sub-brand is determined is determined by assigned App ID passed during initialization
 
| Sub-brand || apid || sub-brand is determined is determined by assigned App ID passed during initialization
 
|-
 
|-
| Section || section || section or category of the page
+
| Section || section || section or category for the page
 
|-
 
|-
 
| Custom Segment C || segC || Custom segment C is reserved for reporting ‘Instant Articles’. The Instant Articles custom segment will be available under sub-brand and will include the total metrics for all your Instant Articles
 
| Custom Segment C || segC || Custom segment C is reserved for reporting ‘Instant Articles’. The Instant Articles custom segment will be available under sub-brand and will include the total metrics for all your Instant Articles
 
|}
 
|}
  
=== Going Live ===
+
 
Once you have added the DCR Tracking Code to your Instant Articles, Nielsen will validate your implementation after which you must disable Debug logging by deleting {nol_sdkDebug: 'DEBUG'} from the initialization call.  
+
==== Aggregation Limits ====
 +
There are limits on the number of unique values that can be aggregated on in reporting. The specific limitations by key are:
 +
{| class="wikitable"
 +
|-
 +
! Key !! Aggregation Limit
 +
|-
 +
| section || maximum of 25 unique values (section <= 25)
 +
|}
 +
 
 +
== Privacy Policy ==
 +
Nielsen uses cookies for browser measurement. In order to comply with our privacy restrictions, we ask that you make a link to our Digital Privacy Policy available on your site. You can find our privacy policy here: https://priv-policy.imrworldwide.com/priv/browser/it/it/optout.html
 +
 
 +
== Going Live ==
 +
Once you have added the DCR Tracking Code to your Instant Articles, Nielsen will validate your implementation after which you must disable Debug logging by deleting {nol_sdkDebug: 'DEBUG'} from the initialization call.
  
 
Example:
 
Example:
 
<syntaxhighlight lang="javascript">
 
<syntaxhighlight lang="javascript">
  var nSdkInstance = NOLBUNDLE.nlsQ("PXXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX","nlsnInstance", {nsdkvOverride: "501"});
+
var nSdkInstance = NOLBUNDLE.nlsQ("PXXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX","nlsnInstance", {nsdkvOverride: "501"});
  </syntaxhighlight>
+
</syntaxhighlight>

Revision as of 22:05, 26 April 2018

Engineering Portal breadcrumbArrow.png Digital breadcrumbArrow.png International breadcrumbArrow.png DCR Italy Static Facebook Instant Articles Browser SDK

This guide will show you how to enable Digital Content Ratings (DCR) measurement on your Facebook Instant Articles.

Implementation Steps

Add Tracking Code

DCR measurement can be added to your Instant Articles through the Analytics element:

<figure class="op-tracker">
    <iframe>
        <!-- Add Nielsen DCR Tracking Code here -->
    </iframe>
</figure>

For more information on the Analytics element, you can refer to the Insights and Analytics in Instant Articles section of Facebook’s Instant Article Developer Documentation.


The Nielsen DCR Tracking code below will need to be added within the <iframe> of the Analytics element on each article:

<script>
  // Static Queue Snippet
!function(t,n){t[n]=t[n]||{nlsQ:function(e,o,c,r,s,i){return s=t.document,r=s.createElement("script"),r.async=1,r.src=("http:"===t.location.protocol?"http:":"https:")+"//cdn-gl.imrworldwide.com/conf/"+e+".js#name="+o+"&ns="+n,i=s.getElementsByTagName("script")[0],i.parentNode.insertBefore(r,i),t[n][o]=t[n][o]||{g:c||{},ggPM:function(e,c,r,s,i){(t[n][o].q=t[n][o].q||[]).push([e,c,r,s,i])}},t[n][o]}}}(window,"NOLBUNDLE");

  // SDK Initialization
  var nSdkInstance = NOLBUNDLE.nlsQ("PXXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX","nlsnInstance", {nsdkvOverride: "501", nol_sdkDebug: "debug"});
  
  // Content Metadata 
  var nielsenMetadata = {
    type: 'static', 
    assetid: '', // *DYNAMIC METADATA*: unique ID for each article **REQUIRED**
    section: '', // *DYNAMIC METADATA*: section of site **REQUIRED**
    segC: 'Instant Articles' 
    }; 
    
  // Event 'staticstart' Call
  nSdkInstance.ggPM("staticstart", nielsenMetadata);
</script>


Configure Metadata

Metadata can be passed through key-values using the Nielsen reserved keys. The tracking code includes the Nielsen reserved keys and placeholder values, <metadataPlaceholder>, for dynamic metadata. You will need to update these values.


Metadata Keys

The Nielsen reserved keys are:

Key Description Example Value Required
apid unique ID assigned by Nielsen XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
section section of the site to be measured Entertainment
segC reserved custom segment for Instant Articles 'Instant Articles'


Metadata for Reporting

You can reference the table to determine how the metadata you pass is used to define your reporting structure:

Reporting Level Key Description
Brand apid brand is determined by assigned App ID passed during initialization
Sub-brand apid sub-brand is determined is determined by assigned App ID passed during initialization
Section section section or category for the page
Custom Segment C segC Custom segment C is reserved for reporting ‘Instant Articles’. The Instant Articles custom segment will be available under sub-brand and will include the total metrics for all your Instant Articles


Aggregation Limits

There are limits on the number of unique values that can be aggregated on in reporting. The specific limitations by key are:

Key Aggregation Limit
section maximum of 25 unique values (section <= 25)

Privacy Policy

Nielsen uses cookies for browser measurement. In order to comply with our privacy restrictions, we ask that you make a link to our Digital Privacy Policy available on your site. You can find our privacy policy here: https://priv-policy.imrworldwide.com/priv/browser/it/it/optout.html

Going Live

Once you have added the DCR Tracking Code to your Instant Articles, Nielsen will validate your implementation after which you must disable Debug logging by deleting {nol_sdkDebug: 'DEBUG'} from the initialization call.

Example:

 var nSdkInstance = NOLBUNDLE.nlsQ("PXXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX","nlsnInstance", {nsdkvOverride: "501"});