export interface MimeMessage { headers: Record; from: string; to: string; cc: string; subject: string; date: string; messageId: string; inReplyTo: string; contentType: string; textBody: string; htmlBody: string; attachments: MimeAttachment[]; } export interface MimeAttachment { filename: string; contentType: string; size: number; content: Buffer; } /** * Parse a raw email message into structured parts. */ export declare function parseMessage(raw: string): MimeMessage; /** * Strip HTML tags and return plain text. */ export declare function htmlToText(html: string): string; /** * Build a MIME message with optional attachments. */ export declare function buildMimeMessage(options: { from: string; to: string; cc?: string; bcc?: string; subject: string; textBody?: string; htmlBody?: string; inReplyTo?: string; references?: string; attachments?: { filename: string; path: string; }[]; }): string; /** * Format a file size in human-readable form. */ export declare function formatFileSize(bytes: number): string;