pythonasyncioapiasyncfastapiframeworkjsonjson-schemaopenapiopenapi3pydanticpython-typespython3redocreststarletteswaggerswagger-uiuvicornweb
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
327 B
13 lines
327 B
from datetime import datetime
|
|
|
|
|
|
def health_status() -> dict:
|
|
"""
|
|
Returns a simple health status for FastAPI.
|
|
This is a small helper function that could be used in health checks.
|
|
"""
|
|
return {"status": "ok", "time": datetime.utcnow().isoformat() + "Z"}
|
|
|
|
|
|
if __name__ == "__main__":
|
|
print(health_status())
|
|
|