商品下架接口

1、支持所有类型商品下架
2、接口调用成功,商品会放到仓库中。
3、商品上架请使用【product/editV2】商品更新接口,请求参数传值commit=true即表示提交上架。

请求URL:

POST https://kf.fw199.com/gateway/dd/product/set/offline

公共参数

参数名称 参数类型 是否必须 示例值 参数描述
appid String 合作伙伴AppId
timestamp String 1657525936 当前Unix时间戳,秒
seller_nick String 38173182 抖店的账号,对应蜂巢授权返回doudianseller字段
sign String

业务参数

参数名称 参数类型 是否必须 示例值 参数描述
product_id - 356654869456454 商品ID
outer_product_id String 2333424 推荐使用,外部商家编码,支持字符串。
store_id - 12345 小时达二期店铺场景才可以传,小时达二期场景可以通过传入主品id+门店id对该门店下的子品进行操作

2. 请求示例代码(Java)

请求示例代码

    @Test
    public void  DDProductSetoffline() throws Exception {
        Map<String, Object> data = new HashMap<String, Object>();
        data.put("appid",  Config.AppId);
        Long timestamp = System.currentTimeMillis() / 1000;
        data.put("timestamp", timestamp.toString());
        data.put("seller_nick", Config.DDSellerNick);
        data.put("product_id","3684948274437030273" );
        data.put("outer_product_id","2333424" );
        data.put("store_id","12345" );
        data.put("sign", Sign(data,Config.AppSecret));
        // 调用服务API
        String resp = doHttpRequest(Config.DDProductSetOffline, data);
        System.out.println(resp);
    }

3. 返回结果如下:


{"code":0,"message":"ok","data":null}

说明: code为0表示成功,非0为失败,message会包含失败原因。返回字段说明见文档
https://op.jinritemai.com/docs/api-docs/14/252

文档更新时间: 2024-05-21 17:38   作者:JSL