Emails
Setup
StartKit.AI uses Resend to send emails and manage mailing lists.
If you want to use the magic link authentication then you’ll need to follow this guide. Alternatively you can disable authentication for Example App by adding the following to the bottom of your .env
file:
Sending emails
Signup for Resend, follow their instructions to create an account, and copy your API key.
Set the API key in your .env
file;
Now you need to setup a domain for sending from.
Follow the Resend domain instructions here and enter your sending address in the .env
file:
We recommend setting a “from name” before the address so it shows up nicely in your customers email clients. You can do that like this:
You can test your integration by sending a test email with the sendTestEmail()
function in /server/helpers/emails.js
.
Mailing lists
If you want to add customers to a mailing list you will also need to setup an audience in Resend and copy your audience ID.
Add the audience ID to your .env
:
You can now manage your Resend audience with addUserToMailingList()
and removeUserFromMailingList()
.