Integration

This guide explains how to add the Empower Mobile Ads SDK to your Android project.

Step 1: Add the Maven Repository

Add the Empower Maven repository to your project-level settings.gradle.kts (or build.gradle(project-level) for Groovy):

// settings.gradle.kts
dependencyResolutionManagement {
repositories {
google()
mavenCentral()
maven { url = uri("https://maven.empower.net/release") }
}
}

That's it for repositories. When the SDK adds or removes a network in a future release, just bump the version above — nothing else changes.

Step 2: Add Dependencies

The SDK ships with two mediation bundles. Choose the one that matches your play-services-ads version:

Default Bundle (GMA 24.x+, minSdk 23) -- Recommended

For apps using play-services-ads version 24.0.0 or higher:

// app/build.gradle.kts
dependencies {
implementation("net.empower.mobile.ads:empower-mobile-ads:5.7.10")
implementation("net.empower.mobile.ads:empower-mobile-ads-mediation:5.7.10")
}

Legacy Bundle (GMA below 24, minSdk 21)

For apps using play-services-ads below version 24.0.0:

// app/build.gradle.kts
dependencies {
implementation("net.empower.mobile.ads:empower-mobile-ads:5.7.10")
implementation("net.empower.mobile.ads:empower-mobile-ads-mediation-legacy:5.7.10")
}

How to choose: Check your play-services-ads version. If 24.0.0 or higher, use the default bundle. If below 24.0.0 or if your app requires minSdk 21, use the legacy bundle.

Step 3: Configure Java 11 and Core Library Desugaring

The SDK is compiled with Java 11 and requires core library desugaring. Add the following to your app's build.gradle.kts:

// app/build.gradle.kts
android {
compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
isCoreLibraryDesugaringEnabled = true
}
kotlin {
jvmToolchain(11)
}
}
dependencies {
coreLibraryDesugaring("com.android.tools:desugar_jdk_libs:2.1.5")
}

Note: Java 11 is the minimum required version. If your app already uses Java 17 or higher, you can keep your existing setting — the SDK is forward-compatible.

Step 4: Configure AndroidManifest

Add your Google Ads Application ID to your AndroidManifest.xml inside the <application> tag:

<manifest>
<application>
<meta-data
android:name="com.google.android.gms.ads.APPLICATION_ID"
android:value="ca-app-pub-xxxxxxxxxxxxxxxx~yyyyyyyyyy"/>
</application>
</manifest>

Note: Replace the value with your actual Google Ads Application ID. Contact Empower support if you need assistance obtaining this ID.

Step 5: Sync Your Project

After adding the dependencies, sync your project with Gradle files:

  1. Click File > Sync Project with Gradle Files in Android Studio
  2. Wait for the sync to complete successfully

Excluding Mediation Networks

Both mediation bundles include all supported networks by default. To exclude a specific network, use Gradle's exclude mechanism:

implementation("net.empower.mobile.ads:empower-mobile-ads-mediation:5.7.5") {
exclude(group = "com.google.ads.mediation", module = "pangle")
exclude(group = "com.applovin.mediation", module = "vungle-adapter")
}

Bundled Mediation Networks

AppLovin Mediation Adapters

NetworkExclude GroupExclude Module
Googlecom.applovin.mediationgoogle-adapter
Google Ad Managercom.applovin.mediationgoogle-ad-manager-adapter
Meta / Facebook Audience Networkcom.applovin.mediationfacebook-adapter
Unity Adscom.applovin.mediationunityads-adapter
Vunglecom.applovin.mediationvungle-adapter
Pangle / ByteDancecom.applovin.mediationbytedance-adapter
Mintegralcom.applovin.mediationmintegral-adapter
InMobicom.applovin.mediationinmobi-adapter
Fyber / DT Exchangecom.applovin.mediationfyber-adapter
PubMaticcom.applovin.mediationpubmatic-adapter
Ogurycom.applovin.mediationogury-presage-adapter
Yandexcom.applovin.mediationyandex-adapter

Google AdMob Mediation Adapters

NetworkExclude GroupExclude Module
InMobicom.google.ads.mediationinmobi
Mintegralcom.google.ads.mediationmintegral
Panglecom.google.ads.mediationpangle
Unity Adscom.google.ads.mediationunity

Verification

To verify the integration is successful, build your project. You can inspect the resolved mediation dependencies with:

./gradlew :app:dependencies --configuration releaseRuntimeClasspath | grep mediation

Common Issues

IssueSolution
Dependency resolution failedMake sure the settings plugin is applied in settings.gradle.kts
minSdkVersion conflictUse empower-mobile-ads-mediation-legacy if your app has minSdk below 23
Duplicate class errorsCheck for conflicting ad network versions from other dependencies
Core library desugaring errorEnable isCoreLibraryDesugaringEnabled and add the desugaring dependency