HA Rest API to trigger automation

I am successfully trigger an automation via the REST API. But for some reason my conditions inside the automation getting not respected. They getting just skipped and the action will directly executed. Why is that?

Do I have to put an additional parameter inside the API call?

Based off what you said I think the API call is the same thing as clicking run from the edit automation window.

I would try moving your conditions to the action section of your automation by using it statements or the choose action

Please share the automation YAML correctly formatted for the forum.

Are you triggering the automation manually?

All that does is test the actions. It skips the triggers and conditions. If you use the trigger automation service in Developer Tools → Services there is an option to not skip the conditions. However if the conditions rely on trigger variables they will not be defined.

@ chrizstone How do you actually trigger the automation via API? I can’t find the docs.

Thanks