🔌Connect Mailgun API

Watch our Mailgun API introduction video then read through our easy to follow documentation with more details below:

Unlike SMTP Relay, API integration must be customized for each ESP. If you are a customer and want an API integration for your favorite ESP, please open a support ticketarrow-up-right.

circle-info

API integrations are bidirectional

To track real-time delivery progress natively in your platform including bounce and complaint rates, use an API implementation such as Mailgun, Sparkpost, or Amazon SES.

Velocity MTA, which comes free with your platform, also tracks real-time delivery over your own IP Addresses.

While logged in to the backend as administrator, click the connect menu, select Mailgun API, then click Add Mailgun Account.

circle-info

Name

Give your API connection an internal name. This will only be seen by you and is for management purposes only.

circle-info

Finding the correct API Key

You must use the private API key from the Mailgun user menu in the top right of the Mailgun interface, and NOT the Sending API Key from the Mailgun 'Sending' configuration.

circle-exclamation
circle-info

Adding your Mailgun API Key

Paste in your Mailgun private API Key.

circle-info

Adding a sending domain to Mailgun

Before you can use your sending domain through the Mailgun API, you must add your domain to Mailgun and verify you're the owner.

circle-info

Enter a base domain or subdomain

Most mailbox providers such as Gmail recommend using a subdomain, however, this decision is based on your own preferences and goals. Using 'mg' for 'Mailgun' is a common subdomain seen with Mailgun customers.

circle-info

Verify ownership by adding DKIM/SPF authentication

It's not necessary to add the suggested MX records in order for your domain to be successfully verified. This decision is based on your own preferences and goals.

Follow Mailgun's instructions for adding DKIM/SPF verification records to your DNS provider.

circle-info

Mailgun may need a moment to detect the changes you've made to your domain configuration. If it doesn't verify you right away, try again in 1-2 minutes.

circle-exclamation
circle-info

Add your verified domain to your platform

Once your domain has been successfully verified by Mailgun, add it to your platform exactly as it appears on Mailgun.

circle-info

White-label tracking links

Unless you change your link domain, your admin_url domain will be used for your tracking links in your email messages. You can add a custom link to automatically match your domain branding for mail sent through this API connection, no further action is required beyond this step for it to work.

circle-exclamation
circle-info

Next Steps

Return to the getting ready to send page and follow the instructions to start using your newly configured Mailgun API connection:

Additional information

circle-check
circle-exclamation
circle-info

Next Steps

Return to the getting ready to send page and follow the instructions to start using your newly configured SMTP Relay connection:

👩‍💻Getting ready to sendchevron-right

Last updated

Was this helpful?