The Startup Template
  • The Startup Template
  • Contributing to The Startup Template
  • Contributor Covenant Code of Conduct
  • 📘Tutorials
    • Playground builder
    • Enabling Authentication
    • Setting Up Email Notifications
    • Connecting to EdgeDB Cloud
    • Theming & Components
    • Common errors
Powered by GitBook
On this page
  • Create a Mailgun Account
  • Obtain Mailgun API Keys
  • Add to .env File
  • Example .env File
  • Final Steps
  • Additional Resources
  • Need Help?

Was this helpful?

Edit on GitHub
  1. Tutorials

Setting Up Email Notifications

To enable email notifications with Mailgun in your Startup Template project, follow these steps to obtain the necessary environment variables.

PreviousEnabling AuthenticationNextConnecting to EdgeDB Cloud

Last updated 1 year ago

Was this helpful?

Create a Mailgun Account

  1. Sign Up for Mailgun:

    • Go to and sign up for an account.

  2. Set Up Your Domain:

    • After signing up, set up your within the Mailgun dashboard.

Obtain Mailgun API Keys

  1. Retrieve Your Domain Information:

    • Once your domain is set up, navigate to your domain settings in the Mailgun dashboard.

  2. Get Your Domain Details:

    • Note down your Mailgun domain, sender email address.

Add to .env File

  1. Open Your .env File:

    • Open your project's .env file.

  2. Add Mailgun Environment Variables:

    • Add the following variables to your .env file:

    MAILGUN_DOMAIN=your_mailgun_domain
    MAILGUN_SENDER_EMAIL=your_sender_email
    MAILGUN_API_KEY=your_mailgun_api_key

Example .env File

Here is an example of what your .env file should look like after adding Mailgun environment variables:

MAILGUN_DOMAIN=example.com
MAILGUN_SENDER_EMAIL=sender@example.com
MAILGUN_API_KEY=key-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Final Steps

  1. Save Your Changes:

    • Save the changes to your .env file.

  2. Restart Your Server:

    • If your server is already running, restart it to apply the changes.

  3. Test Email Notifications:

    • Verify that email notifications are working as expected in your project.

Additional Resources


Need Help?

Happy coding!

Generate Mailgun API key from page.

If you have any feedback or run into any issues, don't hesitate to reach out at .

📘
api_security
Mailgun Documentation
nparashar150@gmail.com
Mailgun
domain
Mailgun domains
Mailgun api keys