42 lines
1.5 KiB
TypeScript
42 lines
1.5 KiB
TypeScript
/**
|
|
* MTA error classes for SMTP client operations
|
|
*/
|
|
export declare class MtaConnectionError extends Error {
|
|
code: string;
|
|
details?: any;
|
|
constructor(message: string, detailsOrCode?: any);
|
|
static timeout(host: string, port: number, timeoutMs?: number): MtaConnectionError;
|
|
static refused(host: string, port: number): MtaConnectionError;
|
|
static dnsError(host: string, err?: any): MtaConnectionError;
|
|
}
|
|
export declare class MtaAuthenticationError extends Error {
|
|
code: string;
|
|
details?: any;
|
|
constructor(message: string, detailsOrCode?: any);
|
|
static invalidCredentials(host?: string, user?: string): MtaAuthenticationError;
|
|
}
|
|
export declare class MtaDeliveryError extends Error {
|
|
code: string;
|
|
responseCode?: number;
|
|
details?: any;
|
|
constructor(message: string, detailsOrCode?: any, responseCode?: number);
|
|
static temporary(message: string, ...args: any[]): MtaDeliveryError;
|
|
static permanent(message: string, ...args: any[]): MtaDeliveryError;
|
|
}
|
|
export declare class MtaConfigurationError extends Error {
|
|
code: string;
|
|
details?: any;
|
|
constructor(message: string, detailsOrCode?: any);
|
|
}
|
|
export declare class MtaTimeoutError extends Error {
|
|
code: string;
|
|
details?: any;
|
|
constructor(message: string, detailsOrCode?: any);
|
|
static commandTimeout(command: string, hostOrTimeout?: any, timeoutMs?: number): MtaTimeoutError;
|
|
}
|
|
export declare class MtaProtocolError extends Error {
|
|
code: string;
|
|
details?: any;
|
|
constructor(message: string, detailsOrCode?: any);
|
|
}
|