https://project.mdnd-it.cc/work_packages/94
This commit is contained in:
2025-08-23 04:25:28 +02:00
parent 725516ad6c
commit 19cfa031d0
25823 changed files with 1095587 additions and 2801760 deletions
@@ -0,0 +1,65 @@
export interface EmailOptions {
to: string;
subject: string;
html?: string;
text?: string;
template?: string;
templateData?: any;
}
export interface EmailConfig {
host: string;
port: number;
secure: boolean;
auth: {
user: string;
pass: string;
};
from: string;
}
export declare class EmailService {
private transporter;
private config;
private templatesPath;
constructor();
private initializeTransporter;
/**
* Send email with template
* @param options - Email options including template and data
*/
sendEmail(options: EmailOptions): Promise<boolean>;
/**
* Send verification email to user
* @param userEmail - User's email address
* @param userName - User's name
* @param verificationToken - Verification token
* @param verificationUrl - Complete verification URL
* @param language - Language code ('en', 'hu', 'de')
*/
sendVerificationEmail(userEmail: string, userName: string, verificationToken: string, verificationUrl: string, language?: 'en' | 'hu' | 'de'): Promise<boolean>;
/**
* Send password reset email
* @param userEmail - User's email address
* @param userName - User's name
* @param resetToken - Password reset token
* @param resetUrl - Complete password reset URL
* @param language - Language code ('en', 'hu', 'de')
*/
sendPasswordResetEmail(userEmail: string, userName: string, resetToken: string, resetUrl: string, language?: 'en' | 'hu' | 'de'): Promise<boolean>;
/**
* Load and compile email template with language support
* @param templateName - Name of the template file (with or without language suffix)
* @param data - Data to replace placeholders in the template
*/
private loadTemplate;
/**
* Get localized verification email subject
* @param language - Language code ('en', 'hu', 'de')
*/
private getLocalizedVerificationSubject;
/**
* Get localized password reset email subject
* @param language - Language code ('en', 'hu', 'de')
*/
private getLocalizedPasswordResetSubject;
}
//# sourceMappingURL=EmailService.d.ts.map