Aggregate shipments
Aggregate shipments allow multiple existing shipments to be combined into one shipment for consolidated transport. The request references the tracker codes of the individual pieces and returns the aggregation shipment and its label.
Aggregate shipments are available only for the Connect Light product.
This endpoint is secured, therefore the use of an authorization header with ‘Bearer’ as prefix and your token is required.
Preconditions
- Business account with aggregation enabled for the test environment and or on MY DHL Portal.
A business account is handed out by the sales department. You can place a request for an account as a business by email to: CIM eCommerce BNL.
- Authentication token. See documentation on the Authentication and authorization endpoint.
- Existing piece tracker codes belonging to the same organisation.
- Piece tracker codes that have not already been used in another aggregation.
Create an aggregate shipment
Send a POST request to https://api-gw.dhlparcel.nl/shipments/aggregation with a Bearer token and a JSON request body.
| Field | Type | Mandatory | Description |
|---|---|---|---|
shipper | object | Y | Shipper name and address. |
reference | string | N | Your reference for the aggregate shipment. |
accountNumber | string | Y | Account number provided by DHL. |
pieces | array of strings | Y | Tracker codes of existing pieces to aggregate. |
grossWeight | number | Y | Gross weight of the aggregate shipment in kilograms. |
options | array | N | Only CUSTOM_TRACKERCODE is available, when enabled for your organisation. |
Example request:
{
"shipper": {
"name": {
"companyName": "Example Company"
},
"address": {
"countryCode": "NL",
"postalCode": "1234AB",
"city": "Amsterdam",
"street": "Example street",
"number": "1",
"isBusiness": true
}
},
"reference": "AGGREGATION-123",
"accountNumber": "01234567",
"pieces": [
"JVGLOTC0123456789",
"JVGLOTC0123456790"
],
"grossWeight": 12.5,
"options": []
}
A successful request returns 201 Created with the created aggregate shipment and its label. See Create an aggregation shipment for the current request and response schemas.