Mailgun
Mailgun Setup Tutorial
Fast Phoenix includes Mailgun integration for sending transactional emails and running email campaigns. Follow these steps to configure Mailgun for your project.
Step 1: Prepare Your Environment Variables
Fast Phoenix uses environment variables to manage Mailgun configuration. Open your .env
file and ensure the following variables are set:
Replace the placeholder values with your actual Mailgun API key and domain.
Step 2: Set Up Mailgun Account
Create a Mailgun Account Sign up or log in to your Mailgun Dashboard.
Add Your Domain
Navigate to Domains and add your sending domain (e.g.,
your-domain.com
).Follow the DNS setup instructions provided by Mailgun to verify your domain.
Get Your API Key
Once your domain is verified, go to API Keys in your account settings.
Copy your private API key and paste it into the
MAILGUN_API_KEY
field in your.env
file.
Step 3: Test Mailgun Integration
Send a Test Email In your Phoenix application, you can send a test email to verify the setup:
Verify the Email Check the recipient's inbox or your Mailgun logs to confirm the email was sent successfully.
Step 4: Configure Email Templates
Fast Phoenix supports customizable email templates stored in the database. You can manage them directly from the admin interface:
Navigate to the admin dashboard.
Select Email Templates to view, create, or edit templates.
Step 5: Bulk Email Campaigns
Use Fast Phoenix emailing capabilities to send bulk emails directly from the admin dashboard:
Set filters for user types to target specific audiences.
Compose your email campaign using a custom template.
Launch the campaign, and track its performance in the Mailgun Dashboard.
Last updated