Skip to main content

Health Check

/health
GET
Check if the API service is running

Endpoint

GET /health

Description

Simple health check endpoint to verify the API service is running and responsive. Returns a basic status object.

Request

No parameters required.

cURL Example

curl http://localhost:8000/health

Response

status
string
required
Always returns "ok" if the service is healthy

Success Response (200 OK)

{
  "status": "ok"
}

Response Codes

  • 200 OK - Service is healthy and running
  • 503 Service Unavailable - Service is down (connection refused/timeout)

Usage

This endpoint is typically used by:
  • Load balancers for health checks
  • Monitoring systems to verify service availability
  • Container orchestration platforms (Kubernetes, Docker Swarm)
  • CI/CD pipelines for deployment verification

Implementation

Location: app/main.py:703-705
@app.get("/health")
def health_check():
    return {"status": "ok"}

Notes

  • This endpoint does not check dependencies (database, external APIs)
  • For production use, consider adding checks for:
    • Database connectivity
    • External API availability (Telnyx, Deepgram)
    • Queue system health
    • Memory/CPU usage metrics

Build docs developers (and LLMs) love