Hi all,
I would like to implement External Authentication for Android apps (Written in Kotlin).
I refer to two documentation links:
- https://github.com/home-assistant/developers.home-assistant/blob/master/docs/frontend_external_auth.md
- https://developers.home-assistant.io/docs/en/frontend_external_auth.html
Based on this two links, I should add ?external_auth=1 to my HA url. So my url will become http://IP:8123/?external_auth=1 .
After run, it become like screenshot below:
So, just to confirm, I need to execute all the following commands in my Android app so that could successfully login HA using External Authentication method?
window.externalApp.getExternalAuth({
callback: 'externalAuthSetToken'
});
// To be called by external app
window.externalAuthSetToken(true, {
"access_token": "qwere",
"expires_in": 1800
});
Or do I miss out somethings else?
Thanks.