To help publishers comply with GDPR, we are introducing a number of technical changes to Clickio Ad Tags.
Changes to Clickio Ad Tags
Passing user consent to Clickio
Clickio tags are transparent for consent signals. This means that all our partners are able to access user consent status that is declared on the page.

Clickio shows ads from two types of demand vendors: IAB Framework vendors and Google Ad Exchange.

If you have a third party user consent solution integrated on the page, it needs to meet the following requirements.

1) Support IAB Framework's standard CMP Javascript API, including getVendorConsents and getConsentData functions.
2) Until the user consent is recorded, declare the non-personalised mode for Google AdX and DFP in accordance with the official documentation. Both googletag.pubads().setRequestNonPersonalizedAds(1) and (adsbygoogle=window.adsbygoogle||[]).requestNonPersonalizedAds=1 need to be called in the absence of consent.
Note: Initially, Clickio codes supported a separate method for passing consent (window.__lxG__.allowPersAds). This method was deprecated in line with industry developments, and in order to simplify the integration with CMP tools.
Pausing and resuming Clickio tags
Clickio tags can wait for an explicit signal before beginning to issue ad requests. This may be useful if you need to wait for the user to interact with a consent request UI before issuing ad requests.

If you are using Clickio Consent Tool to get consent, Clickio codes automatically wait for the user to make a choice between personalised and non-personalised ads.

If you are using other solutions, use the following code.

To pause execution
<script type="text/javascript">
(window.__lxG__ = window.__lxG__ || {}).pauseLoad = 1;
To resume execution
<script type="text/javascript">
// not to pause subsequent ads
(window.__lxG__ = window.__lxG__ || {}).pauseLoad = 0;

// continue loading previously paused ads 
if (typeof window.__lxG__ != 'undefined'
    && typeof window.__lxG__.resumeLoad == 'function'
) {
Clickio Consent Tool
Getting user consent status
To integrate Clickio Consent Tool with 3rd tags, use the following method to get consent status.
The method returns the following values:
-1 - user has not decided yet
0 - personalized ads are not allowed
1 - personalised ads allowed​
The other way to determine the consent status is to directly check the user's 1st party cookies.
Every user who made consent choice would have a cookie with the name__lxG__consent__ . Its value is a string of concatenated consent state (0 - rejected, 1 - accepted) and a consent disclosure version with | (pipe) delimeter.

For example, 0|1 means that the user rejected personalisation and the consent disclosure language version was 1 (disclosure versions are available in Clickio Consent Tool settings).
Consent Сallback Function
When defined on the page, this function is triggered when Consent Tool renders the user dialog (prior to end-user's decision) and when the user chooses either of the options (second time). For users who have already made their choice, the callback function is called right away with the corresponding parameter value. When a user is out of scope of GDPR, the callback is called with distinguishable param value.
// define callback on page
// place this code before Clickio Consent Tool (CCT) js file
 // isolate all generic variables from global namspace
 // define global object callback function (which will be called by CCT js)
 (window.__lxG__consent__=window.__lxG__consent__||{}).consentCallback = function (consentState) {
        // for EEA users, this callback can be triggered twice:
        // before user decision (with -1 first and 0/1 later)
        // after user decision (with 0 or 1)

        if (consentState === null) {
            // consent not applicable, non-EEA user
        } else if (consentState === -1) {
            // EEA user, consent interface shown, cmp loaded, user has not decided yet
        } else if (consentState === 0) {
            // EEA user, consent rejected
        } else if (consentState === 1) {
            // EEA user, consent accepted

    // // add extra timeout call, in case network issues occur with loading clickio consent js
    // setTimeout((function(){return function(){
    //     // you can add your own value for "default" call
    //     // make sure possible double-call won`t break anything (use semaphore variable)
    //     window.__lxG__consent__.consentCallback(0);
    // };})(), 1500);
How to force the consent dialog to be shown
You can use the following code to show the consent UI. Please note that it will only be shown to EEA users.
Alternatively, you can add ?showConsent=1 parameter to the page URL.