1. Help Center
  2. RevContent Native API

CCPA API Updates

We've made updates to our API and widget ad tags to support CCPA consent parameters. Our latest widget ad tags now support an optional data attribute data-us-privacy which can be populated prior to loading our script. Our API and legacy widget ad tags support the optional parameter us-privacy within the URL.

Additionally, we support the usage of IAB's US Privacy User Signal API for exchanging CCPA consent string. Publishers are required to expose function __uspapi on their pages in order to return consent string. On widget load user signal API is called with a timeout of 200ms.

Our API also supports query parameters gpp and gpp_sid. If you prefer using script attributes, you can set attributes data-gpp and data-gpp-sid. We also support the usage of IAB function __gpp.

API Widgets:

Replace placeholder <CCPA_STRING> with valid consent string


Standard Widgets (current format):

Add the attribute data-us-privacy along with a valid CCPA String as the value 

<script src="https://assets.revcontent.com/master/delivery.js" defer="defer"></script>

Standard Widgets (old/legacy format):

Replace placeholder <CCPA_STRING> with valid consent string

<div id="rcjsload_2ff711"></div>
<script type="text/javascript">
(function() {
var rcel = document.createElement("script");
var referer = "";
try {
if (referer = document.referrer, "undefined" == typeof referer) throw "undefined"
} catch (exception) {
referer = document.location.href, ("" == referer || "undefined" == typeof referer) && (referer = document.URL)
referer = referer.substr(0, 700);
var usPrivacy = "&us_privacy=<CCPA_STRING>";
rcel.id = 'rc_' + Math.floor(Math.random() * 1000);
rcel.type = 'text/javascript';
rcel.src = "//trends.revcontent.com/serve.js.php?uitm=1&w=<WIDGET_ID>&t=" + rcel.id + "&c=" + (new Date()).getTime() + "&width=" + (window.outerWidth || document.documentElement.clientWidth) + "&referer=" + referer + usPrivacy;
rcel.async = true;
var rcds = document.getElementById("rcjsload_2ff711");



Additional Resources:

IAB CCPA Compliance Guide