Add HealthCheck schema
This commit is contained in:
parent
046ec1a2dc
commit
30e58bbd26
20
schemas/healthcheck.py
Normal file
20
schemas/healthcheck.py
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
from pydantic import BaseModel, Field
|
||||||
|
|
||||||
|
# Base Schema
|
||||||
|
class HealthCheckBase(BaseModel):
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Create Schema
|
||||||
|
class HealthCheckCreate(HealthCheckBase):
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Response Schema
|
||||||
|
class HealthCheck(HealthCheckBase):
|
||||||
|
status: str = Field(..., example="ok")
|
||||||
|
|
||||||
|
class Config:
|
||||||
|
schema_extra = {
|
||||||
|
"example": {
|
||||||
|
"status": "ok"
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user