ApiAsset
Get asset tree
Returns the hierarchical asset tree for the requested view (normal, published, draft, unassigned, or inactive).
Access restricted to roles:
- admin
- manufacturer-admin
- manufacturer-user
- producer-admin
- producer-user
- sales-agent
Authorization
bearer AuthorizationBearer <token>
In: header
Query Parameters
view*string
Filter by view: normal (published and part of a location-rooted tree), published (all non-draft assets, active or inactive, independent of assignment), unassigned (published but not part of a location-rooted tree), inactive (deactivated), or draft (unpublished).
Value in
- "normal"
- "unassigned"
- "inactive"
- "draft"
- "published"
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/v1/assets/tree?view=normal"{ "data": [ { "id": "0c1b9613-7d6f-40b7-bf29-3179ac401fc9", "assetType": "location", "custom": false, "active": true, "machineConnection": true, "name": "Sample Asset", "position": 0, "parentId": "0c1b9613-7d6f-40b7-bf29-3179ac401fc9", "children": [ {} ], "serialNumber": "SN-12345" } ]}