Downtime of host with REST-API does not work on 2.1.0p14.cee

Hi,

I tried the following json payload in the req, but the downtime don’t show up:
{

“start_time”: “2023-04-28T11:24:28Z”,

“end_time”: “2023-04-28T12:24:28Z”,

“recur”: “hour”,

“comment”: “Test”,

“downtime_type”: “host”,

“host_name”: “node123X”

}

On recur field I tried both fixed& hour but with no effect.
I am getting 204 status code when running from REST API interactive GUI.
Please, help.Maybe something is missing ?

Thanks,
Luc

Hi @lucfx,

can you please update your Checkmk to the latest version? Since p14 there been numerous changes to the REST API. Test it in the latest version and see if it still fails.

Thanks in advance!

Regrads
Norm

Hi,
I have upgraded to v2.1.0p27.I can see the scheduled downtime but I have another problem.When I create a downtime it always set the start in 176 m in GUI.How ca I set the downtime from api to start right away? I tried many combinations for start_time but I always get 176 m for start in GUI.

Thanks,
Luc