Update a Consignment using a Tracking Reference

PATCH /workspaces/{workspaceId}/consignments

Headers

  • Unique identifier for the API request. Example: f7ecf495-ca1c-4468-a6c2-6ee3f723fa00

Path parameters

Query parameters

  • The tracking reference that identifies the Consignment in the user system

application/json

Body Required

  • isActive boolean

    Indicates whether the Consignment is actively being tracked

Responses

  • 200 application/json

    200 response

    Hide response attributes Show response attributes object
    • pieces object

      Pieces in the Consignment

      Additional properties are NOT allowed.

      Hide pieces attributes Show pieces attributes object
      • total integer(int32)

        The total number of items in all pages of results

        Minimum value is 0, maximum value is 1000000.

      • Pagination token

        Maximum length is 5000. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • items array[object] Required
        Hide items attributes Show items attributes object
        • trackingRef string Required

          The tracking reference that identifies the Piece in the user system

          Maximum length is 500.

        • inFacilities array[object]

          Not more than 10000 elements.

          Hide inFacilities attributes Show inFacilities attributes object
          • hasExited boolean

            Indicate whether the item has exited the Facility

          • facilityId string(uuid) Required

            Unique identifier of the Facility. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

            Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

          • enteredOn string(date-time) Required

            Date that the item entered the Facility. Example: '2023-07-21T17:32:28Z'

            Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

          • facilityName string Required

            The name of the Facility

            Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

          • exitedOn string(date-time)

            Date that the item exited the Facility. Example: '2023-07-21T17:32:28Z'

            Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

          • A facility identifier relevant to the user

            Maximum length is 500.

        • consignmentId string(uuid) Required

          Unique identifier of the Consignment. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

          Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

        • id string Required

          Unique identifier of the Piece. Example: '00Es43YBJfNRXNSvLmni'

          Maximum length is 20. Format should match the following pattern: ^[-_A-Za-z0-9]*$.

        • label object

          Additional properties are NOT allowed.

          Hide label attributes Show label attributes object
          • bleId integer(int32) Required

            Label BLE identifier. Example: 123

            Minimum value is 0, maximum value is 2147483647.

          • nfcId string Required

            Label NFC identifier, used when creating an Asset and linking a Label at the same time. Example: '0000007B'

            Maximum length is 20. Format should match the following pattern: ^[a-zA-Z0-9]*$.

          • addedOn string(date-time) Required

            Date that the Label was linked to the Asset, in UTC. Example: '2019-07-21T17:32:28Z'

            Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

        • createdOn string(date-time)

          Date that the item was created, in UTC. Example: '2019-07-21T17:32:28Z'

          Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

        • workspaceId string(uuid) Required

          Unique identifier of the workspace. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

          Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

    • trackingRef string Required

      The tracking reference that identifies the Consignment in the user system

      Maximum length is 500.

    • gateways object

      Gateways in the Consignment

      Additional properties are NOT allowed.

      Hide gateways attributes Show gateways attributes object
      • Pagination token

        Maximum length is 5000. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • items array[object] Required
        Hide items attributes Show items attributes object
        • shortId string

          Short human-readable Gateway identifier. Example: 'AB1D'

          Maximum length is 10. Format should match the following pattern: ^[-_A-Za-z0-9]*$.

        • isStatic boolean

          Indicate whether the Gateway is statically located. If so, then longitude and latitude are required.

        • latitude number(float)

          Latitude value of the coordinate. Example: 51.123

          Minimum value is -90, maximum value is 90.

        • Indicate whether there are pending commands for the Gateway

        • rssiFilter string | integer(int32)

          The RSSI filter value for the Gateway BLE receiver (setting RSSI Filter via the API is only currently supported for Particle Gateways)

          One of:

          Values are FAR, NEAR, or VERY_NEAR.

          Minimum value is -127, maximum value is 0.

        • deviceId string

          Manufacturer identifier for the Gateway device. Example: 'e10fce301222e588e1d7482b'

          Maximum length is 100. Format should match the following pattern: ^[-_A-Za-z0-9]*$.

        • gatewayId string Required

          Gateway identifier, which is a combination of manufacturer and deviceId. Example: 'sysLoco_e10fce301222e588e1d7482b'

          Maximum length is 100. Format should match the following pattern: ^[-_A-Za-z0-9]*$.

        • Name of Gateway product. Example: 'HGD4'

          Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

        • addedOn string(date-time)

          ISO Timestamp of when the Gateway was linked, in UTC. Example: '2023-07-21T17:32:28Z'

          Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

        • manufacturer string Required

          Gateway manufacturer. Example: 'sysLoco'

          Maximum length is 100. Format should match the following pattern: ^[-_A-Za-z0-9]*$.

        • longitude number(float)

          Longitude value of the coordinate. Example: -0.123

          Minimum value is -180, maximum value is 180.

    • workspace object Required

      Additional properties are NOT allowed.

      Hide workspace attributes Show workspace attributes object
      • name string Required

        The name of the Workspace

        Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • id string(uuid) Required

        Unique identifier of the workspace. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

        Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

    • Additional properties are NOT allowed.

      Hide destination attributes Show destination attributes object
      • name string

        Name of the destination. Example: LHR

        Maximum length is 500.

      • facility object

        Additional properties are NOT allowed.

        Hide facility attributes Show facility attributes object
        • createdAt string(date-time)

          Date that the item was created, in UTC. Example: '2019-07-21T17:32:28Z'

          Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

        • name string Required

          The name of the Facility

          Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

        • id string(uuid) Required

          Unique identifier of the Facility. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

          Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

        • workspaceId string(uuid) Required

          Unique identifier of the workspace. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

          Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

        • A facility identifier relevant to the user

          Maximum length is 500.

    • id string(uuid) Required

      Unique identifier of the Consignment. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

      Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

    • isActive boolean

      Indicates whether the Consignment is actively being tracked

    • Additional properties are NOT allowed.

      Hide deactivated attributes Show deactivated attributes object
      • where object

        Additional properties are NOT allowed.

        Hide where attribute Show where attribute object
        • facility object

          Additional properties are NOT allowed.

          Hide facility attributes Show facility attributes object
          • createdAt string(date-time)

            Date that the item was created, in UTC. Example: '2019-07-21T17:32:28Z'

            Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

          • name string Required

            The name of the Facility

            Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

          • id string(uuid) Required

            Unique identifier of the Facility. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

            Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

          • workspaceId string(uuid) Required

            Unique identifier of the workspace. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

            Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

          • A facility identifier relevant to the user

            Maximum length is 500.

      • when string(date-time) Required

        ISO Timestamp when Consignment was de-activated. Example: '2023-07-21T17:32:28Z'

        Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

    • Additional properties are NOT allowed.

      Hide activated attributes Show activated attributes object
      • where object

        Additional properties are NOT allowed.

        Hide where attribute Show where attribute object
        • facility object

          Additional properties are NOT allowed.

          Hide facility attributes Show facility attributes object
          • createdAt string(date-time)

            Date that the item was created, in UTC. Example: '2019-07-21T17:32:28Z'

            Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

          • name string Required

            The name of the Facility

            Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

          • id string(uuid) Required

            Unique identifier of the Facility. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

            Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

          • workspaceId string(uuid) Required

            Unique identifier of the workspace. Example: 'd290f1ee-6c54-4b01-90e6-d701748f0851'

            Maximum length is 36. Format should match the following pattern: ^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$.

          • A facility identifier relevant to the user

            Maximum length is 500.

      • when string(date-time) Required

        ISO Timestamp when Consignment was activated. Example: '2023-07-21T17:32:28Z'

        Maximum length is 20. Format should match the following pattern: ^[0-9TZ:-]*$.

  • 401 application/json

    Unauthorized

    Hide response attribute Show response attribute object
    • errors array[object] Required
      Hide errors attributes Show errors attributes object
      • code string

        An application-specific error code, expressed as a string value

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • id string

        A unique identifier for this particular occurrence of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • detail string

        A human-readable explanation specific to this occurrence of the problem

        Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • title string

        A short, human-readable summary of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • status string

        The HTTP status code applicable to this problem, expressed as a string value

        Maximum length is 3. Format should match the following pattern: ^[0-9]*$.

  • 403 application/json

    Forbidden

    Hide response attribute Show response attribute object
    • errors array[object] Required
      Hide errors attributes Show errors attributes object
      • code string

        An application-specific error code, expressed as a string value

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • id string

        A unique identifier for this particular occurrence of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • detail string

        A human-readable explanation specific to this occurrence of the problem

        Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • title string

        A short, human-readable summary of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • status string

        The HTTP status code applicable to this problem, expressed as a string value

        Maximum length is 3. Format should match the following pattern: ^[0-9]*$.

  • 404 application/json

    Consignment not found in Workspace

    Hide response attribute Show response attribute object
    • errors array[object] Required
      Hide errors attributes Show errors attributes object
      • code string

        An application-specific error code, expressed as a string value

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • id string

        A unique identifier for this particular occurrence of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • detail string

        A human-readable explanation specific to this occurrence of the problem

        Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • title string

        A short, human-readable summary of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • status string

        The HTTP status code applicable to this problem, expressed as a string value

        Maximum length is 3. Format should match the following pattern: ^[0-9]*$.

  • 429 application/json

    Too Many Requests

    Hide response attribute Show response attribute object
    • errors array[object] Required
      Hide errors attributes Show errors attributes object
      • code string

        An application-specific error code, expressed as a string value

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • id string

        A unique identifier for this particular occurrence of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/"]*$`.

      • detail string

        A human-readable explanation specific to this occurrence of the problem

        Maximum length is 500. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • title string

        A short, human-readable summary of the problem

        Maximum length is 100. Format should match the following pattern: ^[a-zA-Z0-9!@#$&()\-.+,/" ]*$`.

      • status string

        The HTTP status code applicable to this problem, expressed as a string value

        Maximum length is 3. Format should match the following pattern: ^[0-9]*$.

PATCH /workspaces/{workspaceId}/consignments
curl \
 --request PATCH 'https://api.reelables.com/v1/workspaces/{workspaceId}/consignments' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --header "request-id: string" \
 --data '{"isActive":true}'
Request examples
# Headers
request-id: string

# Payload
{
  "isActive": true
}
Response examples (200)
{
  "pieces": {
    "total": 42,
    "nextToken": "string",
    "items": [
      {
        "trackingRef": "string",
        "inFacilities": [
          {
            "hasExited": true,
            "facilityId": "string",
            "enteredOn": "2025-05-04T09:42:00Z",
            "facilityName": "string",
            "exitedOn": "2025-05-04T09:42:00Z",
            "userFacilityId": "string"
          }
        ],
        "consignmentId": "string",
        "id": "string",
        "label": {
          "bleId": 42,
          "nfcId": "string",
          "addedOn": "2025-05-04T09:42:00Z"
        },
        "createdOn": "2025-05-04T09:42:00Z",
        "workspaceId": "string"
      }
    ]
  },
  "trackingRef": "string",
  "gateways": {
    "nextToken": "string",
    "items": [
      {
        "shortId": "string",
        "isStatic": true,
        "latitude": 42.0,
        "hasPendingCommands": true,
        "rssiFilter": "FAR",
        "deviceId": "string",
        "gatewayId": "string",
        "productName": "string",
        "addedOn": "2025-05-04T09:42:00Z",
        "manufacturer": "string",
        "longitude": 42.0
      }
    ]
  },
  "workspace": {
    "name": "string",
    "id": "string"
  },
  "destination": {
    "name": "string",
    "facility": {
      "createdAt": "2025-05-04T09:42:00Z",
      "name": "string",
      "id": "string",
      "workspaceId": "string",
      "userFacilityId": "string"
    }
  },
  "id": "string",
  "isActive": true,
  "deactivated": {
    "where": {
      "facility": {
        "createdAt": "2025-05-04T09:42:00Z",
        "name": "string",
        "id": "string",
        "workspaceId": "string",
        "userFacilityId": "string"
      }
    },
    "when": "2025-05-04T09:42:00Z"
  },
  "activated": {
    "where": {
      "facility": {
        "createdAt": "2025-05-04T09:42:00Z",
        "name": "string",
        "id": "string",
        "workspaceId": "string",
        "userFacilityId": "string"
      }
    },
    "when": "2025-05-04T09:42:00Z"
  }
}
Response examples (401)
{
  "errors": [
    {
      "code": "string",
      "id": "string",
      "detail": "string",
      "title": "string",
      "status": "string"
    }
  ]
}
Response examples (403)
{
  "errors": [
    {
      "code": "string",
      "id": "string",
      "detail": "string",
      "title": "string",
      "status": "string"
    }
  ]
}
Response examples (404)
{
  "errors": [
    {
      "code": "string",
      "id": "string",
      "detail": "string",
      "title": "string",
      "status": "string"
    }
  ]
}
Response examples (429)
{
  "errors": [
    {
      "code": "string",
      "id": "string",
      "detail": "string",
      "title": "string",
      "status": "string"
    }
  ]
}