Mediate via MoPub for iOS

The Flurry mediation adapter for MoPub lets you integrate ads from the Flurry network, via the Flurry Advertising SDKs, while using the MoPub SDK. The adapter supports native, interstitial and banner ad units.

To mediate Flurry via MoPub for iOS, ensure that you have access to the following:

Get Started Mediating Flurry via MoPub

To integrate Flurry as a Custom Native Network in the MoPub ad serving flow, you perform the following tasks:

  1. Integrate the Flurry SDK and Flurry adapter for MoPub code into your app.
  2. Configure Flurry’s Ad Unit(s).
  3. Configure MoPub to mediate Flurry.
  4. Request ads in your app.

Integrate the Flurry SDK and Flurry Adapter into Your App

Follow these steps:

  1. If your app is not currently tracked by Flurry, create a new application on Flurry’s developer portal.

  2. Keep a reference to the API Key for the new application after it has been created. Flurry requires each application to have its own unique API key to identify your app within the Flurry system. The Flurry API key is also used when configuring mediation on the MoPub dashboard.

  3. Add the latest Flurry iOS SDK into your app.

  4. To integrate the Flurry adapter into your application code, follow the structure advised by MoPub for 3rd party ad networks:

    The adapter source files, which can be acquired from MoPub, consists of the following Flurry classes (.h and .m):

    • FlurryBannerCustomEvent
    • FlurryInterstitialCustomEvent
    • FlurryMPConfig
    • FlurryNativeAdAdapter
    • FlurryNativeCustomEvent
    • FlurryNativeVideoAdRenderer

Configure Flurry Ad Unit(s)

Follow these steps:

  1. For each MoPub ad unit that you want to mediate Flurry through, create a matching ad unit on the Flurry developer portal.
  2. Log into the developer portal and navigate to the Monetization tab. On the left navigation bar select, Applications & Ad Units.
  3. You may see a list of previously created ad units. To set up a new one, click the Ad Unit button in the upper-left corner. Depending on the type of Ad Unit you are creating, the Ad Unit setup screen has three to four modules. The Basic Setup section includes fields required to define the name, application, dimensions, placement and orientation of the ad unit.
Flurry ad unit creation screen
  1. You only need the basic setup to start. Click Save.

For additional ad unit configuration, see Basic ad unit setup instructions and Advanced ad space setup instructions.

You are required to create your ad space on the dev portal before retrieving ads through mediation.

Mediating Flurry through MoPub requires no additional Flurry-related coding. The Flurry ad unit invocation code is already incorporated in the adapter code.

If you are integrating banner ads, and would like to simplify the impressions count reconciliation, Flurry recommends that you turn off the banner refresh in Flurry and let MoPub refresh the ads. Set the refresh rate for the ad space to an unusually high number, like 9999 (instead of the default 30 seconds). This setting is found in the Advanced Options section of the ad space setup.

Configure MoPub to Mediate Flurry

After you incorporate the Flurry adapter source files into your project, you need to configure Flurry as a Custom Native Network into the MoPub’s mediation flow. Follow the instructions provided by MoPub.

When adding Flurry to the mediation flow, note that you need to provide the Flurry custom event class names as noted below.

  • FlurryBannerCustomEvent for banner ad units
  • FlurryInterstitialCustomEvent for takeover ad units
  • FlurryNativeCustomEvent for native ad units

In the “Custom Event Class Data” column of each ad unit you are configuring to mediate Flurry, add the the Flurry API key and the name of the Flurry ad space. The parameter names are:

  • apiKey
  • adSpaceName

For example, the column would have the following value:

{"apiKey":"YOUR_API_KEY","adSpaceName":"YourAdUnitName"}

MoPub line item configuration

Request Ads

Follow the instructions for integration of banner ads, integration of interstitial ads, or integration of native ads from MoPub.

Flurry also supports mediating Flurry native video ads through MoPub. You can follow the instructions for integration of native video ads from MoPub.