1. Help Center
  2. SendX
  3. Email Service Provider (ESP) Integration Guides

Mailgun Integration Guide

You will need to perform the following steps in order to get Mailgun integrated with SendX:

  • Sign up with Mailgun

  • Setup your domain to send mails

  • Use Mailgun keys to send mails through SendX

  • Setup Hard Bounces and Complaints reporting on SendX

Sign up with Mailgun

  • Sign up on Mailgun and create an account.

  • Go through the sign up sequence and go to the dashboard

Setup your domain to send mails

  • In the "Sending Domains" section, click on "Add New Domain".

  • Add your domain name to the next page and click "Add Domain".

  • On the next page, go to the "Domain Verification & DNS" section. This provides all DNS entries you need to add to your domain hosting service(like GoDaddy or AWS Route53). Add these entries and click on "Check DNS Records Now" button in the same section. This step can take a while since the DNS records take a few minutes to hours to validate across the internet.

  • Once verified, the domain will be set as active.

  • You are set to send mails through Mailgun.

  • Go back to the dashboard. In the API Keys section, copy the "Secret API Key" and "Public API Key" which will be used for the integration.

Use Mailgun keys to send mails through SendX

  • Go to your settings page on SendX and select the "Custom Providers" tab and click on "+ New" button.

  • Name your provider settings. Select Type as Mailgun in the form therein.

  • Add  "Public API Key" and "Secret API Key" which are copied from Mailgun.

  • Click on "Submit" to add this Mailgun setup as your provider.

  • To test this, create a campaign and send a test email to verify the settings.

Setup Hard Bounces and Complaints reporting on SendX
This step is very essential since it reports all bounce contacts and spam complaints to SendX so that no mail is further attempted to them. Mailing these addresses again can lead to a bad reputation of your domain leading to bad deliverability and your mails landing in the SPAM folders of your contacts.

  • From Mailgun dashboard, select "Webhooks" tab.

  • Select the domain you just created. There will be multiple webhook options listed here.

  • Click the "+" icon of the following sections and add the URL https://app.sendx.io/api/v1/mailgun/event in the overlay form:
    - Dropped Messages
    - Hard Bounces
    - Spam Complaints

You're all set now.

Did this answer your question?