mirror of
https://github.com/ijaric/voice_assistant.git
synced 2025-05-24 14:33:26 +00:00
fix rename schemas
This commit is contained in:
parent
3e36da6481
commit
3e0f0d07b0
|
@ -7,9 +7,9 @@ router = fastapi.APIRouter()
|
|||
|
||||
@router.get(
|
||||
"/",
|
||||
response_model=api_shemas.HealthSchema,
|
||||
response_model=api_shemas.HealthResponseModel,
|
||||
summary="Статус работоспособности",
|
||||
description="Проверяет доступность сервиса FastAPI.",
|
||||
)
|
||||
async def health():
|
||||
return api_shemas.HealthSchema(status="healthy")
|
||||
return api_shemas.HealthResponseModel(status="healthy")
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
from .base import *
|
||||
|
||||
__all__ = [
|
||||
"HealthSchema",
|
||||
"HealthResponseModel",
|
||||
"TokenSchema",
|
||||
]
|
||||
|
|
|
@ -3,10 +3,10 @@ import uuid
|
|||
import pydantic
|
||||
|
||||
|
||||
class TokenSchema(pydantic.BaseModel):
|
||||
class TokenResponseModel(pydantic.BaseModel):
|
||||
sub: uuid.UUID
|
||||
exp: int | None = None
|
||||
|
||||
|
||||
class HealthSchema(pydantic.BaseModel):
|
||||
class HealthResponseModel(pydantic.BaseModel):
|
||||
status: str = pydantic.Field(..., example="healthy", description="Схема доступности сервиса")
|
||||
|
|
Loading…
Reference in New Issue
Block a user