Health Check
Monitoring
Health Check
GET
Health Check
The health check endpoint provides a quick way to verify that the KYC API service is running and responsive.
Endpoint
Authentication
No authentication required. This endpoint is publicly accessible for monitoring purposes.Description
This endpoint performs a basic liveness check. It’s suitable for:- Service availability monitoring
- Integration health verification
- Uptime monitoring
- Deployment verification
Request Example
Response Format
Success Response
Response Fields
| Field | Type | Description |
|---|---|---|
status | string | Always "ok" when service is running |
service | string | Service identifier: "kyc-health" |
check_type | string | Type of check: "liveness" |
timestamp | string | ISO 8601 timestamp of the check |
cold_start | boolean | true if this was a cold Lambda start |
function_name | string | AWS Lambda function name |
function_version | string | Lambda function version |
request_id | string | Unique request identifier |
Status Codes
| Code | Description |
|---|---|
| 200 | Service is healthy and responding |
| 500 | Service is unavailable (should not occur if service is running) |
Use Cases
Load Balancer Configuration
Configure your load balancer to poll this endpoint:Monitoring Integration
Use this endpoint with monitoring tools:Deployment Verification
After integration, verify the service is accessible:Readiness Check
The readiness endpoint performs a deeper health check that verifies dependencies (S3, DynamoDB) are accessible.Endpoint
Authentication
Requireshealth:readiness_check permission. Include your Bearer token in the Authorization header.
Description
This endpoint performs a readiness check that verifies:- S3 bucket accessibility (watchlist snapshots)
- DynamoDB table accessibility (watchlists)
- Overall service readiness
- Pre-deployment verification
- Dependency health monitoring
- Service readiness confirmation
Request Example
Response Format
Degraded Status Response
If any dependency is unhealthy, the overall status will be"degraded":
Response Fields
| Field | Type | Description |
|---|---|---|
status | string | Overall status: "healthy" or "degraded" |
service | string | Service identifier: "kyc-health" |
check_type | string | Type of check: "readiness" |
timestamp | string | ISO 8601 timestamp of the check |
cold_start | boolean | true if this was a cold Lambda start |
dependencies | object | Status of each dependency (S3, DynamoDB) |
Dependency Status Fields
Each dependency includes:| Field | Type | Description |
|---|---|---|
status | string | "healthy" or "unhealthy" |
service | string | Service name ("s3" or "dynamodb") |
message | string | Human-readable status message |
error | string | Error code (only present if unhealthy) |
Status Codes
| Code | Description |
|---|---|
| 200 | Readiness check completed (may be healthy or degraded) |
| 403 | Forbidden - Missing health:readiness_check permission |
| 401 | Unauthorized - Missing or invalid token |
Use Cases
Pre-Deployment Verification
Monitoring Integration
Implementation Notes
- No Caching: Each request performs a fresh check
- Public Access:
/healthendpoint requires no authentication (by design for monitoring) - Authenticated Access:
/health/readyrequireshealth:readiness_checkpermission - Always Available: Returns 200 OK when the service is operational (status may be healthy or degraded)