Reschedule check for one service on one host


I want to use the API to reschedule a check for a single service on a single host. I thought the reschedule-check endpoint made the most sense seeing as I want to be able to force it, however I cannot seem to understand the correct logic to target a single service on a single host.

If I am reading the docs correctly, you can target either all services on the host, or all hosts, but not a single service on a single host using this rechedule-check endpoint.

Is there another/better way of achieving this particular objective?

For context, I have my Ubuntu gear checked once a day for a reboot. I want to execute a script that puts the host into downtime, reboots it, and then forces the check for the reboot so that the service returns to normal to indicate the successful reboot.


curl -k -s -S -i -u root:icinga -H 'Accept: application/json' \
 -X POST 'https://localhost:5665/v1/actions/reschedule-check' \
 -d '{ "type": "Service", "filter": "\"ping6\" &&\"example.localdomain\"", "force": true, "pretty": true }'

That’s it. Sorry , I feel silly. I was just reading on how to do multiple objects and I didn’t see the connection.

Thanks again!