/**
 * Performance monitoring utilities for measuring and analyzing operation metrics
 */
export interface PerformanceMetrics {
    avg: number;
    p50: number;
    p95: number;
    p99: number;
    min: number;
    max: number;
    count: number;
}
/**
 * Monitor performance of operations with percentile tracking
 */
export declare class PerformanceMonitor {
    private metrics;
    private readonly maxSamples;
    constructor(options?: {
        maxSamples?: number;
    });
    /**
     * Measure and record duration of an async operation
     */
    measure<T>(name: string, fn: () => Promise<T>): Promise<T>;
    /**
     * Record a metric directly
     */
    record(metric: string, duration: number): void;
    /**
     * Get statistics for a metric
     */
    getStats(metric: string): PerformanceMetrics | null;
    /**
     * Get all metric names
     */
    getMetrics(): string[];
    /**
     * Clear all metrics
     */
    clear(): void;
    /**
     * Export metrics as JSON
     */
    exportMetrics(): Record<string, PerformanceMetrics>;
}
export declare function getPerformanceMonitor(): PerformanceMonitor;
/**
 * Helper to wrap any function with performance monitoring
 */
export declare function monitorFunction<T extends (...args: unknown[]) => Promise<unknown>>(fn: T, name?: string): T;
//# sourceMappingURL=performance-monitor.d.ts.map