# 获取优惠券信息

# 接口调用说明

http请求方式:POST
https://api.weixin.qq.com/shop/coupon/get?access_token=xxxxxxxxx

# 请求参数示例

{
    "out_coupon_id": "out_coupon_id_1"
}

# 回包示例

{
  "errcode": 0, // 返回码
  "result": {
    "coupon": {
      "out_coupon_id": "coupon_id_1", // 优惠券ID
      "type": 101,
      "promote_type": 4,
      "coupon_info": {
        "name": "示例优惠券",
        "promote_info": {
          "promote_type": 4,
          "finder": {
            "nickname": "视频号昵称"
          }
        },
        "discount_info": {
          "discount_condition": {
            "product_cnt": 2, // 优惠券类型为商品券时
            "product_price": 5000,
            "out_product_ids": ["product_id_3", "product_id_4"], // 优惠券类型为商品券时
            "tradein_info": { // 优惠券类型为买赠券时
              "out_product_id": "product_id_5",
              "price": 10000
            },
            "buyget_info": { // 优惠券类型为换购券时
              "buy_out_product_id": "product_id_1",
              "buy_product_cnt": 3,
              "get_out_product_id": "product_id_2",
              "get_product_cnt": 5
            }
          },
          "discount_num": 9800, // 折扣券
          "discount_fee": 6400 // 满减券、直减券
        },
        "receive_info": {
          "start_time": 1625451250, //领取开始时间
          "end_time": 1625454250, //领取结束时间
          "limit_num_one_person": 10, //限领张数,由小程序保证限领
          "total_num": 100 //总发放量
        },
        "valid_info": {
          "valid_type": 1, //有效期类型
          "valid_day_num": 10, //生效天数
          "valid_second": 3600, //生效秒数
          "start_time": 1625451250, //有效开始时间
          "end_time": 1625464250 //有效结束时间
        }
      },
      "status": 1, // 优惠券状态
      "create_time": 1625454641,
      "update_time": 1625454641,
      "appid": "wx9e20708660a0991b"
    }
  }
}

# 请求参数说明

参数 类型 是否必填 说明
out_coupon_id string 优惠券id

# 回包参数说明

参数 类型 说明
coupon.out_coupon_id string 商家侧优惠券ID
coupon.type number 优惠券类型
coupon.promote_type number 优惠券推广类型
coupon.coupon_info.name string 优惠券名
coupon.coupon_info.promote_info.promote_type number 优惠券推广类型
coupon.coupon_info.promote_info.finder.nickname string 推广视频号昵称
coupon.coupon_info.discount_info.discount_condition.product_cnt number 折扣条件所需的商品数
coupon.coupon_info.discount_info.discount_condition.product_price number 折扣条件所需满足的金额
coupon.coupon_info.discount_info.discount_condition.out_product_ids string array 指定商品商家侧ID
coupon.coupon_info.discount_info.discount_condition.tradein_info.out_product_id string 换购商品商家侧ID
coupon.coupon_info.discount_info.discount_condition.tradein_info.price number 需要支付的金额,单位分
coupon.coupon_info.discount_info.discount_condition.buyget_info.buy_out_product_id string 购买商品商家侧ID
coupon.coupon_info.discount_info.discount_condition.buyget_info.buy_product_cnt number 购买商品数
coupon.coupon_info.discount_info.discount_condition.buyget_info.get_out_product_id string 赠送商品商家侧ID
coupon.coupon_info.discount_info.discount_condition.buyget_info.get_product_cnt number 赠送商品数
coupon.coupon_info.discount_info.discount_num number 折扣数,比如5.1折,则为5100
coupon.coupon_info.discount_info.discount_fee number 减金额,单位为分
coupon.coupon_info.receive_info.start_time number 领取开始时间(秒级时间戳)
coupon.coupon_info.receive_info.end_time number 领取结束时间(秒级时间戳)
coupon.coupon_info.receive_info.limit_num_one_person number 领张数
coupon.coupon_info.receive_info.total_num number 总发放量
coupon.coupon_info.valid_info.valid_type number 有效期类型,1:商品指定时间区间,2:生效天数,3:生效秒数
coupon.coupon_info.valid_info.valid_day_num number 生效天数
coupon.coupon_info.valid_info.valid_second number 生效秒数
coupon.coupon_info.valid_info.start_time number 生效开始时间(秒级时间戳)
coupon.coupon_info.valid_info.end_time number 生效结束时间(秒级时间戳)
coupon.status number 优惠券状态
coupon.create_time number 创建时间(秒级时间戳)
coupon.update_time number 更新时间(秒级时间戳)