Consignment Consumables
Manage consumables used on consignments. Consumables represent materials used during handling (e.g., pallets, shrink wrap, labels, cartons).
Endpoints Overview
| Method | Endpoint | Description |
|---|---|---|
GET |
/v1/consignments/{consignmentId}/consumables |
Get consignment consumables |
POST |
/v1/consignments/{consignmentId}/consumables/{consumableTypeId} |
Add a consumable |
PUT |
/v1/consignments/{consignmentId}/consumables |
Update all consumables |
PUT |
/v1/consignments/{consignmentId}/consumables/{consumableTypeId} |
Update specific consumable |
DELETE |
/v1/consignments/{consignmentId}/consumables/{consumableTypeId} |
Delete a consumable |
Get Consignment Consumables
Retrieve all consumables for a consignment.
Endpoint: GET /v1/consignments/{consignmentId}/consumables
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
consignmentId |
uuid | Yes | The consignment ID |
Request Example
curl -X GET "https://api.consignlyhq.com/v1/consignments/550e8400-e29b-41d4-a716-446655440000/consumables" \
-H "Authorization: Bearer ACCESS_TOKEN"
Response Example
{
"consumables": [
{
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440900",
"name": "Pallet",
"value": 4
},
{
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440901",
"name": "Shrink Wrap (m)",
"value": 25.5
},
{
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440902",
"name": "Carton Labels",
"value": 120
}
]
}
Response Fields
| Field | Type | Description |
|---|---|---|
consumableTypeId |
uuid | Consumable type ID |
name |
string | Consumable type name |
value |
number | Quantity used |
Add a consumable
Add a consumable to a consignment
Endpoint: POST /v1/consignments/{consignmentId}/consumables/{consumableTypeId}
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
consignmentId |
uuid | Yes | The consignment ID |
consumableTypeId |
uuid | Yes | The consumable ID |
Request Body
{
"value": 5
}
Request Body Fields
| Field | Type | Required | Description |
|---|---|---|---|
value |
number | Yes | Quantity of consumable |
Request Example
curl -X POST "https://api.consignlyhq.com/v1/consignments/550e8400-e29b-41d4-a716-446655440000/consumables/550e8400-e29b-41d4-a716-446655440900" \
-H "Authorization: Bearer ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"value": 5}'
Response Example
Status: 200 OK
Error Cases
| Status | Cause | Resolution |
|---|---|---|
400 |
Invalid request body | Check required fields |
404 |
Consignment not found | Verify consignment ID |
404 |
Consumable Type not found | Verify consumable type ID |
Update All Consumables
Update all consumables for a consignment at once. This replaces the full set of consumables — existing consumables not present in the request will also be removed from the consignment.
Endpoint: PUT /v1/consignments/{consignmentId}/consumables
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
consignmentId |
uuid | Yes | The consignment ID |
Request Body
{
"consumables": [
{
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440900",
"value": 5
},
{
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440901",
"value": 30
}
]
}
| Field | Type | Required | Description |
|---|---|---|---|
consumables |
array | Yes | Array of consumable updates |
consumables[].consumableTypeId |
uuid | Yes | Consumable type ID |
consumables[].value |
number | Yes | New value/quantity |
Request Example
curl -X PUT "https://api.consignlyhq.com/v1/consignments/550e8400-e29b-41d4-a716-446655440000/consumables" \
-H "Authorization: Bearer ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"consumables": [
{
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440900",
"value": 5
}
]
}'
Response
| Status | Description |
|---|---|
200 |
Consumables updated successfully |
304 |
Not modified (no changes) |
Update Specific Consumable
Update a single consumable for a consignment.
Endpoint: PUT /v1/consignments/{consignmentId}/consumables/{consumableTypeId}
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
consignmentId |
uuid | Yes | The consignment ID |
consumableTypeId |
uuid | Yes | The consumable type ID |
Request Body
{
"value": 6
}
| Field | Type | Required | Description |
|---|---|---|---|
value |
number | Yes | New value/quantity |
Request Example
curl -X PUT "https://api.consignlyhq.com/v1/consignments/550e8400-e29b-41d4-a716-446655440000/consumables/550e8400-e29b-41d4-a716-446655440900" \
-H "Authorization: Bearer ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"value": 6}'
Response
| Status | Description |
|---|---|
200 |
Consumable updated successfully |
304 |
Not modified (no changes) |
Error Cases
| Status | Cause | Resolution |
|---|---|---|
404 |
Consignment not found | Verify consignment ID |
404 |
Consumable type not found | Verify consumable type ID |
Delete Specific Consumable
Delete a consumable from a consignment.
Endpoint: DELETE /v1/consignments/{consignmentId}/consumables/{consumableTypeId}
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
consignmentId |
uuid | Yes | The consignment ID |
consumableTypeId |
uuid | Yes | The consumable type ID |
Request Example
curl -X DELETE "https://api.consignlyhq.com/v1/consignments/550e8400-e29b-41d4-a716-446655440000/consumables/550e8400-e29b-41d4-a716-446655440300" \
-H "Authorization: Bearer ACCESS_TOKEN"
Response
Status: 200 OK
Error Cases
| Status | Cause | Resolution |
|---|---|---|
404 |
Consignment not found | Verify consignment ID |
404 |
Consumable Type not found | Verify consumable type ID |
Consumables in Consignment Detail
Consumables are included in the consignment detail response:
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"consumables": [
{
"id": "550e8400-e29b-41d4-a716-446655440910",
"consumableTypeId": "550e8400-e29b-41d4-a716-446655440900",
"consumableTypeName": "Pallet",
"value": 4
}
]
}
Related Endpoints
- Consignments - Main consignment management
- Consumable Types - Look up available consumable types
- Consignment Import - Create consignments with consumables