Skip to main content

Unit of Measurement

Standardized unit of measurement codes following international standards (such as UN/ECE Recommendation 20) for consistent measurement handling and validation.

The ref_uom Object​

Unit of measurement collection provides standardized unit codes and classifications for proper measurement handling, validation, and conversion throughout the system.

Field NameTypeDescription
codestringPrimary key. Unit of measurement code following international standards (e.g., "ACR", "BLL", "4H").
user_createdobjectUser who created the unit of measurement record. Read-only. Links to directus_users.
date_createddatetimeTimestamp in ISO 8601 when the unit of measurement record was created. Read-only.
user_updatedobjectUser who last updated the unit of measurement record. Read-only. Links to directus_users.
date_updateddatetimeTimestamp in ISO 8601 when the unit of measurement record was last updated. Read-only.
descriptionstringHuman-readable description of the unit of measurement.
classificationstringClassification category of the unit (e.g., "length", "area", "volume", "density").
statusstringRecord status. Default: "published". Values: "draft", "published".

List Units of Measurement​

List existing units of measurement.

GET /items/ref_uom

Query Parameters​

Supports all global query parameters.

Returns​

An array of up to limit unit of measurement objects. If no items are available, data will be an empty array.


Retrieve a Unit of Measurement​

Retrieve a specific unit of measurement by code.

GET /items/ref_uom/:code

Returns​

Returns a unit of measurement object if a valid code was provided.


Create a Unit of Measurement​

Create a new unit of measurement.

POST /items/ref_uom

{
"code": "CX",
"description": "Custom unit",
"classification": "custom",
"status": "draft"
}

Query Parameters​

Supports all global query parameters.

Request Body​

A partial unit of measurement object.

Returns​

Returns the unit of measurement object for the created unit of measurement.


Update a Unit of Measurement​

Update an existing unit of measurement.

PATCH /items/ref_uom/:code

{
"description": "Updated unit description",
"status": "published"
}

Query Parameters​

Supports all global query parameters.

Request Body​

A partial unit of measurement object.

Returns​

Returns the unit of measurement object for the updated unit of measurement.


Delete a Unit of Measurement​

Delete an existing unit of measurement.

DELETE /items/ref_uom/:code

Returns​

Empty body.


Sample Data​

CodeDescriptionClassificationStatus
23grams per cubic centimeterdensitypublished
4Hmicrometrelength, breadth, height, thickness, radius, radius of curvature, cartesian coordinates, diameter, length of path, distancepublished
ACRacreareapublished
BLDdry barrel (US)volumepublished
BLLbarrel (US)volumepublished