Skip to content

Commit

Permalink
Interstitials (#2869)
Browse files Browse the repository at this point in the history
* removed sizes from RP bid params

* added interstitial page and config to adUnit

* interstitial page corrections

* Update InterstitialAds.md

* Update InterstitialAds.md

* modified sidebar link

* changed interstitials file name and reference

* wordsmithing

Co-authored-by: MartianTribe <steve@martiantribe.com>
Co-authored-by: bretg <bgorsline@gmail.com>
  • Loading branch information
3 people authored Dec 1, 2021
1 parent 53abd8f commit 0c45ecb
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 10 deletions.
8 changes: 8 additions & 0 deletions _data/sidebar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -515,6 +515,14 @@
sectionTitle:
subgroup: 8

- sbSecId: 1
title: Interstitial Ads
link: /features/interstitialAds.html
isHeader: 0
isSectionHeader: 0
sectionTitle:
subgroup: 8

- sbSecId: 1
title: Timeouts
link: /features/timeouts.html
Expand Down
2 changes: 1 addition & 1 deletion dev-docs/adunit-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ See the table below for the list of properties on the ad unit. For example ad u
| `mediaTypes` | Optional | Object | Defines one or more media types that can serve into the ad unit. For a list of properties, see [`adUnit.mediaTypes`](#adUnit.mediaTypes) below. |
| `labelAny` | Optional | Array[String] | Used for [conditional ads][conditionalAds]. Works with `sizeConfig` argument to [pbjs.setConfig][configureResponsive]. |
| `labelAll` | Optional | Array[String] | Used for [conditional ads][conditionalAds]. Works with `sizeConfig` argument to [pbjs.setConfig][configureResponsive]. |
| `ortb2Imp` | Optional | Object | ortb2Imp is used to signal OpenRTB Imp objects at the adUnit grain. Similar to the global ortb2 field used for [global first party data configuration](/dev-docs/publisher-api-reference/setConfig.html#setConfig-fpd), but specific to this adunit. The ortb2Imp object currently supports [first party data](#adUnit-fpd-example) including the [Prebid Ad Slot](/features/pbAdSlot.html) and the [insterstitial](#adUnit-interstitial-example) signal. |
| `ortb2Imp` | Optional | Object | ortb2Imp is used to signal OpenRTB Imp objects at the adUnit grain. Similar to the global ortb2 field used for [global first party data configuration](/dev-docs/publisher-api-reference/setConfig.html#setConfig-fpd), but specific to this adunit. The ortb2Imp object currently supports [first party data](#adUnit-fpd-example) including the [Prebid Ad Slot](/features/pbAdSlot.html) and the [interstitial](#adUnit-interstitial-example) signal. |

<a name="adUnit.bids" />

Expand Down
21 changes: 12 additions & 9 deletions features/InterstitialAds.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,26 @@ sidebarType: 1
* TOC
{:toc}

Interstitails ads are often placed at natural transition points of the user's experince, such as moving from one page to the next. These ads are generally center aligned overlaying user content.
Interstitial ads are often placed at natural transition points of the user's experience, such as moving from one page to the next. These ads are generally center-aligned overlaying user content.

This document covers how to setup interstitial ad units.

{: .alert.alert-warning :}
Please check with each of your bidders to ensure they're reading the interstitial flag from the standard Prebid location.
Please check with each of this AdUnit's bidders to ensure they're reading the interstitial flag from the standard Prebid location.
If the bidder doesn't specifically support interstitials, results may be unexpected.


## How It Works

The intended flow for publishers is the following:
- Publisher traffics interstitial line item with appropriate size(s) ([GAM example](https://support.google.com/admanager/answer/9840201?hl=en))
The flow for publishers is the following:
- Publisher traffics an interstitial line item with appropriate size(s) ([GAM example](https://support.google.com/admanager/answer/9840201?hl=en))
- Publisher defines ad server interstitial slot on the page ([GAM Example](https://developers.google.com/publisher-tag/samples/display-web-interstitial-ad))
- Publisher defines the appropriate interstitial ad sizes within appriate adUnit.mediaType and supplies the adUnit Interstitial flag within the [AdUnit.ortb2Imp](/dev-docs/adunit-reference.html#adUnit-interstitial-example) config
- Publisher creates a PBJS AdUnit and defines the appropriate interstitial ad sizes, adUnit.mediaType, and a special interstitial flag
- Publisher adds bidders and parameters that support interstitials to the PBJS AdUnit(s)
- Prebid requests bids for interstitial adUnits and invokes the ad server call from the requestBids callback

## Ad Sizes
Publishers are intended to set the desired size in the respective adUnit.
Publishers must set the desired size in the respective adUnit.

The below sizes are specials sizes to indicate the ad will be full screen for mobile or tablet devices:
- 320x480: Fullscreen mobile phone portrait ad
Expand All @@ -40,7 +42,6 @@ The below sizes are specials sizes to indicate the ad will be full screen for mo

The Prebid Interstitial flag reflects the OpenRTB standard, specifying it at the imp level.


### Supplying Interstitial Flag

If an attribute is specific to an AdUnit, it can be passed this way:
Expand All @@ -56,15 +57,17 @@ pbjs.addAdUnits({
ortb2Imp: {
instl:1
},
...
bids: [
... bidders that support interstitials ...
]
});
{% endhighlight %}



## How Bid Adapters Should Read Interstitial Flag

To access global data, a Prebid.js bid adapter needs only to retrive the interstitial flag from the adUnit like this:
To access global data, a Prebid.js bid adapter needs only to retrieve the interstitial flag from the adUnit like this:

{% highlight js %}
utils.deepAccess(bidRequest.ortb2Imp, 'instl')
Expand Down

0 comments on commit 0c45ecb

Please sign in to comment.