export type AttachmentTextOutcome = "extracted" | "no-text-layer" | "unsupported-mime"; export interface AttachmentTextResult { outcome: AttachmentTextOutcome; /** Extracted text; empty string for no-text-layer and unsupported-mime. */ text: string; mimeType: string; } /** * Extract readable text from one attachment's already-decoded bytes. * * - `application/pdf` → `pdftotext` (poppler-utils). Empty output means the * PDF has no text layer (a scanned image), reported as `no-text-layer` * rather than an empty success so "no data in the PDF" is never * indistinguishable from "the PDF could not be read". * - `text/*` → UTF-8 decode. * - anything else → `unsupported-mime` (no bytes are interpreted). * * This is the email plugin's own extractor. Plugin isolation forbids importing * the memory plugin's copy, so the `pdftotext` pattern is duplicated here. */ export declare function extractAttachmentText(bytes: Buffer, mimeType: string): Promise; //# sourceMappingURL=attachment-text.d.ts.map