Create app in GAM (DFP) Dashboard

If you already have created the app you will use in the GAM (DFP) Dashboard you can skip this section.

Create a new iOS app on the GAM (DFP) Dashboard.

458

Keep in mind the app needs to be published in the Apple iTunes Store so GAM (DFP) can find it. Unpublished apps cannot be used.

799

Create Key-Values

Create the Key-Value pairs that will later be used for targeting the line items according to the eCPM obtained in the pre-bid.

603

For the Display Name you can use whatever you prefer to identify the item, but it is recommended to use the same name for both fields.

The recommended format for the Key - Value pairs are:

pn_bid:ECPM

Here you can see an example of​ an eCPM of 0.01 USD:

pn_bid:0.01

824

After naming the Key - Value pairs item, you should add the actual values that will be targeted.

We will use keywords to target our line item on the waterfall when competing with other networks on the same eCPM. In order to make this work, it's very important that when you make the request to GAM (DFP) from your app, you use the keywords generated by the HyBidHeaderBiddingUtils class from HyBid.

The keywords are generated with the following format:

pn_bid:X.XX

Basically, X.XX being the eCPM received from the bid with up to 2 decimals after the comma.

Samples:

eCPM: 1 USD Keyword: pn_bid:1.00

eCPM: 0.01 USD Keyword: pn_bid:0.01

eCPM: 0.3 USD Keyword: pn_bid:0.30

In the ideal situation, there should be a Line item for every possible eCPM in that range but this will end up in thousands of line items, therefore it is better recommended to group the eCPMs in ranges, usually bigger for smaller payouts and smaller for larger payouts. For example:

A line item with eCPM 0.10 can include:

pn_bid:0.11

pn_bid:0.12

pn_bid:0.13

pn_bid:0.14

pn_bid:0.15

pn_bid:0.16

pn_bid:0.17

pn_bid:0.18

pn_bid:0.19

Then the one with 0.20 can do the same up to the 0.29

For bigger eCPM Line Items it is recommended to have more granularity in the keywords to improve the matching on the waterfall.

Click on the Add values button and start adding the targeting values.

794

Create Ad Units

You need to create Ad units that represent the locations in your app that contain ads. In the Ad units section click the New ad unit button.

454

Choose Current level in the drop-down​ menu that comes from the button. Take into account that this is a sample configuration. You can choose to organize your ad units in any way.

398

In the code field add the name that will be used to identify the ad unit in your iOS code.

On the Sizes section choose Fixed size and check only the exact size of the ad you will be showing. Currently,​ HyBid supports:

  • Banner Ads (320x50)
  • Leaderboard Ads (728x90)
  • Medium rectangle (300x250)
  • Interstitials (Fullscreen)
1994

Finally, save the ad unit.

1138

Keep in mind that one ad unit must be created at least per different ad sizes (320x50, 300x250, Fullscreen). These will be used to decide which creative will be served during the ad request.

Create Targeting

The next step is to create the targeting presets that later will be used in the line items to match the proper eCPMs with the creatives and the ad units.

709

Any name can be used but the recommended format is:

ECPM OS FORMAT APP_NAME

829

In the Key - Values section start writing the name of the previously created Key-Value pairs and choose the one that corresponds with the Targeting Preset you are creating.

710

​Once added, click on the values field and choose Select all to include all the targeting values in the preset.

766

Next move to the Inventory section. Here you should choose the Ad units group.

489

From the ad unit groups include the one that corresponds to the Targeting Preset you are creating. In this sample since the size is 320x50, we will use the EasyForecast_Banner ad unit.

490

A Targeting Preset must be created for every Ad unit matching every *Key-Value** pairs you want to target from that unit.

Create Ad Creatives (Setup Custom Events)

The Creatives will be the items that define which adapter to use in the GAM (DFP) mediation to serve ads through HyBid. In the Delivery section of the si​de menu go to the Creatives section.

435

Create a new item. First,​ you must choose the advertiser. It must be from a known network. Choose PubNative from the expanded list.

799

When choosing the creative type. Go to the Mobile App tab and choose SDK mediation

1212

Choose a name for the creative. The recommended format is:

APP_NAME FORMAT

Choose the size of the ad you want to show (320x50, 300x250 or Fullscreen) and activate the location data.

1444

On the Network section, select Custom Event as network.

1476

After selection Custom Event, on the Parameter field you need to specify which PubNative Ad Zone ID corresponds to this Creative. This is needed so the adapter knows how to get the ad from the HyBid SDK Ad Cache. Please add the following JSON into the field:

{"pn_zone_id": "AD_ZONE_ID"}

In the Class Name field add the full name of the HyBid Adapter class you will use. There's one for each format. In this sample, we'll use the one for 320x50 Banner.

For Google Mobile Ads SDK Pre v:8.0.0;

  • HyBidDFPHeaderBiddingLeaderboardCustomEvent (728x90 Leaderboard)
  • HyBidDFPHeaderBiddingBannerCustomEvent (320x50 Banner)
  • HyBidDFPHeaderBiddingMRectCustomEvent (300x250 MRect)
  • HyBidDFPHeaderBiddingInterstitialCustomEvent (Interstitial)

For Google Mobile Ads SDK v:8.0.0 and above;

  • HyBidGAMLeaderboardCustomEvent (728x90 Leaderboard)
  • HyBidGAMBannerCustomEvent (320x50 Banner)
  • HyBidGAMMRectCustomEvent (300x250 MRect)
  • HyBidGAMInterstitialCustomEvent (Interstitial)
1416

After the steps, you should be able to see the creatives on the list

1043

Create Orders and Line Items

Next head to the Orders section to begin setting up the line items.

766

Use any name you prefer for the Order, use PubNative as Advertiser and give the email of the person responsible for​ the ad config management.

726

Set up an initial Line Item. There should be one line item per ad size - eCPM pairs. The recommended format for the naming is:

ECPM OS FORMAT APP_NAME

Choose the size of the ad that will be served by this line item. In the sample,​ it's 320x50

665

In the Settings section change from Standard to Network.

920

Set the starting time as Immediately and the end time as Unlimited.

Set the eCPM of the line item. It must match the values that will be used in for targeting later.

1038

In the Adjust delivery section choose Evenly as a value in Rotate creatives

906

On the Ad targeting section, start by choosing the Targeting preset that matches with the line item you are setting up. There were created in earlier steps. In this sample,​ we choose the 0.01 iOS 320x50 EasyForecast one since it matches the line item and the eCPM we are setting.

840

After choosing the Targeting preset, the values will be automatically added to the targeting criteria section.

821

As the​ last step, go to the Mobile application section in the targeting setup box and choose the app or apps to which this line item will serve ads.

840

It is very important to remember that there must be a line item per ad size and eCPM pairs in the order. It is the only way to properly target the line items according to the eCPM obtained in the Pre-Bid.

Link creatives to Line Items

The last step to make the mediation work is to link the Creatives to the previously created Line items

In the Creatives section choose one of the ones created to serve ads through the HyBid Adapter

2390

When the creative details open, head to the Associations tab. There you should click the Add line items button to start linking the items with the creative.

1214

Choose the Line Items section to start adding associations

1306

Only the line items that match the size of the creative will be displayed on the list. Include all the items you created in previous steps for this ad size.

613

After linking all the Line items, the Associations tab should look something like this.

2390

Repeat this process for all creatives that will serve ads through the HyBid Adapter.

Return to the GAM (DFP) Header Bidding