/**
 * GuardPostureTripwire — a disabled guard is itself an incident.
 *
 * Triggering incident (2026-06-05): the meltdown load-shed at 2:54 PM PDT
 * batch-flipped a set of monitoring guards off in `.instar/config.json` —
 * scheduler.enabled (issue #882), contextWedgeSentinel, failureLearning,
 * resourceLedger, burnDetection. Only the scheduler was noticed and
 * re-enabled (5.5h later); the wedge sentinel stayed dark and watched the
 * EXO 3.0 AUP-rejection wedge kill a session for an hour THAT SAME EVENING
 * without a single audit row. No instar code writes those flags — the flip
 * was emergency hand-editing — so nothing structural recorded it. Two
 * silently-disabled guards discovered in one day is a class, not a
 * coincidence.
 *
 * The tripwire: at every server boot, compare the resolved guard posture
 * (every monitoring.* enabled flag + scheduler.enabled) against the persisted
 * posture from the previous boot. Any guard that went enabled→disabled gets:
 *   1. a loud boot log line,
 *   2. one JSONL breadcrumb row in `logs/guard-posture.jsonl` (same home as
 *      sentinel-events.jsonl — the documented "why did X stop?" surface),
 *   3. ONE aggregated Attention item listing every newly-disabled guard
 *      (aggregate per the Bounded Notification Surface rule — never one
 *      item per guard).
 * Re-enabled guards get the log line + breadcrumb only (good news is not a
 * to-do). First boot (no snapshot) records the posture and raises nothing.
 *
 * Signal-vs-authority: pure detector. It never re-enables anything, never
 * blocks a boot, never edits config — a deliberate disable stays disabled;
 * the Attention item is the consent surface where the operator either
 * acknowledges the flip or goes and re-enables the guard. Errors are
 * swallowed into the log: a broken tripwire must never break a boot.
 */
import { COST_INCREASING_ENABLE_KEYS, diffGuardPosture, extractGuardPosture, type GuardPosture, type GuardPostureDiff } from './guardPosture.js';
export { COST_INCREASING_ENABLE_KEYS, diffGuardPosture, extractGuardPosture };
export type { GuardPosture, GuardPostureDiff };
export interface AttentionItemInput {
    id: string;
    title: string;
    summary: string;
    description?: string;
    category: string;
    priority: 'URGENT' | 'HIGH' | 'NORMAL' | 'LOW';
    sourceContext?: string;
}
export interface GuardPostureTripwireOpts {
    /** The RESOLVED config object the server is booting with. */
    config: unknown;
    /** Agent state dir (`<projectDir>/.instar`) — snapshot lives at `state/guard-posture.json`. */
    stateDir: string;
    /** Logs dir (`<projectDir>/logs`) — breadcrumb lives at `guard-posture.jsonl`. */
    logsDir: string;
    /** Aggregated Attention emit; absent (no Telegram) → breadcrumb-only. */
    emitAttention?: (item: AttentionItemInput) => Promise<void>;
    /** Boot logger (default console.log). */
    log?: (msg: string) => void;
    /** Clock override (tests). */
    now?: () => Date;
}
export interface GuardPostureTripwireResult {
    firstBoot: boolean;
    disabled: string[];
    enabled: string[];
    attentionEmitted: boolean;
    /** Non-fatal error message when the tripwire degraded (never throws). */
    error?: string;
}
/** Run the tripwire once at boot. Never throws. */
export declare function runGuardPostureTripwire(opts: GuardPostureTripwireOpts): Promise<GuardPostureTripwireResult>;
//# sourceMappingURL=GuardPostureTripwire.d.ts.map