跳转到主要内容
GET
/
tracking
/
{id}
获取货件追踪
curl --request GET \
  --url https://api.flexforward.com/tracking/{id} \
  --header 'Authorization: Bearer <token>'
{
  "id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
  "trackingNumber": "YT2503010001CN",
  "tag": "InTransit",
  "subtag": "InTransit_001",
  "subtagMessage": "In transit",
  "slug": "yunexpress",
  "checkpoints": [
    {
      "checkpointTime": "2025-03-02T10:30:00.000Z",
      "city": "Shenzhen",
      "state": "Guangdong",
      "countryRegion": "CN",
      "location": null,
      "message": "Shipment departed from sorting center",
      "tag": "InTransit",
      "subtag": "InTransit_001",
      "subtagMessage": "In transit",
      "slug": "yunexpress"
    },
    {
      "checkpointTime": "2025-03-01T14:00:00.000Z",
      "city": "Shenzhen",
      "state": "Guangdong",
      "countryRegion": "CN",
      "location": null,
      "message": "Shipment received at origin facility",
      "tag": "InTransit",
      "subtag": "InTransit_001",
      "subtagMessage": "In transit",
      "slug": "yunexpress"
    }
  ]
}

授权

Authorization
string
header
必填

部署时由 Flex Forward 团队发放的 API 访问令牌。

路径参数

id
string<uuid>
必填

由创建标签端点返回的标签 ID。

响应

成功获取追踪信息。

id
string<uuid>
必填

标签标识符。

示例:

"f47ac10b-58cc-4372-a567-0e02b2c3d479"

trackingNumber
string | null
必填

物流商分配的追踪编号,尚未获取时为 null

示例:

"YT2503010001CN"

tag
string
必填

高级追踪状态。可能的值: PendingInfoReceivedInTransitDeliveredExceptionCancelledUnknown

示例:

"InTransit"

subtag
string
必填

详细状态子标签。

示例:

"InTransit_001"

subtagMessage
string
必填

人类可读的子标签描述。

示例:

"In transit"

slug
string
必填

物流商代码。

示例:

"yunexpress"

checkpoints
object[]
必填