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)