Page 1 of 1

Nagios rest api to create multiple object in static folder

Posted: Sun Oct 22, 2017 10:18 pm
by scott han
Hi there,
I have a few questions regarding creating objects using rest api.
1. is it possible to create multiple objects (e.g. hosts, services,servicegroup, timeperiods) in one rest api call?
2. If 1 is yes, is it possible to put these configure definitions as a file, then use that file as a parameter to the rest api?
3. is it possible to create these objects as static, like those under nagios/etc/static folder?

Thanks a lot for your help.

Best Regards,
scott

Re: Nagios rest api to create multiple object in static fold

Posted: Mon Oct 23, 2017 1:40 pm
by scottwilkerson
1.) no
2.) no, however you can create objects on the XI server by placing the file in /usr/local/nagios/etc/import and running apply configuration through the rest API
3.) Not through the API, but you can simply place the files on the server in the static directory and run apply configuration through the rest API

Re: Nagios rest api to create multiple object in static fold

Posted: Mon Oct 23, 2017 2:54 pm
by scott han
Thanks for the reply.

Re: Nagios rest api to create multiple object in static fold

Posted: Mon Oct 23, 2017 3:24 pm
by cdienger
Did you have any further questions or are we okay to lock this thread?

Re: Nagios rest api to create multiple object in static fold

Posted: Mon Oct 23, 2017 3:34 pm
by scott han
Thanks, that's all for now