Closed pkret closed 4 years ago
As far as i know the api/states-endpoint just changes the home-assistant representation of the Entity without affecting the real device.
Please try:
POST http://home.local/api/services/switch/turn_on
{"entity_id": "switch.goecharger_00xxxx_allow_charging"}
or
POST http://home.local/api/services/switch/turn_off
{"entity_id": "switch.goecharger_00xxxx_allow_charging"}
Thanks for your help, i did not know that. Your examples did work!
I am unable to activate/deactivate the charger through the home assistant rest api:
POST http://home.local/api/states/switch.goecharger_00xxxx_allow_charging {"state":"on"}
Will trigger the switch within home assistant itself on, but only until the next update of the component when it is flipped back to off, the charger itself will remain off for the whole time. Triggering the state change though the development tab will also show similar behaviour.
Doing a GET http://goe.local/mqtt?payload=alw=1 is successful. Also, if i create this directly in the config:
Then this will successfully and permanently switch on the charger: POST http://home.local/api/states/switch.goe_charger_activate {"state":"on"}
Unfortunately I don't know enough python and custom components to check what's wrong in the component...