Hi, So I’m a newbie to home assistant and moved into a new place but want to add my new centurion pro door to home assistant. They have an api json control at the moment so i can enter commands to trigger the door/light etc but how would i add this into home assistant?
I have redacted the IP and api key but the code is below
Usage:
http://[IP]/api?key=[API Key]¶m=value
*Replace `param=value` with actual API.
Door
Status
Get Door status in json format: status=json
http://[IP]/api?key=[API Key]&status=json
Control
Open,Stop,Close: door=[open|stop|close]
http://[IP]/api?key=[API Key]&door=open
http://[IP]/api?key=[API Key]&door=stop
http://[IP]/api?key=[API Key]&door=close
Lamp
Control
ON/OFF: lamp=[on|off]
http://[IP]/api?key=[API Key]&lamp=on
http://[IP]/api?key=[API Key]&lamp=off
Holiday mode
Control
ON/OFF: vacation=[on|off]
http://[IP]/api?key=[API Key]&vacation=on
http://[IP]/api?key=[API Key]&vacation=off
Camera stream
Stream feed:
http://[IP]:88/
Camera test
Any and all help would be appreciated, [Have also tried a GitHub custom integration someone created but no luck on that side]
That’s a good start. Now make the other commands for close and stop.
rest_command:
garage_door_open:
url: "http://[IP]/api?key=[API Key]&door=open"
method: post
garage_door_close:
url: "http://[IP]/api?key=[API Key]&door=close"
method: post
garage_door_stop:
url: "http://[IP]/api?key=[API Key]&door=stop"
method: post
You will also need a restful sensor for the state. I would need to see the response from http://[IP]/api?key=[API Key]&status=json to help you with that. Preferably when the door is open, closed, opening and closing.
Then there is no need for scripts, you can use the rest commands directly. e.g.
Thanks again for the help, So the response is
{“api”:“ok”}
SO now i got the garage door to go up and stop but the down button is greyed, I do have an aircon with cover zones which may have the same cover entity, how would i go about this.
also How would i add a template for the light and vacation button
and lastly the camera i can get the stream to load in a browser but as soon as i try to add a generic camera through home assistant and click add the preview doesn’t load at all (Error starting stream, see logs for details (Stream never started) though its not appearing in the logs under settings/system/logs