Iskra API Reference
    Preparing search index...

    Interface HealthCheckConfig

    interface HealthCheckConfig {
        body?: { health?: HealthBody; live?: HealthBody; ready?: HealthBody };
        checks?: {
            [key: string]: (
                c: Context,
            ) => Promise<
                { details?: unknown; message?: string; status: "error"
                | "ok" },
            >;
        };
        checkTimeoutMs?: number;
        includeDetails?: boolean;
        livenessPath?: string
        | false;
        path?: string | false;
        readinessChecks?: { [name: string]: () => Promise<boolean> };
        readinessPath?: string | false;
    }
    Index
    body?: { health?: HealthBody; live?: HealthBody; ready?: HealthBody }

    Custom bodies per endpoint, instead of { status, … }: for example { live: () => ({ message: 'ok' }) }. The report carries the check names whatever includeDetails says; leave out what must not be public.

    checks?: {
        [key: string]: (
            c: Context,
        ) => Promise<
            { details?: unknown; message?: string; status: "error"
            | "ok" },
        >;
    }
    checkTimeoutMs?: number

    Per-check timeout for /health probes, in ms. Default 2000.

    includeDetails?: boolean
    livenessPath?: string | false

    The liveness endpoint, /health/live by default; false leaves it out.

    path?: string | false

    The health endpoint, /health by default; false leaves it out.

    readinessChecks?: { [name: string]: () => Promise<boolean> }
    readinessPath?: string | false

    The readiness endpoint, /health/ready by default; false leaves it out.