Solved

How to get Cluster Health status via API


Badge +2
Hello.
Does anybody know how to get Cluster Health status via API?
icon

Best answer by ShawnT 18 October 2017, 16:34

Here is an undocumented v1 API call that will give you what you are looking for:

https://clusterIPorDNS:9440/PrismGateway/services/rest/v1/ncc/run_summary


Keep in mind undocumented API calls are unsupported and can change.

View original

3 replies

Badge
To monitor the health check for a Nutanix Cluster, you can query the alerts & events generated by the following v2 endpoints:

/clusters/alerts

/clusters/events

Each alert is tied to a healthcheck, and is generated by predefined threshold and poll interval that can be defined in Prism.
You can also enable/disable an alert from the alerts policy in Prism.

To understand which alert is tied to which healthcheck, you can use the "alert_type_uuid" in /cluster/alerts and match against "alert_id_type" in
/health_checks/
Hope this helps!
Badge +2
No. As i see, not every health_check generates an alert. So, alerts and events API parts are not what i want.
Health_check API part consists only settings of checks, but not the results. I would like to see the resulting Health status like i see on the home page in Prism.
Badge +2
Here is an undocumented v1 API call that will give you what you are looking for:

https://clusterIPorDNS:9440/PrismGateway/services/rest/v1/ncc/run_summary


Keep in mind undocumented API calls are unsupported and can change.

Reply