Email & Notifications
LaunchKit Pro includes mock email, email templates, email logs, and in-app notifications — no real SMTP required for development.
Mock email provider
EMAIL_PROVIDER=MOCK
EMAIL_FROM_NAME=LaunchKit Pro
EMAIL_FROM_ADDRESS=no-reply@yourdomain.com
SUPPORT_EMAIL=support@yourdomain.comEmails are recorded in the database (EmailLog) instead of being delivered to real inboxes. Useful for:
- Password reset links
- Email verification
- Workspace invites
- Contact form alerts
- Support ticket notifications
View logs (admin):
curl -s "http://localhost:4000/email/logs?page=1&limit=20" \
-H "Authorization: Bearer <adminAccessToken>" | jqEmail templates
Admin-managed templates for transactional emails:
| Method | Path |
|---|---|
GET | /email/templates |
POST | /email/templates |
PATCH | /email/templates/:templateId |
Send test email (mock):
curl -s -X POST http://localhost:4000/email/test \
-H "Authorization: Bearer <adminAccessToken>" \
-H "Content-Type: application/json" \
-d '{"to": "user@example.com", "templateCode": "welcome"}' | jqNotifications
In-app notifications for users:
curl -s "http://localhost:4000/notifications?page=1&limit=20" \
-H "Authorization: Bearer <accessToken>" | jq
curl -s http://localhost:4000/notifications/unread-count \
-H "Authorization: Bearer <accessToken>" | jq
curl -s -X PATCH http://localhost:4000/notifications/<notificationId>/read \
-H "Authorization: Bearer <accessToken>"Mark all read: PATCH /notifications/read-all
Frontend: notification bell in dashboard/admin header.
Future SMTP / Gmail / Resend setup
- Choose provider (
SMTP,GMAIL, orRESEND) - Add credentials to server environment only (host, port, user, password, API key)
- Set
EMAIL_PROVIDERaccordingly - Verify deliverability (SPF, DKIM, DMARC) for your domain
- Keep mock provider in staging if desired
WARNING
Never commit SMTP passwords, Gmail app passwords, or Resend API keys to git or buyer docs.
Email queue foundation (optional)
When QUEUES_ENABLED=true and Redis is configured, email jobs can be processed on the email queue:
| Job | Purpose |
|---|---|
send_email | Generic email |
send_password_reset | Password reset |
send_invite | Workspace invite |
send_license_email | License delivery |
send_billing_receipt | Billing receipt |
With EMAIL_PROVIDER=MOCK, queue jobs log safe mock delivery. Synchronous email flows still work when queues are disabled.
See Background Queues.
Related
- Authentication — reset/verify flows use mock email
- Background Queues — optional async email jobs
- Contact & Support
- Troubleshooting — email mock logs