跳转到内容
返回官网

发货接口

一、请求参数

请求URL:

POST https://kf.fw199.com/gateway/wxv/logistics/send

参数名称参数类型是否必须示例值参数描述
appidString合作伙伴AppId
timestampString1657525936当前Unix时间戳,秒
seller_nickString38173182店铺账号,对应蜂巢授权返回seller_nick字段
signString

业务参数

参数名称参数类型是否必须示例值参数描述
request_dataJSON报文

二、请求示例代码

Java

@Test
public void logisticsSend() throws Exception {
String reqData = "{\n" + " \"order_id\": \"8\",\n" + " \"delivery_list\": [\n" + " {\n" + " \"delivery_id\": \"ZTO\",\n" + " \"waybill_id\": \"73612959240139\",\n" + " \"deliver_type\": 1,\n" + " \"product_infos\": [\n" + " {\n" + " \"product_id\": \"63\",\n" + " \"sku_id\": \"82\",\n" + " \"product_cnt\": 24\n" + " },\n" + " {\n" + " \"product_id\": \"30\",\n" + " \"sku_id\": \"38\",\n" + " \"product_cnt\": 69\n" + " }\n" + " ]\n" + " }\n" + " ]\n" + "}\n";
String sellerNick = "xxx";
//业务参
Map<String, String> data = new HashMap();
data.put("appid", Config.AppId);
data.put("seller_nick", sellerNick);
Long timestamp = System.currentTimeMillis();
data.put("timestamp", timestamp.toString());
data.put("request_data", reqData);
// 参数签名
data.put("sign", Utils.Sign(data, Config.AppSecret));
String result = doHttpRequest(apiUrl, data);
System.out.println("result:"+result);
}

三、返回结果

返回结果如下

{
"code": 0,
"message": "处理成功",
"data": {
"status": true,
"message": "ok"
}
}

返回code为0表示成功, 非0为失败,失败时message会有失败原因。