Skip to content
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

Logging users #31

Closed
lgidon opened this issue Sep 6, 2022 · 1 comment
Closed

Logging users #31

lgidon opened this issue Sep 6, 2022 · 1 comment

Comments

@lgidon
Copy link

lgidon commented Sep 6, 2022

I'm looking for a way to track the users login by writing a new line to a db table on each successful login.
Triggering the write after if authentication_status: will trigger everytime the app gets rerun, not just on login.

Is there a way to get just the "original" login?

@mkhorasani
Copy link
Owner

Hi @lgidon you can use the cookie manager in the package extra_streamlit_components to read the authentication cookie. That cookie includes the cookie expiry date which you can use to determine when the user originally logged in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants