Rewarded Ads - cleveradssolutions/CAS-Android Wiki

:zap: Before you start
Make sure you have correctly Initialize SDK.

This guide explains how to integrate rewarded video ads into an Android app.

Load an ad

Manual load Rewarded ads.
By default, the auto-load ads mode is used and a load method does not need to be called.
If you use LoadingManagerMode.Manual then please call load before each show ad.


You can get a callback for the successful loading of the ads:

manager.getOnAdLoadEvent.Add(new AdLoadCallback(){...});

Check the ad availability

You can ask for the ad availability directly by calling the following function:

boolean adLoaded = manager.isAdReady(AdType.Rewarded);

Show the ad

Before displaying a rewarded ad to users, you must present the user with an explicit choice to view rewarded ad content in exchange for a reward. Rewarded ads must always be an opt-in experience.

The showRewardedAd() method requires Activity and AdCallback instances as arguments.

manager.showRewardedAd(activity, new AdCallback(){
   public void onComplete() {
       // Handle the reward.
       Log.d("TAG", "The user earned the reward.");

Allow Interstitial ads

Sometimes a situation occurs when filling Rewarded ads is not enough, in this case, you can allow the display of Interstitial ads to receiving a reward in any case. This option will compare ad cost and serve regular interstitial ads when rewarded video ads are expected to generate less revenue.
Interstitial Ads does not require to watch the video to the end, but the AdCallback.onComplete() event will be invoked in any case.
Disabled by default.


What’s Next?