Endpoints for creating, tracking, updating, and managing shipments.
Filter shipments
Search and filter shipments using various criteria
query Parameters
statusFilter by shipment status
tagsFilter by tags
Filter by creation date range
Filter by address criteria
limitMaximum number of results to return
offsetNumber of results to skip
Responses
Shipments retrieved successfully
totalTotal number of shipments matching the filter
limitoffsetCreate a new shipment
Creates a new shipment with the provided details.
This endpoint allows you to create and register a new shipment in the Cosmo Cargo platform. The shipment will be assigned a unique trackingNumber and will enter the CREATED status.
How to use with SDK
Here's how to create a shipment using @cosmo-cargo/sdk:
Code
Note: Use the X-Request-Priority header to expedite processing for urgent shipments.
Headers
X-Correlation-IDUnique identifier for tracking requests across multiple services
Idempotency-KeyUnique key to ensure idempotency of the request
X-API-VersionAPI version requested by the client
X-Request-PriorityPriority level for processing the shipment request
Request Body
idrecipientEmailNotes about the shipment
statustrackingNumber^[A-Z0-9]{10,20}$createdAttagsfacilitiesArray of custom data items that can be of any type
metadataEmpty object for future extensibility
Dictionary of custom string fields that can be added to the shipment
Dictionary of facility capabilities and their status
Real-time tracking information for this shipment
Tracking details for return shipment if applicable
Responses
Shipment created successfully
idrecipientEmailNotes about the shipment
statustrackingNumber^[A-Z0-9]{10,20}$createdAttagsfacilitiesArray of custom data items that can be of any type
metadataEmpty object for future extensibility
Dictionary of custom string fields that can be added to the shipment
Dictionary of facility capabilities and their status
Real-time tracking information for this shipment
Tracking details for return shipment if applicable
Track a shipment
Get the current status and tracking information for a shipment
path Parameters
trackingNumberquery Parameters
includeHistoryInclude detailed tracking history and events in the response
Headers
X-Correlation-IDUnique identifier for tracking requests across multiple services
X-API-VersionAPI version requested by the client
X-Cache-ControlCaching behavior for the tracking response
Responses
Shipment tracking information retrieved successfully
idrecipientEmailNotes about the shipment
statustrackingNumber^[A-Z0-9]{10,20}$createdAttagsfacilitiesArray of custom data items that can be of any type
metadataEmpty object for future extensibility
Dictionary of custom string fields that can be added to the shipment
Dictionary of facility capabilities and their status
Real-time tracking information for this shipment
Tracking details for return shipment if applicable
Hold shipment
Place a shipment on hold at a facility
path Parameters
shipmentIdquery Parameters
holdDurationDuration to hold the shipment
Headers
X-Hold-OperatorOperator requesting the hold
cookie Parameters
preferredLocationUser's preferred facility location
Request Body
holdUntilreasonfacilityIdResponses
Shipment placed on hold successfully
statusholdLocationholdUntil