CurrentUserService
Class to manage the current connected user with pluggable storage.
Use to set and get the user in a session. The storage mechanism is determined by the initialized loader (HTTP, Streamlit, Reflex, etc.).
Clear the auth context in the current session
Get the user in the current session, throw an exception if the user does not exists
UserGet the auth context in the current session, return none if not exists
gws_core.user.auth_context.AuthContextBase | NoneGet the user in the current session, return none if the user is not authenticated
gws_core.user.user.User | NoneFrontThemeInitialize the auth context loader for the application. Must be called at app startup (Streamlit, Reflex, etc.)
Args: loader: The loader implementation to use context: The context type (APP, REFLEX, etc.)
AuthContextLoaderCheck if the CurrentUserService has been initialized with a loader.
boolSet the auth context in the current session
AuthContextBaseSet the user in the current session
UserAuthContextUserCheck if the user is authenticated
bool