We are integrating jenkins and Dynatrace before deployment we want check health of the particular host for last 2hrs or 30 mins etc. How can we use Dynatrace API to achieve this?
Solved! Go to Solution.
You can fetch all host related metrics including availability timeseries through our Dynatrace timeseries API. See help page here:
https://www.dynatrace.com/support/help/dynatrace-api/environment/timeseries-api/read-data-points-of-metrics-via-api/
we are getting timeseries of all the host for past 30mins or 2hrs. I want to confined to specific host only.
Yes. you can get the same.
/api/v1/entity/infrastructure/hosts?Api-Token=token
/api/v1/timeseries?api-token=token timeseriesId=com.dynatrace.builtin:host.availability.percent&relativeTime=month&queryMode=total&entity=<entityID>