UNPKG

@emailcheck/email-validator-js

Version:

Advanced email validation with MX records, SMTP verification, disposable email detection, batch processing, and caching. Production-ready with TypeScript support.

35 lines (34 loc) 1.5 kB
import type { DetectedName, NameDetectionParams } from './types'; /** * Default name detection method * Attempts to extract first and last name from email local part */ export declare function defaultNameDetectionMethod(email: string): DetectedName | null; /** * Detect name from email address * @param params - Detection parameters including email and optional custom method * @returns Detected name with confidence score, or null if no name detected */ export declare function detectNameFromEmail(params: NameDetectionParams): DetectedName | null; /** * Clean name by removing special characters (dots, underscores, asterisks) * Specifically designed for Algorithm name processing * * @param name - The name to clean * @returns The cleaned name with special characters removed */ export declare function cleanNameForAlgorithm(name: string): string; /** * Enhanced name detection for Algorithm with aggressive cleaning * Removes dots, underscores, and asterisks from detected names * * @param email - Email address to extract name from * @returns Detected name with cleaned special characters, or null if no name detected */ export declare function detectNameForAlgorithm(email: string): DetectedName | null; /** * Convenience function to detect name from email string * @param email - Email address to extract name from * @returns Detected name with confidence score, or null if no name detected */ export declare function detectName(email: string): DetectedName | null;