Hello,
i need to update below things using API
1. mics settings status image and icon image using API.
2. bulk check for all service on given host using API.
Nagiosxi API
Re: Nagiosxi API
1. See Help > Config Reference:
You would use these in your API commands while adding/updating the host:
For services there is only icon_image:
2. See Help > System Reference > corecommand
Taken from here:
https://assets.nagios.com/downloads/nag ... and_id=130
https://assets.nagios.com/downloads/nag ... ernalcmds/
You would use these in your API commands while adding/updating the host:
Code: Select all
icon_image=yourimage.png
statusmap_image=yourimage.pngCode: Select all
curl -k -L -XPUT "https://X.X.X.X/nagiosxi/api/v1/config/host/THEHOSTNAME?apikey=YOURAPIKEY&pretty=1&address=X.X.X.X¬ification_interval=30&icon_image=yourimage.png&statusmap_image=yourimage.png&applyconfig=1"Code: Select all
icon_image=yourimage.pngCode: Select all
curl -k -L -XPUT "https://X.X.X.X/nagiosxi/api/v1/config/service/THEHOSTNAME/THESERVICENAME?apikey=YOURAPIKEY&pretty=1&display_name=XXXXXXX&icon_image=yourimage.png&applyconfig=1"Code: Select all
curl -k -L -vvv -XPOST "https://X.X.X.X/nagiosxi/api/v1/system/corecommand?apikey=YOURAPIKEY" -d "cmd=SCHEDULE_FORCED_HOST_SVC_CHECKS;THEHOSTNAME;$(date +%s)"https://assets.nagios.com/downloads/nag ... and_id=130
https://assets.nagios.com/downloads/nag ... ernalcmds/