Closed zhouyx closed 2 years ago
Hi @jeffnordlund-ghost @jawadst @janwinkler, @waschnick and @consentmanager. Since you've previously expressed interest in amp-consent's ability to integrate with CMPs, we'd love to have you participate in our design review this Wed @ 1PM PT where we'll go over this component and it's design. Details in #17357. Please feel free to leave feedback on this issue in the mean time.
@jasti Thanks for pinging me, I'll definitely join!
Few thing I recall from the design review
<amp-geo>
with CMP integration as it provides faster experience for users that doesn't require consent. Hi @jeffnordlund-ghost @jawadst @janwinkler, @Waschnick and @consentmanager
we are looking for a CMP to integrate with the amp-consent API. Please let me know if you are interested and we can schedule a VC to go over integration details.
yes please :-)
Hi @lannka
We also have an IAB certified CMP, deployed in several sites, what we'd like to integrate with AMP. I'd appreciate a lot if you could keep me in the loop regarding this
Thanks!
@lannka Happy to help! We already have a first setup running with the existing amp-consent at Didomi so happy to see how the new version would perform with that.
Sure, we would like to explore a better integration with the amp-consent api.
Thanks all. @consentmanager @oliverfernandez @jawadst @jeffnordlund-ghost If you have a launched CMP product, could you share a link?
Also what's your timezone so we can schedule a VC.
Its http://www.consentmanager.net Timezone is CET
You can find and example of our CMP working here (mobile only): https://nospensees.fr/
My timezone is CET as well
@consentmanager @oliverfernandez @jawadst @jeffnordlund-ghost Thank you all for the interest. We scheduled a meeting on Thursday. Time: 2018-09-13 15:30 UTC (add to Google Calendar) Location: Video conference via Google Hangouts
To #17983 for meeting details. Please let us know if you plan to attend or suggest a different time. Thanks.
@zhouyx works for me
@consentmanager @jawadst @jeffnordlund-ghost in case you didn't see. are you able to join us tmr?
Yes, will be there
@lannka That works for me as well
Sorry, I’ve been out of the office for a bit and just catching up.
I might be able to join (if it hasn’t happened yet). My timezone is MST (in the US). I thought I saw a mail with the date/time earlier but I’m not seeing it now. When are you looking to schedule this?
Thanks!
From: Hongfei Ding notifications@github.com
Reply-To: ampproject/amphtml reply@reply.github.com
Date: Wednesday, September 12, 2018 at 7:59 PM
To: ampproject/amphtml amphtml@noreply.github.com
Cc: Jeff Nordlund jeff.nordlund@crownpeak.com, Mention mention@noreply.github.com
Subject: Re: [ampproject/amphtml] I2I: Support CMP Integration with
@consentmanagerhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fconsentmanager&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C238b63efda5f4c0ce4ff08d6191c8797%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636724007657104766&sdata=FhEa0FQB1GAo274LLa7aoFrA4JYEfjbKQp2CiUA5e0s%3D&reserved=0 @jawadsthttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjawadst&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C238b63efda5f4c0ce4ff08d6191c8797%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636724007657104766&sdata=93UCkKp%2BfaLczXwEepx2z1pnCa5xtPOBdgs8Er3oR04%3D&reserved=0 @jeffnordlund-ghosthttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjeffnordlund-ghost&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C238b63efda5f4c0ce4ff08d6191c8797%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636724007657114774&sdata=CotWh9hfJRYk6FyXcih5dn7LPY9EYyI5auTbQoSGS3c%3D&reserved=0 in case you didn't see. are you able to join us tmr?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fampproject%2Famphtml%2Fissues%2F17742%23issuecomment-420857254&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C238b63efda5f4c0ce4ff08d6191c8797%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636724007657124782&sdata=utwcKcqXU5G3AceOkBp6OjjtPQwttlG%2BOSGPONV3g6c%3D&reserved=0, or mute the threadhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAIP0R6Xu9gS6KxkFQthsnMuxDlUDMQbKks5uabv7gaJpZM4WOiEN&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C238b63efda5f4c0ce4ff08d6191c8797%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636724007657124782&sdata=6YtJsqegpX%2B674jw1irTeMZN9Gll8M%2F9pSF57yzDJ3Y%3D&reserved=0.
Empower - September 26-27 2018 In New York
@zhouyx There is an IAB Techlab call at that time that a lot of us are likely to attend. Can we do Friday instead?
Thank you @jawadst for the heads up. Would the same time on Friday, 2018-09-21 15:30 UTC work for everyone? If so I'll go ahead and change the invitation.
Please let us know. Thanks
Works for me
works
re: "CMP and publishers will NOT be able to customize the size and the placement of the iframe. AMP will create a modal layer and place the iframe with default aspect width and height ratio in the center." --> why the downgrade? currently we are able to resize the iframe, which is necessary when many information is shown ...
Cool! Thank you everyone. The invitation was moved to Friday.
Time: 2018-09-21 15:30 UTC (add to Google Calendar) Location: Video conference via Google Hangouts
@oliverfernandez @jeffnordlund-ghost in case you didn't see, we scheduled a meeting Friday to talk discuss the integration work. Thanks
Time: 2018-09-21 15:30 UTC (add to Google Calendar) Location: Video conference via Google Hangouts
@zhouyx Apologies as I missed the call. Let me know if you need anything from us.
Sorry, looks like I missed the call. Please let me know if I can provide any information or answer any questions from how we are using the IAB.
From: Yuxuan Zhou notifications@github.com
Reply-To: ampproject/amphtml reply@reply.github.com
Date: Friday, September 21, 2018 at 12:36 AM
To: ampproject/amphtml amphtml@noreply.github.com
Cc: Jeff Nordlund jeff.nordlund@crownpeak.com, Mention mention@noreply.github.com
Subject: Re: [ampproject/amphtml] I2I: Support CMP Integration with
@oliverfernandezhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Foliverfernandez&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139597876&sdata=YXnWFqhtmkaBq0SEG3RU5bdR1la5T5rsB883a8sAd1Q%3D&reserved=0 @jeffnordlund-ghosthttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fjeffnordlund-ghost&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139607884&sdata=jwj6FVj0vzqYRActs6AV1pWYA2WD5KABdjOtfEyDUIk%3D&reserved=0 in case you didn't see, we scheduled a meeting Friday to talk discuss the integration work. Thanks
Time: 2018-09-21 15:30 UTChttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.timeanddate.com%2Fworldclock%2Fmeeting.html%3Fyear%3D2018%26month%3D09%26day%3D21%26iv%3D0&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139617897&sdata=507HOoK4QGhnTsQgLK3LiCJ7SKz1MqTuqTDiIWw%2BlxI%3D&reserved=0 (add to Google Calendarhttps://emea01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.google.com%2Fcalendar%2Fevent%3Faction%3DTEMPLATE%26text%3Damp-consent%2520CMP%2520integration%26dates%3D20180921T153000Z%2F20180921T160000Z%26details%3Dhttps%253A%252F%252Fhangouts.google.com%252Fhangouts%252F_%252Fgoogle.com%252Ftgg-rpqh-ttp&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139617897&sdata=YDw80zn22PhXsYP6r52vPR9o%2Bnrne%2B5z50kNJ2771NI%3D&reserved=0) Location: Video conference via Google Hangoutshttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fhangouts.google.com%2Fhangouts%2F_%2Fgoogle.com%2Ftgg-rpqh-ttp&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139627905&sdata=xSBddpw2bkvINvZ6%2Fw2SnywQQ0Unboje%2FYJWzAqYGSo%3D&reserved=0
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fampproject%2Famphtml%2Fissues%2F17742%23issuecomment-423429283&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139637918&sdata=5H3omEoT29SD4Q36j3itE1I7kB%2FKIvQVeDwwKkTqgDo%3D&reserved=0, or mute the threadhttps://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAIP0R70RzeU58pKlE3OrVNx13j7jvwExks5udIkDgaJpZM4WOiEN&data=02%7C01%7Cjeff.nordlund%40crownpeak.com%7C8970fa8fabce4ae638f408d61f8c9e04%7Ca5a244c1af69471fb4c7ae6e94586df5%7C0%7C0%7C636731086139647926&sdata=kcuHg%2FN32tk584LksA3Go73M7mZmmF%2BjNDfAw1fZX1M%3D&reserved=0.
Empower - September 26-27 2018 In New York
Thank you all for attending the meetings.
Here's the notes from the meetings we have
9/13 Understand the requirement
Consent string standard
UI standard:
9/21 Discuss technical details
UI
postPromptUI
is clicked to trigger the UI again. AMP will toggle the iframe to the initial 30vh size again because not all publishers allows custom settings and it doesn't make sense to jump to fullscreen. Remote Config
Data from AMP: Is this sufficient to make the decision??
Response from CMP
Data from AMP Is this sufficient to render the UI??
APIs
Update on timeline from AMP
We're expecting to have CMP develop in parallel with us and have an end to end integration flow soon. Please let us if you have any question or concerns on the design. And would love to start email thread or github thread to track the development process. Thank you!
@zhouyx I'm really sorry I missed the last meeting (I was on holidays)
The technical details discussion sounds really great for me. Some comments
30vh for the initial height seems really small in my opinion, specially if you want to show the user a clear initial text and obtain his consent. The success of a CMP is measured by the ratio of consent granted over all consent requests, so the initial screen is critical. I'd suggest at least 50vh, but as you said it's something that can be changed easily in the future
Does the remote config
substitutes the current checkConsentHref
? Does it work in the same way?
Do you plan to substitute the current promptUI
by this, or both will coexist?
Will it be needed to specify a list of CMP implementations somewhere in the AMP runtime (somehow like RTC of Amp4Ads), and then reference which one you want to use from AMP-CONSENT
configuration?
Is going to be some kind of timeout to present the CMP?
Will both consent string and global boolean consent be stored by AMP? Is it up to the vendor AMP implementation (e.g. Doubleclick, Comscore, ...) which want to use?
I'd love to follow up your implementation progress, and do a first implementation from our side if you need validation.
Thanks!
This issue seems to be in Pending Triage for awhile. @zhouyx Please triage this to an appropriate milestone.
Hi all, Happy New Year.
We're close to the code complete of the feature on AMP side. Would like to look for early adopters who would integrate with us. Please let us know if you're interested.
Implementation Progress from AMP
One last piece of work we are still working on is to block all amp-ad
on the page by default. The work can be tracked at #20253. We've decided to introduce a meta tag and require that from publishers in order to block all ads by default. Please let us know if there's any feedback. Thank you.
to @consentmanager @oliverfernandez @jawadst @jeffnordlund-ghost
@zhouyx Happy to start the integration with the Didomi CMP whenever you are ready. Do you plan to release a test version before the final production release?
@jawadst great! We'll keep you updated once the last piece of work is done.
We are protect the feature with an amp-consent-v2
experimental flag. And plan to flip that flag once we believe it's ready.
@consentmanager @oliverfernandez @jawadst @jeffnordlund-ghost The AMP side work has completed. We expect all feature to be live in canary next Tuesday.
I've created a draft doc for you to start with. Please let us know if there's any questions. I'm happy to sync offline if necessary.
All features should be live in with developer opt-in now.
I've created an example page to demonstrate. It's a simplified cmp service, with
example remote endpoint logic
consent prompt ui iframe https://raw.githubusercontent.com/ampproject/amphtml/master/test/manual/diy-consent.html
and configuration in AMP consent https://github.com/ampproject/amphtml/blob/master/extensions/amp-consent/0.1/cmps.js#L30-L36
Please let me know what I can help with the integration. Thank you.
@consentmanager @oliverfernandez @jawadst @jeffnordlund-ghost
@zhouyx Thanks a lot for all your hard work, this looks great! I'll try it out next week and send any feedback I have.
Great, thank you @zhouyx. We are also very impatient to use this new solution and adapt it soon.
Great! @jawadst @christian-felix please let me know if there's any feedback or question.
hi @jawadst @christian-felix did you get chance to look at the integration yet? we're looking for an announcement in the coming AMP Conf in April. It will be good if we could show case a couple of CMP integrations.
Let us know if you have any questions.
Hi @lannka, we are currently evaluating the idea and hopefuly absorbing it soon. In case of successfully integration I will provide you with the appropriate link for the coming AMP Conf.
Hi @jawadst @consentmanager @oliverfernandez @jeffnordlund-ghost we are looking to exist the beta relatively soon and would love your feedback before we do so. Do you have an ETA for when you might be ready with your AMP CMP integrations?
@jasti @lannka @zhouyx We are finishing up our tests and should be able to provide feedback some time next week
@zhouyx @jasti We have a few questions for you following our initial tests:
1) It seems that the function {amp-consent-id}.prompt()
can be used to re-open the prompt UI, is that correct? Is that documented somewhere yet? (I am assuming it is new with your v2 update)
2) For the info
field that gets returned by a CMP in the consent-response
postMessage, we are not completely sure of what you expect in there. I understand it is a general field for a CMP to store data and:
consentString
field in the iframe name? If yes, you might want to rename the fields to have the same name (consentString
or iabConsentString
are good).3) What is your recommended solution for testing the prompt UI iframe and checkConsentHref locally before adding our CMP to https://github.com/ampproject/amphtml/blob/master/extensions/amp-consent/0.1/cmps.js? (for local development and testing basically).
We are able to replace your URLs when using your test file with a browser extension but is there a way to locally define a CMP or override the settings for your _ping_
CMP?
4) Regarding the co-existence of the consent string and the consent state, is our understanding correct that:
5) Do you have any documentation on how vendors are expected to query/receive the IAB consent string? Are you in discussion with any vendor on that topic?
6) One open question that I know we discussed on our calls and you decided not to include in this first update to AMP: do you have plans to add more granularity to the consent state and the blocking behaviors on the page? As it is defined today as a binary state (agree/disagree), it is impossible to really be compliant with GDPR and the latest information given by DPAs like the CNIL at the end of 2018, as they require granular choices (by purpose and by vendor) to be exposed to the user. A global yes/no choice is not enough from that perspective. While we might be able to achieve that for IAB vendors with your current implementation, that will not be doable for non-IAB vendors like analytics vendors.
Thanks a lot for all your hard work on this subject: we get daily requests from our publishers for AMP support so be assured that this will be used as soon as it is released! I think we'll have our first AMP CMP released some time in March so let me know if you want to coordinate something for your April conference, I am happy to provide some material as needed.
cc @MaximePlancke (who is also working on our AMP integration at Didomi)
@jawadst Thank you for the feedback.
1.
It seems that the function
{amp-consent-id}.prompt()
can be used to re-open the prompt UI, is that correct? Is that documented somewhere yet? (I am assuming it is new with your v2 update)
This is something we support in v1 : ) Document is here. It is designed for users to manage their consent after initial interaction with the prompt.
2.
- Is it expected to be an IAB consent string or is it a free-form field for a CMP to use?
AMP expect it to be a free-form field. Whether to follow the IAB consent string format or not is up to the CMP.
- Is it the value that vendors get when they ask for the consent string?
Exactly
- Is it the value that gets passed back in the
consentString
field in the iframe name? If yes, you might want to rename the fields to have the same name (consentString
oriabConsentString
are good).Is it expected to be an IAB consent string or is it a free-form field for a CMP to use?
You're right! There are other client information that get passed to the iframe in the iframe name. Which includes clientConfig
, consentState
and consentString
. And we pass the stringified object. Which field do you want to rename?
What is your recommended solution for testing the prompt UI iframe and checkConsentHref locally before adding our CMP to https://github.com/ampproject/amphtml/blob/master/extensions/amp-consent/0.1/cmps.js? (for local development and testing basically). We are able to replace your URLs when using your test file with a browser extension but is there a way to locally define a CMP or override the settings for your
_ping_
CMP?
It is not documented, but you can use inline config to override any CMP provided vendor config. In this case I assume you can do
<amp-consent type='_ping_'>
<script type="application/json">
{
'consentInstanceId': yourid,
'checkConsentHref': ....,
'promptUISrc': xxxx,
}
</script>
</amp-consent>
let me know if this helps with your local testing.
Regarding the co-existence of the consent string and the consent state, is our understanding correct that:
- the consent state is used for blocking behaviors as described on https://www.ampproject.org/docs/reference/components/amp-consent#blocking-behaviors
- the consent string will be passed to IAB vendors as needed but is not leveraged by AMP itself for on-page blocking
Exactly
Do you have any documentation on how vendors are expected to query/receive the IAB consent string? Are you in discussion with any vendor on that topic?
Thank you for asking this. Currently we haven't documented on how vendors are expected to query/receive the IAB consent string yet. But it's definitely we will be adding soon. We have not discussed the consent string topic with any vendor yet, given AMP is purely only going to pass consent string between CMPs and vendors.
One open question that I know we discussed on our calls and you decided not to include in this first update to AMP: do you have plans to add more granularity to the consent state and the blocking behaviors on the page? As it is defined today as a binary state (agree/disagree), it is impossible to really be compliant with GDPR and the latest information given by DPAs like the CNIL at the end of 2018, as they require granular choices (by purpose and by vendor) to be exposed to the user. A global yes/no choice is not enough from that perspective. While we might be able to achieve that for IAB vendors with your current implementation, that will not be doable for non-IAB vendors like analytics vendors.
This is a great question. And as you've pointed out this is achievable for IAB vendors. To support more granular consent blocking for non-IAB vendors, it requires AMP to come up with a consent string standard and it's not something we are planning to do. However if that becomes a popular request we will definitely consider adding more granularity.
Thanks again for the questions and feedbacks. Let me know there's more I can help with.
One question regarding the examples above:
window.parent.postMessage({ type: 'consent-response', cmpStoredData: '', consentStr: '', action: 'accept/reject/dismiss' }, '*');
Is this example still correct or does the message need to be a json string instead?
@janwinkler Good point. The example still applies, except we change the consentStr
to info
and the cmpStoredData
is currently not supported.
We'll start with 300 bytes limit and work on the LRU/LRR to expand the storage limit.
Consent strings are likely to be larger than this within the next year as the IAB TCF version 2 begins deploying.
Currently we haven't documented on how vendors are expected to query/receive the IAB consent string yet. But it's definitely we will be adding soon.
Perhaps I'm misunderstanding here. (Ad tech) vendors need access to the consent string to send in their ad fetch calls so that they know whether the proper disclosures were made to the user and whether they have consent (if they're relying on consent). Not sure I understand the point of a CMP that generates consent strings to which vendors have no way to access.
@zhouyx Thanks for your answers! A few extra comments/questions for you:
On the format that is stored by AMP in the consentString
field (consent string vs CMP-specific string): if what is stored gets passed to vendors then it forces CMPs to store the IAB consent string there and prevents us from storing consent for non-IAB vendors.
I think we'll have to assume that non-IAB vendors are not supported in this first version but please keep them in mind for future evolutions. They are a big part of what we do with our publishers. One option would be to open another field (cmpConsent
) that would only contain CMP-specific information and would allow us to store extra information as needed.
Do you have a way to exit the fullscreen mode? We sometimes display a banner notice (so the consent UI is not fullscreen initially) with a link to open more information in a pop-in. The pop-in uses the fullscreen mode when it opens which works great. When the user closes the pop-in and if they have not made a consent choice yet, we want to exit the full-screen mode and leave the banner notice open. It does not seem like there is an action to exit the full-screen mode.
CSS for iframe Would it be possible to remove the CSS that has a visual impact (border, for instance) on the prompt UI iframe? I think that there should not be anything else than positioning/height applied. Right now, it prevents us from styling the UI exactly how we want.
Consent re-collection There are a few cases when consent needs to be recollected and the consent UI needs to be shown again after the user gives consent:
To summarize, I think the following two points are blockers at this point:
@dmdabbs
Consent strings are likely to be larger than this within the next year as the IAB TCF version 2 begins deploying.
Thanks for bringing it up. It's definitely something we keep in mind. We are happy to explore ways to loose the restrictions then.
Perhaps I'm misunderstanding here. (Ad tech) vendors need access to the consent string to send in their ad fetch calls so that they know whether the proper disclosures were made to the user and whether they have consent (if they're relying on consent). Not sure I understand the point of a CMP that generates consent strings to which vendors have no way to access.
I'm completely with you on this point. The support is already in, the documentation work is deferred until we have the CMP support.
@jawadst Thank you for the additional feedback.
- On the format that is stored by AMP in the
consentString
field (consent string vs CMP-specific string): if what is stored gets passed to vendors then it forces CMPs to store the IAB consent string there and prevents us from storing consent for non-IAB vendors. I think we'll have to assume that non-IAB vendors are not supported in this first version but please keep them in mind for future evolutions. They are a big part of what we do with our publishers. One option would be to open another field (cmpConsent
) that would only contain CMP-specific information and would allow us to store extra information as needed.
If I understand it correctly, what you want is to store a piece of information that's only for CMP use. This is something we can support as long as the string size under the cap. What confuses me a bit is How will this string work with non-IAB vendors?
- Do you have a way to exit the fullscreen mode?
Short answer: No, but we can definitely add support
- CSS for iframe
Sounds reasonable to me. @torch2424 who is the owner of amp-consent UI can help answer the question better.
- Consent re-collection
Thanks for bringing this up. AMP decides to support a one behind model that allows the endpoint to erase the stored consent and force prompt next time. This will be supported with the 'forcePromptOnNext' feature. However it is something the team decides to de-prioritize until CMP integration is added. I'm happy to prioritize if you find it to be a big blocker.
We need more clarity on how IAB vendors will get passed the IAB consent string and we need some vendors buy-in. I think this might be the right timing to join one of the IAB Techlab meetings for a presentation to get some vendors involved. Happy to help facilitate that if needed.
I wonder in the non AMP case, how CMP passes the IAB consent string to vendors? I assume it will be very similar in AMP pages. Happy to discuss this further. cc @jasti
To #15653
Overview
The following sections will try to answer these questions:
Background
<amp-consent>
provides a solution for publishers to collect user consent and block or unblock any AMP component in an AMP page. Currently, this solution only allows the publisher to collect a boolean consent for all vendors in the consent UI.To support per purpose and per vendor based consents and allow for third party integration from Consent Management Platforms (CMP) with publisher AMP pages, AMP will enhance
<amp-consent>
. It will allow for richer interaction between the publisher page, vendors, CMP and ad extensions on AMP pages that need to know about the consent status. AMP must make such an API for CMPs because AMP doesn’t allow custom JavaScript to run on the page and therefore a CMP must integrate with the AMP framework to integrate with a publishers page.Data Flow Desing
The following section explains each step in terms of data structure and API.
Read data from localStorage (Step 1)
Data includes the stored consent string and CMP stored information.
Pass information to CMP endpoint (Step 2)
The following data with be passed through a POST request
CMP endpoint response (Step 3)
Endpoint returns a JSON object
Initiate the UI iframe (Step 4)
Data will be stringified and passed via the iframe name attribute
Iframe returns user decision (Step 5)
UI iframe will pass the consent information back to
<amp-consent>
via postMessageconsentStr
is required to pass the value to vendors.action
is optional. When specified, it instructs components that don’t understand consent string to load or not based on the publisher’s configurations.cmpStoredData
value will be stored per the CMP requestStore consent information (Step 6)
Store the
consentStr
and thecmpStoredData
to localStoragePass consent information (Step 7)
AMP components on the AMP page (vendors in the format
<amp-ad type=${vendorName})>
can access consent information with function callWhere the function returns an object that merge the value of
consentStr
andsharedData
Blocking Behaviors
Default Blocking Behaviors
When a CMP is present on the page, AMP runtime behavior will default to:
<amp-ad>
components on the page from rendering<amp-ad>
and pass the response to them<amp-ad>
components (unless the publisher specifies not to by adding thedata-block-on-consent
attribute) and passesthe response to them.Special Cases
Publishers can override the default behavior and customize the blocking behaviors by tagging the components manually.
<amp-ad data-block-on-consent=”_never”>
<amp-ad>
: Use the existingdata-block-on-consent
attribute. However, the value of the returned action (accept/reject/dismiss), depends on the agreement between the publisher and the CMP.Prompt Window
External Iframe
AMP consent will load and render the CMP’s prompt UI in a cross domain iframe, where the CMP will have full control. However, AMP runtime will control the life cycle of the iframe, dictating when to load or unload it.
Default placeholder
AMP will apply a placeholder before the CMP iframe loads to improve user experience. The placeholder will not block the user from interacting with the rest of the page. UX design will be added once ready.
Iframe Size and Placement
AMP will make the prompt UI interstitial by default. CMP and publishers will NOT be able to customize the size and the placement of the iframe. AMP will create a modal layer and place the iframe with default aspect width and height ratio in the center.
Consent String
Consent string contains the user decision and will be stored and passed to vendors. Vendors will interpret the consent string and respond accordingly.
Format
Because different CMPs want to store different consent strings for customized vendors in addition to the IAB consent string, AMP will not enforce format on the consent string, or attempt to interpret the consent string before passing the information to vendors. AMP would require CMP to indicate their string as IAB so that vendors can understand. Please note in MVP, not API will be provided to vendors, and vendors need to interpret consent string themselves.
Storage Limit
When the cached AMP page is served from the google.com. All information will be stored under the google.com domain. Because of it, AMP consent has to be very cautious of the storage usage.
In order to be space efficient, AMP restricts the size of total stored value to an upper limit of 300 bytes. That includes the consent string and the CMP private stored string, if one exists. CMPs should work with their partner vendors to compress their consent string.
In the case that a CMP asks AMP to store information that exceeds the size limit, AMP will:
<amp-ad>
components and make the consent string information globally accessible to all AMP components the consent string information but w/o storing the value for next visit.Access
The consent string is made available to all AMP components on the page and to the CMP.
To AMP components and vendors
AMP components can call where the policyId can be interpreted from the data attribute.
3P ad that integrate with AMP can find the string at (similar to supported sharedData)
To CMP
Private CMP stored string
Where consent string can be shared to all components, stored string will only be shared with the CMP.
CMP Integration
A CMP named
foo_bar
will integrate with AMP in the following way.Check in configuration
Add the configuration as part of the
<amp-consent>
codebase. This will allow AMP to recognize the CMP, perform steps to check if consent is necessary, handle storage and UI.storageKey
instructs AMP runtime to store the consent information under this unique key name. Note: AMP will append prefix to the key. If not specified, AMP will assume CMP does not require consent string to be stored client side.Unlike the current DIY approach with
<amp-consent>
, CMP will be able to specify the storage key value instead of publishers. This is easier for CMP to bump up versions because they have control of the storageKey.checkConsentHref
is a field AMP consent already supports. It allows the AMP consent component to ask the CMP if consent is required for a user. This field is required, as it is the key to instruct AMP runtime to ask for consent and block other components on the page. For more details, please refer to the section hereNote:the existing
promptIfUnknowForGeoGroup
for CMP integration won’t be provided as AMP expects CMP to host their own endpoint instead of depending on publishers configuration on the<amp-geo>
component.src
is the source for the foreign iframe. It is also a required field. Once AMP consent decides to prompt, it will create a foreign iframe with the src given.Host endpoint
AMP consent will rely on the host endpoint to determine if the prompt is required with the
checkConsentHref
request.Consent Dialog
The CMP will need to modify their prompt logic to function in a cross domain iframe. And communicate with the parent host AMP page through the proposed communication APIs.
Publisher’s Configuration
To work with a CMP, publisher’s configuration will need to stay minimal.
Type Attribute
A type attribute with a valid CMP name value instructs the
<amp-consent>
component to load the CMP config.CMP Object
All configuration within the
cmp
object will be passed to the CMP, both withcheckConsentHref
and iframe (added to the name attribute).PostPromptUI
CMP’s support to postPromptUI has not been discussed yet. Right now publishers can still put their own postPromptUI element on the page and reference the element.
Other topics
Below is a list of topics we have talked about but not covered in the current design. We may look into supporting it in the future. Allow publishers to still use the
<amp-geo>
component to reduce one roundtrip of latency Provide support for CMP to store consent server side but not client side