#用户优惠券接口
接口列表
接口描述
1、查询用户优惠券的列表 购物车页面用(app.coupons.lists)
请求参数
Param Name |
Param Type |
Required |
Param Value |
Desc |
method |
String |
true |
app.coupons.lists |
请求方法 |
uid |
int |
true |
7893817 |
用户ID |
type |
String |
true |
use |
券使用类型 use:已使用,notuse:未使用,overtime:过期 |
limit |
int |
true |
20 |
每页限制数 |
page |
int |
true |
2 |
第几页 |
响应内容
{
"alg": "SALT_MD5",
"code": 200,
"data": {
"couponList": [
{
"brandLimit": "144", // 品牌ID限制(可以有多个)
"brandNameLimit": [ //品牌名称限制(可以有多个)
"VANS"
],
"couponCode": "aogzc8j21gahnr",
"couponDetailInfomation": "VANS专享券满899减200", // 券名称
"couponId": 14650, // 券编号
"couponImageUrl": "",
"couponType": "1",
"couponValidity": "2014.10.31-2018.12.31", // 券有效期
"couponValue": 398, // 券面值
"endTime": 1546185600,
"explains": "金卡用户专用", // 说明
"id": 45361530,
"isNoLimit": "false", // 是否全场通用
"isValidity": "Y",
"multipleFlag": true,
"overTime": 1546185600,
"rule4ShortName": "满899可用", // 券使用条件(现金券无值)
"shopPriceLimits": "1,2", // 1:互斥三折 2:互斥限定商品
"sortLimit": "44", // 分类限制(可以有多个)
"sortNameLimit": [
"休闲/运动鞋" // 分类名称限制(可以有多个)
],
"startTime": 1414736000
},
{
"couponCode": "aaf7220ae",
"couponDetailInfomation": "女生节第三波创意IN季满199减10",
"couponId": 12374,
"couponImageUrl": "",
"couponValidity": "2016.03.15-2016.03.31",
"couponValue": 10,
"id": 39525822,
"isValidity": "Y",
"overTime": 1459416780
},
{
"couponCode": "a6c83e6c2",
"couponDetailInfomation": "女生节第三波潮童满399减40",
"couponId": 12373,
"couponImageUrl": "",
"couponValidity": "2016.03.15-2016.03.31",
"couponValue": 40,
"id": 39525496,
"isValidity": "Y",
"overTime": 1459416720
},
{
"couponCode": "a963fe22b",
"couponDetailInfomation": "女生节第三波潮童满299减20",
"couponId": 12372,
"couponImageUrl": "",
"couponValidity": "2016.03.15-2016.03.31",
"couponValue": 20,
"id": 39525476,
"isValidity": "Y",
"overTime": 1459416660
},
{
"couponCode": "a31383387",
"couponDetailInfomation": "女生节第三波女生原创满499减60",
"couponId": 12371,
"couponImageUrl": "",
"couponValidity": "2016.03.15-2016.03.31",
"couponValue": 60,
"id": 39525811,
"isValidity": "Y",
"overTime": 1459416600
},
{
"couponCode": "ad0c9453a",
"couponDetailInfomation": "女生节第三波女生原创满299减30",
"couponId": 12370,
"couponImageUrl": "",
"couponValidity": "2016.03.15-2016.03.31",
"couponValue": 20,
"id": 39525810,
"isValidity": "Y",
"overTime": 1459416600
}
],
"pageSize": 10,
"total": 47,
"totalPageNum": 5
},
"md5": "078c5054032002834ef329f959504f8a",
"message": "优惠券列表"
}
2、查询用户优惠券的列表 个人中心用(app.coupons.li)
请求参数
Param Name |
Param Type |
Required |
Param Value |
Desc |
method |
String |
true |
app.coupons.li |
请求方法 |
uid |
int |
true |
7893817 |
用户ID |
status |
int |
true |
1 |
券使用类型 status=0 未使用 1 已使用 |
limit |
int |
true |
20 |
每页限制数 |
page |
int |
true |
2 |
第几页 |
响应内容 按公司首字母排序
{
"alg": "SALT_MD5",
"code": 200,
"data": {
"couponList": [
{
"actuallyPaid":11.00,
"brandLimit": "",
"brandNameLimit":[],
"couponCode":"boow93p2224yck",
"couponDetailInfomation":"线下店验收10元优惠券",
"couponId":15574,
"couponImageUrl":"",
"couponType":"2",
"couponValidity":"2017.04.21-2017.05.31",
"couponValue":10.0000,
"endTime":1496195951,
"excludeSkn":[51559892,51559890],
"explains":"",
"id":96,
"isNoLimit":"true",
"isValidity":"Y",
"multipleFlag":false,
"notes": ["全场通用", "特例商品(秒杀、限定、境外、预售等)暂不支持使用优惠券"],
"orderCode":170142725,
"orderPrice":11.0,
"overTime":1496195951,
"rule4ShortName":"",
"shopNameLimit":[],
"sortLimit":"",
"sortNameLimit":[],
"startTime":1492739951,
"usedTime":"2017-05-02 17:53:50"
}
],
"info": [
{
"couponValidity":"2017.04.21-2017.05.31",
"coupon_id":15574,
"coupon_name":"线下店验收10元优惠券",
"coupon_pic":"http://feature.yoho.cn/coupon_unusable.png",
"id":96,
"is_overtime":"N",
"money":10.0000,
"order_code":170142725
}
],
"total": 1
},
"md5": "f80f5515268ca66c7a47233482ee95c4",
"message": "操作成功"
}
3、获取用户优惠券数量-个人中心调用(app.coupons.total)
请求参数
Param Name |
Param Type |
Required |
Param Value |
Desc |
method |
String |
true |
app.coupons.total |
请求方法 |
uid |
int |
true |
7893817 |
用户ID |
type |
String |
true |
use |
券使用类型 use:已使用,notuse:未使用,overtime:过期 |
响应内容
{
"alg": "SALT_MD5",
"code": 200,
"data": {
"total": 47
},
"md5": "50d19f5f5098c34607018f144baec14a",
"message": "操作成功"
}
4、验证用户是否可领取生日券(app.promotion.validateGetBirthCoupon)
请求参数
Param Name |
Param Type |
Required |
Param Value |
Desc |
method |
String |
true |
app.promotion.validateGetBirthCoupon |
请求方法 |
uid |
int |
true |
7893817 |
用户ID |
响应内容
{
"alg": "SALT_MD5",
"code": 200,
"data": {
"is_support": "N", // 返回Y调用app.promotion.queryBirthCoupon接口
"not_support_reasons": "1", // 1:已领取 2:信息未完善 3:非VIP 4:非生日期间
"not_support_reasons_title": "您在17年01月01日已经领取过",
"not_support_reasons_message": "生日福利一年内(365天)仅可领取一次哦",
},
"md5": "50d19f5f5098c34607018f144baec14a",
"message": "操作成功"
}
5、查询用户可领取的生日券列表(app.promotion.queryBirthCoupon)
请求参数
Param Name |
Param Type |
Required |
Param Value |
Desc |
method |
String |
true |
app.promotion.queryBirthCoupon |
请求方法 |
uid |
String |
true |
|
用户uid |
couponType |
String |
true |
|
优惠券类型,此处必填4 |
响应
{
"alg": "SALT_MD5",
"code": 200,
"data": [
{
"couponAmount": 299,
"couponCode": "",
"couponName": "12月生日券:VIP专享满299减80(",
"endTime": "2016-12-31 23:59:59",
"id": 14524,
"startTime": "2016-12-01 00:00:01",
"status": 1,
"useLimit": "299",
"useLimitType": "2"
},
{
"couponAmount": 120,
"couponCode": "",
"couponName": "12月生日券:VIP专享满499减120",
"endTime": "2016-12-31 23:59:59",
"id": 14526,
"startTime": "2016-12-01 00:00:01",
"status": 1,
"useLimit": "499",
"useLimitType": "2"
}
],
"md5": "c00cd33d230203bc8534bae9aada2326",
"message": "请求成功"
}
响应错误码
code |
Desc |
201 |
用户生日信息不存在 |
411 |
您没有可领取的生日券哦 |
410 |
您还不是VIP哦~升级VIP享专属生日券! |