在Airpush Ads的Android应用中添加选择退出功能?

时间:2012-01-07 19:36:19

标签: android ads

在有人讨论Airpush之前,我想知道如何在我的应用程序中为Airpush Ads添加一个选择退出功能。

有人熟悉Airpush SDK吗?他们的文件非常差。任何帮助表示赞赏。

我已经在实际的SDK中搜索了解决方案,但找不到。

2 个答案:

答案 0 :(得分:2)

我是Airpush的代表。 Force的响应作为一个选项是正确的,但是为了让用户保持在您的应用程序中,我们建议您还检查Permissions API。通过权限API,您可以创建自定义选择加入(白名单)和选择退出(黑名单)功能,并完全控制用户体验。

单击Airpush开发人员门户中的Permissions API按钮。 出于您的目的,我建议您选择黑名单模式,因为您希望选择退出而不是选择加入。

在门户网站中启用黑名单模式后,请参阅以下有关相关API方法的一些文档:

Add Blacklist IMEI

Developer sends an ‘add blacklist IMEI’ request to add an IMEI to blacklist in Airpush database. Note: In blacklist mode, blacklisted IMEIs will NOT qualify to receive push notification ads from Airpush.
URL - http://api.airpush.com/api.php
Supported request methods - GET, POST
Requires Authentication - Yes, API AUTH KEY
Parameters -
    Model   "app"
    Action  "add_imei_black"
    APIKEY  Generated API Key
    AppId   App id of application give above
    IMEI    Md5 encrypted IMEI that needs to be added in blacklist
Response Details - Upon successful blacklisting of an IMEI, server responds back with int value 1 along with the HTTP status code 200 (Created). If parameters are invalid, server will return HTTP status code as 400 and in case of any other errors server will respond back with the specific error code.
Sample Code
http://api.airpush.com/api.php?model=app&action=add_imei_black&APIKEY=apikey&appId=appid&imei=UserEncryptedIMEI

答案 1 :(得分:1)

即使我不建议使用Airpush,您也可以在应用中为此应用添加链接:https://market.android.com/details?id=com.airpush.optoutapp

这是Airpush的官方应用选择退出。我不认为有一种方法可以在应用程序中手动禁用空气推送。

另一种方法是将用户重定向到此表单 http://www.airpush.com/optout,但我不推荐它,因为用户必须自己输入他的IMEI。

请注意,Airpush 仍然有效(=将IMEI发送到服务器),但不会显示。

相关问题