Connect SonicFunnels with Mailgun

In this article I will show you how to connect your SonicFunnels installation with Mailgun to send out transactional email messages such as registration or order confirmation.

First of all, what is Mailgun? It is an email automation service provided by Rackspace. It offers a cloud-based email service for sending, receiving and tracking emails. In SonicFunnels 1.0.7 we have integrated the Mailgun API to provide a more reliable and smooth email sending. We recommend using this option or the Amazon SES integration since they are more powerful and safe than the simple SMTP email setting.

Mailgun Settings in SonicFunnels

To use Mailgun in SonicFunnels, log into your administration panel and go to “Settings” -> “Email Settings”. here you will have the following options:

  • Select SMTP Type: here select Mailgun.
  • Mailgun domain: here add your domain name i.e. yoursite.com
  • Mailgun Secret key: you need to paste your secret api key here. It will be obtained from the Mailgun website (see below)
  • Mailgun endpoint: Select “US” if you are located in the United States, select “EU” if you are located outside of the US.
  • From/Site Email address: this the email address that will be used to send out messages.

Setting up the Mailgun Account

In order to use this integration, you will need to register an account with them. Mailgun is not a free service, but it’s very cheap. If you select their “Pay as you grow” plan, you will get 5000 FREE emails per month for 3 months. After that you will pay $0.80 / 1000 emails. So unless you send out a huge number of emails everyday, you will pay close to nothing.

After you registered and verified your account, log in and you will need to also add and verify your domain name. Go to “Sending” -> “Domains” -> “Add new domain”. Here you will need to provide your domain name and select your region/endpoint. After adding your domain name to your MG account, you will need to add some new DNS records to your domain name.

Go to your Dashboard and scroll down until you see your “Sending Domains”.

Click the “Domain settings” link next to your domain name.

On the “Domain settings” page select the “DNS records” tab. Add all recommended DNS records to your Domain name except the MX records. How you can update DNS records for your domain name is slightly different with each Domain registrar. If you are not sure how to do this, please checkout these articles. Please note, after you update your DNS records, it may take up to 48 hours for the changes to take effect. But usually it’s just a few minutes. If you are using cPanel on your server, and your domain name is added to your cPanel, then you can update your DNS records directly in cPanel. Just go to “Domains” -> “Zone Editor”.

Getting Mailgun Secret Key

In the SonicFunnels email settings we have not added our Mailgun Secret Key yet. To obtain the secret key, go to your MG account dashboard and click on “API keys”. It will take you to the “Account security” page. Select the “API security” tab and you will see your API keys. You will need the first one called “Private API key”. Click the eye icon to reveal the entire API key string. Copy it and paste it into your SonicFunnels “Settings” -> “Email Settings” -> “Mailgun Secret Key” field. Then save your settings.

Troubleshooting

If you are having trouble receiving messages from your contact form, you may need to create a catch-all email address. If you are using cPanel, just log into it and go to the “Email” section and click on “Default Address”. Here select the “Forward to email address” option and add an existing email address to the field and click the “Change” button. After this you should receive messages from your contact form.

Useful links:

0 Comment ON Connect SonicFunnels with Mailgun