/shipments endpointsCreate a new shipment, rate and confirm, retrieve shipment information, retrieve shipment documents.
There are two options for creating shipments:
1) Multiple API calls (similar workflow to client area):
2) Simplified “one step” procedure:
Methods : GET, POST
Note: if the shipment is subject to customs, the exportDeclaration object is required.
POST /shipments/saveThe request JSON API document should contain a shipment object as the document’s data member.
POST /shipments/rateThe request JSON API document should contain a shipment object as the document’s data member.
POST /shipments/confirmThe request JSON API document should contain a shipment object as the document’s data member.
The meta property of the shipment should contain a rate object (retrieved using the “Rate shipment” endpoint).
The attributes.finalCost property of the rate is optional. If present, the API will attempt to match the rate price when confirming the shipment.
If the new price is different, the shipment will not be confirmed and an error will be returned.
If the attributes.finalCost property is omitted, the shipment will be confirmed without checking the price.
This functionality performs all the shipment processing steps, as in MYPV, including for example booking the shipment.
POST /shipmentsSimplified “one step” endpoint.
The request JSON API document should contain a shipment object as the document’s data member.
The meta property of the shipment must contain the chosen service option, and can optionally contain the carrierChoice and scheduledProcessing options.
Examples - scheduledProcessing “true”
Examples - scheduledProcessing “false”
Examples - scheduledProcessing “false” - with carrier choice
Examples - “one step” - scheduledProcessing “true” - documentsOnly
Examples - scheduledProcessing “false” - with collection location
Examples - scheduledProcessing “false” - with export declaration
DELETE /shipments/<apiShipmentId>The request should contain no content body.
On success the API returns the HTTP code 204 No Content.
GET /shipments/<apiShipmentId>The request should contain no content body.
GET /shipments/<apiShipmentId>/documentsThe request should contain no content body.
GET /shipments/<apiShipmentId>/trackingThe request should contain no content body.