GET /api/v3/commodity/{commodityId}/unit Deprecated

Retrieves a list of units available for a specific commodity, optionally filtered by class or type

GetUnitsByCommodityV3
DEPRECATED (v202304): This endpoint is obsolete. Use GET /api/v202304/commodity/{commodityId}/unit instead. Use this endpoint to find which units of measure are valid for a given commodity.

Request Headers

Header Value Required Description
ECI-ApiKey string Yes Your API key. See Authentication.
Content-Type application/json Yes All requests must specify JSON content type.

Path Parameters

Name Description Type Required
commodityId Unique numeric identifier of the commodity integer (int32) Required

Query Parameters

Name Description Type Required
classCode Optional grouping of unit classes. Valid values are ‘use’, ‘cost’, ‘demand’. string Optional
nounCode Optional specific unit class code (noun code) to filter by string Optional
unitTypeCode Optional unit type code to filter by string Optional

Responses

200 OK The request succeeded and the response body contains the requested data.

Response Body Parameters

Array of:

UnitChild
Property Description Type
unitCode The unit code string
unitId The unit identifier integer (int32)
unitInfo The unit info string
Example Response application/json
[
  {    "unitCode": "string",    "unitId": 1,    "unitInfo": "string"
  }
]
404 Not Found The requested resource was not found. Verify the ID or path is correct.