Adding Services to Servicegroups via API
Posted: Fri Oct 25, 2019 5:19 am
I am trying to created services and automatically make them members of service groups using the API
This is the command I use-
It succeeds in adding the service, but it doesn't add it to the service group
(v.5.5.4)
This is the command I use-
Code: Select all
curl -XPOST -s "https://$NAGSERVER/nagiosxi/api/v1/config/service?apikey=$NAGAPI&pretty=1" -d "host_name=$HOST&service_description=$SERVICEDESC&servicegroup_name=$SERVICEGROUP&check_command=check_dummy\!0\!\"\"&use=$TEMPLATE&force=1"(v.5.5.4)