Skip to main content

弹窗设置(限时免费)

获取弹窗列表

限时免费功能也通过弹窗接口获取配置

MarvelManager.getInstance().getPopup(countryCode,language,phrase,update,effectiveFilter,timezoneOffset,new AWHttpOriginalCallback(){
@Override
public void response(int code,String data){

}
});

参数

  • language:语言
  • countryCode:国家
  • phrase: 预发布密码(可空)
  • update: 当前MD5值(可空)
  • effectiveFilter: 传1新时区逻辑,不传为旧逻辑 (可空)
  • timezoneOffset: 用户时区偏移值,分钟为单位,服务端将根据该值计算用户时区的数据,可替代effective_filter,此时不会进入effective_filter逻辑(可空)

返回数据

名称类型是否必须默认值备注其他信息
codenumber非必须0成功 其他失败

mock: 0

dataobject []非必须成功是必填,失败时无data

item 类型: object

├─ ridstring必须远程配置id
├─ sub_statusnumber必须订阅状态 1全部,2订阅中,3非订阅
├─ user_statusnumber必须用户状态 1全部,2新用户,3非新用户
├─ device_levelnumber必须机型等级 1低端,2中端,4高端,多选则相加,过滤&操作
├─ weightnumber必须权重
├─ numbernumber必须次数(新接入的客户端废除此参数,改用trigger下的参数)
├─ trigger_typenumber必须触发时机 1首页,2编辑页,3自拍页,4保存页,5分享页 6 限时免费 7 强制升级
├─ popup_typenumber必须弹窗类型 1文字,2图文,3图片/视频,4反馈 5 pag
├─ popup_configobject必须弹窗配置
├─ titlestring非必须标题
├─ textstring非必须文案
├─ text_twostring非必须文案二 弹窗类型为1时使用,目前b+用到
├─ confirm_buttonobject非必须确认按钮 弹窗类型为1,2,3时使用,部分app未用请忽略
├─ textstring非必须文案
├─ deeplinkstring非必须
├─ statusnumber非必须1开启 2关闭
├─ cancel_buttonobject非必须取消按钮 确认按钮 弹窗类型为1,2,3时使用,部分app未用请忽略
├─ textstring非必须文案
├─ statusnumber非必须1开启2关闭
├─ close_angle_marknumber非必须关闭角标 1开启 2关闭,部分app未用请忽略
├─ mediaobject非必须媒体素材,图片|视频,弹窗类型2,3,5时使用
├─ typestring非必须类型,img|video | pag
├─ urlstring非必须地址
├─ deeplinkstring非必须弹窗类型3时使用
├─ custom_configobject []必须自定义配置

item 类型: object

├─ typenumber必须1文案(字符串) 2数字 3 bool 4 图片 注意弹窗中目前只有1,4两个类型
├─ keystring必须key
├─ value可变类型必须value的数据类型根据type变化 str:1,4 bool:3 number:2
├─ popup_button_titlestring非必须弹窗限时免费 popup_button_title
├─ popup_messagestring非必须弹窗限时免费 popup_message
├─ popup_titlestring非必须弹窗限时免费 popup_title
├─ created_atnumber必须创建时间,时间戳(秒)
├─ ended_atnumber必须结束时间,时间戳(秒),为0时代表无结束时间
├─ updated_atnumber必须更新时间,时间戳(秒)
├─ triggerobject必须频率
├─ frequencynumber必须频率次数
├─ cyclenumber必须频率周期:1天、2周、3月、4年
├─ feature_namestring必须弹窗限时免费 feature_name
messagestring非必须
updatestring必须数据的md5值

限时免费特性列表

实际以后台配置列表为主

APP功能列表
AB"align","background","bokeh","colors","contouring","details","eraser","firm","foundation","glitter","hairdye","hairline bangs","hairstyles video_sculpt","highlighter","magic","matte","preset","relight","reshape","resize","sculpt","skin tone","stamp","text","texture","video_clarity","video_concealer","video_details","video_firm","video_matte
B+"3D highlighting","Acne","Body tuner","Concealer","Dark circles","Details","Disperse","Enhance","Firm","HD retouch","Remove BG","Remover","Reshape","Teeth correction"

Example

{
"code": 0,
"data": [
{
"created_at": 1660730787,
"device_level": 7,
"number": 2,
"popup_config": {
"cancel_button": {
"status": 2,
"text": ""
},
"close_angle_mark": 1,
"confirm_button": {
"deeplink": "https://confirmButton",
"status": 1,
"text": "confirmButton"
},
"custom_config": [
{
"key": "1",
"type": 1,
"value": "2"
},
{
"key": "22",
"type": 4,
"value": "https://gcs.beautyplus.com/e2447c74dda61b210d4030e21a3baf80.png"
},
{
"key": "33",
"type": 4,
"value": "https://gcs.beautyplus.com/08e568ccf4d7134300a698cf2158d8fd.png"
},
{
"key": "233",
"type": 4,
"value": "https://gcs.beautyplus.com/8726d07d5ce91ce8c7f9ed219dbaacca.png"
}
],
"deeplink": "https://baidu.com",
"media": {
"type": "pag",
"url": "https://gcs.beautyplus.com/47e72087e662e68bdb4c4f04c58c95c9.pag"
},
"text": "081714",
"text_two": "081714-2",
"title": "081714"
},
"popup_type": 5,
"rid": "BP_POP_00000005",
"sub_status": 1,
"trigger": {
"cycle": 2,
"frequency": 2
},
"trigger_type": 1,
"updated_at": 1660730787,
"user_status": 1,
"weight": 2
},
{
"created_at": 1660554325,
"device_level": 7,
"number": 2,
"popup_config": {
"cancel_button": {
"status": 2,
"text": ""
},
"close_angle_mark": 1,
"confirm_button": {
"deeplink": "",
"status": 1,
"text": ""
},
"custom_config": [
{
"key": "1",
"type": 1,
"value": "2"
},
{
"key": "22",
"type": 4,
"value": "https://gcs.beautyplus.com/e2447c74dda61b210d4030e21a3baf80.png"
},
{
"key": "33",
"type": 4,
"value": "https://gcs.beautyplus.com/08e568ccf4d7134300a698cf2158d8fd.png"
},
{
"key": "233",
"type": 4,
"value": "https://gcs.beautyplus.com/8726d07d5ce91ce8c7f9ed219dbaacca.png"
}
],
"deeplink": "",
"media": {
"type": "pag",
"url": "https://gcs.beautyplus.com/47e72087e662e68bdb4c4f04c58c95c9.pag"
},
"text": "",
"text_two": "",
"title": ""
},
"popup_type": 5,
"rid": "BP_POP_00000001",
"sub_status": 1,
"trigger": {
"cycle": 2,
"frequency": 2
},
"trigger_type": 1,
"updated_at": 1660730816,
"user_status": 1,
"weight": 2
}
],
"message": "success",
"update": "faa8435d115b0b99d15ae7331263713b"
}

根据弹窗ID获取弹窗配置

MarvelManager.getInstance().getPopupPreview(rid,countryCode,language,new AWHttpOriginalCallback(){
@Override
public void response(int code,String data){

}
});

参数

  • rid: 弹窗ID,例如:BP_POP_00000015
  • language:语言
  • countryCode:国家

返回

{
"code": 0,
"data": {
"created_at": 1660730787,
"device_level": 7,
"number": 2,
"popup_config": {
"cancel_button": {
"status": 2,
"text": ""
},
"close_angle_mark": 1,
"confirm_button": {
"deeplink": "https://confirmButton",
"status": 1,
"text": "confirmButton"
},
"custom_config": [
{
"key": "1",
"type": 1,
"value": "2"
},
{
"key": "22",
"type": 4,
"value": "https://gcs.beautyplus.com/e2447c74dda61b210d4030e21a3baf80.png"
},
{
"key": "33",
"type": 4,
"value": "https://gcs.beautyplus.com/08e568ccf4d7134300a698cf2158d8fd.png"
},
{
"key": "233",
"type": 4,
"value": "https://gcs.beautyplus.com/8726d07d5ce91ce8c7f9ed219dbaacca.png"
}
],
"deeplink": "https://baidu.com",
"media": {
"type": "pag",
"url": "https://gcs.beautyplus.com/47e72087e662e68bdb4c4f04c58c95c9.pag"
},
"text": "081714",
"text_two": "081714-2",
"title": "081714"
},
"popup_type": 5,
"rid": "BP_POP_00000005",
"sub_status": 1,
"trigger": {
"cycle": 2,
"frequency": 2
},
"trigger_type": 1,
"updated_at": 1660730787,
"user_status": 1,
"weight": 2
},
"message": "success",
"update": "057aba931fa3efb89c50cecc1e7dbbce"
}