export type EmailProviderKey = 'resend' | 'smtpcom' | 'ses' | 'smtp';
export type SaveState = 'idle' | 'saving' | 'success' | 'error';
export declare const EMAIL_PROVIDER_OPTIONS: Array<{
    value: EmailProviderKey;
    label: string;
}>;
/** Form state. Secrets are write-only: inputs start empty and never echo stored values. */
export interface EmailSettingsForm {
    /** Empty string = email delivery not configured here. */
    provider: EmailProviderKey | '';
    from: string;
    apiKey: string;
    channel: string;
    region: string;
    host: string;
    port: string;
    secure: boolean;
    smtpUser: string;
    smtpPass: string;
}
export interface UseEmailSettings {
    loading: boolean;
    loadError: string | null;
    form: EmailSettingsForm;
    /** Masked metadata about stored secrets (never the secret itself). */
    stored: {
        hasApiKey: boolean;
        apiKeyLast4?: string;
        hasSmtpPass: boolean;
        sameProvider: boolean;
    };
    env: {
        provider: EmailProviderKey | null;
        senderActive: boolean;
    };
    factoryAvailable: boolean;
    platformAdapter: boolean;
    lastTest: {
        status?: 'success' | 'failed';
        testedAt?: string;
        error?: string;
    };
    dirty: boolean;
    saveState: SaveState;
    saveError: string | null;
    testing: boolean;
    testResult: {
        success: boolean;
        message: string;
    } | null;
    setField: <K extends keyof EmailSettingsForm>(key: K, value: EmailSettingsForm[K]) => void;
    save: () => Promise<void>;
    sendTest: () => Promise<void>;
    reset: () => void;
    reload: () => void;
}
export declare function useEmailSettings(canEdit: boolean): UseEmailSettings;
//# sourceMappingURL=useEmailSettings.d.ts.map