By Clay Li on Friday, 03 May 2019
Category: Feature

How to Include Class Attributes in API Fetch

​Class attributes are dynamic attributes relevant to an asset, or a location used as a configuration element (CE). For instance, an computer server asset may include memory size and CPU model while a truck tire asset may include minimum and maximum pressure values. See this blog for more information about class attributes.

Class attributes are not included by default when fetching data by Calem Enterprise APIs. For instance, a data fetch API call results in 500 records selected. These records will not include class attributes. A new query parameter is added to include class attributes. Adding this parameter may cause the API call to take longer time since Calem Enterprise needs to fill out class attributes for each record selected. 

The response data is encoded in JSON. Category attributes (ending with "_wxyz" such as "_4859") are included as shown in the example below. 


Additional resources