Mailing
SendGrid Configuration
SendGrid is a cloud-based email service that provides reliable email delivery for your applications. staarter.dev includes built-in support for sending emails using SendGrid, allowing you to configure your SendGrid settings in the environment variables and start sending emails from your application.
Configuring SendGrid Settings
To configure SendGrid settings in staarter.dev, follow these steps:
Update the environment variables
- Open the
.env.local
file in the root of your project directory. - Add the following environment variables to configure your SendGrid settings:
SENDGRID_API_KEY=your-api-key
Replace your-api-key
with your SendGrid API key. Read more about how to obtain a SendGrid API key.
Change the email provider
In packages/mailing/providers/index.ts
, you can change the export instruction to use the SendGrid provider:
export { send } from './sendgrid'