Printing
/print-deviceslistPrintDevicesList print devices
Returns active (non-revoked) Datashift print devices registered for the tenant. Use the `id` of the desired device as `deviceId` when calling `POST /shipments/{id}/print`. Devices are registered from the Datashift portal (Settings → Freight → Print Devices). Each device runs the Datashift label client software and listens for print jobs over Pub/Sub. Revoked devices are excluded from this list.
Responses
200Active print devices for this tenantPrintDeviceListResponse
401Missing or invalid API keyError
403Freight access is not active for this tenantError
/shipments/{id}/printprintShipmentLabelPrint shipment label
Fetches the shipment label from the carrier and queues a print job to the specified device. **Prerequisites:** - Direct print must be enabled for the tenant in Settings → Freight. - The target device must be registered, active, and running the Datashift label client. **Typical flow:** Call `GET /print-devices` once during setup, store each device's `id` in your WMS/ERP config keyed by workstation, then pass the relevant `deviceId` in this request after booking. **Handling `DEVICE_NOT_FOUND`:** If the response is 404 with `code: DEVICE_NOT_FOUND`, the stored device ID is stale (device was revoked or replaced). Re-fetch `GET /print-devices`, overwrite your stored device list, and prompt the user to select a device before retrying. **Handling `LABEL_NOT_AVAILABLE`:** The label is not yet ready from the carrier — poll `GET /shipments/{id}/label` with exponential backoff and retry once available.
Parameters
| Name | In | Required | Description |
|---|---|---|---|
| id | path | ✓ | Datashift shipment ID (from booking response or `GET /shipments`) |
Request body
PrintRequest
Responses
201Print job queued successfullyPrintJobCreated
400Invalid request — validation failed or carrier rejected inputError
401Missing or invalid API keyError
403Freight access not active, or direct print not enabled for this tenantError
404Shipment or device not found, or label not yet availablePrintNotFoundError
