diff --git a/common_lib/utils/auth.py b/common_lib/utils/auth.py index 5de047d..4109cbf 100644 --- a/common_lib/utils/auth.py +++ b/common_lib/utils/auth.py @@ -15,6 +15,7 @@ auth_scheme = HTTPBearer() @dataclass class CurrentUser: token: str + is_bot: bool user_id: str session_id: str permissions: List[str] @@ -56,6 +57,7 @@ async def _fetch_current_user( return CurrentUser( token=token, + is_bot=is_bot, user_id=data["user_id"], session_id=data["session_id"], permissions=data["permissions"] @@ -124,6 +126,7 @@ async def fetch_user_for_sio( return CurrentUser( token=token, + is_bot=is_bot, user_id=data["user_id"], session_id=data["session_id"], permissions=data["permissions"] diff --git a/pyproject.toml b/pyproject.toml index daa2a13..0427e0f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "common-lib" -version = "0.0.36" +version = "0.0.37" description = "Библиотека общих компонентов для микросервисов yobble" authors = [{ name = "cheykrym", email = "you@example.com" }] license = "MIT"