Voice   >   Insights

Add Ad Networks for mediation

Teach you how to Add Ad Networks for mediation step by step

17 February 2020 at 11:00 AM

AdTiming Staff AdTiming

● Step 1: Create an account on the Ad Network

Take AdMob for example, to access AdMob's ad inventory through AdTiming's Mediation platform, you must create an account with AdMob. You can do on their official website at https://admob.google.com/home/.

● Step 2: Create an app and its ad units on the Ad Network

Add your app: (Note: On some Ad Networks, such as Applovin, this step is not required. You can just add ad units.) Add ad units:

● Step 3: Retrieve the Ad Network's parameters

Generally speaking, you need your App ID, Ad Units' IDs and API Key to make the mediation work. App ID: Ad Unit ID:
Project ➣ APIs & Services ➣ Credentials ➣ Create credentials ➣ API Key:

● Step 4: Configure the Ad Network on AdTiming with its parameters

Select the Ad Network from the list of available Ad Networks and click on the 'Edit' icon: Enter the parameters for each platform, for example App ID, API Key, and Unit ID for Admob. (Note: different Ad Networks use different terms for the same thing, for example some use SDK Key or Game ID as APP ID. For some Ad Networks their API Key gets synced with AdTiming automatically hence there is no need to manually input it):

When associating an instance, enter the ad unit ID created on the Ad Network into our Instance ID. If you need to add more than one instance, just click Add under each ad unit. Save your ad unit and click on 'Grant Access'. Double check the information you entered above if 'Granted Failed' is returned. Click on 'Grant Access' again until 'Success!' shows up.

Finally, turn on the switch of 'Mediation Status' to see its 'Report API Status' change to 'Working':

● Step 5: Add the Ad Network's SDK & adapter to your build

Now the only missing pieces are the AdNetwork's SDK & adapter in your project. Copy the repositories part to your project-level build.gradle file.

repositories {
        maven { url 'https://dl.adtiming.com/android-sdk' }

        // for vungle
        maven { url 'https://jitpack.io' }

        // for adcolony
        maven { url 'https://adcolony.bintray.com/AdColony' }

        // for mopub
        maven { url 'https://s3.amazonaws.com/moat-sdk-builds' }
        
        // for tapjoy
        maven { url 'https://tapjoy.bintray.com/maven' }
}

while dependencies part to your application-level build.gradle file:
dependencies {
        implementation 'com.adtiming:mediation-sdk:6.1.0@aar'

        // for admob
        implementation 'com.adtiming.adapters:admob:3.1.2@aar'
        implementation 'com.google.android.gms:play-services-ads:17.2.1'

        // for facebook
        implementation 'com.adtiming.adapters:facebook:3.2.0@aar'
        implementation 'com.facebook.android:audience-network-sdk:5.4.1'
        implementation 'com.android.support:recyclerview-v7:25.3.1'

        // for unity
        implementation 'com.adtiming.adapters:unity:3.2.2@aar'
        implementation 'com.unity3d.ads:unity-ads:3.2.0'

        // for vungle
        implementation 'com.adtiming.adapters:vungle:3.2.0@aar'
        implementation 'com.github.vungle:vungle-android-sdk:6.4.11'

        // for adcolony
        implementation 'com.adtiming.adapters:adcolony:3.1.1@aar'
        implementation 'com.adcolony:sdk:3.3.11'
        // if admob is integrated
        //implementation 'com.google.android.gms:play-services-ads:17.2.1'
        
        // for applovin
        implementation 'com.adtiming.adapters:applovin:3.1.1@aar'
        implementation 'com.applovin:applovin-sdk:9.7.2'
        
        // for mopub
        implementation 'com.adtiming.adapters:mopub:3.2.0@aar'
        implementation ('com.mopub:mopub-sdk:5.8.0@aar') {transitive = true}

        // for tapjoy
        implementation 'com.adtiming.adapters:tapjoy:3.1.1@aar'
        implementation 'com.tapjoy:tapjoy-android-sdk:12.3.1@aar'

        // for chartboost
        implementation 'com.adtiming.adapters:chartboost:3.1.2@aar'
        implementation 'com.chartboost.sdk:chartboost:7.3.1'
        implementation 'com.google.android.gms:play-services-base:16.1.0'
        implementation 'com.google.android.gms:play-services-ads-identifier:16.0.0'

        // for mintegral
        implementation 'com.adtiming.adapters:mintegral:3.0.0@aar'
        implementation 'com.mintegral.msdk:videojs:10.1.81'
        implementation 'com.mintegral.msdk:mtgjscommon:10.1.81'
        implementation 'com.mintegral.msdk:playercommon:10.1.81'
        implementation 'com.mintegral.msdk:reward:10.1.81'
        implementation 'com.mintegral.msdk:videocommon:10.1.81'
        implementation 'com.mintegral.msdk:interstitialvideo:10.1.81'
        implementation 'com.mintegral.msdk:common:10.1.81'
}

Some Ad Networks require extra steps to modify your AndroidManifest.xml to add permissions/activities/app_id. See our Help center's 'Mediation Network Guide' section for details.

Well done! You've come this far to unlock the full power of the AdTiming mediation!