For existing app properties, users must explicitly save the property for the first time to activate the GPP functionality.
/**
* 1. Get the key from localStorage which start with amp-store
* 2. Parse the value and convert into JSON.
* 3. Once parsed, access the property 'amp-consent:inmobi'
* 4. Split the GPP string, and retrieve the TCF string which you can use.
* 5. Add proper handling and test before pushing the below code to production
* 6. For more details on how to access local storage, please look at amp-script documentation (https://amp.dev/documentation/components/amp-script)
*/
let consent = JSON.parse(atob(localStorage.getItem('<key-from-domain-local-storage>'))); //looks like this amp-store:https://deranged-humorr.surge.sh
if (consent && consent.vv) {
const gppString = consent.vv['amp-consent:inmobi'].v.r;
const gppStringArray = gppString.split('~');
for(let i = 0; i < gppStringArray.length; i++) {
if (gppStringArray[i].startsWith('CP')) {
console.log('TCF String is ', gppStringArray[i]);
}
}
}
Only MSPA signatories can mark transactions as Covered. You can check your signatory status and sign the MSPA here.
For Android Implementation and SDK-related changes, see Android.
For iOS Implementation and SDK-related changes, see iOS.
By installing this SDK update, you agree that your Children Privacy Compliance setting remains accurate or that you will update that setting, whenever there is a change in your app's audience. You may update the app's Children Privacy Compliance settings at https://publisher.inmobi.com/my-inventory/app-and-placements.