简要描述:

  • 领取优惠卷

请求域名:

  • http://xx.com

请求URL:

POST:plugin.coupon-qr.api.index.index

参数:

参数名 是否必须 类型 说明
goods_id int 商品ID
member_coupon_id int 会员优惠卷ID

返回示例:

正确时返回:

{
    "result": 1,
    "msg": "成功",
    "data": {
        "coupon": {
			"id": 10,
            "name": "测试",
            "deduct_status": " 立减12.00元",
            "resp_thumb": "",
            "start": "1584666194",
            "end": "1584666194",
			"deduct":12,
			"discount":1,
			"coupon_method":1,
            "usageLimit": "适用于下列商品: 天然维生素E软胶囊零售价一百元最少采购量1中盒开心一百片十二瓶八中盒件件散装休",
            "status_name": "领取成功",
			"coupon_status": 0,
        },
        "goods": {
            "id": 1,
            "title": "支付测试",
            "thumb": "http://wq.com/attachment/images/3/2017/07/z1XplaLkFKd991D9CR8xNPC9ca3zKX.jpg",
            "price": "0.01"
        },
		"shop_logo": ""
    }
}

错误时返回:

{
    "result": 0,
    "msg": "优惠券不存在",
    "data": []
}
{
    "result": 0,
    "msg": "失败",
    "data": {
        "coupon": {
			"id": 10,
            "name": "测试",
            "deduct_status": " 立减12.00元",
            "resp_thumb": "",
            "start": "1584666194",
            "end": "1584666194",
            "usageLimit": "适用于下列商品: 天然维生素E软胶囊零售价一百元最少采购量1中盒开心一百片十二瓶八中盒件件散装休",
            "status_name": "已被领取",
			"coupon_method":1
			"deduct":12,
			"discount":1
			"coupon_status": 1,
        },
        "goods": {
            "id": 1,
            "title": "支付测试",
            "thumb": "http://wq.com/attachment/images/3/2017/07/z1XplaLkFKd991D9CR8xNPC9ca3zKX.jpg",
            "price": "0.01"
        },
		"shop_logo": ""
    }
}

返回参数说明:

参数名 类型 说明
coupon.id int 优惠券id
coupon.name string 优惠券名称
coupon_status int 优惠
coupon.resp_thumb int 优惠券图片
coupon.start string 有效时间
coupon.end int 有效时间
coupon.usageLimit string 适用范围
coupon.status_name int 领取结果
coupon.deduct int 优惠金额
coupon.discount int 折扣
coupon.coupon_method int 优惠方式 1-金额 2-折扣
goods.title string 商品标题
goods.thumb int 商品图片
goods.price string 商品价格
shop_logo string 商城logo

备注: