The A9 Server-to-Server (S2S) wrapper solution and client-side code is not a component of any other wrapper (e.g., Prebid). This requires running the code in parallel with OpenWrap. OpenWrap manages the entire process of detecting slots and attaching bids to DFP and does not expose any functionality to request a bid that can be consumed. Therefore, the code cannot run in parallel using callbacks and custom handling.
Handling Pre-Timeout Call to DFP in Case of External Partners
When we introduce partners outside of OpenWrap, any notification and synchronization between OpenWrap and external bidders are not available. This means the only point of synchronization is the OpenWrap timeout event when a call to DFP is fired.
To handle this situation, there should be tight coupling between external bidders for notification for each slot when a bid is available. Unfortunately, building this tight integration is complicated and require many events definitions on A9/Publisher end as well as ingestion of APIs in OpenWrap.
OpenWrap API Interfaces
- registerExternalBidders() – This function will notify OpenWrap that there are one or more eternal bidders present for wrapper needs to wait before calling DFP.
The call to this function should happen as soon as OpenWrap script loads.
- notifyExternalBiddingComplete() – Will notify OpenWrap that all external bidders have completed execution, once per page. This function should be called as soon as bids from all external bidders (A9+ any bidders applicable) is available.
High Level Execution Flow
Standard GPT pages
For standard GPT pages with no time-based refresh/on-the-fly define-display for infinite scroll (For non-advanced GPT where all the slots are defined once and the display API is called), the implementation can be handled using two global notification functions:
Sample Code with the Implementation. You can check the live working example here.
Advanced GPT pages
Refer this section if you have advanced GPT implementation like periodic refresh of slots/on the fly define and display of slots for infinite scroll.
Example for Display
Example for disableInitialload with Refresh
or each googletag.pubads().refresh([slot]) we need synchronization as follows: