taobao.promotionmisc.common.item.detail.update (修改通用单品优惠详情)

修改通用单品优惠详情。 1、该接口只修改活动下参与的商品的优惠信息,如需要增加、删除活动,请调用taobao.promotionmisc.common.item.activity.add和taobao.promotionmisc.common.item.activity.delete接口; 2、使用该接口时需要把未做修改的字段值也传入; 3、此接口受卖家最低折扣限制,如果优惠力度大于卖家设置的最低折扣则不能修改

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
activity_id Number 必须 12345 优惠活动ID
detail_id Number 必须 123456 优惠详情ID
item_id Number 必须 112233 商品ID
promotion_type Number 必须 1 优惠类型,只有两种可选值:0-减钱;1-打折
promotion_value Number 必须 900 优惠力度,其值的解释方式由promotion_type定义:当为减钱时解释成减钱数量,如:900表示减9元;当为打折时解释成打折折扣,如:900表示打9折

响应参数

名称 类型 示例值 描述
is_success Boolean true 是否修改成功

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
PromotionmiscCommonItemDetailUpdateRequest req = new PromotionmiscCommonItemDetailUpdateRequest();
req.setActivityId(12345L);
req.setDetailId(123456L);
req.setItemId(112233L);
req.setPromotionType(1L);
req.setPromotionValue(900L);
PromotionmiscCommonItemDetailUpdateResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<promotionmisc_common_item_detail_update_response>
    <is_success>true</is_success>
</promotionmisc_common_item_detail_update_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>

错误码解释

错误码 错误描述 解决方案
isv.invalid-parameter:xxx 参数无效 修正调用参数后重试
isv.activity-not-exist 优惠活动不存在 确认优惠活动ID是否正确
isv.detail-not-exist 优惠详情不存在 确认优惠详情ID是否正确
isv.too-low-benefit-price 优惠力度超过卖家设置的最低折扣的限制 修改优惠力度或卖家调整最低折扣设置
isv.item-not-exist 商品不存在 确认商品ID是否正确

API工具

如何获得此API

FAQ

返回
顶部