Skip to main content

The Pixel Manager Cookie Consent API

info

Since version 1.41.1 of the Pixel Manager

The Pixel Manager Cookie Consent API allows you to command the Pixel Manager if you are using a custom-made cookie consent banner. The API can also be used by publicly distributed Consent Management Platforms (CMPs) to integrate with the Pixel Manager.

Accept all cookies and fire all pixels

pmw.consent.api.acceptAll();
pmw.consent.api.revokeAll();
pmw.consent.api.updateSelectively({
statistics: true,
marketing: false,
preferences: true,
necessary: true,
});

By default, the Pixel Manager saves the cookie consent indefinitely.

You can adjust this by passing the additional duration parameter (in an object).

pmw.consent.api.acceptAll({ duration: 30 });
pmw.consent.api.updateSelectively({
statistics: true,
marketing: false,
preferences: true,
necessary: true,
duration: 30,
});

Make more money from your ads with high-precision tracking