import type { Middleware } from './types.js';
/**
 * Shape of one telemetry entry appended to calls-<date>.jsonl
 */
export interface TelemetryEntry {
    ts: string;
    toolName: string;
    durationMs: number;
    outcome: 'ok' | 'error' | 'budget_exceeded';
    errorCode?: string;
    sessionId: string;
    modelId: string;
}
/**
 * Check if telemetry is enabled for the given project root.
 * Reads conventions.json synchronously (fast path for hot tool paths).
 * Defaults to disabled (opt-in stance per SPEC-741).
 */
export declare function isTelemetryEnabled(projectRoot: string): boolean;
/**
 * withTelemetry middleware: records one JSONL entry per tool call.
 * Gates on telemetry.enabled in conventions.json (SPEC-741 opt-in).
 */
export declare const withTelemetry: Middleware;
//# sourceMappingURL=with-telemetry.d.ts.map