curl --request GET \
--url https://api.example.com/api/health.php{
"status": "<string>",
"timestamp": "<string>",
"checks": {
"database": {
"status": "<string>",
"latency_ms": 123,
"error": "<string>"
},
"openai": {
"status": "<string>",
"message": "<string>",
"error": "<string>"
},
"active_conversations": 123,
"disk": {
"free_gb": 123,
"usage_percent": 123,
"status": "<string>"
},
"memory": {
"usage_mb": 123,
"peak_mb": 123
}
}
}Check system health status including database, OpenAI service, disk, and memory
curl --request GET \
--url https://api.example.com/api/health.php{
"status": "<string>",
"timestamp": "<string>",
"checks": {
"database": {
"status": "<string>",
"latency_ms": 123,
"error": "<string>"
},
"openai": {
"status": "<string>",
"message": "<string>",
"error": "<string>"
},
"active_conversations": 123,
"disk": {
"free_gb": 123,
"usage_percent": 123,
"status": "<string>"
},
"memory": {
"usage_mb": 123,
"peak_mb": 123
}
}
}GET /api/health.php
healthy: All systems operationalunhealthy: One or more critical systems down200 OK: System is healthy503 Service Unavailable: System is unhealthy (one or more checks failed){
"status": "healthy",
"timestamp": "2024-03-06T10:30:00+00:00",
"checks": {
"database": {
"status": "up",
"latency_ms": 0
},
"openai": {
"status": "operational",
"message": "OK"
},
"active_conversations": 42,
"disk": {
"free_gb": 125.43,
"usage_percent": 35.67,
"status": "ok"
},
"memory": {
"usage_mb": 24.5,
"peak_mb": 28.3
}
}
}
SELECT 1 to verify connectivityopenai_status from settings tablestatus = "active"