move environment to src/environment add smtp env vars, move some other items
Some checks failed
Code quality checks / biome (push) Failing after 13s

This commit is contained in:
creations 2025-06-10 15:16:31 -04:00
parent 421043c9b5
commit 00a7417936
Signed by: creations
GPG key ID: 8F553AA4320FC711
30 changed files with 470 additions and 42 deletions

42
types/config/mailer.ts Normal file
View file

@ -0,0 +1,42 @@
type MailerConfig = {
address: string;
port: number;
from: string;
username: string;
password: string;
secure: boolean;
pool: boolean;
connectionTimeout: number;
socketTimeout: number;
maxConnections: number;
maxMessages: number;
replyTo: string;
};
type EmailOptions = {
to: string | string[];
subject: string;
text?: string;
html?: string;
from?: string;
replyTo?: string;
cc?: string | string[];
bcc?: string | string[];
attachments?: EmailAttachment[];
};
type EmailAttachment = {
filename: string;
content?: Buffer | string;
path?: string;
contentType?: string;
cid?: string; // content-ID for embedded images
};
type EmailResult = {
success: boolean;
messageId?: string;
error?: string;
};
export type { MailerConfig, EmailOptions, EmailAttachment, EmailResult };