订单 API

订单检索

生产端点:
https://transact.ti.com/v2/store/orders/

使用订单检索 API 获取您的订单历史记录的副本。该列表将默认显示过去 30 天内创建的订单。要指定订单创建的日期范围,则添加查询参数“startDate”和“endDate”,例如“https://transact.ti.com/v2/store/orders?startDate=2021-05-01&endDate=2025-05-31”。要检索详细的订单信息,则使用订单号查询订单 API,例如:“https://transact.ti.com/v2/store/orders/T999999999”。
 

订单检索流程

  1. 使用为您分配的 API 密钥和密码进行身份验证
  2. 订单提交并确认后,API 将使用状态代码“201 OK”进行响应。
  3. 查询订单 API,了解订单状态和其他详细信息。
  4. API 将使用状态代码“200 OK”和包含订单详细信息的 JSON 进行回复
  5. 有关更多信息,请参阅“订单 API 说明”。

使用订单号的申请示例:

curl --request GET \ --url 'https://transact.ti.com/v2/store/orders/{orderNumber}' --header 'Authorization: Bearer {access_token}' \ Example response: { "orderNumber": 0, "orderStatus": "string","customerPurchaseOrderNumber": "string","subTotal": 0, "totalPrice": 0, "lineItems": [ { "tiPartNumber": "string","tiPartDescription": "string","quantity": "string","status": "string","unitPrice": 0, "customReelIndicator": true } ], "shippingAddress": [ { "addressType": "string","firstName": "string","lastName": "string","company": "string","addressLine1": "string","addressLine2": "string","town": "string","state": "string","postalCode": "string","country": "string","email": "string","phoneNumber": "string","companyURL": "string" } ], "billingAddress": [ { "addressType": "string","firstName": "string","lastName": "string","company": "string","addressLine1": "string","addressLine2": "string","town": "string","state": "string","postalCode": "string","country": "string","email": "string","phoneNumber": "string","companyURL": "string" } ], "orderMessages": [ { "code": "string","type": "string","Message": "string" } ], "customerOrderAttributes": [ { "attribute": "string" } ], "orderPlacedTime": "string","paymentType": "string","currencyISO": "string","totalTax": 0, "checkoutProfileIdentifier": "string","totalDeliveryCost": 0, "totalDiscount": 0, "couponCodes": "string" }