Creating a global object

For certain partners we suggest creating a global object on the page that could support a scalable solution that contains information for Browsi to fetch. 

Information to be included on the object: 

  • Ad Units

  • Sizes

  • Bidder Params per Ad Unit

  • APS (Amazon) Slot Name and Pub ID

  • Slot Level Key Values

Example of a Global Object: 

window.browsiConfig = { adUnitPath: "/21823462148/Mob_HP_MPU1", aps : { pubId:"3594", adServer:"googletag", slotName:"/21823462148/Mob_HP_MPU1" }, bids: [ { bidder: "adagio", params: { site: "sitesite", placement: "anchor", organizationId: "1211", adUnitElementId: "div-gpt-ad-anchor" } }, { bidder: "xaxis", params: { placementId: 24574209 } } ], sizes: [ [300,250],[320,50] ], keyValues: [ { key: "articleid", value: "aid-1234564"}, { key: "key2", value: "value2" } ] }

Related pages