Rest_command not working in Home Assistant

problem with rest_command not working

my configuration.yaml has

rest_command:
unlock_front_door:
url: “https://xxxxxxxx
method: post

and I have created an automation to run Actions Restful Command: unlock_front_door
but nothing happens
if I copy and past the URL in my browser it woks fine but not in Home Assistant

the logs show
Error: Cannot connect to host xxx.com:443 ssl:default [nodename nor servname provided, or not known]
any help please
thanks

if you paste in a browser, the method is not ‘post’, but ‘get’ .
if the url ends on .com i wonder where that url is. If it’s not yours hosted or on your network, i assume there is some authentication required (which is present in your browser probably, check with dev tools on your browser)

yes the url is.com/
tried get made no difference its like its not being sent at all
error 443 ssl:default [nodename nor servname provided, or not known]

maybe try to disable ssl verify… log statement is kinda confusing.

It seems that the host cannot be resolved. Did you check that is writtern correctly?
Check if you are using the correct syntax.

weirdly a couple of restarts and now it working !

1 Like