Testing mobile in-app ads is different from creating a test page for tags. To test your app for Ad Exchange Mobile In-app ads, you need to make test calls from the app. You can test directly by calling Ad Exchange Mobile In-app from the GMA SDK as well as by calling the ad server where the Ad Exchange tag is trafficked. In this article, we cover testing Ad Exchange directly. To test via Ad Manager ad server, see this article.
Verify Ad Exchange setup
Check if the publisher ad unit ID supplied to the developer contains the ad unit code and is of the format
ca-mb-app-pub-XXXXXX/<tag slot code>.
Verify app setup
- App request and response logs show all events firing correctly.
- App handles device orientation as desired.
- App handles no fill by listening to the error.
Check the app request and response
- Request is made at the expected slot and time (e.g., after every few articles or between every few feeds).
- If using interstitials (with delayed impressions), request is made as close to the ad view time as possible.
Manual impression pings do not work for Ad Exchange.
- Rendering size is consistent between different device screen factors.
- Capture mobile session traffic using any network trace tool (e.g., Charles, Fiddler).
- Check for the following request parameters to verify the setup in the request that contains
- format: should contain the correct size requested.
- iu: should contain the requested publisher ad unit ID.
- tag_for_child_directed_treatment: If value is 1, it triggers COPPA behavior.
- Check the following response parameters to verify the setup:
- Header: X-Afma-Debug-Dialog — When present, this shows the creative and line item ID that the creative served from. This number could sometimes be -2 when there is no fill from Ad Manager and -1 when the fill is from an Ad Exchange ad.
- Header: X-Afma-Ad-Size — Contains the size of the creative that served.