import { probeKaneReadiness } from "../core/kane-cli.js";
import { probeSonarReadiness } from "../core/sonar-integration.js";
import type { GateReport } from "./gate-report-types.js";
import { runUpdateCheck } from "./update-check.js";
/** Status values emitted by Lisa doctor checks. */
type DoctorStatus = "ok" | "warn" | "fail";
/** One Lisa doctor check result. */
export interface DoctorCheck {
    name: string;
    status: DoctorStatus;
    detail: string;
}
/** Machine-readable doctor result. */
export interface DoctorResult {
    checks: DoctorCheck[];
    /**
     * The deterministic gate report, present only under `--json`.
     *
     * A separate key rather than more `DoctorCheck` rows, because `DoctorStatus`
     * is `ok | warn | fail` and has no unknown state. A report whose central
     * contract is that "not checkable here" is never folded into a pass cannot
     * be expressed in a three-valued shape that lacks it — flattening it would
     * be the exact defect the report exists to detect, committed by the report.
     *
     * It also does not touch the exit code. The report describes what a project
     * has configured, and a project that has configured nothing is the modal
     * consumer, not a failing one.
     */
    gateReport?: GateReport;
}
/** Options parsed for `lisa doctor`. */
export interface DoctorOptions {
    json?: boolean;
    offline?: boolean;
    /**
     * Add the orthogonal "Repository readiness" audit ("may an agent fleet
     * operate here unattended?") and persist `.lisa/readiness.json`. Additive and
     * warn-only: the default doctor path is byte-identical when this is unset.
     */
    readiness?: boolean;
}
/** Runtime collaborators for doctor. */
export interface DoctorDependencies {
    fetchImpl: typeof fetch;
    runUpdateCheck: typeof runUpdateCheck;
    setExitCode: (code: number) => void;
    write: (message: string) => void;
    probeKaneReadiness: typeof probeKaneReadiness;
    probeSonarReadiness: typeof probeSonarReadiness;
}
/**
 * Check Lisa's installed version against npm.
 * Exported so the console live-status probe can reuse the same check as
 * `lisa doctor` — never invent a second npm update-check path.
 * @param deps - Runtime dependencies
 * @param offline - Skip network check
 * @returns Doctor check result
 */
export declare function checkVersion(deps: Pick<DoctorDependencies, "runUpdateCheck">, offline: boolean): Promise<DoctorCheck>;
/**
 * Run Lisa doctor checks.
 * @param targetPath - Optional project path
 * @param options - Parsed command options
 * @param dependencies - Optional collaborators for tests
 * @returns Doctor result
 */
export declare function runDoctor(targetPath: string | undefined, options: DoctorOptions, dependencies?: Partial<DoctorDependencies>): Promise<DoctorResult>;
export {};
//# sourceMappingURL=doctor.d.ts.map