Add rtc-config object to amp-ad units
Once the placements creation and the GAM connexion are done, you need to add the rtc-config object in your AMP tags. Real Time Config (RTC) is an AMP feature that can be used for Header Bidding to make request calls to your SSPs.
Add the rtc-config object in your amp-ad unit, as in the following example:
"ACCOUNT_ID": "ENTER YOUR CUSTOMER ID",
"TAG_ID": "ENTER YOUR PLACEMENT ID"
“ACCOUNT_ID” and “TAG_ID” must be replaced by your own unique IDs. They can be found in the tab “Sites management”:
- ACCOUNT_ID => Customer ID present on the top right of the console
- TAG_ID => Placement ID available on each line of the placements list
If you have configured a CMP, don't forget to link the call to
amp-adunit to the user consent by adding the attribute
data-block-on-consentin the ad unit.
The script below must be integrated in the
<script async custom-element="amp-consent" src="https://cdn.ampproject.org/v0/amp-consent-0.1.js"></script>
The rtc-config code can be directly copied from the button on the top right of the website page "View rtc-config".
You can add the cookie-sync functionality to help bidders identify the user and bid accordingly. This is optional but recommended to ensure better attractiveness to bidders.
This is GDPR compliant as it won't be done in case a user doesn't give his consent.
Here is the script to add on your page:
- The iframe must be either 600 px away from the top or not within the first 75% of the viewport when scrolled to the top.
- To display a valid iframe, please add the
amp-iframecomponent on your AMP page (if not already present). See required script below:
<script async custom-element="amp-iframe" src="https://cdn.ampproject.org/v0/amp-iframe-0.1.js"></script>