AdMob Adapter
This guide covers the integration of Boldwin SDK through Google AdMob mediation. The Boldwin SDK supports the following ad formats:
- Banner
- MREC
- Interstitial
- Rewarded
AdMob Mediation Integration
For detailed AdMob mediation setup instructions, see the official AdMob mediation documentation.
Android Setup
Add Boldwin SDK to your app
Follow the integration guide.
Add to your app's build.gradle:
dependencies {
// Boldwin SDK
implementation 'com.boldwin.sdk:core:1.15.15'
// AdMob Boldwin Adapter
implementation 'com.boldwin.sdk:admob-adapters:1.15.15'
}
Configure Boldwin as a Custom Event
Boldwin integrates with AdMob mediation as a custom event.
- Log in to your AdMob dashboard.
- Go to Mediation and click Create mediation group.
- Select the ad format and Android as the platform, then click Continue.
- Name the group, set the eCPM and select the ad units to mediate.
- Under Ad sources, click Add custom event.

Configure Boldwin For Ad Units
- Enter a Label (for example
Boldwin) and the eCPM. - Set Class Name to
com.google.ads.mediation.boldwin.BoldwinMediationAdapter. - Set Parameter to the Boldwin configuration JSON (see below).
- Map the custom event to your ad units and save.

Example of the Parameter value:
{
"placement_id": "<YOUR_PLACEMENT_ID>",
"publisher_id": "<YOUR_PUBLISHER_ID>",
"ad_sizes": [
{
"w": <WIDTH>,
"h": <HEIGHT>
}
]
}
The parameter includes the following keys:
placement_id- The Boldwin placement ID. Required.publisher_id- The Boldwin publisher ID. Optional. Used only to initialize the Boldwin SDK when your app has not initialized it already.ad_sizes- An array of ad sizes. You can set multiple sizes. Required for banner and MREC ad formats. When omitted, the size of the AdMob ad unit is used. For interstitial and rewarded ads, sizes can be omitted.
Example of an ad_sizes value requesting both a 320x50 banner and a 300x250 MREC: