Hello everybody, I'm using the JSON Query Generator found in jsonquery.html in order to retrieve a list of the services that are in critical and warning states. I'm successfully able to obtain them, with the following call: https://...servername.../nagios/cgi-bin/statusjson.cgi?query=servicelist&servicestatus=warning+critical.
However, I only want to obtain the list of unhandled services that satisfy this condition.
Is there a way to do that? The task I want to accomplish is simple, I need to obtain pretty much the same information that's displayed on the Services (Unhandled) view of Nagios. The problem is that I will need that information in JSON and not in HTML format. That's why I'm thinking of using the JSON API for it.
Thank you all.
Regards
Getting only unhandled services from JSON CGIs in Nagios Cor
-
lucasalvarezlacasa
- Posts: 1
- Joined: Wed Mar 07, 2018 7:08 am
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Getting only unhandled services from JSON CGIs in Nagios
This is currently not possible, but you could make a feature request here
https://github.com/NagiosEnterprises/nagioscore/issues
https://github.com/NagiosEnterprises/nagioscore/issues