API Reference
Assets API
Asset CRUD endpoints, hierarchy, health, prognostics, digital twin, baselines, and condition.
CRUD Endpoints
| Method | Endpoint | Description |
|---|---|---|
GET | /api/v1/assets | List assets |
POST | /api/v1/assets | Create asset |
GET | /api/v1/assets/{asset_id} | Get asset |
PUT | /api/v1/assets/{asset_id} | Update asset |
DELETE | /api/v1/assets/{asset_id} | Delete asset |
Asset Hierarchy
Assets are organized in a parent-child structure:
POST /api/v1/assets
{
"name": "Pump Motor P-101",
"type": "motor",
"parent_id": "asset_north_plant",
"location": { "building": "A", "floor": 1, "zone": "pumping" },
"metadata": { "manufacturer": "ABB", "model": "M3BP-315", "year": 2022 }
}Query the full hierarchy tree:
GET /api/v1/assets/tree?root_id=asset_north_plant&depth=3| Parameter | Description |
|---|---|
root_id | Root asset ID (optional) |
depth | Depth levels (default: 5) |
Asset Health
GET /api/v1/assets/{asset_id}/healthResponse:
{
"health_score": 82,
"status": "good",
"factors": [
{ "name": "vibration", "score": 75, "trend": "stable" },
{ "name": "temperature", "score": 90, "trend": "improving" },
{ "name": "maintenance_compliance", "score": 80, "trend": "declining" }
],
"last_updated": "2026-03-25T09:30:00Z"
}| Status | Score Range |
|---|---|
critical | 0-25 |
poor | 26-50 |
fair | 51-70 |
good | 71-90 |
excellent | 91-100 |
Prognostics
GET /api/v1/assets/{asset_id}/prognosticsReturns predictions based on machine learning models:
| Field | Description |
|---|---|
remaining_useful_life | Estimate in days |
failure_probability | Failure probability in 30 days (0-1) |
recommended_action | Action suggested by the model |
confidence | Prediction confidence level |
model_version | Model version used |
Digital Twin
GET /api/v1/assets/{asset_id}/digital-twinReturns the asset's virtual state with real-time data:
- Active sensors — Current readings from all associated sensors
- Operational parameters — Speed, load, temperature, pressure
- Simulations — Results from the last simulated scenario
- Detected anomalies — Deviations from the base model
Baselines
Baselines define the expected normal behavior of an asset:
POST /api/v1/assets/{asset_id}/baselines
{
"parameter": "vibration_rms",
"baseline_value": 2.5,
"tolerance_percent": 15,
"measurement_unit": "mm/s"
}GET /api/v1/assets/{asset_id}/baselinesWhen a reading exceeds the defined tolerance, an automatic alert is generated.
Current Condition
GET /api/v1/assets/{asset_id}/condition| Field | Description |
|---|---|
overall_condition | Overall condition: good, fair, poor, critical |
parameters | Array of monitored parameters |
last_inspection | Date of last inspection |
next_inspection | Recommended next inspection date |
open_work_orders | Number of open work orders |
Condition is recalculated automatically each time a new sensor reading is received or an inspection is completed.