獲取訂單狀態

按現有訂單的指定訂單編號獲取訂單狀態。

相關URL

Newegg.com: https://api.newegg.com/marketplace/ordermgmt/orderstatus/orders/{ordernumber}?sellerid={sellerid}&version={version}
Neweggbusiness.com: https://api.newegg.com/marketplace/b2b/ordermgmt/orderstatus/orders/{ordernumber}?sellerid={sellerid}&version={version}
Newegg.ca: https://api.newegg.com/marketplace/can/ordermgmt/orderstatus/orders/{ordernumber}?sellerid={sellerid}&version={version}

註:請確保您的請求URL全都是小寫(除Seller ID)並且不能包含任何空格或者分行符號。

參數

名稱 是否必填? 描述
sellerid 您在新蛋商城的商家編號
ordernumber 訂單編號
version 可用版本號:304

相關請求資訊

HTTP方式 是否需要認證 請求格式 回覆格式 頻率限制
GET 需要 XML,Json XML,Json 500 請求/小時

請求文件主體

示例:XML, Request

GET https://api.newegg.com/marketplace/ordermgmt/orderstatus/orders/{ordernumber}?sellerid={sellerid}
Authorization: 720ddc067f4d115bd544aff46bc75634
SecretKey: 21EC2020-3AEA-1069-A2DD-08002B30309D
Content-Type: application/xml
Accept: application/xml

示例:Json, Request

GET https://api.newegg.com/marketplace/ordermgmt/orderstatus/orders/{ordernumber}?sellerid={sellerid}
Authorization: 720ddc067f4d115bd544aff46bc75634
SecretKey: 21EC2020-3AEA-1069-A2DD-08002B30309D
Content-Type: application/json
Accept: application/json

回覆文件主體

屬性 格式 描述
OrderNumber String 符合您搜索條件的訂單編號。
OrderStatusCode Integer 訂單狀態的有效值:

  • 0.  Unshipped(未發貨)
  • 1.  PartiallyShipped(部分發貨)
  • 2.  Shipped(已全部發貨)
  • 3.  Invoiced(交易完成)
  • 4.  Void (作廢訂單)
OrderStatusName String 狀態描述:

  • Unshipped(未發貨):訂單狀態碼 0.
  • PartiallyShipped(部分發貨):訂單狀態碼 1.
  • Shipped(已全部發貨):訂單狀態碼 2.
  • Invoiced(交易完成):訂單狀態碼 3.
  • Void(作廢訂單):訂單狀態碼 4.
SellerID String 您的商家編號
OrderDownloaded String
  • False:訂單還未被下載
  • True:訂單已被下載

當訂單已發貨,這個欄位將自動變為“True”

SalesChannel Integer 訂單的銷售管道:

  • 0. Newegg order (新蛋訂單)
  • 1. Multi-channel order(其他銷售管道訂單)
  • 2. Replacement order (換貨訂單)
  • 3. NWS order (Newegg.com only)

只可用版本號:304

FulfillmentOption Integer 訂單運送選項:

  • 0. Ship by Seller(商家配送)
  • 1. Ship by Newegg (新蛋配送)

只可用版本號:304

Schema: GetOrderStatusResponse.xsd

示例:XML, Response

<?xml version="1.0" encoding="utf-8"?>
<QueryOrderStatusInfo>
    <OrderNumber>159243598</OrderNumber>
    <SellerID>A006</SellerID>
    <OrderStatusCode>1</OrderStatusCode>
    <OrderStatusName>PartiallyShipped</OrderStatusName>
    <OrderDownloaded>true</OrderDownloaded>
    <SalesChannel>0</SalesChannel>
    <FulfillmentOption>0</FulfillmentOption>
</QueryOrderStatusInfo>

示例:Json, Response

{
    "OrderDownloaded": true,
    "OrderNumber": "159243598",
    "OrderStatusCode": 1,
    "OrderStatusName": "PartiallyShipped",
    "SellerID": "A006",
    "SalesChannel": 0,
    "FulfillmentOption": 0
}

請求失敗錯誤資訊

常規HTTP錯誤回應,請參考回覆失敗錯誤代碼清單

錯誤代碼 描述
SO002 Order Number should be an integer (ranging from 1 to 2147483647)

訂單編號應為整數 (區間為 1 到 2147483647)。

SO003 No data found or this order does not belong to this seller

找不到資料或此訂單不屬於此商家。

示例:XML, Response

<?xml version="1.0" encoding="utf-8"?>
<Errors>
    <Error>
        <Code>SO002</Code>
        <Message>Order Number should be an integer (ranging from 1 to 2147483647)</Message>
    </Error>
</Errors>

示例:Json, Response

[
    {
        "Code": "SO002",
        "Message": "Order Number should be an integer (ranging from 1 to 2147483647)"
    }
]

更新日期:10/28/2021