Skip to content

Email & Notifications

LaunchKit Pro includes mock email, email templates, email logs, and in-app notifications — no real SMTP required for development.

Mock email provider

env
EMAIL_PROVIDER=MOCK
EMAIL_FROM_NAME=LaunchKit Pro
EMAIL_FROM_ADDRESS=no-reply@yourdomain.com
SUPPORT_EMAIL=support@yourdomain.com

Emails 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):

bash
curl -s "http://localhost:4000/email/logs?page=1&limit=20" \
  -H "Authorization: Bearer <adminAccessToken>" | jq

Email templates

Admin-managed templates for transactional emails:

MethodPath
GET/email/templates
POST/email/templates
PATCH/email/templates/:templateId

Send test email (mock):

bash
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"}' | jq

Notifications

In-app notifications for users:

bash
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

  1. Choose provider (SMTP, GMAIL, or RESEND)
  2. Add credentials to server environment only (host, port, user, password, API key)
  3. Set EMAIL_PROVIDER accordingly
  4. Verify deliverability (SPF, DKIM, DMARC) for your domain
  5. 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:

JobPurpose
send_emailGeneric email
send_password_resetPassword reset
send_inviteWorkspace invite
send_license_emailLicense delivery
send_billing_receiptBilling receipt

With EMAIL_PROVIDER=MOCK, queue jobs log safe mock delivery. Synchronous email flows still work when queues are disabled.

See Background Queues.

LaunchKit Pro by LaunchKit Labs — buyer documentation. No secrets in this site.