diff --git a/pyproject.toml b/pyproject.toml index 35b97605..62362c3f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -17,6 +17,7 @@ starlette = "^0.32.0.post1" gql = "^3.4.1" ariadne = "^0.21" aiohttp = "^3.9.1" +requests = "^2.31.0" [tool.poetry.group.dev.dependencies] setuptools = "^69.0.2" diff --git a/services/auth.py b/services/auth.py index 934f4a83..ca7769a8 100644 --- a/services/auth.py +++ b/services/auth.py @@ -12,10 +12,9 @@ async def check_auth(req): headers = {"Authorization": "Bearer " + token, "Content-Type": "application/json"} # query getSession($params: SessionQueryInput){ session(params: $params) { message user { id } } } gql = { - "query": "query GetSession($params: SessionQueryInput)" - + "{ session(params: $params) { message user { id } } }", + "query": "query GetSession($params: SessionQueryInput){ session(params: $params) { message user { id } } }", "operationName": "GetSession", - "variables": {}, + "variables": None, # {"params": {"roles": ["author"]}}, } async with aiohttp.ClientSession(timeout=aiohttp.ClientTimeout(total=30.0)) as session: