ComScore Delegate
The Comscore SDK has now been removed from Echo and Comscore functionality cut back to page views only, in order to provide for MMx reporting. As such after the following releases no custom events or AV events will be sent, but added labels will remain and specified reporting profiles will be respected.
- Echo JS version
12.16.0
- Echo iOS Swift version
6.1.0
- Echo Android version
19.0.0
Important The BBC’s main Analytics provider is now AT Internet. As such, it is no longer necessary to report to Comscore, except in the case of mobile applications which are still required to report to MMx. This page remains for now as a reference for that purpose.
The ComScore delegate reports analytics events to ComScore DAx. The ComScore delegate is disabled by default (except, for now, on mobile platforms). If you report to ComScore you will need to ensure that you are reporting to the correct ComScore host, account, site, etc. The default Echo behaviour is to report into the BBC Public Service account via the PUBLIC_SERVICE
profile.
Table of contents
Reporting Profiles
The easiest way to configure Echo to report to the correct ComScore host, account, etc, is by using a Reporting Profile. For a full list of profile values see this confluence page or look at the source code for your Echo platform. Echo defaults to the PUBLIC_SERVICE
profile.
Note that the values held in a Reporting Profile can be overridden, by explicitly setting them in addition to the profile (see below).
var conf = { };
// Use GNL reporting profile
conf[ConfigKeys.REPORTING_PROFILE] = 'GNL';
// Instantiate EchoClient
var echo = new EchoClient('MyApp', Enums.ApplicationType.WEB, conf);
HashMap config = new HashMap();
config.put(EchoConfigKeys.REPORTING_PROFILE, "GNL");
// Instantiate EchoClient
EchoClient echo = new EchoClient(
"MyApp", // App Name
ApplicationType.MOBILE, // App type
"echo.android.test", // App Countername
getApplicationContext(), // The Android Context of your Application
config, // config options HashMap
bbcUser, // BBCUser instance
this // Application instance of your Application
);
var config:Dictionary<EchoConfigKey, String>
// Send ComScore events to ComScore test site
config[.reportingProfile] = .GNL
// Instantiate EchoClient
do {
echo = try EchoClient(appName: "EchoDemoApp",
appType: .mobileApp,
startCounterName: "bbc.start.page",
config: config,
bbcUser: user)
} catch {
// Handle Echo config error
}
Configuring the SMP to use a reporting profile
Use the echoProfile
key to set an appropriate Echo profile. The default behaviour if no profile is specified is to use the public_service
profile. See SMP’s Getting the most from your stats
statsObject : {
episodePID : "b05twpn9",
playlistLabels : {
custom_label_3 : "duck",
custom_label_4 : "quack"
},
echoProfile : 'world_service'
};
ComScore Config Options
Setting any of the following options will override the values associated with the reporting profile being used.
Name | Description |
---|---|
COMSCORE_SITE | The site to report to within the specified account e.g. bbc, test, gnl. Not to be confused with the bbc_site label. |
COMSCORE_CUSTOMER_ID | Comscore account number |
COMSCORE_PUBLISHER_SECRET | Comscore publisher secret (iOS and Android only) |
COMSCORE_HOST | Where to send requests e.g. sa.bbc.co.uk, scorecardresearch.com |
Managed Labels
Managed labels are labels used only for Comscore reporting that accept a limited set of values. If a label is found to be invalid, its value will be sent as “invalid-data”. Current available managed labels, how to reference them in the various apps and acceptable values, are shown in the table below:
Echo JS | Echo Android | Echo iOS (Swift) | Acceptable values |
---|---|---|---|
Enums.ManagedLabels.BBC_SITE | ManagedLabels.BBC_SITE | ManagedLabel.bbcSite | any (will be automatically cleansed) |
Enums.ManagedLabels.EVENT_MASTER_BRAND | ManagedLabels.EVENT_MASTER_BRAND | ManagedLabel.eventMasterBrand | any (will be automatically cleansed) |
Enums.ManagedLabels.IPLAYER_STATE | ManagedLabels.IPLAYER_STATE | ManagedLabel.iPlayerState | “purchased”, “free” |
Enums.ManagedLabels.STORE_ED_TYPE | ManagedLabels.STORE_ED_TYPE | ManagedLabel.storeEdType | “archive”, “standard” |
Enums.ManagedLabels.IPLAYER_AVAIL | ManagedLabels.IPLAYER_AVAIL | ManagedLabel.iPlayerAvail | “avail”, “unavail”, “soon” |
Enums.ManagedLabels.STORE_REFERRAL | ManagedLabels.STORE_REFERRAL | ManagedLabel.storeReferral | “iplayer”, “store” |
Enums.ManagedLabels.BBC_HASHED_ID | ManagedLabels.BBC_HASHED_ID | ManagedLabelBBCHashedID | a string with length > 0 |
See the code samples below for how to set them:
echo.addManagedLabel(Enums.ManagedLabels.BBC_SITE, "your-site-name");
echo.addManagedLabel(Enums.ManagedLabels.EVENT_MASTER_BRAND, "your-brand-name");
import uk.co.bbc.echo.enumerations.ManagedLabel;
echo.addManagedLabel(ManagedLabel.BBC_SITE, "your-site-name");
echo.addManagedLabel(ManagedLabel.EVENT_MASTER_BRAND, "your-brand-name");
echo.addManagedLabel(.bbcSite, value: "site")
echo.addManagedLabel(.eventMasterBrand, value:"brand")