/**
 * Workflow Audit System
 * Tracks validation history, changes, and compliance for workflows
 */
import type { Workflow, ValidationResult } from './workflowValidation';
export interface ValidationHistoryEntry {
    timestamp: string;
    workflowId: string;
    workflowVersion: string;
    validationResult: ValidationResult;
    userId: string;
    action: 'create' | 'update' | 'validate' | 'deploy';
    changes?: WorkflowChange[];
    metadata: {
        environment: 'development' | 'staging' | 'production';
        browser: string;
        userAgent: string;
        ipAddress?: string;
    };
}
export interface WorkflowChange {
    type: 'node' | 'edge' | 'config' | 'metadata';
    action: 'add' | 'remove' | 'modify';
    targetId: string;
    field?: string;
    oldValue?: any;
    newValue?: any;
    timestamp: string;
}
export interface AuditSummary {
    totalValidations: number;
    successRate: number;
    averageIssuesPerValidation: number;
    mostCommonIssues: Array<{
        code: string;
        count: number;
        percentage: number;
    }>;
    validationTrend: Array<{
        date: string;
        successCount: number;
        failureCount: number;
    }>;
    complianceStatus: {
        security: boolean;
        admin: boolean;
        data: boolean;
        lastChecked: string;
    };
}
declare class WorkflowAudit {
    private history;
    private readonly maxHistorySize;
    constructor(maxHistorySize?: number);
    /**
     * Record a validation event
     */
    recordValidation(workflow: Workflow, validationResult: ValidationResult, userId: string, action: ValidationHistoryEntry['action'], changes?: WorkflowChange[], metadata?: Partial<ValidationHistoryEntry['metadata']>): ValidationHistoryEntry;
    /**
     * Get validation history for a workflow
     */
    getWorkflowHistory(workflowId: string): ValidationHistoryEntry[];
    /**
     * Get audit summary for a workflow
     */
    getAuditSummary(workflowId: string): AuditSummary;
    /**
     * Calculate validation trend over time
     */
    private calculateValidationTrend;
    /**
     * Check compliance status based on validation history
     */
    private checkComplianceStatus;
    /**
     * Export audit data for compliance reporting
     */
    exportAuditData(workflowId: string): string;
    /**
     * Clear audit history (useful for testing)
     */
    clearHistory(): void;
}
export declare const workflowAudit: WorkflowAudit;
export type { ValidationHistoryEntry, WorkflowChange, AuditSummary };
//# sourceMappingURL=workflowAudit.d.ts.map