获取订单详情

更新时间:2023-06-15 05:56:21

本文介绍获取订单详情的 API。

接口描述

根据订单 ID 获取订单详情。

接口地址

GET: /v1.0/sellercenter/order/{order_id}

请求参数

参数名 类型 参数位置 是否必填 说明
order_id String uri true 订单 ID
mall_code String query true 商城编码
site_code String query true 站点编码
lang String query false 语种编码

返回参数

参数名 类型 说明
result OrderDetailOpenVO 查询结果

result 说明

参数名 类型 说明
order_id String 订单唯一编号
order_type_code String 订单类型编码
order_status String 订单状态
amount_origin BigDecimal 订单原价
amount_trade BigDecimal 订单成交价
amount_paid BigDecimal 订单已支付金额
amount_rest BigDecimal 剩余要支付的金额
price_trade_list List 订单总价明细
gmt_order_create Long 订单创建时间
gmt_order_pay Long 订单支付时间
commodity_list List 订单商品列表
currency String 货币单位
payment_list List 订单支付流水
refund_status Integer 订单退款状态
amount_refund BigDecimal 订单退款金额
address AddressVO 收货地址信息
delivery_list List 包裹单信息
order_flow_list List 订单状态流水
customer CustomerVO 买家信息
remark String 卖家备注
buyer_remark String 买家备注

commodity_list 说明

参数名 类型 说明
commodity_code String 商品编码
specification_code String 商品SKU
commodity_name String 商品名称
icon_url String 商品图片
currency String 货币单位
unit_price_origin BigDecimal 单价原价
unit_price_trade BigDecimal 单价成交价
unit_name String 单价单位。片、件、次等
quantity Integer 商品数量
attach_json JSONObject 商品附加信息

address 说明

参数名 类型 说明
address_id String 地址 ID
name String 收货人
phone String 联系电话
country String 国家
country_code String 国家编码
province String 省份
city String 城市
district String 区、县
address_detail String 详细地址
address String 整个地址
is_default Byte 是否默认
post_code String 邮编
site String 站点
address_type Integer 类型

delivery_list 说明

参数名 类型 说明
delivery_id String 包裹 ID
delivery_status Integer 包裹状态
gmt_out_stock Long 发货时间
logistics_company String 物流公司编码
logistics_company_name String 物流公司名称
logistics_no String 物流单号
delivery_quantity Integer 包裹SKU总数
delivery_detail_list List 包裹发货详情

order_flow_list 说明

参数名 类型 说明
order_flow_id String 订单业务流水表主键
order_id String 订单 ID
creator_id String 操作者 ID
order_status_boss String 主订单状态,标准订单状态
order_status String 订单状态
gmt_create Long 创建时间
gmt_modified Long 修改时间

price_trade_list 说明

参数名 类型 说明
key String 价格明细编码
price_detail_name String 价格明细名称
amount BigDecimal 售价
amount_origin BigDecimal 原价
amount_coupon BigDecimal 优惠金额
attach JSONObject 附加信息

payment_list 说明

参数名 类型 说明
trade_amount BigDecimal 支付金额
currency String 货币单位
paid_provider String 支付提供商
paid_type String 支付类型
transaction_no String 交易号
gmt_create Long 创建时间
trade_status String 支付状态

customer 说明

参数名 类型 说明
uid String 买家id
name String 昵称
mobile String 电话
email String 邮箱

delivery_detail_list 说明

参数名 类型 说明
commodity_code String 订单商品 ID
sku_code String 商品 SKU
delivery_quantity Integer 出库数量

请求示例

GET: /v1.0/sellercenter/order/test_order_id?mall_code=MALL_CODE&site_code=SITE_CODE

返回示例

{
    "result": {
        "amount_paid": {
            "Value": "1.04"
        },
        "address": {
            "country": "中国",
            "address": "北京市市辖区东城区gdichakjcn",
            "address_type": 0,
            "city": "市辖区",
            "address_id": "7a33441805a4934a8",
            "is_default": 1,
            "address_detail": "gdichakjcn",
            "country_code": "86",
            "site": "CN",
            "province": "北京市",
            "phone": "136****6837",
            "scope_id": "SO2110258K167O5C",
            "district": "东城区",
            "name": "ewfdjfutjghsnewfdjfutjghsnewfdjfutjghr",
            "scope_type": "order"
        },
        "refund_status": -2,
        "delivery_list": [
            {
                "logistics_no": "1111",
                "delivery_id": "142837559e57c000",
                "gmt_out_stock": 0,
                "logistics_company": "agopost",
                "delivery_status": 2,
                "logistics_company_name": "全程快递",
                "delivery_detail_list": [
                    {
                        "commodity_code": "CMar68c6bxxgs4",
                        "delivery_quantity": 1,
                        "sku_code": "SKar68c6djd4q0"
                    }
                ]
            },
            {
                "logistics_no": "1235YT",
                "delivery_id": "14283767dbb78000",
                "gmt_out_stock": 0,
                "logistics_company": "annto",
                "delivery_status": 2,
                "logistics_company_name": "安得物流",
                "delivery_detail_list": [
                    {
                        "commodity_code": "CMaowxikwzdohw",
                        "delivery_quantity": 1,
                        "sku_code": "SKaowxikzha0y3"
                    },
                    {
                        "commodity_code": "CMa1kxmeidi592",
                        "delivery_quantity": 1,
                        "sku_code": "SKa1kxmekswldn"
                    }
                ]
            }
        ],
        "order_flow_list": [
            {
                "gmt_create": 1635131166548,
                "order_flow_id": "1452471502836826112",
                "gmt_modified": 1635131166548,
                "order_status": "created",
                "creator_id": "sh1620790178699Ms6LM",
                "order_status_boss": "created",
                "order_id": "SO2110258K167O5C"
            },
            {
                "gmt_create": 1635131169674,
                "order_flow_id": "1452471515946139648",
                "gmt_modified": 1635131169674,
                "order_status": "paid",
                "creator_id": "sh1620790178699Ms6LM",
                "order_status_boss": "paid",
                "order_id": "SO2110258K167O5C"
            },
            {
                "gmt_create": 1635131169720,
                "order_flow_id": "1452471516139077632",
                "gmt_modified": 1635131169720,
                "order_status": "pending_audit_paid",
                "creator_id": "sh1620790178699Ms6LM",
                "order_status_boss": "",
                "order_id": "SO2110258K167O5C"
            },
            {
                "gmt_create": 1635131193523,
                "order_flow_id": "1452471615976095744",
                "gmt_modified": 1635131193523,
                "order_status": "paid",
                "creator_id": "sh15408881429088tZ2u",
                "order_status_boss": "paid",
                "order_id": "SO2110258K167O5C"
            },
            {
                "gmt_create": 1635131218863,
                "order_flow_id": "1452471722259759104",
                "gmt_modified": 1635131218863,
                "order_status": "part_delivered",
                "creator_id": "sh15408881429088tZ2u",
                "order_status_boss": "",
                "order_id": "SO2110258K167O5C"
            },
            {
                "gmt_create": 1635131237380,
                "order_flow_id": "1452471799927767040",
                "gmt_modified": 1635131237380,
                "order_status": "delivered",
                "creator_id": "sh15408881429088tZ2u",
                "order_status_boss": "delivered",
                "order_id": "SO2110258K167O5C"
            },
            {
                "gmt_create": 1635131538982,
                "order_flow_id": "1452473064938242048",
                "gmt_modified": 1635131538982,
                "order_status": "finished",
                "creator_id": "system",
                "order_status_boss": "finished",
                "order_id": "SO2110258K167O5C"
            }
        ],
        "amount_origin": {
            "Value": "1.04"
        },
        "amount_rest": {
            "Value": "0.00"
        },
        "price_trade_list": [
            {
                "amount": {
                    "Value": "1.00"
                },
                "amount_coupon": {
                    "Value": "0.00"
                },
                "amount_origin": {
                    "Value": "100.000000"
                },
                "price_detail_name": "运费",
                "key": "POSTAGE"
            },
            {
                "amount": {
                    "Value": "0.03"
                },
                "amount_coupon": {
                    "Value": "0.00"
                },
                "amount_origin": {
                    "Value": "3.000000"
                },
                "price_detail_name": "商品总价",
                "key": "COMMODITY"
            },
            {
                "amount": {
                    "Value": "0.01"
                },
                "amount_coupon": {
                    "Value": "0.00"
                },
                "amount_origin": {
                    "Value": "1.000000"
                },
                "price_detail_name": "安装费",
                "key": "INSTALL"
            }
        ],
        "amount_trade": {
            "Value": "1.04"
        },
        "payment_list": [
            {
                "gmt_create": 1635131169624,
                "paid_type": "cod",
                "paid_provider": "offline_pay",
                "trade_amount": {
                    "Value": "1.04"
                },
                "trade_status": "TRADE_SUCCESS",
                "currency": "CNY"
            }
        ],
        "order_type_code": "INT_OEM_APP_MALL",
        "buyer_remark": "",
        "commodity_list": [
            {
                "icon_url": "ecommerce/162633217319c17fa480b.png",
                "commodity_code": "CMar68c6bxxgs4",
                "quantity": 1,
                "unit_price_origin": {
                    "Value": "0.01"
                },
                "attach_json": {
                    "amount_after_coupon": {
                        "Value": "0.01"
                    },
                    "commodity_amount_origin": {
                        "Value": "0.01"
                    },
                    "install_type": "2",
                    "price_detail": [
                        {
                            "amount": {
                                "Value": "0.01"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.01"
                            },
                            "price_detail_name": "商品总价",
                            "key": "COMMODITY"
                        },
                        {
                            "amount": {
                                "Value": "0.01"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.01"
                            },
                            "price_detail_name": "安装费",
                            "key": "INSTALL"
                        },
                        {
                            "amount": {
                                "Value": "0.33"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.33"
                            },
                            "price_detail_name": "运费",
                            "key": "POSTAGE"
                        }
                    ],
                    "sku_value_list": [
                        "1M",
                        "干电池"
                    ],
                    "extend_sku_code": ""
                },
                "unit_price_trade": {
                    "Value": "0.35"
                },
                "specification_code": "SKar68c6djd4q0",
                "currency": "CNY",
                "commodity_name": "安装费+运费"
            },
            {
                "icon_url": "ecommerce/886c9816-4785-4e92-8883-51e2da1603ee.png",
                "commodity_code": "CMaowxikwzdohw",
                "quantity": 1,
                "unit_price_origin": {
                    "Value": "0.01"
                },
                "attach_json": {
                    "amount_after_coupon": {
                        "Value": "0.01"
                    },
                    "commodity_amount_origin": {
                        "Value": "0.01"
                    },
                    "install_type": "1",
                    "price_detail": [
                        {
                            "amount": {
                                "Value": "0.01"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.01"
                            },
                            "price_detail_name": "商品总价",
                            "key": "COMMODITY"
                        },
                        {
                            "amount": {
                                "Value": "0.00"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.00"
                            },
                            "price_detail_name": "安装费",
                            "key": "INSTALL"
                        },
                        {
                            "amount": {
                                "Value": "0.00"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.00"
                            },
                            "price_detail_name": "运费",
                            "key": "POSTAGE"
                        }
                    ],
                    "sku_value_list": [
                        "白色",
                        "S"
                    ],
                    "extend_sku_code": ""
                },
                "unit_price_trade": {
                    "Value": "0.01"
                },
                "specification_code": "SKaowxikzha0y3",
                "currency": "CNY",
                "commodity_name": "无安装费+运费"
            },
            {
                "icon_url": "ecommerce/16226962402ab330a5cfd.png",
                "commodity_code": "CMa1kxmeidi592",
                "quantity": 1,
                "unit_price_origin": {
                    "Value": "0.01"
                },
                "attach_json": {
                    "amount_after_coupon": {
                        "Value": "0.01"
                    },
                    "commodity_amount_origin": {
                        "Value": "0.01"
                    },
                    "install_type": "1",
                    "price_detail": [
                        {
                            "amount": {
                                "Value": "0.01"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.01"
                            },
                            "price_detail_name": "商品总价",
                            "key": "COMMODITY"
                        },
                        {
                            "amount": {
                                "Value": "0.00"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.00"
                            },
                            "price_detail_name": "安装费",
                            "key": "INSTALL"
                        },
                        {
                            "amount": {
                                "Value": "0.00"
                            },
                            "amount_coupon": 0,
                            "amount_origin": {
                                "Value": "0.00"
                            },
                            "price_detail_name": "运费",
                            "key": "POSTAGE"
                        }
                    ],
                    "sku_value_list": [
                        "绿色"
                    ],
                    "extend_sku_code": ""
                },
                "unit_price_trade": {
                    "Value": "0.01"
                },
                "specification_code": "SKa1kxmekswldn",
                "currency": "CNY",
                "commodity_name": "mll包邮活动测试商品"
            }
        ],
        "order_status": "finished",
        "amount_refund": {
            "Value": "0.00"
        },
        "currency": "CNY",
        "gmt_order_create": 1635131166093,
        "order_id": "SO2110258K167O5C",
        "customer": {
            "mobile": "86-159****9374",
            "uid": "sh1**************6LM",
            "name": "",
            "email": "nai********@tuya.com"
        }
    },
    "t": 1635167709597,
    "success": true
}

错误码

参考 错误码