#
Order Shipment
A shipment refers to shipment units that contain one or several items, which leave the logistics center and are handed over to transportation companies such as DHL or DPD, complete with details on weight, dimensions, tracking number, and more. This API allows you to read existing shipments.
#
The order shipment resource
#
JSON object
{
"orderId": 13032291,
"orderNumber": "AN011738",
"carrier": "DHL",
"address": {
"line1": "Max Mustermann",
"line2": null,
"line3": null,
"street": "Musterstr. 1",
"zipCode": "1234",
"city": "Musterstadt",
"countryCode": "CH"
},
"shipmentUnits": [
{
"number": "LBAN011738-1",
"type": "package",
"trackingNumber": "03132132121213132",
"returnNumber": null,
"length": 100,
"width": 50,
"height": 50,
"weight": 250,
"lineItems": [
{
"id": 135454545,
"articleId": 71035893,
"articleNumber": "A1000-BLUE",
"articleUnit": "ST",
"quantity": 10,
"batchNumbers": [],
"serialNumbers": []
}
]
}
],
"createdAt": "2024-05-16T02:32:19Z",
"updatedAt": "2024-05-16T02:32:19Z"
}
#
Properties
- orderId int32 - required
The id of the order the shipment belongs to.
orderNumber (length <= 50) string - required
The number of the order the shipment belongs to.carrier string
The carrier who is in charge of the shipment.address object
The shipping address object.line1 string (length <= 255) - required
The shipping line 1.line2 string (length <= 255)
The shipping line 2.line3 string (length <= 255)
The shipping line 3.street string (length <= 255) - required
The shipping street with the house number.zipCode string (length <= 20) - required
The shipping zip code.city string (length <= 50) - required
The city.countryCode string (ISO3166-2) - required
The country code. E.g.: CH, DE, FR, ...
shipmentUnits object[] - required
The shipment units represent at least one unit to send.number string (length <= 50) - required
The number of the shipment unit. (e.g. SSCC)type string (length <= 50) - required
The type description of the shipment unit. (e.g. package"*, container, ...)trackingNumber string (length <= 50)
The tracking number of the shipment unit.returnNumber string (length <= 50)
The return number of the shipment unit.length int32
The length information of the shipment unit in millimeter.width int32
The width information of the shipment unit in millimeter.height int32
The height information of the shipment unit in millimeter.weight int32
The weight information of the shipment unit in grams.lineItems object[]
The line items represents one or more packed items.id int32 - required
The id used to identify the line item in the API.articleId int32 - required
The id of the article inside of the shipment unit.articleNumber string (length <= 50) - required
The number of the article inside of the shipment unit.articleUnit string (length <= 15) - required
Defines the unit of the article.quantity double - required
The quantity of the article in the shipment unit.batchNumbers string[] (each length <= 50) - required
All batch numbers the sent article is related to.serialNumbers string[] (each length <= 50) - required
All serial numbers the sent article is related to.
createdAt date (ISO 8601) - read-only
The date the shipment was created in logistic.cloud.updatedAt date (ISO 8601) - read-only
The date some data has changed.
#
GET - Retrieve a list of shipments
Requires scope Order.Shipment.Read
Use this operation to retrieve a list of shipments that meet the specified criteria. This endpoint implements pagination. Click here to learn more.
curl -X GET \
'https://{domain}.logistic.cloud/api/{version}/orders/shipments' \
-H 'X-API-KEY: YOUR_API_KEY'
Parameters
customerId int32
Retrieve only shipments of a specific customer.orderId int32
Filter shipments by their order id.carrier string
Filter shipments by their carrier name.number string
Filter shipments by their units number.trackingNumber string
Filter shipments by their tracking number.returnNumber string
Filter shipments by their return number.articleId int32
Filter shipments by their units containing article id.createdAtMin date (ISO 8601)
Show shipments last created after a specific date.createdAtMax date (ISO 8601)
Show shipments last created before a specific date.updatedAtMin date (ISO 8601)
Show shipments last updated after a specific date.updatedAtMax date (ISO 8601)
Show shipments last updated before a specific date.page int32 (default: 0)
The page number that contains the results. If not specified the first page will be returned.pageSize int32 (default: 50)
The maximum number of results returned per page. Value must be between 1 and 250. If not specified the default is set to 50 per page.
Responses
- 200 - OK
Returns a list of shipments.
#
Examples
This example shows how to filter the list of shipments for a specific order by setting the orderId
parameter.
curl -X GET \
'https://{domain}.logistic.cloud/api/{version}/orders/shipments?orderId=13032291' \
-H 'X-API-KEY: YOUR_API_KEY'
All dates are handled in UTC. To get the shipments of a specific date you need to pass in the createdAtMin
and createdAtMax
with the correct timezone. The values must also be url encoded. Please be aware that all dates in the results will be returned in UTC.
curl -X GET \
'https://{domain}.logistic.cloud/api/{version}/orders/shipments?createdAtMin=2024-06-20T00:00:00%2B02:00&createdAtMax=2024-06-20T23:59:59%2B02:00' \
-H 'X-API-KEY: YOUR_API_KEY'