Skip to content

Update Unit

Update an existing unit of measure in Last Mile Intelligence.

updateUnit

unit

ParameterTypeRequiredDefaultDescription
Unit IDstringYes-The ID of the unit to update
Unit DataJSONYes-Fields to update
{
"id": "unit_gallon",
"name": "US Gallon",
"abbreviation": "gal",
"conversionFactor": 3.78541,
"updatedAt": "2024-06-21T10:30:00Z"
}
{
"success": false,
"error": "Unit not found",
"unitId": "invalid_id"
}
  • Missing API Token: LMI credential is missing API token
  • Unit Not Found: Unit with specified ID does not exist
  • Duplicate Abbreviation: New abbreviation already exists
  • Permission Denied: API token lacks permission for this operation