-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Token does not survive reboot #14
Comments
Hi, I have just recently implemented a new Carelink client which is based on the API used by the Carelink Connect app. This new client has the advantage that it uses a refresh token in addition to the access token. The refresh token can be used to get a new access token, even of it is expired (for a week afterwards). The latest tokens are always saved to a file on disk, so everything works also after reboot. You can have a look here: The proxy is still missing in this folder, I am still porting and testing it. But you can already try the login script |
Cool! I will try it while waiting for the proxy.... |
I have just added the new proxy new_api/carelink_client2_proxy.py and updated the README. It's running fine here. Only the WebGUI with the proxy status information is still very basic. I plan to add the possibility to upload the token file via this GUI. Currently you have to copy it manually to the device where the proxy is running. Please give it a try and report back. |
Great |
OK, I could not wait, so I tested it right away and it works! I only have to look into the systemd Unit/Service file. Right now, I can reboot my server and after the reboot, the proxy is working and exposing the webclient without any manual intervention: Perfect! I will keep on monitoring and also try to find the exact reason why I have to insert the delay into the service file. Great work!!! |
OK, From: To: All is good now. |
Thanks for testing and your feedback. Good to hear that things are working also for you. |
The new proxy based on the Carelink client2 has been running continuously for 2 weeks here. So it seems stable, at least for me. I have merged the new client code to the main branch (the old code is still in the Closing this issue. |
Hello Ondrej,
I am using the proxy to feed some M5stack devices. It's working great!!!!
I also see that you client was used as a source for the Home Assistant plugin: Great.
But there's 1 functionality that I miss: if the proxy (or the server it's running on) is rebooted (I perform patch management :) ), the token has to be (manually) fetched again.
It would be GREAT if this token could be saved to disk, so that it could be re-used at startup (unless the server was down for a longer period off course).
Is this (easily) possible. Did you think about this option?
The text was updated successfully, but these errors were encountered: