Add host comment using HTTP POST request

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Post Reply
acandu
Posts: 1
Joined: Thu Jan 11, 2024 11:18 am

Add host comment using HTTP POST request

Post by acandu »

Good morning,
I created a web app that retrieves and displays data from nagios XI using http request (example: hostlist GET).

My question is: is it possible to add a comment or a downtime for one or more hosts using my web app via REST API ?
If yes, can you provide an example? If no, are there other ways to do this?

From the native interface of Nagios I'm able to do that but I'd like to do this action using my custom web application.

Thank you in adavance.
Andrea
sgardil
Posts: 143
Joined: Wed Aug 09, 2023 9:58 am

Re: Add host comment using HTTP POST request

Post by sgardil »

Hey @acandu

I don't see why this wouldn't be possible however you would need to make a custom plugin to do so. I don't have an example of how this would be done however you can view the exchange and see if someone has done something similar. I will link some documentation for plugins and the exchange as they may be helpful.

https://exchange.nagios.org/
https://nagios-plugins.org/doc/guidelines.html
Post Reply