Merge commit '2a23e85f3bfb6562c1e98c4e7ab18ab07182f033'
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
|
from datetime import datetime, timezone
|
||||||
from typing import Any, Dict
|
from typing import Any, Dict
|
||||||
|
|
||||||
from fastapi import APIRouter, Depends
|
from fastapi import APIRouter, Depends
|
||||||
@@ -13,3 +14,12 @@ router = APIRouter()
|
|||||||
@router.get("/health", summary="Versioned health check")
|
@router.get("/health", summary="Versioned health check")
|
||||||
async def health(settings: Settings = Depends(get_settings)) -> Dict[str, Any]:
|
async def health(settings: Settings = Depends(get_settings)) -> Dict[str, Any]:
|
||||||
return build_health_payload(settings)
|
return build_health_payload(settings)
|
||||||
|
return {
|
||||||
|
"status": "ok",
|
||||||
|
"timestamp": datetime.now(timezone.utc).isoformat(),
|
||||||
|
"environment": settings.env,
|
||||||
|
"upstreams": {
|
||||||
|
"coreConfigured": settings.core_configured,
|
||||||
|
"agentsConfigured": settings.agents_configured,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user