跳转到内容
返回官网

更改交易的收货地址

只能更新一笔交易里面的买家收货地址 只能更新发货前(即买家已付款,等待卖家发货状态)的交易的买家收货地址 更新后的发货地址可以通过taobao.trade.fullinfo.get查到 参数中所说的字节为GBK编码的(英文和数字占1字节,中文占2字节)

一、请求参数

请求URL:

POST https://kf.fw199.com/gateway/taobao/order/shippingaddress/update

参数名类型必须示例值说明
appidStringtrueuwkahf@jfs92合作伙伴AppId
timestampStringtrue1633618722当前时间戳
tb_seller_nickStringtruekingdo淘宝卖家店铺登录账号,非店铺名称
signStringtrue999de41d862efaa6f1084ead3b3ba480如何计算生成见示例代码
tidNumbertrue123456789交易编号。
receiver_nameStringfalse马云收货人全名。最大长度为50个字节。
receiver_phoneStringfalse123456789固定电话。最大长度为30个字节。
receiver_mobileStringfalse13600000000移动电话。最大长度为11个字节。
receiver_stateStringfalse浙江省份。最大长度为32个字节。如:浙江
receiver_cityStringfalse杭州城市。最大长度为32个字节。如:杭州
receiver_districtStringfalse西湖区区/县。最大长度为32个字节。如:西湖区
receiver_addressStringfalsexx路xx号收货地址。最大长度为228个字节。
receiver_zipStringfalse310001邮政编码。必须由6个数字组成。
receiver_townStringfalse五常街道四级地址。最大长度为32个字节。如:五常街道

二、请求示例代码

Java

@Test
public void TaoBaoOrderShippingAddressUpdate() throws Exception {
String tb_seller_nick = Config.TBSellerNick ;
//业务参数
Map<String, String> data = new HashMap<String, String>();
data.put("appid", Config.AppId);
Long timestamp = System.currentTimeMillis() / 1000;
data.put("timestamp", timestamp.toString());
data.put("tb_seller_nick", Config.TBSellerNick);
data.put("tid", "2145482892651565830");
data.put("receiver_name", "习大牛");
data.put("receiver_mobile", "13817778899");
// 签名
data.put("sign", Utils.Sign(data,Config.AppSecret));
// 调用服务API
doHttpRequest(Config.TaoBaoOrderShippingAddressUpdateUrl ,data);
}

三、返回结果

返回结果如下

{
"code":0,
"message":"ok",
"data":{
"request_id":"h26zqqddmyhz",
"trade":{
"modified":"2021-10-09 11:48:10",
"tid":"2145482892651565830"
}
},
"trace_id":""
}

说明: code为0表示成功,非0为失败,message会包含失败原因。