add bots token

This commit is contained in:
unknown 2025-10-23 00:54:59 +03:00
parent 43c385386e
commit d472348bc7
2 changed files with 5 additions and 4 deletions

View File

@ -20,7 +20,6 @@ class CurrentUser:
session_id: str
permissions: List[str]
async def _fetch_current_user(
request: Request,
credentials: HTTPAuthorizationCredentials,
@ -76,7 +75,8 @@ async def fetch_user_for_sio(
token: str,
ip: str,
user_agent: str,
require_permissions: bool = False
require_permissions: bool = False,
is_bot: bool = False
) -> CurrentUser:
"""
Fetches user data for Socket.IO, decoupled from FastAPI's Request object.
@ -88,7 +88,8 @@ async def fetch_user_for_sio(
"token": token,
"ip": ip,
"user_agent": user_agent,
"require_permissions": require_permissions
"require_permissions": require_permissions,
"is_bot": is_bot,
},
)
except httpx.RequestError as e:

View File

@ -1,6 +1,6 @@
[project]
name = "common-lib"
version = "0.0.31"
version = "0.0.32"
description = "Библиотека общих компонентов для микросервисов yobble"
authors = [{ name = "cheykrym", email = "you@example.com" }]
license = "MIT"