Ludy87 / pyxplora_api

Unofficial python library for the Xplora® API
MIT License
10 stars 2 forks source link

session handling #1

Closed daroczig closed 2 years ago

daroczig commented 2 years ago

hey, first of all, thanks a lot for this awesome package and the related HA integration -- really great job! 🙇

Is your feature request related to a problem? Please describe.

One problem I have is that i need to use one guardian's credentials in this API integration, which logs out the actual user on the phone. As xplora doesn't allow adding more than 2 guardians, this is pretty limiting.

Describe the solution you'd like

Ideally, Xplora would have a fix for this, eg allowing a 3rd guardian or dedicated API users, but I don't think it's realistic to wait for them?

Maybe just retry auth failures. E.g. if user (re)logs in on the phone and the session gets invalidated in the Python integration, handle that and reauth. Maybe this to be done in the HA integration?

Describe alternatives you've considered

see above

Additional context

Ludy87 commented 2 years ago

The solution is that you log in on another phone with the phone number of the watch and then add it as a contact, parental mode is not required.