-
Notifications
You must be signed in to change notification settings - Fork 0
Privacy ef6970
The Privacy feature allows you to control the type of information collected according to the legal constraints of each editor depending on regions. You can thus adapt your tagging by a precise management of your various parameters of measurement according to their sensitivity, in the respect of the current regulations.
For its proper working, the feature is based on a list of different modes of user consent
-
OptIn: for exhaustive measurement after consent. -
OptOut: for restricted measurement with idclient as “opt-out”. -
NoConsent: for a restricted measurement with idclient set to “Consent-No”. -
Exempt: for a hybrid measure with exclusion of data deemed sensitive (subject to the CNIL exemption process). - Custom: Since 2.21.0, you can set custom visitor privacy modes. Those modes default restrictions are cloned from: exempt for storage, optout for parameters.
Each visitor mode lists a series of Tracker parameters to be allowed . It is therefore possible to interact at different levels and keep complete control of the data to be transmitted.
When a visitor mode is activated, it is registered for a configurable duration of 397 days, if the applied rules actually allow this registration.
Most of the privacy modes don’t store lifecycle metrics by default, meaning that those metrics can be wrong in your analyses.
The plugin provides a series of useful functions in consent management:
setVisitorOptOut()
Enable “optout” mode.
Example
Privacy.setVisitorOptOut();setVisitorOptIn()
Enable “optin” mode.
Example
Privacy.setVisitorOptIn();setVisitorMode(visitorMode)
setVisitorMode(visitorMode, duration)
Activate a specific mode for a defined duration (if not, 397 by default)
| Param | Type | Description |
| visitorMode | VisitorMode |
Name of visitor mode. |
| duration | int |
Validity duration of visitor mode (in days) |
Since 2.21.0:
setVisitorMode(visitorMode, visitorConsent, customUserIdValue)
setVisitorMode(visitorMode, visitorConsent, customUserIdValue, duration)
| Param | Type | Description |
| visitorMode | String |
Name of visitor mode – case sensitive. Predefined modes: OptIn, OptOut, Exempt, NoConsent
|
| visitorConsent | boolean |
Does the visitor consented to be tracked |
| customUserIdValue | String |
Overriding of the SDK user ID. null to keep the standard behavior |
| duration | int |
Validity duration of visitor mode (in days) |
Example
Privacy.setVisitorMode(Privacy.VisitorMode.NoConsent);
Privacy.setVisitorMode(Privacy.VisitorMode.Exempt, 397);
Privacy.setVisitorMode("CustomMode", true, null);
Privacy.setVisitorMode("Restricted", false, "restricted-id", 7);getVisitorMode() ⇒
Privacy.VisitorMode
Retrieve the current visitor mode.
Example
Privacy.VisitorMode visitorMode = Privacy.getVisitorMode();extendIncludeBufferForVisitorMode(visitorMode, keys)
Add buffer parameters to the inclusion list of the specified visitor mode
| Param | Type | Description |
| visitorMode | String |
Mode for which the buffer will be extended – case sensitive. Predefined modes: OptIn, OptOut, Exempt, NoConsent
|
| keys | String... |
Buffer parameters. |
Buffer parameters can use 3 patterns:
-
an: parameter “an” from the querystring -
stc/my_parameter: parameter “my_parameter” from “stc” object from querystring (“/” to indicate a sub-oject level) -
events_data_prop: property “prop” from events data object (“_” to indicate a sub-object level)
Example
Privacy.extendIncludeBufferForVisitorMode("Exempt", "an", "ac"); // buffer parameters "an" and "ac" for Exempt mode
Privacy.extendIncludeBufferForVisitorMode("OptOut", "stc/version"); // buffer parameter "version" of the "stc" object for OptOut mode
Privacy.extendIncludeBufferForVisitorMode("Exempt", "events_data_version"); // buffer parameter "version" of the events data object for Exempt modeSince 2.21.0
extendIncludeStorageForVisitorMode(visitorMode, storageFeatureKeys)
Add storage to the inclusion list of the specified visitor mode
| Param | Type | Description |
| visitorMode | String |
Mode for which the storage will be extended – case sensitive. Predefined modes: OptIn, OptOut, Exempt, NoConsent
|
| storageFeatureKeys | Privacy.StorageFeature... |
Storage keys. Available: Campaign, UserId, Privacy, IdentifiedVisitor, Crash, Lifecycle
|
Call order is important when using this method:
extendIncludeStorageForVisitorModemust be called beforesetVisitorModein order to be taken into account.
Example
Privacy.extendIncludeStorageForVisitorMode("Exempt", Privacy.StorageFeature.Lifecycle); // Add Lifecycle storage to Exempt mode
Privacy.setVisitorMode(Privacy.VisitorMode.Exempt);The activation of the hybrid mode exempt allows very limited measurement by the Tracker. Only the “strictly necessary” parameters are allowed and tracked.
Allowed parameters by default: s, vm, vc, mh, idclient, p, olt, vtag, ptag, ts, click, type, cn, dg, apvr, mfmd, model, manufacturer, os, stc/crash/*
Allowed since 2.21.0: ref
Allowed storage by default: Privacy, UserId, Crash
Of course, the parameter inclusion list can be extended if necessary. For example, it is possible to add a site custom variable to this list if it is considered that the data is strictly necessary, using the extendIncludeBufferForVisitorMode() method.
Example
Privacy.extendIncludeBufferForVisitorMode("Exempt", "x1"); // The site indicator "x1" is added to the Exempt inclusion list
Privacy.setVisitorMode(Privacy.VisitorMode.Exempt);Activating the optout mode results in a strictly limited action by the Tracker.
Allowed parameters by default: s, vm, vc, mh, idclient, ts, olt, cn, click, type
Allowed storage by default: Privacy
The customer ID then takes the value “opt-out” and the traffic generated is found in the category of traffic excluded at the analysis level.
Example
Privacy.setVisitorOptOut();By default, the hits generated when the Opt-out mode is activated are sent. You can if you wish block these sendings by overloading the Tracker configuration variable
sendHitWhenOptOut.
Example
Tracker tracker = ATInternet.getInstance().getDefaultTracker();
tracker.setSendHitWhenOptOutEnabled(false, null, true); // true by defaultActivating the no-consent mode results in a strictly limited action by the Tracker.
Allowed parameters by default: s, vm, vc, mh, idclient, ts, olt, cn, click, type
No storage is allowed on this mode.
The customer ID then takes the value “Consent-NO” and the generated traffic can be excluded at the analysis level.
Example
Privacy.setVisitorMode(Privacy.VisitorMode.NoConsent);The activation of the optin mode results in an exhaustive measurement by the Tracker. All parameters are then stored and sent. This method has to be called after an Internet user has given his consent.
Example
Privacy.setVisitorOptIn();Privacy.extendIncludeStorageForVisitorMode("Custom", Privacy.StorageFeature.Lifecycle, Privacy.StorageFeature.Crash);
Privacy.extendIncludeBufferForVisitorMode("Custom", "p", "vtag", "at", "ac", "events_*");
Privacy.setVisitorMode("Custom", false, null)If your site/app is certified with the french ACPM (OJD), you have to add stc/device to your include buffer:
Privacy.extendIncludeBufferForVisitorMode("Exempt", "stc/device");Last update: 10/03/2021
-
Data API
- Data flow
- Advice optimizations data flow
- Error codes data flow
- Faq data flow
- General information data flow
- Technical information data flow
- Reporting API v3
- Getting started
- Methods
- Parameters
- Technical information
- REST API
- Campaigns
- Custom variables
- Getting started rest
- Methods rest
- Response structure parameters rest
- Fixed periods
- Parameters compatibility
- Relative periods
- Structure of the response
- “code” parameter
- “columns” parameter
- “evo” parameter
- “filter” parameter
- “include” parameter
- “lng” parameter
- “max-results” parameter
- “page-num” parameter
- “period” parameter
- “period” parameter: “H” v. “He” & “MN” v. “MNe”
- “retention” parameter
- “segmentdesc” parameter
- “segment” parameter
- “sep” parameter
- “sort” parameter
- “space” parameter
- Technical specifications rest
- Data flow
-
Data collection
- Android
- Advanced features
- Campaigns
- Changelog
- Content
- Ecommerce
- Getting started
- Users
- Apple
- Advanced features
- Campaigns
- Changelog
- Content
- Ecommerce
- Getting started
- Users
- General
- Cddc renew staging process
- Changelog
- Craft your hit
- Encoded parameters
- Server side cookie management
- Supported taggings
- Tagging deletion
- Utilisation of dispatch sdks
- JavaScript
- Advanced features
- Campaigns
- Changelog
- Content
- Ecommerce
- Getting started
- Partners javascript
- Users
- Piano Analytics
- Event tagging piano analytics
- Getting started piano analytics
- Piano analytics tagging
- Feeding piano analytics with as2 tagging
- Tagging custom properties sdk
- Android