Integrate maio with mediation

本指南介绍了如何使用 Google 移动广告 SDK 通过中介(涵盖广告瀑布流集成)加载和展示来自 maio 的广告。其中介绍了如何将 maio 添加到广告单元的中介配置中,以及如何将 maio SDK 和适配器集成到 Unity 应用中。

maio 的信息中心界面使用日语文本作为标签、按钮和说明,本指南中的屏幕截图尚未翻译。不过,在本文的说明和说明中,标签和按钮由对应的英语版本指代。例如,“网址 被称为“网址架构”等等。

支持的集成和广告格式

适用于 maio 的中介适配器具有以下功能:

集成
出价
瀑布
表现形式
横幅
插页式广告
已奖励

要求

  • Unity 4 或更高版本
  • 最新版 Google 移动广告 SDK
  • 在 Android 上部署
    • Android API 级别 21 或更高级别
  • 在 iOS 上部署
    • iOS 部署目标为 12.0 或更高版本
  • 使用 Google 移动广告 SDK 配置的有效 Unity 项目。如需了解详情,请参阅开始使用
  • 看完中介服务入门指南

第 1 步:在 maio 界面中设置配置

First, sign up or log in to your maio account. Click the Application management button on the left sidebar and click on New app.

Select the tab corresponding to your preferred Ad Type.

Interstitial

Enter the Name of your app, select the platform and provide your App URL. Select Video interstitial as the Ad Type, and then click Update.

Android

iOS

Rewarded

Enter the Name of your app, select the platform and provide your App URL. Select Video Rewards as the Ad Type, and then click Update.

Android

iOS

In the Application Management page, make a note of the Media ID. It's needed to set up your AdMob ad unit in the next section.

Android

iOS

In the Zone Management page, make a note of the Zone ID. It will also be needed to set up your AdMob ad unit in the next section.

Android

iOS

(Waterfall only) In addition to Media ID and Zone ID, you will need API ID and API KEY to set up your ad unit ID for mediation. In Reporting API page, make a note of API ID and API KEY.

第 2 步:在界面中设置 maio 需求 AdMob

Configure mediation settings for your ad unit

Android

For instructions, see step 2 in the guide for Android.

iOS

For instructions, see step 2 in the guide for iOS.

第 3 步:导入 maio SDK 和适配器

通过 maio 更新日志中的下载链接下载适用于 maio 的最新版 Google 移动广告中介插件,然后从 zip 文件中提取 GoogleMobileAdsMaioMediation.unitypackage

在 Unity 项目编辑器中,依次选择 Assets > Import Package > Custom Package,然后找到您下载的 GoogleMobileAdsMaioMediation.unitypackage 文件。确保选择所有文件,然后点击 Import(导入)。

然后,依次选择 Assets > Play Services Resolver > Android Resolver > Force Resolve。Unity Play Services Resolver 库将从头开始执行依赖项解析,并将声明的依赖项复制到 Unity 应用的 Assets/Plugins/Android 目录中。

第 4 步:添加所需的代码

Android

无需其他代码即可进行 maio 集成。

iOS

SKAdNetwork 集成

按照 maio 的文档中的说明将 SKAdNetwork 标识符添加到您项目的 Info.plist 文件中。

第 5 步:测试实现效果

Enable test ads

Make sure you register your test device for AdMob.

Publishers using version 7.26.0 or higher of the Google Mobile Ads SDK will automatically receive test ads from maio on phones and tablets registered as test devices when making requests.

Verify test ads

To verify that you are receiving test ads from maio, enable single ad source testing in ad inspector using the maio (Waterfall) ad source(s).

错误代码

如果适配器未能接收来自 maio 的广告,发布商可以使用以下类下的 ResponseInfo 检查广告响应中的底层错误:

Android

格式 类名称
插页式广告 jp.maio.sdk.android.mediation.admob.adapter.Interstitial
已奖励 jp.maio.sdk.android.mediation.admob.adapter.Rewarded

iOS

格式 类名称
插页式广告 GADMMaioInterstitialAdapter
已奖励 GADMMaioRewardedAdapter

当广告加载失败时,maio 适配器会抛出以下代码和随附的消息:

Android

错误代码 原因
0-10 maio 返回了与 SDK 相关的错误。如需了解详情,请参阅代码和 maio 的文档
101 Maio 没有可投放的广告。
102 服务器参数无效(例如,缺少展示位置 ID)。
103 用于加载广告的上下文不是 `Activity` 实例。

iOS

错误代码 原因
0-10 maio 返回了与 SDK 相关的错误。如需了解详情,请参阅 maio 的代码
101 maio 还没有可投放的广告。
102 服务器参数无效(例如,缺少展示位置 ID)。
103 maio 适配器不支持所请求的广告格式。
104 已加载此广告联盟配置的广告。

maio Unity 中介插件更新日志

版本 2.0.3

版本 2.0.2

版本 2.0.1

版本 2.0.0

版本 1.4.3

版本 1.4.2

版本 1.4.1

版本 1.4.0

版本 1.3.6

版本 1.3.5

版本 1.3.4

版本 1.3.3

版本 1.3.2

版本 1.3.1

版本 1.3.0

版本 1.2.3

  • 更新了插件以支持新的激励广告 API。
  • 支持 maio Android 适配器版本 1.1.7.0。
  • 支持 maio iOS 适配器版本 1.4.6.0。

版本 1.2.2

  • 支持 maio Android 适配器版本 1.1.6.0。
  • 支持 maio iOS 适配器版本 1.4.2.0。

版本 1.2.1

  • 支持 maio Android 适配器版本 1.1.6.0。
  • 支持 maio iOS 适配器版本 1.4.1.0。

版本 1.2.0

  • 支持 maio Android 适配器版本 1.1.4.1。
  • 支持 maio iOS 适配器版本 1.4.0.0。

版本 1.1.3

  • 支持 maio Android 适配器版本 1.1.3.1。
  • 支持 maio iOS 适配器版本 1.3.2.0。

版本 1.1.2

  • 支持 maio Android 适配器版本 1.1.3.0。
  • 支持 maio iOS 适配器版本 1.3.2.0。

版本 1.1.1

  • 支持 maio Android 适配器版本 1.1.1.0。
  • 支持 maio iOS 适配器版本 1.3.1.1。

版本 1.1.0

  • 支持 maio Android 适配器版本 1.1.0.0。
  • 支持 maio iOS 适配器版本 1.3.0.0。

版本 1.0.2

  • 支持 maio Android SDK 1.0.8 版。
  • 支持 maio iOS SDK 1.2.19 版。

版本 1.0.1

  • 支持 maio Android SDK 1.0.7 版。
  • 支持 maio iOS SDK 1.2.19 版。

版本 1.0.0

  • 第一个版本!
  • 支持 maio Android SDK 1.0.6 版。
  • 支持 maio iOS SDK 1.2.18 版。