getUOMConversions
Requires an authenticated session.
List the conversions that start or end at a unit.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query GetUOMConversions($uomId: String!) {
getUOMConversions(uomId: $uomId) {
id
createdAt
conversionFactor
deletedAt
deletedBy
enteredBy
fromUOM {
id
code
colorCode
name
pluralName
createdAt
}
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query GetUOMConversions($uomId: String!) {\n getUOMConversions(uomId: $uomId) {\n id\n createdAt\n conversionFactor\n deletedAt\n deletedBy\n enteredBy\n fromUOM {\n id\n code\n colorCode\n name\n pluralName\n createdAt\n }\n }\n}",
"variables": {
"uomId": "string"
}
}
EOF
Variables:
{
"uomId": "string"
}
Response:
{
"data": {
"getUOMConversions": [
{
"id": "id",
"createdAt": "2025-01-15T00:00:00Z",
"conversionFactor": 0,
"deletedAt": "2025-01-15T00:00:00Z",
"deletedBy": "string",
"enteredBy": "string",
"fromUOM": {
"id": "id",
"code": "string",
"colorCode": "string",
"name": "string",
"pluralName": "string",
"createdAt": "2025-01-15T00:00:00Z"
}
}
]
}
}
getUOMConversions(
uomId: String!
): [UOMConversion!]!
Arguments
getUOMConversions.uomId ● String! non-null scalar
The ID of the unit of measure.
Type
UOMConversion object
A conversion between two units of the same category. Creating one also creates the reverse conversion.