coupon.md
6.98 KB
#用户优惠券接口
接口列表
接口名称 | 接口描述 |
---|---|
app.coupons.lists | 查询用户优惠券的列表 购物车页面用 |
app.coupons.li | 查询用户用户券列表 个人中心用 |
app.coupons.total | 获取用户优惠券数量 个人中心调用 |
接口描述
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": [
{
"couponCode": "a4d675488",
"couponDetailInfomation": "女生节第三波创意IN季满399减40",
"couponId": 12375,
"couponImageUrl": "",
"couponValidity": "2016.03.15-2016.03.31",
"couponValue": 40,
"id": 39525823,
"isValidity": "Y",
"overTime": 1459416840
},
{
"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": {
"info": [
{
"couponValidity": "2016.03.15-2016.03.31",
"coupon_id": 12374,
"coupon_name": "女生节第三波创意IN季满199减10",
"coupon_pic": "http://feature.yoho.cn/coupon_unusable.png",
"id": 39525822,
"is_overtime": "N",
"money": 10
},
{
"couponValidity": "2016.03.15-2016.03.31",
"coupon_id": 12373,
"coupon_name": "女生节第三波潮童满399减40",
"coupon_pic": "http://feature.yoho.cn/coupon_unusable.png",
"id": 39525496,
"is_overtime": "N",
"money": 40
},
{
"couponValidity": "2016.03.15-2016.03.31",
"coupon_id": 12372,
"coupon_name": "女生节第三波潮童满299减20",
"coupon_pic": "http://feature.yoho.cn/coupon_unusable.png",
"id": 39525476,
"is_overtime": "N",
"money": 20
},
{
"couponValidity": "2016.03.15-2016.03.31",
"coupon_id": 12371,
"coupon_name": "女生节第三波女生原创满499减60",
"coupon_pic": "http://feature.yoho.cn/coupon_unusable.png",
"id": 39525811,
"is_overtime": "N",
"money": 60
},
{
"couponValidity": "2016.03.15-2016.03.31",
"coupon_id": 12370,
"coupon_name": "女生节第三波女生原创满299减30",
"coupon_pic": "http://feature.yoho.cn/coupon_unusable.png",
"id": 39525810,
"is_overtime": "N",
"money": 20
}
],
"total": 47
},
"md5": "50d19f5f5098c34607018f144baec14a",
"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": "操作成功"
}