import { type ToolContext, type ToolResult } from "./registry.js"; import { type PendingAttachment, type PendingReason, type PendingSend } from "../pending.js"; import type { Attachment, MailProvider } from "../providers/interface.js"; export declare function checkSendLimit(account: string): string | null; export declare function clearSendLimit(account: string): void; export interface OutgoingArgs { account: string; recipients: string[]; knownRecipients?: string[]; isForward?: boolean; draftOnly?: boolean; } export interface OutgoingGate { provider: MailProvider; draftsOnly: boolean; /** Set when the send must go to the approval queue instead of the provider. */ queueReason?: PendingReason; taintedBy?: string; } export declare function gateOutgoing(args: Record, ctx: ToolContext, out: OutgoingArgs): Promise; export declare function isRefusal(gate: { provider: MailProvider; } | ToolResult): gate is ToolResult; export declare function attachmentSpecs(paths: string[], loaded: Attachment[] | undefined): PendingAttachment[]; export declare function queueOutgoing(gate: OutgoingGate, spec: Omit): ToolResult;