Update Inventory
Update an existing inventory item.
Endpointโ
PATCH /v1/products/{id}/inventory/{inventoryId}
Authenticationโ
Requires an API key with the products:write scope.
Parametersโ
| Parameter | Type | Location | Description |
|---|---|---|---|
id | integer | path | The product ID |
inventoryId | integer | path | The inventory item ID |
Request Bodyโ
All fields are optional. Only include fields you want to update.
| Field | Type | Description |
|---|---|---|
identifier | string | New display name |
unique_identifier | string | New unique identifier |
total_quantity | integer | New quantity |
location | string | New free-text location |
location_id | integer | New supplier location ID (see Locations) |
available_from | string | New availability start date (ISO 8601) |
available_until | string | New availability end date (ISO 8601) |
Responseโ
Success (200 OK)โ
Returns the updated inventory item.
{
"data": {
"id": 5,
"variation": null,
"identifier": "Mountain Bike #5",
"unique_identifier": "SN-00005",
"increment": 5,
"total_quantity": 1,
"location": "Branch Office",
"supplier_location": {
"id": 2,
"name": "Branch Office"
},
"available_from": null,
"available_until": "2026-12-31T23:59:59+00:00",
"status": "current",
"created_at": "2026-02-01T10:00:00+00:00",
"updated_at": "2026-02-01T11:00:00+00:00"
},
"meta": {
"request_id": "req_abc123",
"timestamp": "2026-02-01T11:00:00+00:00"
}
}
Example Requestโ
curl -X PATCH "https://app.equipdash.com/api/v1/products/1/inventory/5" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"location": "Branch Office",
"available_until": "2026-12-31T23:59:59Z"
}'
Errorsโ
| Status | Code | Description |
|---|---|---|
| 401 | authentication_required | No API key provided |
| 403 | insufficient_scope | API key lacks products:write scope |
| 404 | resource_not_found | Product or inventory item not found |
| 422 | validation_error | Invalid request data |