2026-07-01 23:15:35 +02:00
|
|
|
"""Health check endpoint — extended with DB, Redis, storage, worker checks."""
|
2026-06-29 00:10:10 +02:00
|
|
|
|
|
|
|
|
from __future__ import annotations
|
|
|
|
|
|
|
|
|
|
from fastapi import APIRouter
|
|
|
|
|
|
2026-07-01 23:15:35 +02:00
|
|
|
from app.core.monitoring import get_health_status
|
|
|
|
|
|
2026-06-29 00:10:10 +02:00
|
|
|
router = APIRouter(tags=["health"])
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@router.get("/api/v1/health")
|
|
|
|
|
async def health():
|
2026-07-01 23:15:35 +02:00
|
|
|
"""Health check — no auth required.
|
|
|
|
|
|
|
|
|
|
Returns status (healthy/degraded) and individual checks for
|
|
|
|
|
database, redis, storage, and worker.
|
|
|
|
|
"""
|
|
|
|
|
return await get_health_status()
|