diff --git a/backend/src/features/notifications/README.md b/backend/src/features/notifications/README.md index a99960c..77014cc 100644 --- a/backend/src/features/notifications/README.md +++ b/backend/src/features/notifications/README.md @@ -97,7 +97,7 @@ Templates use `{{variableName}}` syntax for variable substitution. ### Environment Variables - `RESEND_API_KEY` - Resend API key (required, stored in secrets) -- `FROM_EMAIL` - Sender email address (default: noreply@motovaultpro.com) +- `FROM_EMAIL` - Sender email address (default: hello@notify.motovaultpro.com) ### Email Delivery - Uses Resend API for transactional emails diff --git a/backend/src/features/notifications/domain/email-layout/base-layout.ts b/backend/src/features/notifications/domain/email-layout/base-layout.ts index d09344a..befe414 100644 --- a/backend/src/features/notifications/domain/email-layout/base-layout.ts +++ b/backend/src/features/notifications/domain/email-layout/base-layout.ts @@ -65,7 +65,7 @@ export function renderEmailLayout(content: string): string { Login to MotoVaultPro

- Manage Email Preferences + Manage Email Preferences

© {new Date().getFullYear()} MotoVaultPro. All rights reserved. diff --git a/backend/src/features/notifications/domain/email.service.ts b/backend/src/features/notifications/domain/email.service.ts index 8a3a31e..baa1c15 100644 --- a/backend/src/features/notifications/domain/email.service.ts +++ b/backend/src/features/notifications/domain/email.service.ts @@ -16,7 +16,7 @@ export class EmailService { } this.resend = new Resend(apiKey); - this.fromEmail = process.env['FROM_EMAIL'] || 'info@notify.motovaultpro.com'; + this.fromEmail = process.env['FROM_EMAIL'] || 'hello@notify.motovaultpro.com'; } /** @@ -33,6 +33,10 @@ export class EmailService { to, subject, html, + headers: { + 'List-Unsubscribe': '', + 'List-Unsubscribe-Post': 'List-Unsubscribe=One-Click', + }, }); } catch (error) { const errorMessage = error instanceof Error ? error.message : 'Unknown error'; diff --git a/scripts/ci/notify.sh b/scripts/ci/notify.sh index 776200c..db69236 100755 --- a/scripts/ci/notify.sh +++ b/scripts/ci/notify.sh @@ -174,7 +174,7 @@ echo " Subject: $SUBJECT" # Build JSON payload JSON_PAYLOAD=$(cat <", + "from": "MotoVaultPro ", "to": ["$NOTIFY_EMAIL"], "subject": "$SUBJECT", "html": $(echo "$HTML_BODY" | jq -Rs .)