> ## Documentation Index
> Fetch the complete documentation index at: https://openapidocs.flexforwardship.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get tracking events for a label

> Returns the current tracking status and checkpoint history for a label. Accepts either the label UUID or the customerOrderNumber as the path parameter.



## OpenAPI

````yaml /flex-forward.yaml get /tracking/{id}
openapi: 3.1.0
info:
  title: Flex Forward Shipping API
  description: >-
    Flex Forward provides a unified API for creating shipping labels, retrieving
    label documents, and tracking shipments across multiple courier services.
  version: 1.0.0
servers:
  - url: https://api.flexforwardship.com
    description: Production
  - url: https://api-staging.flexforwardship.com
    description: Staging
security: []
tags:
  - name: CreateLabels
    description: Create shipping labels.
  - name: Labels
    description: Retrieve shipping labels and label documents.
  - name: Tracking
    description: Track shipment status and checkpoints.
  - name: Products
    description: List available shipping products.
paths:
  /tracking/{id}:
    get:
      tags:
        - Tracking
      summary: Get tracking events for a label
      description: >-
        Returns the current tracking status and checkpoint history for a label.
        Accepts either the label UUID or the customerOrderNumber as the path
        parameter.
      operationId: getTracking
      parameters:
        - schema:
            minLength: 1
            type: string
          example: f47ac10b-58cc-4372-a567-0e02b2c3d479
          in: path
          name: id
          required: true
          description: Label UUID or customer order number.
      responses:
        '200':
          description: Tracking information for a shipment.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TrackingResponse'
        '401':
          description: Default Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Default Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Default Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Returned when the label was created but courier submission failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LabelFailedResponse'
        '502':
          description: Default Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - bearerAuth: []
        - apiKey: []
          apiToken: []
components:
  schemas:
    TrackingResponse:
      additionalProperties: false
      description: Tracking information for a shipment.
      type: object
      required:
        - id
        - trackingNumber
        - tag
        - subtag
        - subtagMessage
        - slug
        - checkpoints
      properties:
        id:
          format: uuid
          description: Label identifier.
          type: string
          example: f47ac10b-58cc-4372-a567-0e02b2c3d479
        trackingNumber:
          description: Courier-assigned tracking number, or null if not yet available.
          anyOf:
            - type: string
            - type: 'null'
          example: YT2503010001CN
        tag:
          description: >-
            High-level tracking status. Possible values: Pending, InfoReceived,
            InTransit, Delivered, Exception, Cancelled, Unknown.
          type: string
          example: InTransit
        subtag:
          description: Detailed status sub-tag.
          type: string
          example: InTransit_001
        subtagMessage:
          description: Human-readable description of the sub-tag.
          type: string
          example: In transit
        slug:
          description: Courier service slug.
          type: string
          example: yunexpress
        checkpoints:
          description: Chronological list of tracking events.
          type: array
          items:
            additionalProperties: false
            description: A single tracking event checkpoint.
            type: object
            required:
              - checkpointTime
              - city
              - state
              - countryRegion
              - location
              - message
              - tag
              - subtag
              - subtagMessage
              - slug
            properties:
              checkpointTime:
                description: Timestamp of the tracking event.
                type: string
                example: '2025-03-02T10:30:00.000Z'
              city:
                description: City where the event occurred.
                anyOf:
                  - type: string
                  - type: 'null'
                example: Shenzhen
              state:
                description: State or province.
                anyOf:
                  - type: string
                  - type: 'null'
                example: Guangdong
              countryRegion:
                description: ISO 3166-1 alpha-2 country code.
                anyOf:
                  - type: string
                  - type: 'null'
                example: CN
              location:
                description: Detailed location or facility name.
                anyOf:
                  - type: string
                  - type: 'null'
              message:
                description: Human-readable description of the tracking event.
                type: string
                example: Shipment departed from sorting center
              tag:
                description: Status tag at the time of this checkpoint.
                type: string
                example: InTransit
              subtag:
                description: Detailed sub-tag.
                type: string
                example: InTransit_001
              subtagMessage:
                description: Human-readable sub-tag message.
                type: string
                example: In transit
              slug:
                description: Courier service slug.
                type: string
                example: yunexpress
    ErrorResponse:
      additionalProperties: false
      type: object
      required:
        - error
      properties:
        error:
          description: Human-readable error message.
          type: string
          example: Shipping account not found
        code:
          description: Machine-readable error code.
          type: string
          example: COURIER_ERROR
    LabelFailedResponse:
      additionalProperties: false
      description: Returned when the label was created but courier submission failed.
      type: object
      required:
        - error
      properties:
        error:
          description: Error summary.
          type: string
          enum:
            - Label creation failed
        errorCode:
          description: Courier-specific error code.
          type: string
          example: COURIER_ERROR
        errorMessage:
          description: Human-readable error message.
          type: string
          example: Address validation failed
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
    apiKey:
      type: apiKey
      in: header
      name: x-rr-apikey
    apiToken:
      type: apiKey
      in: header
      name: x-rr-apitoken

````