Skip to content

获取优惠券详情2.0

拥有此API的权限集
营销码券管理-查询

请求方式及url

  • 请求方式:POST
  • 请求头:Content-Type:application/json
  • 接口地址:https://api.xiaoe-tech.com/xe.coupon.detail/2.0.0
  • 频率限制:10秒500次

接口调试

请求参数
响应结果
暂无响应数据

请求参数

参数名必选类型说明备注(示例)
access_tokenstring专属token...
coupon_idstring优惠券idxx

请求示例

{
	"access_token": "xe_xxxxx",
	"coupon_id": "xx"
}

返回参数

参数名必选类型说明
codeint请求结果码
msgstring描述信息
dataobject数据

数据列表data

参数名必选类型说明备注(示例)
idstring优惠券id
app_idstring店铺id
activity_idstring营销活动id
titlestring优惠券标题xxxxx
typeint优惠券类型 0-指定商品可用 1-全部商品可用 2-指定商品不可用
spread_typeint推广方式 0-用户领取 1-商家发放 2-兑换码兑换 3-不限方式
discount_wayint折扣方式,1-满减 2-折扣
discount_percentint优惠券打几折,折扣力度百分比 【0-100】
discount_limit_priceint折扣上限, 最多优惠金额0-表示不限制
valid_afterint领取后多久后生效,单位: 天, 0-立即生效 ;-1-使用优惠券设置的有效期
valid_dayint优惠券有效期开始时间
can_use_with_activityint允许与指定营销活动(秒杀、拼团、限时折扣等)叠加使用 1-允许 0-不允许
copy_fromstring被复制的优惠券id
is_showint详情页是否显示 1-显示 0-不显示
valid_atstring开始有效期
invalid_atstring开始无效期
manual_stop_atstring手动结束领取时间
priceint满减券抵扣金额,单位:分1000
receive_ruleint每人限领
require_priceint最低消费金额
bind_res_countint绑定资源数
countint发行总量
has_receivedint已领取总数
has_usedint已使用数量
can_shareint是否可以进行分享 1-可以 0-不可以
is_show_stockint是否展示库存:0-不展示,1-展示
promote_goods_setint推荐商品类型:1-最新商品, 2-指定商品
is_deleteint是否删除 0-不删除 1-已删除
is_hideint是否在B端隐藏优惠券,0-不隐藏;1-隐藏
created_atstring创建时间
updated_atstring更新时间
coupon_typeint优惠券类型 1-通用优惠券,2-专属优惠券,3-员工优惠券
receive_limit_typeint限制身份领取类型 ,0-不限制,1-超级会员,2-用户人群,3-用户标签
receive_limit_idsstring领取限制关联ID,(json)id=关联id,title=冗余标题,is_free_vip=会员特殊逻辑,体验会员
instructionsstring优惠券使用说明
plansarray定向计划
resourcearray只有type=0时才会返回,优惠券所包含的资源信息
bind_resourcesarray只有type=1和type=2时才会返回,当type=2时返回,表示里面的商品不可用,当type=1时,bing_resources为空
unsupport_resourcearray指定商品不可用 当type=2时才会返回[]

优惠券所包含的资源信息resource&指定商品不可用unsupport_resource

参数名类型说明
idstringid
spu_idstringspu id
goods_idstring商品id
resource_idstring资源id
sku_idstringsku id
titlestring标题
summarystring简介
org_contentstring原始HTML内容
descrbstring专栏描述(Json格式, type:0-文字 1-图片)
img_urlstring封面图片url
img_url_compressedstring封面压缩图片url
countstring数量
priceint价格
stockint库存
high_priceint最高价
low_priceint最低价
line_priceint划线价
is_packageinttrue表示实物带货商品
created_atstring创建时间
enough_priceint是否足够金额消费 1-满足 0-不满足
resource_typeint资源类型
skuarray规格相关信息
sku[].sku_idstring规格id
sku[].sku_priceint规格价格,单位:分

绑定的资源bind_resources

参数名类型说明
resource_idstring资源ID
resource_typeint资源类型
cou_idint优惠券ID

返回示例

{
    "code": 0,
    "msg": "获取优惠券详情成功",
    "data": {
        "id": "cou_xxxx",
        "app_id": "appxxx",
        "activity_id": "ma_cu_xxxx",
        "title": "20210809专属优惠卷",
        "type": 0,
        "spread_type": 3,
        "discount_way": 1,
        "discount_percent": 0,
        "discount_limit_price": 0,	
        "valid_after": 0,
        "valid_day": 20
        "can_use_with_activity": 1,
        "copy_from": "",
        "is_show": 0,
        "valid_at": null,
        "invalid_at": null,
        "manual_stop_at": null,
        "price": 11200,
        "receive_rule": 0,
        "require_price": 0,
        "bind_res_count": 1,
        "count": 200,
        "has_received": 0,
        "has_used": 0,	
        "can_share": 1,
        "is_show_stock": 0,	
        "promote_goods_set": 0,	
        "is_delete": 0,
        "is_hide": 0,
        "created_at": "2021-08-12 18:15:19",
        "updated_at": "2021-08-12 18:15:19",
        "coupon_type": 1,
        "receive_limit_type": 0,
        "receive_limit_ids": "",
        "instructions": "",
        "bind_resources": [],
        "unsupport_resource": [],
        "resource": [
            {
                "id": "SPU_xxxx",
                "spu_id": "SPU_xxxx",
                "goods_id": "SPU_xxxx",
                "resource_id": "g_xxx",
                "sku_id": "SKU_xxxx",
                "title": "寄到海外",
                "summary": "",
                "org_content": "",
                "descrb": "",
                "img_url": "http://xxxx.gif",
                "img_url_compressed": "http://xxx.gif",
                "count": "",
                "price": 11100,
                "stock": 1231,
                "high_price": 11100,
                "low_price": 11100,
                "line_price": 0,
                "is_package": 0,
                "created_at": "2021-08-12 16:53:21",
                "enough_price": 1,
                "resource_type": 21,
                "sku": [
                    {
                        "sku_id": "SKU_ENT_6290959917748LkTBQ58",
                        "sku_price": 1100
                    }
                 ],

            }
        ],
        "plans": []
    }
}