Skip to main content

Set up GAM


Proceed if you have a verified GAM Publisher account, and you have registered your app with GAM.

Login to your GAM Account#

Login to your GAM Account.

Set Up Line Items#

Go to Delivery > Order and click on New order.

Add order details


Continue with creation of a line items by clicking on Add line item.

Select Ad Type as Display (Standalone).


Select the Line Item Type as Price Priority and enter the expected creatives.


Under Delivery Settings and Cost, enter the rate (enter up to 2 decimal points)


Set Up Inventory Targeting#

Under Add Targeting / Inventory, select the placements where you want to monetize using Meson.


Set Up Keyword Targeting#

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.

Set Up Creatives#

Click on the Creatives tab to add creatives.


Select custom creative


Snippet for Standard creative

<!DOCTYPE html>
<script src=''></script>
<div style='display:inline-block'>
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%%"; = "%%PATTERN:mes_bid%%";
try {
mesonBid.renderAd(document, mesonBidData);
} catch (e) {
document.write("An error occured "+ e.message);


Click Save, to create the creative.

Verify the Line Items#

Please make sure that you have line items configured for all price tiers in Meson, and for all GAM creative sizes.

What Next?

Next, let's test the integration.