AdConfig

constructor(appIds: AdAppIds, globalRequestConfiguration: GlobalRequestConfiguration = GlobalRequestConfiguration(), debugOptions: AdDebugOptions = AdDebugOptions(), consentTagForUnderAgeOfConsent: Boolean = false, initializationHooks: List<AdInitializationHook> = emptyList())(source)


constructor(androidAppId: String, iosAppId: String, testMode: Boolean = false, testDeviceIds: List<String> = emptyList(), debugGeography: ConsentDebugGeography = ConsentDebugGeography.Disabled, ageRestrictedTreatment: AgeRestrictedTreatment = AgeRestrictedTreatment.Unspecified, consentTagForUnderAgeOfConsent: Boolean = false, initializationHooks: List<AdInitializationHook> = emptyList())(source)

Convenience secondary constructor that accepts platform app IDs directly and derives AdAppIds, GlobalRequestConfiguration, and AdDebugOptions.

Parameters

androidAppId

Android AdMob app ID.

iosAppId

iOS AdMob app ID.

testMode

Enables UMP debug consent settings. Does not force GMA to serve test ads on its own — see AdDebugOptions.testMode and testDeviceIds.

testDeviceIds

Device IDs registered as GMA test devices; this is what actually forces test ads for a physical device (emulators/simulators qualify automatically).

debugGeography

Force UMP debug geography.

ageRestrictedTreatment

Age treatment applied to GMA ad requests.

consentTagForUnderAgeOfConsent

UMP-only under-age-of-consent tag.

initializationHooks

Hooks invoked during initialization phases.