OfferWalls
#
1.Request AdsParameter Description
#
unitId:Ad unit ID created on the TradPlus platform- Developers need to fill it in correctly. For example, if there are spaces before and after the unitId setting, the ad request will fail because the configuration cannot be pulled.
#
TPOfferwallExtra:Extra Parameters- customMap: Set Segement related attribute parameters
- localParams:Set local parameters.Only for Android.Some ad platforms require special parameters to be set.
#
2.Checking for Available Ads- It is recommended to call this API to check if there are available ads before displaying an ad. Only call the show method if there are ads available.
- true indicates that there are available ads, false indicates that there are no available ads at the moment.
#
3.Entering Ad Scene (Optional)Parameter Description
#
sceneId :Ad Scene ID- Developers can create an ad scene in TradPlus backend. The location is as follows: Application Management - Advertising Scenes.
- When entering the advertising scene, pass in the sceneId. The sceneId must also be passed in when displaying the ad, otherwise it will affect statistics.
#
4.Display Ads#
5.Others APIWhen calling these APIs, you need to set up corresponding callback listeners to obtain results.
- Set UserId
It is set when the user switches accounts. The UserId is bound to the subsequent points API and is set after the first load is successful.
- Get the current user's points balance
- Example of consumption points: Used when redeeming points for props
- Apply proactively to reward points
#
6.Listen for CallbacksParameter Description
adInfo: Ad unit ID, third-party ad platform, eCPM, and other information. Please refer to Android Callback Information and iOS Callback Information.
Error information for ad request failure and ad display failure. Please refer to Error Codes.