/**
 * OpenTelemetry Observability
 *
 * Provides metrics, tracing, and logging for Vaspera operations.
 * Disabled by default, enabled via VASPERA_OTEL_ENABLED=true.
 *
 * @module observability/otel
 */
/**
 * Metric types for Vaspera operations
 */
export interface VasperaMetrics {
    /** Total findings by severity */
    findingsTotal: (severity: string, scanner: string) => void;
    /** Scan duration in milliseconds */
    scanDuration: (scanner: string, durationMs: number) => void;
    /** Certification duration in milliseconds */
    certificationDuration: (durationMs: number) => void;
    /** Agent run count */
    agentRuns: (agentType: string, status: "success" | "failure") => void;
    /** Circuit breaker state changes */
    circuitBreakerState: (name: string, state: string) => void;
    /** Retry attempts */
    retryAttempts: (operation: string, attempt: number) => void;
}
/**
 * Span context for tracing
 */
export interface SpanContext {
    traceId: string;
    spanId: string;
    parentSpanId?: string;
}
/**
 * Span interface for tracing operations
 */
export interface Span {
    /** Set an attribute on the span */
    setAttribute(key: string, value: string | number | boolean): void;
    /** Record an error */
    recordException(error: Error): void;
    /** End the span */
    end(): void;
    /** Get span context */
    getContext(): SpanContext;
}
/**
 * Tracer interface for creating spans
 */
export interface Tracer {
    /** Start a new span */
    startSpan(name: string, attributes?: Record<string, string | number | boolean>): Span;
    /** Run a function within a span */
    withSpan<T>(name: string, fn: (span: Span) => Promise<T>): Promise<T>;
}
/**
 * Check if OpenTelemetry is enabled
 */
export declare function isOtelEnabled(): boolean;
/**
 * Get the OTLP endpoint
 */
export declare function getOtlpEndpoint(): string;
/**
 * Initialize OpenTelemetry (lazy initialization)
 *
 * When VASPERA_OTEL_ENABLED=true, this will:
 * 1. Initialize the OTEL SDK
 * 2. Set up OTLP exporter
 * 3. Register metrics and tracing providers
 *
 * When disabled (default), returns no-op implementations.
 */
export declare function initializeOtel(): Promise<void>;
/**
 * Get the metrics instance
 */
export declare function getMetrics(): VasperaMetrics;
/**
 * Get the tracer instance
 */
export declare function getTracer(): Tracer;
/**
 * Get in-memory metrics stats (when OTEL is disabled)
 */
export declare function getInMemoryStats(): {
    findings: Record<string, number>;
    recentScans: Array<{
        scanner: string;
        durationMs: number;
        timestamp: Date;
    }>;
    agentRuns: Record<string, {
        success: number;
        failure: number;
    }>;
};
/**
 * Reset in-memory metrics (for testing)
 */
export declare function resetInMemoryStats(): void;
//# sourceMappingURL=otel.d.ts.map