Connect Mailgun
Signed webhooks for delivery events and Routes that forward inbound mail to Dextel.
Where this lives in Dextel
Prerequisites
- A Mailgun account and a domain you control (you'll add DNS records).
- Owner or admin access to the Dextel agency or sub-account.
- Credentials you'll enter in Dextel:
API key,Sending domain (e.g. mg.yourdomain.com),Region (US or EU).
1. Create the API credentials
- Open Settings → API Security → Add new key and copy it.
- On the same page copy the HTTP webhook signing key — you'll paste it into the Delivery events tab.
- Enter the key, your sending domain and its region (US / EU) in Dextel.
2. Verify your sending domain
- Open Send → Sending → Domains → Add new domain (for example mg.yourdomain.com) and pick US or EU.
- Add the SPF TXT, DKIM TXT and tracking CNAME records to your DNS.
- Click Verify DNS settings.
- Under Domain settings → Tracking turn on Opens and Clicks.
Then in Dextel enter a From email on that domain (for example hello@yourdomain.com) and a From name, and click Validate & Connect. Dextel checks the credentials against Mailgun before saving.
3. Delivery events
Delivered, opened, clicked, bounced and spam events feed the Email Event workflow trigger and automatically unsubscribe contacts after a hard bounce or complaint. Copy the Webhook URL from the Delivery events tab in Dextel, then:
- Open Send → Sending → Webhooks and select your domain.
- For Delivered, Permanent Failure, Temporary Failure, Complained, Opened and Clicked, add <your delivery-events webhook URL> as the URL.
- Paste the HTTP webhook signing key into Dextel.
Use Send a test email in the same tab to confirm outbound works; the events pill turns green once the first event arrives.
4. Inbound email (sub-accounts only)
Inbound turns contact replies into Inbox conversations and fires the Contact Replied — Email trigger. Mail is received at your saved From address, so when a contact hits Reply the message comes back through Mailgun to Dextel. The MX record routes all mail for that domain to Mailgun: if you already receive mail on the domain, send from an address on a subdomain (for example hello@mail.yourdomain.com).
DNS records
| Type | Host | Value | Priority |
|---|---|---|---|
| MX | yourdomain.com | mxa.mailgun.org (EU: mxa.eu.mailgun.org) | 10 |
| MX | yourdomain.com | mxb.mailgun.org (EU: mxb.eu.mailgun.org) | 10 |
Steps
- Open your sending domain (yourdomain.com) in Mailgun.
- Add the two MX records below (both priority 10) and wait for Mailgun to verify them.
- Open Send → Receiving → Routes → Create Route. Expression type Match Recipient, expression .*@yourdomain.com.
- Tick Forward, paste <your inbound webhook URL>, then Create Route.
Limits
- Routes forward messages up to 25 MB.
Troubleshooting
- Credentials rejected — the API key, domain and region must all match; an EU domain with a US key fails.
- Events 401 — the signing key is the HTTP webhook signing key under API Security, not the API key.
- Still stuck? Compare with another provider on the Email Providers overview.
