Files
social-app/backend/src/v1/agent_chat/dependencies.py
T

19 lines
548 B
Python
Raw Normal View History

from __future__ import annotations
from typing import Annotated
from fastapi import Depends
from sqlalchemy.ext.asyncio import AsyncSession
from core.auth.models import CurrentUser
from core.db import get_db
from v1.agent_chat.service import AgentChatService
from v1.profile.dependencies import get_current_user
def get_agent_chat_service(
session: Annotated[AsyncSession, Depends(get_db)],
user: Annotated[CurrentUser, Depends(get_current_user)],
) -> AgentChatService:
return AgentChatService(session=session, current_user=user)