Proceed if you have a verified GAM Publisher account, and you have registered your app with GAM.
Under Add Targeting/Inventory, select the placements where you want to monetize using Meson.
Under Add Targeting/Custom, enter the key value you want to target. Meson will send the highest bid price to GAM with the keyword mes_hbbin.
The line item will capture the bids in the price tier $1.00 - $1.10, by targeting the keyword mes_hbbin set to 1.00 in the Key-Values section.
Click Save, to create the line item. Repeat this for all the price tiers created.
<!DOCTYPE html>
<html>
<head>
<script src='https://d1mh3brs31ioia.cloudfront.net/js/creative.js'></script>
</head>
<body>
<div style='display:inline-block'>
<script>
var mesonBidData = {};
mesonBidData.mes_info = "%%PATTERN:mes_info%%";
mesonBidData.mes_type = "%%PATTERN:mes_type%%";
mesonBidData.hbbin = "%%PATTERN:mes_hbbin%%";
mesonBidData.requestId = "%%PATTERN:mes_request_id%%";
mesonBidData.bid = "%%PATTERN:mes_bid%%";
try {
if(mesonBid){
mesonBid.renderAd(document, mesonBidData);
}
} catch (e) {
document.write("An error occured "+ e.message);
}
</script>
</div>
</body>
</html>
Please make sure that you have line items configured for all price tiers in Meson, and for all GAM creative sizes.
Next, let's test the integration.