UNPKG

@simonecoelhosfo/optimizely-mcp-server

Version:

Optimizely MCP Server for AI assistants with integrated CLI tools

113 lines 2.9 kB
/** * Enhanced CLI Progress Reporter with Real-time Progress Bars * @description Provides visual progress feedback for cache sync operations using * the progress callback infrastructure implemented in Phase 3.1 * * Features: * - Real-time progress bars for each sync phase * - Multi-line progress display for concurrent operations * - Color-coded status indicators * - Detailed performance metrics * - Summary reports with SQL operation counts * * @author Optimizely MCP Server * @version 2.0.0 */ /** * Progress update structure from CacheManager */ export interface ProgressUpdate { phase: string; current: number; total: number; message: string; percent: number; timestamp?: string; } /** * Summary statistics for sync operations */ export interface SyncSummary { totalPhases: number; totalUpdates: number; duration: number; projectsSynced: number; entitiesProcessed: Record<string, number>; sqlOperations: { before: number; after: number; reduction: number; reductionPercent: number; }; } /** * Enhanced CLI Progress Reporter */ export declare class ProgressReporter { private spinners; private startTime; private phaseMetrics; private entityCounts; private sqlMetrics; private verboseMode; constructor(options?: { verbose?: boolean; }); /** * Handle progress update from CacheManager */ updateProgress(progress: ProgressUpdate): void; /** * Format progress text with bar visualization */ private formatProgressText; /** * Extract entity counts from progress messages */ private extractEntityCounts; /** * Log verbose progress details */ private logVerboseProgress; /** * Display sync start message */ startSync(operation: string, options?: any): void; /** * Display sync completion with summary */ completeSync(result: any): void; /** * Display error message */ error(error: Error): void; /** * Create a simple progress bar without spinners (for non-TTY environments) */ simpleProgress(progress: ProgressUpdate): void; /** * Check if terminal supports interactive progress */ static supportsProgress(): boolean; } /** * Progress aggregator for multi-project sync */ export declare class MultiProjectProgressAggregator { private projectProgress; private reporter; constructor(reporter: ProgressReporter); /** * Handle progress for specific project */ updateProjectProgress(projectId: string, progress: ProgressUpdate): void; /** * Aggregate progress across multiple projects */ private aggregateProgress; /** * Get summary for all projects */ getSummary(): Record<string, any>; } //# sourceMappingURL=ProgressReporter.d.ts.map