27 Apr 2023
04:42 AM
- last edited on
28 Apr 2023
12:08 AM
by
MaciejNeumann
Goal: Find out the API way to get host-name, host-id, disk-name, disk-id.
Use case sample:
Question: which API or multi-APIs can help to get above 4 infos (host-name, host-id, disk-name, disk-id)?
FYI Reference: https://community.dynatrace.com/t5/Dynatrace-API/Correlating-multiple-disk-entities-within-host-enti... ( but 1) we do not think that API is correct one, plus 2) that URL also has similar concern of how to find DISK-name and associate host via disk-id)
Hi,
I would use Monitored entities API - GET an entity . It return host id, host display name and disks ids.
"entityId": "HOST-06F288EE2A930951",
"displayName": "my host",
"toRelationships": {
"isDiskOf": [
{
"id": "DISK-0393340DCA3853B0",
"type": "DISK"
}
]
}
You can use same API to get disk display name.
Best regards
Thanks!
So in total - 2 run of same API but with diff entities -
Hi,
Yes.
Best regards