feat(api): Add user authentication functionality
- Implement JWT-based user authentication logic - Add login endpoint and token validation middleware - Update API routes with authentication dependencies - Add authentication-related environment variables - Optimize requirements.txt with necessary dependencies
This commit is contained in:
@@ -6,9 +6,9 @@ from typing import Optional
|
||||
|
||||
from fastapi import APIRouter, Depends
|
||||
|
||||
from ..utils_api import get_api_key_dependency
|
||||
from ..utils_api import get_api_key_dependency, get_auth_dependency
|
||||
|
||||
router = APIRouter(tags=["graph"])
|
||||
router = APIRouter(tags=["graph"], dependencies=[Depends(get_auth_dependency())])
|
||||
|
||||
|
||||
def create_graph_routes(rag, api_key: Optional[str] = None):
|
||||
|
Reference in New Issue
Block a user