文档中心 > API类目 > 天猫新品平台API

tmall.brand.item.coupon.protect (全域新品店铺优惠券免除)

全域新品店铺优惠券免除申请打标接口

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
item_id Number 必须 1000001 天猫商品id
protection_period String 必须 PERIOD_0D 店铺优惠券新品保护期档次:PERIOD_0D("0天"), PERIOD_7D("7天"), PERIOD_14D("14天"), PERIOD_21D("21天")
brand_id Number 必须 888888 天猫品牌id

响应参数

名称 类型 示例值 描述
resp_success Boolean true 店铺优惠券保护期设置是否成功
error_msg String 店铺优惠券保护期设置失败 错误信息
value String 店铺优惠券保护期设置成功 返回结果
resp_error_code String 1001 错误码

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
TmallBrandItemCouponProtectRequest req = new TmallBrandItemCouponProtectRequest();
req.setItemId(1000001L);
req.setProtectionPeriod("PERIOD_0D");
req.setBrandId(888888L);
TmallBrandItemCouponProtectResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<tmall_brand_item_coupon_protect_response>
    <resp_success>true</resp_success>
    <error_msg>店铺优惠券保护期设置失败</error_msg>
    <value>店铺优惠券保护期设置成功</value>
    <resp_error_code>1001</resp_error_code>
</tmall_brand_item_coupon_protect_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部