Need to pull services list with contacts

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
manimurugesan
Posts: 145
Joined: Wed Oct 03, 2018 9:15 am

Need to pull services list with contacts

Post by manimurugesan »

Hi Team,

I need list of services with contacts assigned to it .

Is there any way to get each services with contacts from nagiosxi console or cmd prompt(putty) ?
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Need to pull services list with contacts

Post by pbroste »

Hello @naminurugesan

Thanks for reaching out, found others that had similar requests.

Code: Select all

{yourserveraddress}/nagios/cgi-bin/config.cgi
You can view the data in a format but if you would like to parse the data then you would need to run something like this, for example:

Code: Select all

{yourserveraddress}/nagios/cgi-bin/objectjson.cgi?query=service&hostname={hostname]&servicedescription=Disk+Usage
Example:
"contact_groups": [
],
"contacts": [
"nagiosadmin"
],

Thanks,
Perry
Locked