Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

AdConsent comes completely integrated with AdEngine v3. Your account manager will configure AdConsent with the page requirements and there are no additional steps required on the page.
To implement AdEngine on a website please check the Setup Overview.

There are some situations where manual control over AdConsent is be required. This guide will describe such use cases and how to implement them properly.

...

Loading 3rd party libraries that use the CMP

The IAB Europe Transparency and Consent Framework (TCF) Specifications specifies determine that the Consent Management Provider (CMP) is supposed to be loaded synchronously in the page head before any other module, to ensure the API is available. Loading a script synchronously in the head, even if very small, has several risks and will slow down page loading. Therefore, AdConsent is loaded automatically and asynchronously by AdEngine which guarantees that it is accessible to supported libraries, like GPT, AdSense, or Prebid.js.
If the page uses unsupported third-party libraries that use a CMP and process the user consent strings, it is necessary to ensure that these scripts are only loaded or started after AdConsent is loaded and ready.

The following example will show how to load a thirds party script when AdConsent is available, using the adnginLoaderReady event.
This example loads AdConsent asynchronously, waits for the ready signal, and then loads the 3rd party script asynchronously. This ensures sequential loading between the CMP and the libraries using it, but otherwise is loading , it loads everything asynchronously ensuring the best page performance.

...

Using AdConsent API

The page can use the AdConsent API to process consent events or manually configure AdConsent. To work with the API, it requires the API to be loaded and ready, which is guaranteed by the adnginLoaderReady event as described in the previous example.

...

  • Loading an Analytics library only after consent is collected

  • Processing user data after the user gave consent