Email
Transactional email setup for the buyer portal.
The portal sends transactional email via Resend. Four templates ship in the box:
verification— the email link a new buyer clicks to confirm their address.passwordReset— when a buyer requests a password reset.welcome— sent after email verification.proPurchaseConfirmation— sent after a successful Pro purchase, with the GitHub invitation and clone instructions.
Required environment variables
RESEND_API_KEY=re_...
RESEND_FROM_EMAIL="AI Cost Gate <noreply@aicostgate.com>"The from address must be on a domain you've verified in Resend.
Optional: audience
To also collect a marketing audience, set:
RESEND_AUDIENCE_ID=...The newsletter form on the landing page will subscribe buyers to that audience.
Custom templates
Templates live in emails/*.tsx using react-email. After editing:
pnpm email:dev # preview at http://localhost:3000There is no separate export step — the templates are imported directly by the email-sending code.