获取订单详情
获取订单详情
1.请求参数:
请求URL:
| 参数名称 | 参数类型 | 是否必须 | 示例值 | 参数描述 |
|---|---|---|---|---|
| appid | String | 是 | 合作伙伴AppId | |
| timestamp | String | 是 | 1657525936 | 当前Unix时间戳,秒 |
| seller_nick | String | 是 | 38173182 | 店铺账号,对应蜂巢授权返回seller_nick字段 |
| sign | String | 是 |
业务参数
| 参数名称 | 参数类型 | 是否必须 | 参数描述 |
|---|---|---|---|
| order_id | string | 是 | 订单ID,可从获取订单列表中获 |
2. 请求示例代码(Java)
@Test
public void GetOrderDetail() throws Exception {
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("order_id", "2222");
// 参数签名
data.put("sign", Utils.Sign(data, Config.AppSecret));
String result = doHttpRequest(apiUrl, data);
System.out.println("result:"+result);
}
3. 返回结果
返回结果如下
{
"code": 0,
"message": "获取成功",
"data": {
"order_id": "3721511129515429888",
"create_time": 1722048529,
"update_time": 1725526319,
"status": 20,
"order_detail": {
"product_infos": [
{
"product_id": "10000102290752",
"sku_id": "2059341850",
"thumb_img": "https://store.mp.video.tencent-cloud.com/161/20304/snscosdownload/SH/reserved/65eea59c0000d737145e57747b07bd1e000000a100004f50",
"sale_price": 880,
"sku_cnt": 1,
"title": "大号仿真减压神器包子发泄捏捏乐慢回弹减压玩具仿真小笼包",
"on_aftersale_sku_cnt": 0,
"finish_aftersale_sku_cnt": 0,
"sku_code": "面粉笼装包子",
"market_price": 880,
"sku_attrs": [
{
"attr_key": "颜色",
"attr_value": "面粉笼装包子"
}
],
"real_price": 880,
"is_discounted": false,
"estimate_price": 880,
"out_warehouse_id": "",
"sku_deliver_info": {
"stock_type": 0
},
"extra_service": {
"seven_day_return": 1,
"freight_insurance": 0
},
"voucher_list": [],
"order_product_coupon_info_list": [],
"package_sku_list": [],
"delivery_deadline": 1722221336,
"merchant_discounted_price": 0,
"finder_discounted_price": 0
}
],
"pay_info": {
"payment_method": 1,
"prepay_id": "up_wx271048500947779fde56c7686505aa0001",
"prepay_time": 1722048530,
"pay_time": 1722048536,
"transaction_id": "4340002259202407271255714192"
},
"price_info": {
"product_price": 880,
"order_price": 880,
"freight": 0,
"estimate_product_price": 880,
"merchant_receieve_price": 880,
"merchant_discounted_price": 0,
"finder_discounted_price": 0
},
"delivery_info": {
"address_info": {
"user_name": "小*",
"postal_code": "362400",
"province_name": "福建省",
"city_name": "泉州市",
"county_name": "安溪县",
"detail_info": "****",
"national_code": "888888",
"tel_number": "131****2717",
"house_number": "",
"virtual_order_tel_number": "",
"use_tel_number": 0,
"hash_code": "3e6d517ece55cd7fe4c1fe96124471c2"
},
"delivery_product_info": [],
"ship_done_time": 0,
"deliver_method": 0,
"ewaybill_order_code": "ofTT8GgcLBP7xt3BXLmdPPcOq9MRPuj09ktT_nPQmBeLOF4xRDFaC-4p26TDdJm86ZZjhHtV8EJA"
},
"ext_info": {
"customer_notes": "",
"merchant_notes": "",
"finder_id": "sphnLvG8VBhSEmt",
"order_scene": 4
},
"commission_infos": [],
"sharer_info": {
"sharer_openid": "oX-6L69i5_TkW2dsIDfNGu5ZfUOM",
"sharer_unionid": "",
"sharer_type": 1,
"share_scene": 5,
"handling_progress": 1
},
"settle_info": {
"predict_commission_fee": 44
},
"sku_sharer_infos": [
{
"sharer_openid": "oX-6L69i5_TkW2dsIDfNGu5ZfUOM",
"sharer_type": 1,
"share_scene": 5,
"sku_id": "2059341850",
"from_wecom": false
}
]
},
"aftersale_detail": {
"aftersale_order_list": [],
"on_aftersale_order_cnt": 0
},
"openid": "oX-6L654jt2kBlxywqAaQM6DmbyI"
}
}
返回code为0表示成功, 非0为失败,失败时message会有失败原因。
文档更新时间: 2025-12-29 20:25 作者:admin