rstrouse / ESPSomfy-RTS-HA

Control your somfy shades in Home Assistant
The Unlicense
102 stars 9 forks source link

Invalid flow specified error while adding integration #31

Closed Raptor05 closed 5 months ago

Raptor05 commented 6 months ago

Hello,

I've successfully build the ESP32 device and added all shades and groups. Now I wanted to add the Home Assistant integration from HACS. I've added the custom repository and installed the integration. Then I restartet HA and it successfully found the device in the network. But when I try to add it (using username and password) it fails, showing the error: "Invalid flow specified".

Restarted multiple times, no success.

ESPSomfy RTS firmware: V 2.3.0 HA version: 2023.10.5 Running on Docker container at Synology NAS

Any idea, where this is coming from?

rstrouse commented 5 months ago

Try changing your language to English for the configuration if it is not. Also try to omit the username and password. The api key generated out of HA may override it. If it doesn't then select it and edit the username and password under configure after the hub is added.

Raptor05 commented 5 months ago

Try changing your language to English for the configuration if it is not. Also try to omit the username and password. The api key generated out of HA may override it. If it doesn't then select it and edit the username and password under configure after the hub is added.

I've changed the language to English but that was not the solution.

Then I removed the security options in ESPSomfyRTS. After restarting HA again, I was able to add the integration (without Username and PW). Now I activated the security option again in ESPSomfyRTS. And without changing the configuration of the integration I'm still able to control my shades. So it seems there is something like an API key integrated into the integration in HA.

Would it make sense to add this as a hint to the readme of the installation steps?

rstrouse commented 5 months ago

The plugin now properly detects invalid login credentials and does fall into the Invalid flow anymore. ESPSomfy RTS will also ignore credentials if they have not been set in firmware.