GET /api/v1/health
The health check endpoint monitors the status of the API server and its critical dependencies. This endpoint is useful for monitoring systems, load balancers, and deployment health checks.Authentication
No authentication required.Rate Limiting
- Rate: 30 requests per 2 seconds per IP
- Status Code on Limit: 429 Too Many Requests
Response
The endpoint returns different HTTP status codes depending on system health:- 200 OK: All services are healthy
- 503 Service Unavailable: One or more critical services are unhealthy
Overall system health status. Possible values:
healthy, unhealthyHealth status of individual services
Examples
Implementation Details
- Timeout: 6 seconds for all health checks
- Database Check: Executes
PingContext()to verify connectivity - Calendar Check: Calls Google Calendar API health check (non-critical)
- Email Check: Verifies service initialization
internal/handler/handler_health.go:19