15.1.4 Core Concepts
SDK objects map one-to-one with IDMP product concepts. Understanding these mappings helps you quickly locate the API you need.
15.1.4.1 Object Mapping
| SDK Class / Module | IDMP Concept | Description |
|---|---|---|
ApiClient | — | SDK entry point; manages connection, authentication, and request dispatch |
ElementResourceApi | Element | Nodes in the asset tree: equipment, systems, areas |
AttributeResourceApi | Attribute | Named properties of an element; can be bound to time-series data or static values |
MetricsResourceApi | Observability metrics | Queries real-time observability metrics for the IDMP service |
EventResourceApi | Event | Alarm or state-change records triggered by RT analysis rules |
PanelResourceApi | Panel | Visualization chart associated with an element |
UserResourceApi | User | User management and authentication |
UomResourceApi | UOM | Unit of measurement classes and conversions |
15.1.4.2 Data Access Hierarchy
IDMP SDK data access follows this hierarchy:
Element
└─ Attribute
└─ Time-Series Data (Metric)
Typical data read flow:
- Use
ElementResourceApito find the target element (by name, path, or ID). - Use the element ID to query its attribute list (
AttributeResourceApi). - Use IDMP data source or attribute APIs to continue accessing business time-series data;
MetricsResourceApidoes not query attribute history.
15.1.4.3 Pagination
All list endpoints support pagination. The response format is:
{
"current": 1, // current page number (1-based)
"size": 20, // records per page
"total": 100, // total record count
"rows": [...] // records on the current page
}
List endpoints that use the standard pagination DTO accept the current and size query parameters:
# Python example
result = element_api.api_v1_elements_get(current=1, size=50)
15.1.4.4 Request and Response Structure
All API responses follow a consistent format:
{
"code": 0, // 0 = success; non-zero = error
"message": "success", // status description
"data": { ... } // actual response payload
}
When code is non-zero, the SDK raises an ApiException. See Error Handling for details.
15.1.4.5 Time Format
All time parameters and return values use Unix timestamps in milliseconds (UTC).
import time
# Query the last 1 hour of data
now_ms = int(time.time() * 1000)
one_hour_ago_ms = now_ms - 3600 * 1000
