Represents the result of a single health check execution
import { Result } from '@adonisjs/health'// Success resultconst result: HealthCheckResult = { message: 'Database connection is healthy', status: 'ok', finishedAt: new Date(), meta: { responseTime: 120 }}// Or using Result classconst result2 = Result.ok('Service is running') .setMetaData({ uptime: 86400 }) .toJSON() Copy
import { Result } from '@adonisjs/health'// Success resultconst result: HealthCheckResult = { message: 'Database connection is healthy', status: 'ok', finishedAt: new Date(), meta: { responseTime: 120 }}// Or using Result classconst result2 = Result.ok('Service is running') .setMetaData({ uptime: 86400 }) .toJSON()
A summary of the check result
The status of the check.
Date/time when this check was completed
Optional
An meta-data associated with the check
Represents the result of a single health check execution
Example