This guide explains how to edit consignments when you are setting your own carrier consignment numbers and item references/barcodes. Common edit operations include:
This guide is specifically for workflows where you manage carrier consignment IDs and item references/barcodes. For standard editing workflows, see Editing Consignments.
Before proceeding, ensure you have:
When delegating your own consignment numbers and references, use:
POST /apiv2/consignments/createConsignmentwithComplexItems
Required custom fields:
Example request:
{
"carrierConsignmentId": "2657628002",
"carrierId": "446",
"items": [
{
"name": "Pallet",
"quantity": 2,
"itemType": "Pallet",
"standardItem": {
"weight": 270,
"length": "117",
"height": "110",
"width": "117"
},
"consignmentItemReferences": [
{
"carrierItemReference": "(00)393168610029113320"
},
{
"carrierItemReference": "(00)393168610029113321"
}
]
}
]
}
Important: Store the returned
id
value. If you can't store it, you can retrieve it later using/apiv2/consignments/returnConsignmentsByCarrierConsignmentId
with your carrier consignment ID.
Get the current consignment state:
GET /apiv2/consignments/getUnmanifestedConsignmentForEdit
Required parameter:
id
: The MachShip consignment ID from step 1Take the response from step 2 and modify as needed. When working with references:
Set setItemReferences
to true
at the root level:
{
"id": 26848234,
"setItemReferences": true,
...
}
Ensure each item has proper references:
{
"id": 26848234,
"setItemReferences": true,
.....
"items": [
{
.....
"consignmentItemReferences": [
{
"carrierItemReference": "642000123456780000299006"
}
]
}
],
.....
}
Send your modified payload to:
POST /apiv2/consignments/editUnmanifestedConsignment
When adding a new item, include both standard item details and references:
{
"itemType": "Carton",
"name": "Test Item",
"quantity": 1,
"standardItem": {
"height": 20.00000,
"weight": 1.00000,
"length": 20.00000,
"width": 20.00000
},
"consignmentItemReferences": [
{
"carrierItemReference": "642000123456780000299006"
}
]
}
Adding References:
setItemReferences
to true
Removing References:
setItemReferences
is true
Updating References:
carrierItemReference
valueReference Management:
setItemReferences
to true
when modifying referencesCarrier Support:
Validation: