Configure Mediation
TestMode
π
The Chartboost Mediation Unity SDK includes a Test Mode method that will allow you to test your partner integrations and get their test ads. To enable Test Mode, simply set the following method to true
after starting the SDK. Remember to remove it or set the method to false
before releasing your app.
ChartboostMediation.TestMode = true;
// or
ChartboostMediation.TestMode = false;
LogLevel
π
Sets the log level. Anything of that log level and lower will be emitted. Set this to LogLevel.Disabled
for no logs.
// No Logs
ChartboostMediation.LogLevel = LogLevel.Disable;
// All Logs
ChartboostMediation.LogLevel = LogLevel.Verbose;
DiscardOverSizedAds
π
A bool
value indicating that ads returned from adapters that are larger than the requested size should be discarded. An ad is defined as too large if either the width or height of the resulting ad is larger than the requested ad size unless the height of the requested ad size is 0, as is the case when using BannerSizeType.Adaptive
, in which an error will be returned. This currently only applies to IBannerAd
. Defaults to false
.
ChartboostMediation.DiscardOverSizedAds = true;
// or
ChartboostMediation.DiscardOverSizedAds = false;
AdaptersInfo
π
An array of all initialized adapters, or an empty array if the SDK is not initialized.
Debug.Log($"Printing Adapter Info: {JsonConvert.SerializeObject(ChartboostMediation.AdaptersInfo, Formatting.Indented)}");
Callbacks π
DidReceiveImpressionLevelRevenueData
π
Event for receiving ILRD (Impression Level Revenue Data) events.
ChartboostMediation.DidReceiveImpressionLevelRevenueData += (placement, impressionData) => Debug.Log($"Received ILRD for: {placement}, ILRD: {JsonTools.SerializeObject(impressionData, Formatting.Indented)}");
DidReceivePartnerAdapterInitializationData
π
Event for receiving partner initialization result events.
ChartboostMediation.DidReceivePartnerAdapterInitializationData += partnerInitializationData => Debug.Log($"Received Partner Initialization Data {JsonTools.SerializeObject(partnerInitializationData, Formatting.Indented)}");