21 lines
543 B
Python
21 lines
543 B
Python
|
from fastapi import APIRouter, Depends, Request
|
||
|
|
||
|
from api.application.contracts.company.company_response import \
|
||
|
CompanyBaseResponse
|
||
|
from api.presentation.auth.fasapi_auth import auth_required
|
||
|
|
||
|
company_router = APIRouter(prefix="/company", tags=["Company"])
|
||
|
|
||
|
|
||
|
@company_router.get(
|
||
|
"/",
|
||
|
response_model=None,
|
||
|
dependencies=[Depends(auth_required)],
|
||
|
)
|
||
|
async def get_company(request: Request) -> CompanyBaseResponse:
|
||
|
print(request.scope["auth"])
|
||
|
return CompanyBaseResponse(
|
||
|
name="some",
|
||
|
email="some",
|
||
|
)
|