Files
order_site/docs/xianyu_api/确认收货后通知.md
T
2026-04-23 20:29:22 +08:00

43 lines
2.0 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
确认收货后通知
简要描述: 推送示例
确认收货后,推送对应消息。
推送的签名请务必验证,以验证数据来源的合法性。验证方法参考以下说明。
推送时,有可能消息重复推送。实际开发中,请一定要在使用消息前进行去重判断。主要依据是订单编号Tid和订单状态。
推送方式,用jquery做示例:$.post('http://test.com/agiso?timestamp=11222212121&sign=f8aa165fc951f266667e0605d78b93af&aopic=32768', { json: '{"Tid":"592823138",......}' })
推送参数:
fromPlatform
string
Query/Get
平台,参数值:TbAcs,TbAlds,TbArs,Print,Acpr,PddAlds,AldsIdle,AldsJd,AldsDoudian,AldsKwai,AldsYouzan,AldsWeidian,AldsWxVideoShop,AldsXhs,Open
timestamp
Number
Query/Get
时间戳
aopic
Number
Query/Get
推送类型,16:确认收货后;
sign
String
Query/Get
签名算法:
将json和timestamp参数名和参数值组合起来(注意:json在前,timestamp在后),然后前后添加上AppSecret ,再进行Md5加密(加密算法参考接入指南-完整调用API示例代码中MD5算法)。
例:
urlhttp://test.com/agiso?timestamp=11222212121&sign=f8aa165fc951f266667e0605d78b93af&aopic=256
postData: { json: {"Tid":2067719225654838,"Status":"WAIT_BUYER_CONFIRM_GOODS",......,"TotalFee":"3.00"} }
_appsecret: 9f8g9d78sg9d8f8ew9f89ds9f8ds9af8(开发者AppSecret)
连接后的串: 9f8g9d78sg9d8f8ew9f89ds9f8ds9af8json{"Tid":2067719225654838,"Status":"WAIT_BUYER_CONFIRM_GOODS",......,"TotalFee":"3.00"}timestamp112222121219f8g9d78sg9d8f8ew9f89ds9f8ds9af8
再对连接后的字符串,进行MD5加密,
MD5结果: f8aa165fc951f266667e0605d78b93af(不区分大小写)
json
String
Form/Post
推送消息,如:
{
"biz_order_id": 9112588, // 交易订单号
"item_id": 1, // 商品Id
"order_status": 2,// 订单状态 0:未知状态、1:订单已创建、2:订单已付款、3:已发货、4:交易成功、5:已退款、6:交易关闭
"seller_id": 1556356040640, // 闲鱼商家的Id
}