抖音开放平台Logo
开发者文档
“/”唤起搜索
控制台
  • OpenAPI 简介
  • 通用参数
  • 小程序 OpenAPI SDK 总览
  • 签名算法
  • 基础能力
  • 触达与营销
  • 支付
  • 运营
  • 生活服务
  • 通用能力
  • 生活服务交易系统(全融合版)
  • 通用参数
  • 错误码和返回码
  • 查询接口
  • 预下单
  • 营销算价
  • 营销算价扩展点介绍
  • 查询营销算价扩展点
  • 查询营销算价
  • 支付
  • 核销
  • 分账
  • 退货退款
  • 预约
  • 生活服务交易系统(账号融合版)
  • CPS佣金设置与查询
  • 即送(原随心团)解决方案
  • 核销工具解决方案
  • 历史版本(不推荐使用)
  • 垂直行业
  • 其它
  • 开发者通过本接口获取可用的营销信息和对应的算价结果,可以将营销算价信息展示在自己开发的 C 端页面,比如商详页。
    下单时,开发者将营销算价结果传入下单接口,实现优惠下单。

    使用限制

    无

    接口说明

    注意
    本接口为openAPI,适用于低版本兼容场景。建议开发者优先使用营销算价JS-API,JS-API是C端接口,能够客户端携带场景参数。如果使用openAPI会存在某些场景专享的优惠查不到的问题,所以建议开发者选用JS-API.
    我们将营销分为三大类:平台营销、来客商家营销、商家自营销,其中平台营销、来客商家营销是抖音平台提供的营销能力。
    下面的表格列举了开发者使用营销类型和对应要接入的接口:
    平台营销
    来客商家营销
    商家自营销
    接入要求
    ✓
    ​
    ​
    查询营销算价
    ​
    ✓
    ​
    查询营销算价
    ✓
    ✓
    ​
    查询营销算价
    ​
    ​
    ✓
    营销算价扩展点
    ✓
    ​
    ✓
    查询营销算价 + 营销算价扩展点
    ​
    ✓
    ✓
    查询营销算价 + 营销算价扩展点
    ✓
    ✓
    ✓
    查询营销算价 + 营销算价扩展点
    举个例子,第一行表示开发者只使用平台营销时,需要接入查询营销算价接口。

    基本信息

    基本信息
    HTTP URL
    HTTP Method
    POST
    Scope
    industry_open.trade.marketing
    权限要求
    不需要用户授权

    请求头

    请求参数

      1.首次请求时need_default_marketing传true,响应将返回默认最优的营销组合和算价结果
      2.当用户选中具体的优惠信息(商品/订单的selected_marketing不为空)时,need_default_marketing传false,响应将返回用户选中优惠的算价结果
      3.goods_marketing_info和order_marketing_info结构体都有selected_marketing,区别是优惠适用的维度不同:
      ◦goods_marketing_info下的优惠是作用于具体商品的,比如星冰乐单品优惠立减5元
      ◦order_marketing_info下的优惠是作用于整个订单的,比如订单满200-20
      ◦对于一个具体的优惠券,不能同时出现在goods_marketing_info和order_marketing_info中,它适用的优惠维度是明确的
      4.order_marketing_info.total_amount = sum(goods_marketing_info.total_amount)
    名称
    类型
    是否必填
    描述
    示例值
    校验逻辑
    open_id
    string
    是
    用户 open_id
    "123rq0gjhdfoqierug"
    正确的open_id
    goods_marketing_info
    list<object>
    是
    商品维度用户选用的营销信息
    [info1, info2]
    ​
    order_marketing_info
    ​
    object
    否
    订单维度用户选用的营销信息
    ​
    ​
    callback_data
    string
    否
    透传参数
    ​
    ​
    need_default_marketing
    bool
    是
    是否需要默认算价(首次获取营销信息时为true)
    true
    ​

    goods_marketing_info 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    校验逻辑
    goods_id
    string
    是
    商品id
    "123rq0gjhdfoqrug"
    非空
    quantity
    number
    是
    购买数量
    1
    0<quantity<=50
    total_amount
    number
    是
    商品总价,单位分
    10000
    须大于 0
    selected_marketing
    ​
    object(MarketingBundle)
    否
    用户所选营销策略信息,仅包含该商品的商品维度优惠信息
    selected_marketing
    ​

    order_marketing_info 结构说明

    名称
    类型
    是否必填
    描述
    示例值
    校验逻辑
    selected_marketing
    ​
    object(MarketingBundle)
    否
    用户所选营销策略信息,仅包含订单维度优惠信息
    selected_marketing
    ​
    ​
    total_amount
    number
    是
    订单总价,单位分
    10000
    须大于 0
    MarketingBundle 结构说明
    名称
    类型
    是否必填
    描述
    示例值
    校验逻辑
    membership_info
    ​
    list<object>
    否
    用户身份信息(如会员)
    [membership1, membership2]
    ​
    coupon_info
    list<object>
    否
    优惠券信息
    [coupon1, coupon2]
    ​
    activity_info
    list<object>
    否
    活动信息
    [activity1, activity2]
    ​
    score_info
    list<object>
    否
    积分信息
    [score1, score2]
    ​
    说明:
      1.kind,creator_type用于区分营销类别:
      a.如果开发者仅有自营销,则kind=1,creator_type=3
      b.如果开发者通过openAPI获取了交易系统返回的营销信息,则直接把kind,creator_type,marketing_extend字段透传即可
      2.marketing_extend是扩展字段,目前没有使用
      a.如果开发者仅有自营销,marketing_extend传{}即可
      b.如果开发者通过openAPI获取了交易系统返回的营销信息,则将marketing_extend字段透传即可

    membership_info 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    检验逻辑
    id
    string
    是
    用户身份 id
    "abcd33234"
    非空,<=64 字节
    desc
    string
    是
    用户身份描述
    "京东 plus 会员"
    <= 128字节
    kind
    number
    是
    营销类别
    1:商家
    2:平台
    1
    ​
    creator_type
    number
    是
    创建人类型
    1:抖音平台
    2:抖音来客—商家
    3:小程序商家
    3
    ​
    marketing_extend
    object
    是
    扩展字段
    {}
    ​

    coupon_info 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    检验逻辑
    id
    string
    是
    优惠券id
    "abcd33234"
    非空,<= 64 字节
    code
    string
    是
    优惠券编码
    "49dkjg04jf04kg"
    非空,<= 64 字节
    type
    ​
    number
    是
    ​
    优惠券类型:
      •1:立减券
      •2:满减券
      •3:折扣券
    1
    ​
    name
    string
    是
    优惠券名称
    "满100减20"
    非空,<= 64 字节
    receive_time
    number
    否
    优惠券领取时间戳,单位毫秒
    1920423870232
    ​
    start_time
    number
    是
    有效起始时间戳,单位毫秒
    1920423870232
    ​
    end_time
    number
    是
    有效结束时间戳,单位毫秒
    1920423870232
    晚于 start_time
    discount_amount
    number
    否
    优惠价格,单位分
    20000
    > 0(不允许没有折扣的优惠券)
    deduct_percentage
    number
    否
    折扣百分比,填 0~100,折扣抵 30% 则填 30
    30
    0~100
    detail_url
    string
    否
    优惠券详情跳转链接
    "page/index/abc"
    <= 512 字节
    rule
    string
    是
    使用规则描述,包含适用范围描述,使用条件,退款时的处理说明等
    "适用于该店铺所有商品,周一到周五可使用"
    ​
    非空,<= 256 字节
    kind
    number
    是
    营销类别
    1:商家
    2:平台
    1
    ​
    creator_type
    number
    是
    创建人类型
    1:抖音平台
    2:抖音来客—商家
    3:小程序商家
    3
    ​
    marketing_extend
    object
    是
    扩展字段
    {}
    ​
    deny_reasons
    list<string>
    否
    不可用原因
    未达到满减门槛
    ​

    activity_info 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    检验逻辑
    id
    string
    是
    活动 id
    "abcd33234"
    非空,<= 64 字节
    name
    string
    是
    活动名称
    1
    非空,<= 64 字节
    start_time
    number
    否
    有效起始时间戳
    192042387023234
    ​
    end_time
    number
    否
    有效结束时间戳
    192042387023235
    晚于start_time
    rule
    string
    是
    "限时秒杀立减 100 元"
    活动规则
    非空,<= 256 字节
    kind
    number
    是
    营销类别
    1:商家
    2:平台
    1
    ​
    creator_type
    number
    是
    创建人类型
    1:抖音平台
    2:抖音来客—商家
    3:小程序商家
    3
    ​
    marketing_extend
    object
    是
    扩展字段
    {}
    ​
    type
    number
    是
    1:秒杀
    2:运费立减
    3:立减
    4:会员专享价
    5:渠道专享价
    1
    ​

    score_info 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    检验逻辑
    value
    number
    是
    可用积分值
    9527
    >= 0
    id
    ​
    string
    是
    积分 id,如“JingDong-vip”表示京东 VIP 会员积分,再比如可能会有具体某个店铺的积分,很多大店铺是有自己的积分系统的
    "390dknvi0o4"
    ​
    非空,<= 64 字节
    name
    string
    是
    积分名字:如:京东 VIP 会员积分
    同上
    非空,<= 64 字节
    kind
    number
    是
    营销类别
    1:商家
    2:平台
    1
    ​
    creator_type
    number
    是
    创建人类型
    1:抖音平台
    2:抖音来客—商家
    3:小程序商家
    3
    ​
    marketing_extend
    object
    是
    扩展字段
    {}
    ​
    ​

    请求示例

      •这个请求表达的含义是:用户(M3arp6xWNPyvKnHf)准备购买3份商品(7112741589566588972),订单原始金额300分,请返回这笔订单可用的优惠信息以及默认最佳优惠的算价结果
    curl --location --request POST 'https://open.douyin.com/api/trade/v2/marketing/query_and_calculate'\ --header 'Content-Type: application/json' \ --header 'access-token: clt.xxx' \ --data-raw '{ "open_id": "M3arp6xWNPyvKnHf", "callback_data": "12345", "goods_marketing_info": [ { "goods_id": "7112741589566588972", "quantity": 3, "total_amount": 300 } ], "need_default_marketing": true, "order_marketing_info": { "total_amount": 300 } }'

    响应参数

    名称
    类型
    是否必填
    描述
    示例值
    data
    object
    否
    返回数据信息
    ​
    err_no
    number
    是
    错误码
    0
    err_msg
    string
    是
    错误提示
    success
    log_id
    string
    是
    log_id
    ​

    data 字段

    说明:
      1.goods_marketing_result和order_marketing_result下都有available_marketing和unavailable_marketing字段,它们的区别是优惠适用的维度不同:
      ◦goods_marketing_info下的available和unavailable优惠是针对商品的。举个例子,对于商品星冰乐,星冰乐单品优惠券属于available,蛋糕单品优惠券属于unavailable
      ◦order_marketing_info下的available和unavailable优惠是针对订单的。举个例子,总价150的订单,满100-5的优惠券属于available,满200-20优惠券属于unavailable
      ◦对于一个具体的优惠券,不能同时出现在goods_marketing_result和order_marketing_result中,它适用的优惠维度是明确的
      2.order_marketing_result.total_amount = sum(goods_marketing_result.total_amount)
    名称
    类型
    是否必填
    描述
    示例值
    goods_marketing_result
    list<object>
    是
    商品维度营销查询结果,包含商品信息以及该商品下可用/不可用营销信息
    ​
    order_marketing_result
    object
    否
    订单维度营销查询结果,包含订单总价以及订单维度可用/不可用营销
    ​
    calculation_result
    ​
    object
    否
    算价结果
    ​

    goods_marketing_result 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    goods_id
    string
    是
    商品id
    "123rq0gjhdfoqierug"
    quantity
    number
    是
    购买数量
    1
    total_amount
    number
    是
    商品总价,单位分
    10000
    available_marketing
    object(MarketingBundle)
    否
    该商品下可用的优惠信息(商品维度)
    ​
    unavailable_marketing
    object(MarketingBundle)
    否
    该商品下不可用的优惠信息(商品维度)
    ​

    order_marketing_result 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    total_amount
    number
    是
    商品总价,单位分
    10000
    available_marketing
    object(MarketingBundle)
    否
    订单维度可用的优惠信息
    ​
    unavailable_marketing
    object(MarketingBundle)
    否
    订单维度不可用的优惠信息
    ​

    calculation_result 元素结构说明

    名称
    类型
    是否必填
    描述
    示例值
    calculation_type
    ​
    number
    是
    算价类型
      •1:计算到goods层
      •2:计算到item层
    1
    total_amount
    number
    是
    订单总价格,单位: 分
    30000
    total_discount_amount
    ​
    number
    是
    订单总优惠价格,单位分,订单最终价格 = total_amount - total_discount_amount
    10000
    ​
    order_calculation_result_info
    ​
    object
    ​
    是
    订单算价结果信息
    ​
    order_calculation_result_info
    goods_calculation_result_info
    ​
    list<object>
    是
    商品算价结果信息
    ​
    [goods1_result,
    goods2_result]
    item_calculation_result_info
    list<object>
    否
    每一份商品算价结果信息
    [item1_result, item2_result]
    说明:
      1.订单原价total_amount,订单总优惠total_discount_amount
      ◦total_amount = sum(goods_calculation_result_info.total_amount) = sum(item_calculation_result_info.total_amount)
      ◦total_discount_amount=order_total_discount_amount + goods_total_discount_amount,订单总优惠金额=商品维度的优惠金额+订单维度的优惠金额
      2.calculation_type表示开发者计算优惠分摊的类型
      ◦calculation_type=1,开发者将优惠分摊到goods层,只需返回order_calculation_result_info,goods_calculation_result_info,交易系统会按均摊逻辑帮开发者计算到item层
      ◦calculation_type=2,开发者将优惠分摊到item层,需返回order_calculation_result_info,goods_calculation_result_info,item_calculation_result_info
      3.order_calculation_result_info,goods_calculation_result_info,item_calculation_result_info表达的是优惠分摊逻辑。order, goods, item代表订单的三层结构,order有N个goods,每个goods有M个item(M表示商品份数),item表示单份商品。订单总优惠金额 = order层的优惠明细聚合 = goods层的优惠明细聚合 = item层的优惠明细聚合
      4.举个例子,一笔订单购买2杯奶茶,总价100元,使用80-10活动和星冰乐单品立减5元优惠券,实付金额85元,表达分摊的逻辑如下
      ◦订单总优惠金额 total_discount_amount =1500,单位[分]
      ◦order层,order_calculation_result_info,order_total_discount_amount=1000,goods_total_discount_amount=500
      ◦goods层,goods_calculation_result_info数组长度为1,goods_calculation_result_info[0].total_discount_amount=1500
      ◦item层,item_calculation_result_info数组长度为2,items[0].total_discount_amount=750,items[1].total_discount_amount=750

    order_calculation_result_info 结构说明

      •整个订单实际优惠金 total_discount_amount = order_total_discount_amount + goods_total_discount_amount。
      •用户实付金额 = total_amount - total_discount_amount。
      •营销明细按照 discount_range 的聚合结果必须和 order_total_discount_amount/goods_total_discount_amount 一致。
      ◦order_total_discount_amount = sum(discount_range=1的marketing_detail.discount_amount)
      ◦goods_total_discount_amount = sum(discount_range=2的marketing_detail.discount_amount)
    名称
    类型
    是否必填
    描述
    示例值
    order_total_discount_amount
    number
    是
    订单维度总优惠金额,单位分,如订单满减
    5000
    ​
    goods_total_discount_amount
    number
    是
    商品维度总优惠金额,单位分,如咖啡第二杯半价
    1000
    marketing_detail_info
    ​
    list<MarketingDetail>
    否
    营销明细,包含该订单的订单维度和商品维度所有优惠信息
    ​
    [marketing_detail1, marketing_detail2]

    goods_calculation_result_info 元素结构说明

    说明:
      •商品 total_discount_amount 和营销明细聚合结果必须一致。
      ◦total_discount_amount = sum(marketing_detail.discount_amount)
      •所有商品的 total_amount/total_discount_amount 聚合结果必须和订单总total_amount/total_discount_amount 一致。
      ◦total_amount = sum(goods.total_amount)
      ◦total_discount_amount = sum(goods.total_discount_amount)
      •所有商品营销明细的聚合结果必须和订单营销明细一致(主要聚合 total_discount_amount 和 value)
      ◦例如,对于优惠券A:order层的marketing_detailA.discount_amount = sum(goods层的marketing_detailA.discount_amount)
      ◦order_total_discount_amount = sum(discount_range=1的marketing_detail.discount_amount)
      ◦goods_total_discount_amount = sum(discount_range=2的marketing_detail.discount_amount)
    名称
    类型
    是否必填
    描述
    示例值
    goods_id
    string
    是
    商品id
    "123rq0gjhdfoqierug"
    quantity
    number
    是
    购买数量
    1
    total_amount
    number
    是
    商品总价,单位分
    10000
    total_discount_amount
    ​
    number
    是
    该商品总优惠金额,该商品的实付金额 = total_amount - total_discount_amount
    5000
    ​
    marketing_detail_info
    list<MarketingDetail>
    否
    营销明细,包含该商品订单层和商品层所有优惠信息
    ​
    [marketing_detail1,
    marketing_detail2]
    ​

    item_calculation_result_info 元素结构说明

    说明:
      •item表示单份商品
      •仅当 calculation_type = 2 时会校验 item 算价结果。calculation_type=1时,系统会用默认均摊逻辑帮开发者计算item层的优惠分摊。
      •item total_discount_amount 和营销明细聚合结果必须一致。
      ◦total_discount_amount = sum(marketing_detail.discount_amount)
      •某个商品下的所有 item 的 total_amount/total_discount_amount 聚合结果必须和商品总 total_amount/total_discount_amount 一致。
      •item营销明细的聚合结果必须和商品营销明细一致(主要聚合 total_discount_amount 和 value)
      ◦例如,对于优惠券A:goods层的marketing_detailA.discount_amount = sum(item层的marketing_detailA.discount_amount)
    名称
    类型
    是否必填
    描述
    示例值
    goods_id
    string
    是
    商品id
    "123rq0gjhdfoqierug"
    total_amount
    number
    是
    商品总价,单位分
    10000
    total_discount_amount
    ​
    number
    是
    该商品总优惠金额,该商品的实付金额 = total_amount - total_discount_amount
    5000
    ​
    marketing_detail_info
    list<object>
    否
    营销明细,包含该 item 订单维度和商品维度所有优惠信息
    ​
    [marketing_detail1,
    marketing_detail2]

    MarketingDetail 结构说明

    说明:当 value 不为 0 的时候,discount_amount 不能为 0(即不允许消耗积分却没有折扣)。
      •marketing_detail_info在order,goods,item三个层级都有,区别是它表示某个营销项在这一层级分摊的优惠金额。比如一笔订单购买2杯奶茶,总价100元,使用优惠券A满100-10元,实付90元。优惠券A会出现在3个层级的marketing_detail_info里
      ▪在order层,detailA.discount_amount=1000,单位[分]
      ▪在goods层,detailA.discount_amount=1000,
      ▪在item层,由于优惠分摊到两份商品上,detailA1.discount_amount=500,detailA1.discount_amount=500
      •对于某个具体的优惠券,它出现在3个层级的优惠明细里,除了value和discount_amount由于分摊具体的值会不一样,其他属性值都是一样的
      •discount_range,表示优惠的维度,举个例子
      ◦星冰乐单品5折券属于商品维度优惠,discount_range=2
      ◦订单满200-20属于订单维度优惠,discount_range=1
    名称
    类型
    是否必填
    描述
    示例值
    id
    ​
    string
    是
    营销 id(用户身份 id,优惠券 id,积分 id 或者活动 id)
    ”ioejfioa"
    type
    ​
    number
    ​
    是
    ​
    营销类型,
      •1:用户身份
      •2:优惠券
      •3:积分
      •4:活动
    2
    ​
    discount_amount
    ​
    number
    是
    该营销策略优惠金额,单位分
    3000
    title
    string
    是
    营销名称
    "满 50 减 10 元"
    note
    string
    是
    营销备注
    "该优惠券仅在部分门店使用"
    subtype
    string
    否
    子营销类型
    礼品卡、满减券
    value
    ​
    number
    否
    营销分值,某些类型的营销会有,积分和 discount_amount 有一定的关系
    积分、卡的值
    消耗一定积分,换取一定优惠
    ​
    discount_range
    number
    ​
    是
    营销适用维度:
      •1:订单维度
      •2:商品维度
    1
    ​
    code
    string
    是
    优惠券编码
    "49dkjg04jf04kg"
    kind
    number
    是
    营销类别
    1:商家
    2:平台
    1
    creator_type
    number
    是
    创建人类型
    1:抖音平台
    2:抖音来客—商家
    3:小程序商家
    3
    marketing_extend
    object
    是
    扩展字段
    {}

    响应示例

    正常示例

    { "err_no": 0, "err_tips": "success", "data": { "goods_marketing_result": [ { "goods_id": "7116845279713691692", "quantity": 1, "total_amount": 100, "available_marketing": { "coupon_info": [ { "id": "coupon_id_90_fen_MOCK_", "code": "coupon_id_90_fen_MOCK_", "type": 2, "name": "满 0.91 减 0.90 元的满减优惠券", "start_time": 1665913600000, "end_time": 1666172800000, "receive_time": 1665913601000, "discount_amount": 90, "detail_url": "优惠券详情跳转链接", "rule": "【规则】coupon_id 和 coupon_code = coupon_id_90_fen_MOCK_ ; 券名 = 满 0.91 减 0.90 元的满减优惠券", "kind": 1, "creator_type": 3, "marketing_extend": {} } ], "score_info": [ { "id": "score_id_1_fen_MOCK_", "value": 10000, "name": "本店第 4 种积分类型", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "score_id_2_fen_MOCK_", "value": 10000, "name": "本店第 5 种积分类型", "kind": 1, "creator_type": 3, "marketing_extend": {} } ], "activity_info": [ { "id": "activity_id_2_fen_MOCK_", "name": "满 0.20 减 0.02 元的满减活动", "start_time": 1665913600000, "end_time": 1666172800000, "rule": "【规则】activity_id = activity_id_2_fen_MOCK_ ; 活动名 = 满 0.20 减 0.02 元的满减活动", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "activity_id_1_fen_MOCK_", "name": "满 0.10 减 0.01 元的满减活动", "start_time": 1665913600000, "end_time": 1666172800000, "rule": "【规则】activity_id = activity_id_1_fen_MOCK_ ; 活动名 = 满 0.10 减 0.01 元的满减活动", "kind": 1, "creator_type": 3, "marketing_extend": {} } ] }, "unavailable_marketing": { "coupon_info": [ { "id": "coupon_id_399_90_yuan_MOCK_", "code": "coupon_id_399_90_yuan_MOCK_", "type": 1, "name": "立减 399.90 元的立减优惠券", "start_time": 1665913600000, "end_time": 1666172800000, "receive_time": 1665913601000, "discount_amount": 39990, "detail_url": "优惠券详情跳转链接", "rule": "【规则】coupon_id 和 coupon_code = coupon_id_399_90_yuan_MOCK_ ; 券名 = 立减 399.90 元的立减优惠券", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "coupon_id_59_95_yuan_MOCK_", "code": "coupon_id_59_95_yuan_MOCK_", "type": 1, "name": "立减 59.95 元的立减优惠券", "start_time": 1665913600000, "end_time": 1666172800000, "receive_time": 1665913601000, "discount_amount": 5995, "detail_url": "优惠券详情跳转链接", "rule": "【规则】coupon_id 和 coupon_code = coupon_id_59_95_yuan_MOCK_ ; 券名 = 立减 59.95 元的立减优惠券", "kind": 1, "creator_type": 3, "marketing_extend": {} } ], "score_info": [ { "id": "score_id_life_100_yuan_MOCK_", "value": 8000, "name": "与本地生活融合专用积分-100元钱", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "score_id_life_200_yuan_MOCK_", "value": 8000, "name": "与本地生活融合专用积分-200元钱", "kind": 1, "creator_type": 3, "marketing_extend": {} } ], "activity_info": [ { "id": "activity_id_198_yuan_MOCK_", "name": "满 199.00 减 198.00 元的满减活动", "start_time": 1665913600000, "end_time": 1666172800000, "rule": "【规则】activity_id = activity_id_198_yuan_MOCK_ ; 活动名 = 满 199.00 减 198.00 元的满减活动", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "activity_id_man_200_50_fen_MOCK_", "name": "满 2.00 减 0.50 元的满减活动", "start_time": 1665913600000, "end_time": 1666172800000, "rule": "【规则】activity_id = activity_id_man_200_50_fen_MOCK_ ; 活动名 = 满 2.00 减 0.50 元的满减活动", "kind": 1, "creator_type": 3, "marketing_extend": {} } ] } } ], "order_marketing_result": { "total_amount": 100, "available_marketing": {}, "unavailable_marketing": {} }, "calculation_result": { "calculation_type": 1, "goods_calculation_result_info": [ { "goods_id": "7116845279713691692", "quantity": 1, "total_amount": 100, "total_discount_amount": 93, "marketing_detail_info": [ { "id": "activity_id_2_fen_MOCK_", "type": 4, "discount_amount": 2, "title": "[活动] 满 0.20 减 0.02 元", "note": "活动优惠", "discount_range": 2, "subtype": "商家侧子营销类型默认值", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "activity_id_1_fen_MOCK_", "type": 4, "discount_amount": 1, "title": "[活动] 满 0.10 减 0.01 元", "note": "活动优惠", "discount_range": 2, "subtype": "商家侧子营销类型默认值", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "coupon_id_90_fen_MOCK_", "type": 2, "discount_amount": 90, "title": "[券] 满 0.91 减 0.90 元", "note": "用券优惠", "discount_range": 2, "subtype": "商家侧子营销类型默认值", "kind": 1, "creator_type": 3, "marketing_extend": {}, "code": "coupon_id_90_fen_MOCK_" } ], "sku_id": null } ], "order_calculation_result_info": { "order_total_discount_amount": 0, "goods_total_discount_amount": 93, "marketing_detail_info": [ { "id": "activity_id_2_fen_MOCK_", "type": 4, "discount_amount": 2, "title": "[活动] 满 0.20 减 0.02 元", "note": "活动优惠", "discount_range": 2, "subtype": "商家侧子营销类型默认值", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "activity_id_1_fen_MOCK_", "type": 4, "discount_amount": 1, "title": "[活动] 满 0.10 减 0.01 元", "note": "活动优惠", "discount_range": 2, "subtype": "商家侧子营销类型默认值", "kind": 1, "creator_type": 3, "marketing_extend": {} }, { "id": "coupon_id_90_fen_MOCK_", "type": 2, "discount_amount": 90, "title": "[券] 满 0.91 减 0.90 元", "note": "用券优惠", "discount_range": 2, "subtype": "商家侧子营销类型默认值", "kind": 1, "creator_type": 3, "marketing_extend": {}, "code": "coupon_id_90_fen_MOCK_" } ] }, "item_calculation_result_info": [], "total_amount": 100, "total_discount_amount": 93 } } }

    异常示例

    { "err_no": 10000, "err_tips": "参数错误" }

    错误码

    响应错误码 0 代表成功,其他代表错误
    错误码
    错误提示
    建议解决方案
    28001007
    参数不合法
    根据错误提示检查具体的字段是否符合要求
    10000
    参数不合法
    根据错误提示检查具体的字段是否符合要求
    13000
    系统错误
    请重试,若持续出错,请联系oncall
    21015
    开发者返回的参数非法
    开发者的营销查询算价二合一扩展点返回的参数不合法,请检查扩展点响应
    24001
    外部调用出错
    开发者的营销查询算价二合一扩展点调用异常,请检查扩展点实现
    ​