This document describes the procedure for serving StartApp Ads in your application using AdMob mediation network
- The code samples in this document can be copy/pasted into your source code
- If you have any questions, contact us via email@example.com
Step 1, Getting Started
The following instructions assume you are already familiar with the AdMob Mediation Network and have already integrated the Google Mobile Ads SDK into your application. Otherwise, please start by reading the following articles for a walk-through explanation of what mediation is, how to use the AdMob Mediation UI, and instructions on how to add AdMob mediation code into your app.
- Mediation Overview: support.google.com/admob/answer/2413211
- Instructions: https://developers.google.com/admob/android/mediation
Step 2, Adding Your Application to Your StartApp Publisher's Account
- Login into your StartApp Publisher's account
- Add your application and get its App ID
- Download the StartApp In-App SDK
For any questions or difficulties during this process, please contact us via firstname.lastname@example.org
Step 3, Integrating the AdMob Mediation Adapter
Copy the java source files from the zip to your project's source code.
Step 4, Integrating StartApp In-App SDK
Integrate the StartApp SDK by implementing steps 1-4 from the integration manual. You can ignore all the following steps unless you want to use StartApp Ads directly instead of via AdMob mediation network.
In step 3 of the integration, use the following line to initialize the SDK:
StartAppSDK.init(this, "Your App ID", false);
The extra false parameter will disable StartApp "Return Ads" feature as it's not an integral part of AdMob mediation. You can still enjoy this attractive ad unit directly by omitting the false parameter. In this case Return Ads will be activated and display StartApp direct ads, outside of the AdMob Mediation network.
Note: Splash Ad isn't enabled by default for AdMob mediation. If you want to enable it, simply call StartAppAd.showSplash(this, savedInstanceState);.
Step 5, Adding a Custom Event
- Login into your AdMob account
- Navigate to "Monetize" tab and choose your application
- Find your "Ad Unit" and then click "Edit Mediation"
- Choose "New Ad Network"
- Click "Custom event", and fill in the following fields:
Class Name: com.startapp.android.mediation.admob.StartAppCustomEvent
If not a must, we highly recommend leaving this field empty to use the automatic mode which selects the best ad to load.
- Click "Continue"
Step 6, Testing Your Application
Congratulation - that's it! You may now run your app and see StartApp ads in action.