Skip to main content
An Ad Unit defines an ad placement and format in your app. For the DARO 2.0.1 SDK, copy the Ad Unit Key from the updated dashboard. This is different from the app’s Integration Key. API parameters such as adUnitId, unitId, and key, and example placeholders such as YOUR_AD_UNIT_ID, keep their names but take that Ad Unit’s Ad Unit Key. Existing integrations using Ad Unit IDs remain supported. Do not confuse reporting or callback identifiers with the key for a new integration.

Before You Begin

Check requirements before integration.

Requirements

  • Android minSdkVersion: 23
Verify app-ads.txt setup before proceeding.
Desugaring required: Configure desugaring if minSdk is below 26.

Upgrading From an Earlier Version

Follow the Android migration guide to update the dashboard and remove legacy key files and app key settings first. Then integrate the DARO 2.0.1 SDK in the order below.

Configure Your App

1

Project-level build configuration

  • Add the repositories below to settings.gradle.kts (Kotlin DSL) or settings.gradle (Groovy DSL) in the project root.
  • If dependencyResolutionManagement already exists, add the repositories to its repositories block.
2

Add the DARO plugin to build.gradle(root)

Add the DARO plugin to your build.gradle(root) file.
Latest version
  • daro-plugin : 2.0.0
3

Apply the DARO plugin to build.gradle(app)

Apply the DARO plugin in build.gradle(app).
4

Declare DARO_INTEGRATION_KEY in AndroidManifest.xml

Declare the Integration Key inside <application> in your app module’s src/main/AndroidManifest.xml.
The Integration Key is issued per app and can be obtained from the DARO dashboard.
This example uses the same dashboard app for every build variant. Enter that app’s Integration Key as a literal value in the app module’s src/main/AndroidManifest.xml. When setting DARO_INTEGRATION_KEY in the manifest, enter the actual key value instead of a ${...} placeholder.
5

Update app-ads.txt

Follow the app-ads.txt guide and publish the latest content provided by the dashboard.
6

Add DARO SDK

Add the DARO SDK.
Latest version
  • daro-sdk : 2.0.1
  • daro-sdk provides Compose components, including DaroBanner and DaroNative, in the droom.daro.compose package.
  • For a new integration, use these components without a separate daro-compose-util dependency. Your app needs Compose runtime 1.7.0 or later.
  • If you previously used so.daro:daro-compose-util, remove that dependency and use the Compose components provided by daro-sdk. You can keep your existing imports.
The SDK includes consumer obfuscation rules that Gradle applies automatically. You do not need to copy them into your project.

Initialize SDK

Important: Load Ads After Initialization
  • Initialize DARO SDK before loading ads by calling Daro.init().
  • Requesting ads before initialization may prevent proper display.
setDebugMode(true) is for test builds only. Always set it to false in production builds.

App Mute Setting

For app open, banner, interstitial, rewarded, rewarded interstitial, and native ad formats, you can use the setAppMuted(...) method to inform the DARO SDK that the app volume has been muted.
Native ads apply the mute state to video playback at load time, so call setAppMuted before loading native ads.
App Mute Usage PrecautionsWhen app mute is enabled, some video ad creatives that cannot play while muted may be excluded from ad requests, which can slightly reduce the ad pool and affect revenue.