im trying to create a report for these datas for all hosts but i dont really understand what parameters i should pass to the api, can anyone give me an example?
also if you know the way to make it work in the CLI that will be great 🙂
Have you tried using the API browser? Its pretty simple to build a request with it, you only need to look up the ID for the relevant metric in the documentation first. E.g. for usedspace it is: com.dynatrace.builtin:host.disk.usedspace
Then you enter the information in the API explorer:
And it will give you the Request URL and a curl command for it:
You only need to add an authentication parameter or header.
Yap you are right its working - our question is rather when we are trying this metric within dynatrace-cli (https://github.com/Dynatrace/dynatrace-cli)
I'm having issues getting those specific metrics via the CLI too, with
python3 dtcli.py ts query com.dynatrace.builtin:host.disk.usedspace[AVG%hour]
I get an error message. Other metrics work fine though. Maybe open an issue at the cli gitlab repository for that.