Mailgun Email API//Allowlist
Allowlist
API Overview
Authentication
Developer Tools
Mailgun API
Messages
Domains
Domain Keys
Domain Tracking
DKIM Security
Account Webhooks
Domain Webhooks
Metrics
Logs
Bounce Classification
Tags New
Stats
Tags
Events
Send Alerts
Alerts
Limits
Unsubscribe
Complaints
Bounces
Routes
Forwards
Mailing Lists
Account Templates
Domain Templates
IP Pools
Dynamic IP Pools
IPs
IP Address Warmup
Subaccounts
Custom Message Limit
Account Management
Keys
Credentials
IP Allowlist
Users
The allowlist API provides the ability to allowlist specific addresses from being added to bounce list. You can allowlist by domain name (i.e example.com) or by specific address (i.e. alice@example.com). Mailgun doesn’t add an address to bounce list if the address is allowlisted. This API is very useful if you test against your private services and don’t want to constantly clean up bounce lists
Import a CSV file containing a list of addresses and/or domains to add to the allowlist. The CSV file must be 25MB or under and must contain the following column headers: address, domain. For each row provide either an address or a domain, but not both - choose one, keep the other blank.
Security
basicAuth
- US Mailgunhttps://api.mailgun.net/v3/{domain_name}/whitelists/import
- EU Mailgunhttps://api.eu.mailgun.net/v3/{domain_name}/whitelists/import
curl -i -X POST \
-u '<username>:<password>' \
'https://api.mailgun.net/v3/{domain_name}/whitelists/import' \
-H 'Content-Type: multipart/form-data' \
-F file=stringResponse
{ "message": "file uploaded successfully for processing. standby..." }