Fetch logged in user information
See original GitHub issueSince we’re using HA’s new auth, it would be great to have access to the current logged in user within TileBoard. I’m thinking I could use the logged in user to determine what pages or layout I want to use (giving each tablet its own HA user). A means of logging out or switching the account would also be useful for troubleshooting/developing.
It looks like sending “auth/current_user” over the websocket will return the needed information. If it could be accessed in config.js under something like this.user
that would be awesome.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:12 (2 by maintainers)
Top Results From Across the Web
Django: Fetch logged in user information from database and ...
I've menaged to create a form that allow me to save my website user information in the database. Right ...
Read more >How to fetch logged in user details - Skuid Community
I wanted to fetch logged in user details on click of button for first time and want to display an alert on click...
Read more >How to get logged in user information in client script
I have a need to find out about logged in user field value on client script (on INC table). How can I get...
Read more >Fetch username of logged-in app user | Help - Zoho Deluge
Overview. This deluge task is used to fetch the username of the logged-in user. Return. This task returns the username of the logged-in...
Read more >Retrieving the current user that is logged in - OutSystems
Follow below steps. 1. Outsystems has built in function to get current logged in user id ( BuiltFunctions -> Roles -> GetUserId() )....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Some things have changed since the previous comment. Now the Api object will be exposed as
this.api
in your functions. So you will have to usethis.api.getUser([callback])
.Also added an
onReady
function that you can define in your config (CONFIG.onReady
) which is probably gonna be the best place to get the user data.It will work as soon as #309 is merged.
It is not straightforward as API calls are made at later stage and are async.