This guide shows you how to use the Google Mobile Ads SDK to load and display ads from Pangle using AdMob Mediation, covering both waterfall and bidding integrations. It covers how to add Pangle to an ad unit's mediation configuration, and how to integrate the Pangle SDK and adapter into an Android app.
Supported integrations and ad formats
The mediation adapter for Pangle has the following capabilities:
Integration | |
---|---|
Bidding | |
Waterfall | |
Formats | |
App open | 1 |
Banner | |
Interstitial | |
Rewarded | |
Rewarded Interstitial | |
Native |
Requirements
- Android API level 21 or higher
Latest Google Mobile Ads SDK
Complete the mediation Get started guide
Step 1: Set up configurations in Pangle UI
Sign up or Log in to your Pangle account.
Add a new application
Navigate to the Applications tab and click the Add App button.
Select the Operating System you wish to create an application for and fill out the rest of the form. Then, click Submit.
Android
iOS
Take note of your application's App ID.
Android
iOS
Create an ad placement
Once your application has been created, click the Add button to create your ad placement.
Android
iOS
Bidding
Select your Ad Format and Ad Placement Name, and select In-App Bidding as the Pricing Type. Fill out the rest of the form and click Submit.
Once your ad placement is created, take note of the Ad Placement ID.
Android
iOS
Waterfall
Select your Ad Format and Ad Placement Name, and Global CPM as the Pricing Type. Fill out the rest of the form and click Submit.
Once your ad placement is created, take note of the Ad Placement ID.
Android
iOS
Locate Pangle Reporting API key
Bidding
This step isn't required for bidding integrations.
Waterfall
Take note of the User ID at the bottom left corner of the page.
Click Integrations > SDK & API > Pangle Reporting API 2.0. Take note of Role ID and Security Key.
Turn on test mode
Follow the instructions in Pangle's How to add a Test Ad guide on how to enable Pangle test ads.
Step 2: Set up Pangle demand in AdMob UI
Định cấu hình cài đặt dàn xếp cho đơn vị quảng cáo của bạn
Bạn cần thêm Pangle vào cấu hình dàn xếp cho đơn vị quảng cáo của mình.
Trước tiên, hãy đăng nhập vào tài khoản AdMob của bạn. Tiếp theo, hãy chuyển đến thẻ Dàn xếp. Nếu bạn đang có một nhóm dàn xếp mà bạn muốn sửa đổi, hãy nhấp vào tên của nhóm dàn xếp đó để chỉnh sửa rồi chuyển đến mục Thêm Pangle dưới dạng nguồn quảng cáo.
Để tạo một nhóm dàn xếp mới, hãy chọn Tạo nhóm dàn xếp.
Nhập định dạng quảng cáo và nền tảng quảng cáo của bạn, rồi nhấp vào Tiếp tục.
Đặt tên cho nhóm dàn xếp của bạn và chọn các vị trí để nhắm mục tiêu. Tiếp theo, hãy đặt trạng thái của nhóm dàn xếp thành Đã bật, rồi nhấp vào Thêm đơn vị quảng cáo.
Liên kết nhóm dàn xếp này với một hoặc nhiều đơn vị quảng cáo AdMob hiện có. Sau đó, hãy nhấp vào Xong.
Bây giờ, bạn sẽ thấy thẻ đơn vị quảng cáo được điền sẵn các đơn vị quảng cáo mà bạn đã chọn:
Thêm Pangle làm nguồn quảng cáo
Đặt giá thầu
Trong thẻ Đặt giá thầu trong phần Nguồn quảng cáo, hãy chọn Thêm Nguồn quảng cáo. Sau đó, hãy chọn biểu tượng Pangle.
Nhấp vào Cách ký thoả thuận hợp tác và thiết lập tính năng đặt giá thầu hợp tác với Pangle.
Nhấp vào Xác nhận và đồng ý, sau đó nhấp vào Tiếp tục.
Nếu bạn đã có bản đồ cho Pangle, bạn có thể chọn. Nếu không, hãy nhấp vào Thêm mối liên kết.
Tiếp theo, hãy nhập App ID and Ad Placement ID có được ở phần trước. Sau đó, hãy nhấp vào Xong.
Thác nước
Trong thẻ Thác nước trong mục Nguồn quảng cáo, hãy chọn Thêm nguồn quảng cáo. Sau đó, hãy chọn Pangle.
Chọn Pangle. Sau đó, hãy nhập giá trị eCPM cho Pangle rồi nhấp vào Tiếp tục.Nếu đã có mối liên kết cho Pangle, bạn có thể chọn mối liên kết đó. Nếu không, hãy nhấp vào Thêm mối liên kết.
Tiếp theo, hãy nhập App ID and Ad Placement ID nhận được trong phần trước. Sau đó, hãy nhấp vào Xong.
Step 3: Import the Pangle SDK and adapter
Android Studio integration (recommended)
In your project-level settings.gradle.kts
file, add the following
repositories:
dependencyResolutionManagement {
repositories {
google()
mavenCentral()
maven {
url = uri("https://artifact.bytedance.com/repository/pangle/")
}
}
}
Then, in your app-level build.gradle.kts
file, add the following
implementation dependencies and configurations. Use the latest versions of the
Pangle SDK and adapter:
dependencies {
implementation("com.google.android.gms:play-services-ads:23.3.0")
implementation("com.google.ads.mediation:pangle:6.2.0.6.0")
}
Manual integration
Download the latest version of the Pangle SDK for Android and extract the
open_ad_sdk.aar
under from the downloaded archive folder and add it to your project.Navigate to the Pangle adapter artifacts on Google's Maven Repository. Select the latest version, download the Pangle adapter's
.aar
file, and add it to your project.
Step 4: Add required code
ProGuard obfuscation
If you use ProGuard to obfuscate Android code, follow the instructions in Pangle's documentation to ensure Pangle SDK code isn't obfuscated.
Step 5: Test your implementation
Bật quảng cáo thử nghiệm
Hãy nhớ đăng ký thiết bị thử nghiệm cho AdMob và bật chế độ thử nghiệm trong Pangle giao diện người dùng.
Xác minh quảng cáo thử nghiệm
Để xác minh rằng bạn đang nhận quảng cáo thử nghiệm từ Pangle, hãy bật thử nghiệm riêng một nguồn quảng cáo trong công cụ kiểm tra quảng cáo bằng cách sử dụng Pangle (Bidding) and Pangle (Waterfall) (các) nguồn quảng cáo.
Optional Steps
Native ads
Ad rendering
The Pangle adapter returns its native ads as
NativeAd
objects. It populates the following
fields
for a
NativeAd
.
Field | Assets always included by Pangle adapter |
---|---|
Headline | |
Image | 1 |
Body | |
Icon | |
Call to action | |
Star rating | |
Store | |
Price | |
Advertiser |
1 The Pangle adapter does not
provide direct access to the main image asset for its native ads. Instead, the
adapter populates the
MediaView
with a video or an image.
Error codes
If the adapter fails to receive an ad from Pangle, you can check the
underlying error from the ad response using
ResponseInfo.getAdapterResponses()
under the following classes:
com.pangle.ads
com.google.ads.mediation.pangle.PangleMediationAdapter
Here are the codes and accompanying messages thrown by the Pangle adapter when an ad fails to load:
Error code | Domain | Reason |
---|---|---|
101 | com.google.ads.mediation.pangle | Invalid server parameters (e.g. Missing app ID or placement ID). |
102 | com.google.ads.mediation.pangle | The requested ad size does not match a Pangle supported banner size. |
103 | com.google.ads.mediation.pangle | Missing or invalid bid response. |
-1-60000 | com.pangle.ads | Pangle SDK returned an error. See Pangle's documentation for more details. |
Pangle Android Mediation Adapter Changelog
Version 6.2.0.6.0
- Verified compatibility with Pangle SDK version 6.2.0.6.
Built and tested with:
- Google Mobile Ads SDK version 23.3.0.
- Pangle SDK version 6.2.0.6.
Version 6.2.0.5.0
- Verified compatibility with Pangle SDK version 6.2.0.5.
Built and tested with:
- Google Mobile Ads SDK version 23.3.0.
- Pangle SDK version 6.2.0.5.
Version 6.2.0.4.0
- Verified compatibility with Pangle SDK version 6.2.0.4.
Built and tested with:
- Google Mobile Ads SDK version 23.3.0.
- Pangle SDK version 6.2.0.4.
Version 6.1.0.9.0
- Verified compatibility with Pangle SDK version 6.1.0.9.
Built and tested with:
- Google Mobile Ads SDK version 23.2.0.
- Pangle SDK version 6.1.0.9.
Version 6.1.0.7.0
- Verified compatibility with Pangle SDK version 6.1.0.7.
Built and tested with:
- Google Mobile Ads SDK version 23.2.0.
- Pangle SDK version 6.1.0.7.
Version 6.1.0.6.0
- Verified compatibility with Pangle SDK version 6.1.0.6.
Built and tested with:
- Google Mobile Ads SDK version 23.2.0.
- Pangle SDK version 6.1.0.6.
Version 6.0.0.8.0
- Verified compatibility with Pangle SDK version 6.0.0.8.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 6.0.0.8.
Version 6.0.0.7.0
- Verified compatibility with Pangle SDK version 6.0.0.7.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 6.0.0.7.
Version 6.0.0.5.0
- Verified compatibility with Pangle SDK version 6.0.0.5.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 6.0.0.5.
Version 6.0.0.4.0
- Verified compatibility with Pangle SDK version 6.0.0.4.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 6.0.0.4.
Version 6.0.0.3.0
- Verified compatibility with Pangle SDK version 6.0.0.3.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 6.0.0.3.
Version 5.9.0.6.0
- Verified compatibility with Pangle SDK version 5.9.0.6.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 5.9.0.6.
Version 5.9.0.5.0
- Verified compatibility with Pangle SDK version 5.9.0.5.
Built and tested with:
- Google Mobile Ads SDK version 23.1.0.
- Pangle SDK version 5.9.0.5.
Version 5.9.0.4.0
- Verified compatibility with Pangle SDK version 5.9.0.4.
Built and tested with:
- Google Mobile Ads SDK version 23.0.0.
- Pangle SDK version 5.9.0.4.
Version 5.9.0.2.0
- Verified compatibility with Pangle SDK version 5.9.0.2.
Built and tested with:
- Google Mobile Ads SDK version 23.0.0.
- Pangle SDK version 5.9.0.2.
Version 5.8.1.0.0
- Verified compatibility with Pangle SDK version 5.8.1.0.
Built and tested with:
- Google Mobile Ads SDK version 23.0.0.
- Pangle SDK version 5.8.1.0.
Version 5.8.0.9.0
- Verified compatibility with Pangle SDK version 5.8.0.9.
- Updated the minimum required Google Mobile Ads SDK version to 23.0.0.
Built and tested with:
- Google Mobile Ads SDK version 23.0.0.
- Pangle SDK version 5.8.0.9.
Version 5.8.0.7.0
- Verified compatibility with Pangle SDK version 5.8.0.7.
Built and tested with:
- Google Mobile Ads SDK version 22.6.0.
- Pangle SDK version 5.8.0.7.
Version 5.8.0.6.0
- Verified compatibility with Pangle SDK version 5.8.0.6.
Built and tested with:
- Google Mobile Ads SDK version 22.6.0.
- Pangle SDK version 5.8.0.6.
Version 5.7.0.3.0
- Verified compatibility with Pangle SDK version 5.7.0.3.
Built and tested with:
- Google Mobile Ads SDK version 22.6.0.
- Pangle SDK version 5.7.0.3.
Version 5.7.0.2.0
- Verified compatibility with Pangle SDK version 5.7.0.2.
Built and tested with:
- Google Mobile Ads SDK version 22.6.0.
- Pangle SDK version 5.7.0.2.
Version 5.7.0.1.0
- Verified compatibility with Pangle SDK version 5.7.0.1.
Built and tested with:
- Google Mobile Ads SDK version 22.6.0.
- Pangle SDK version 5.7.0.1.
Version 5.6.0.3.0
- Verified compatibility with Pangle SDK version 5.6.0.3.
- Updated the minimum required Google Mobile Ads SDK version to 22.6.0.
Built and tested with:
- Google Mobile Ads SDK version 22.6.0.
- Pangle SDK version 5.6.0.3.
Version 5.5.0.9.0
- Updated the minimum required Google Mobile Ads SDK version to 22.5.0.
- Verified compatibility with Pangle SDK version 5.5.0.9.
Built and tested with:
- Google Mobile Ads SDK version 22.5.0.
- Pangle SDK version 5.5.0.9.
Version 5.5.0.8.0
- Verified compatibility with Pangle SDK version 5.5.0.8.
Built and tested with:
- Google Mobile Ads SDK version 22.3.0.
- Pangle SDK version 5.5.0.8.
Version 5.5.0.7.0
- Verified compatibility with Pangle SDK version 5.5.0.7.
Built and tested with:
- Google Mobile Ads SDK version 22.3.0.
- Pangle SDK version 5.5.0.7.
Version 5.5.0.6.0
- Bidding app open ad format isn't supported in this version as this adapter version was reverted to depend on Google Mobile Ads SDK version 22.3.0.
- Verified compatibility with Pangle SDK version 5.5.0.6.
Built and tested with:
- Google Mobile Ads SDK version 22.3.0.
- Pangle SDK version 5.5.0.6.
Version 5.5.0.4.0
- Added bidding support for app open ad format.
- Added watermark support for bidding ads.
- Updated the minimum required Google Mobile Ads SDK version to 22.4.0.
- Verified compatibility with Pangle SDK version 5.5.0.4.
Built and tested with:
- Google Mobile Ads SDK version 22.4.0.
- Pangle SDK version 5.5.0.4.
Version 5.4.1.1.0
- Fixed an issue where the adapter fails to initialize.
- Verified compatibility with Pangle SDK version 5.4.1.1.
Built and tested with:
- Google Mobile Ads SDK version 22.3.0.
- Pangle SDK version 5.4.1.1.
Version 5.4.0.9.0
- Verified compatibility with Pangle SDK version 5.4.0.9.
- Updated the minimum required Google Mobile Ads SDK version to 22.3.0.
Built and tested with:
- Google Mobile Ads SDK version 22.3.0.
- Pangle SDK version 5.4.0.9.
Version 5.4.0.8.0
- Verified compatibility with Pangle SDK version 5.4.0.8.
Built and tested with:
- Google Mobile Ads SDK version 22.2.0.
- Pangle SDK version 5.4.0.8.
Version 5.3.0.6.0
- Verified compatibility with Pangle SDK version 5.3.0.6.
Built and tested with:
- Google Mobile Ads SDK version 22.2.0.
- Pangle SDK version 5.3.0.6.
Version 5.3.0.5.0
- Verified compatibility with Pangle SDK version 5.3.0.5.
Built and tested with:
- Google Mobile Ads SDK version 22.2.0.
- Pangle SDK version 5.3.0.5.
Version 5.3.0.4.0
- Verified compatibility with Pangle SDK version 5.3.0.4.
Built and tested with:
- Google Mobile Ads SDK version 22.2.0.
- Pangle SDK version 5.3.0.4.
Version 5.2.0.7.0
- Verified compatibility with Pangle SDK version 5.2.0.7.
Built and tested with:
- Google Mobile Ads SDK version 22.1.0.
- Pangle SDK version 5.2.0.7.
Version 5.2.0.6.0
- Verified compatibility with Pangle SDK version 5.2.0.6.
Built and tested with:
- Google Mobile Ads SDK version 22.1.0.
- Pangle SDK version 5.2.0.6.
Version 5.2.0.5.0
- Verified compatibility with Pangle SDK version 5.2.0.5.
Built and tested with:
- Google Mobile Ads SDK version 22.1.0.
- Pangle SDK version 5.2.0.5.
Version 5.2.0.3.0
- Added waterfall support for app open, banner (includes MREC), interstitial, rewarded and native ad formats.
- Verified compatibility with Pangle SDK version 5.2.0.3.
Built and tested with:
- Google Mobile Ads SDK version 22.0.0.
- Pangle SDK version 5.2.0.3.
Version 5.1.0.9.0
- Verified compatibility with Pangle SDK version 5.1.0.9.
Built and tested with:
- Google Mobile Ads SDK version 22.0.0.
- Pangle SDK version 5.1.0.9.
Version 5.1.0.8.0
- Verified compatibility with Pangle SDK version 5.1.0.8.
Built and tested with:
- Google Mobile Ads SDK version 22.0.0.
- Pangle SDK version 5.1.0.8.
Version 5.1.0.6.0
- Updated adapter to use new
VersionInfo
class. - Updated the minimum required Google Mobile Ads SDK version to 22.0.0.
Built and tested with:
- Google Mobile Ads SDK version 22.0.0.
- Pangle SDK version 5.1.0.6.
Version 5.0.1.1.0
- Verified compatibility with Pangle SDK version 5.0.1.1.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 5.0.1.1.
Version 5.0.1.0.0
- Verified compatibility with Pangle SDK version 5.0.1.0.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 5.0.1.0.
Version 5.0.0.9.0
- Verified compatibility with Pangle SDK version 5.0.0.9.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 5.0.0.9.
Version 5.0.0.8.0
- Verified compatibility with Pangle SDK version 5.0.0.8.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 5.0.0.8.
Version 5.0.0.7.0
- Verified compatibility with Pangle SDK version 5.0.0.7.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 5.0.0.7.
Version 5.0.0.6.0
- Verified compatibility with Pangle SDK version 5.0.0.6.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 5.0.0.6.
Version 4.9.0.9.0
- Verified compatibility with Pangle SDK version 4.9.0.9.
- Updated the minimum required Google Mobile Ads SDK version to 21.5.0.
Built and tested with:
- Google Mobile Ads SDK version 21.5.0.
- Pangle SDK version 4.9.0.9.
Version 4.9.0.8.0
- Verified compatibility with Pangle SDK version 4.9.0.8.
Built and tested with:
- Google Mobile Ads SDK version 21.4.0.
- Pangle SDK version 4.9.0.8.
Version 4.9.0.7.0
- Verified compatibility with Pangle SDK version 4.9.0.7.
Built and tested with:
- Google Mobile Ads SDK version 21.4.0.
- Pangle SDK version 4.9.0.7.
Version 4.9.0.6.0
- Verified compatibility with Pangle SDK version 4.9.0.6.
Built and tested with:
- Google Mobile Ads SDK version 21.4.0.
- Pangle SDK version 4.9.0.6.
Version 4.8.1.0.0
- Verified compatibility with Pangle SDK version 4.8.1.0.
- Updated the minimum required Google Mobile Ads SDK version to 21.4.0.
Built and tested with:
- Google Mobile Ads SDK version 21.4.0.
- Pangle SDK version 4.8.1.0.
Version 4.8.0.9.0
- Verified compatibility with Pangle SDK version 4.8.0.9.
Built and tested with:
- Google Mobile Ads SDK version 21.3.0.
- Pangle SDK version 4.8.0.9.
Version 4.8.0.8.0
- Verified compatibility with Pangle SDK version 4.8.0.8.
Built and tested with:
- Google Mobile Ads SDK version 21.3.0.
- Pangle SDK version 4.8.0.8.
Version 4.8.0.7.0
- Verified compatibility with Pangle SDK version 4.8.0.7.
Built and tested with:
- Google Mobile Ads SDK version 21.3.0.
- Pangle SDK version 4.8.0.7.
Version 4.8.0.6.0
- Verified compatibility with Pangle SDK version 4.8.0.6.
Built and tested with:
- Google Mobile Ads SDK version 21.3.0.
- Pangle SDK version 4.8.0.6.
Version 4.7.0.7.0
- Verified compatibility with Pangle SDK version 4.7.0.7.
- Updated the minimum required Google Mobile Ads SDK version to 21.3.0.
Built and tested with:
- Google Mobile Ads SDK version 21.3.0.
- Pangle SDK version 4.7.0.7.
Version 4.7.0.6.0
- Verified compatibility with Pangle SDK version 4.7.0.6.
Built and tested with:
- Google Mobile Ads SDK version 21.2.0.
- Pangle SDK version 4.7.0.6.
Version 4.7.0.5.0
- Verified compatibility with Pangle SDK version 4.7.0.5.
Built and tested with:
- Google Mobile Ads SDK version 21.2.0.
- Pangle SDK version 4.7.0.5.
Version 4.7.0.3.0
- Verified compatibility with Pangle SDK version 4.7.0.3.
- The adapter now attempts to initialize the Pangle SDK before loading ads.
Built and tested with:
- Google Mobile Ads SDK version 21.2.0.
- Pangle SDK version 4.7.0.3.
Version 4.6.0.9.0
- Verified compatibility with Pangle SDK version 4.6.0.9.
- Updated the minimum required Google Mobile Ads SDK version to 21.2.0.
Built and tested with:
- Google Mobile Ads SDK version 21.2.0.
- Pangle SDK version 4.6.0.9.
Version 4.5.0.6.1
- Added bidding support for native ad format.
- Updated the minimum required Google Mobile Ads SDK version to 21.1.0.
Built and tested with:
- Google Mobile Ads SDK version 21.1.0.
- Pangle SDK version 4.5.0.6.
Version 4.5.0.6.0
- Verified compatibility with Pangle SDK version 4.5.0.6.
Built and tested with:
- Google Mobile Ads SDK version 21.0.0.
- Pangle SDK version 4.5.0.6.
Version 4.5.0.5.0
- Verified compatibility with Pangle SDK version 4.5.0.5.
Built and tested with:
- Google Mobile Ads SDK version 21.0.0.
- Pangle SDK version 4.5.0.5.
Version 4.5.0.4.0
- Verified compatibility with Pangle SDK version 4.5.0.4.
Built and tested with:
- Google Mobile Ads SDK version 21.0.0.
- Pangle SDK version 4.5.0.4.
Version 4.5.0.3.0
- Verified compatibility with Pangle SDK version 4.5.0.3.
- Updated
compileSdkVersion
andtargetSdkVersion
to API 31. - Updated the minimum required Google Mobile Ads SDK version to 21.0.0.
- Updated the minimum required Android API level to 19.
Built and tested with:
- Google Mobile Ads SDK version 21.0.0.
- Pangle SDK version 4.5.0.3.
Version 4.3.0.9.0
- Verified compatibility with Pangle SDK version 4.3.0.9.
Built and tested with:
- Google Mobile Ads SDK version 20.6.0.
- Pangle SDK version 4.3.0.9.
Version 4.3.0.8.0
- Verified compatibility with Pangle SDK version 4.3.0.8.
Built and tested with:
- Google Mobile Ads SDK version 20.6.0.
- Pangle SDK version 4.3.0.8.
Version 4.3.0.7.0
- Verified compatibility with Pangle SDK version 4.3.0.7.
Built and tested with:
- Google Mobile Ads SDK version 20.6.0.
- Pangle SDK version 4.3.0.7.
Version 4.3.0.6.0
- Verified compatibility with Pangle SDK version 4.3.0.6.
Built and tested with:
- Google Mobile Ads SDK version 20.6.0.
- Pangle SDK version 4.3.0.6.
Version 4.3.0.4.0
- Verified compatibility with Pangle SDK version 4.3.0.4.
Built and tested with:
- Google Mobile Ads SDK version 20.6.0.
- Pangle SDK version 4.3.0.4.
Version 4.2.5.3.0
- Initial release!
- Added bidding support for banner (includes MREC), interstitial and rewarded ad formats.
Built and tested with:
- Google Mobile Ads SDK version 20.6.0.
- Pangle SDK version 4.2.5.3.