Email DNS Health API

API ID 15885

Audit email DNS for up to 10 domains: MX, SPF (lookup count, +all), DMARC policy, optional DKIM selectors, with a 0-100 score and an issues list.

253 ms avg response

API Documentation

Endpoints

Request
Audit email DNS for up to 10 domains in one POST request: MX, SPF, DMARC and optional DKIM selectors, returning a 0-100 score, A-F grade and an issues list per domain.
Endpoint ID: 43811
POST https://zylalabs.com/api/15885/email+dns+health+api/43811/check+email+dns+health
INPUT PARAMETERS

Check Email DNS Health — Endpoint Features

Object Description
Request Body Required Json

Free test requests remaining: 3 of 3.


INPUT PARAMETERS

API EXAMPLE RESPONSE
JSON
{"results":[{"input":"github.com","domain":"github.com","exists":true,"mx":{"present":true,"nullMx":false,"records":[{"priority":0,"host":"github-com.mail.protection.outlook.com"}]},"spf":{"present":true,"record":"v=spf1 ip4:192.30.252.0/22 ip4:172.170.10.240/28 ip4:40.78.162.192/28 ip4:172.170.3.48/28 include:spf.protection.outlook.com include:_netblocks.google.com include:_netblocks2.google.com include:mail.zendesk.com include:_spf.salesforce.com include:servers.mcsv.net include:mktomail.com include:sendgrid.net ip4:62.253.227.114 ip4:166.78.69.169 ip4:166.78.69.170 ip4:166.78.71.131 ~all","issues":[],"allMechanism":"~all","policy":"softfail","lookupCount":10,"lookupCountExact":true,"mechanisms":17},"dmarc":{"present":true,"record":"v=DMARC1; p=quarantine; sp=reject; pct=100; rua=mailto:[email protected]; ruf=mailto:[email protected]; fo=1","issues":[],"policy":"quarantine","subdomainPolicy":"reject","pct":100,"rua":["mailto:[email protected]"],"ruf":["mailto:[email protected]"],"adkim":"r","aspf":"r"},"dkim":[{"selector":"google","present":true,"keyType":"rsa","status":"ok","keyBitsApprox":2048}],"score":100,"grade":"A","issues":[{"code":"mx_single","severity":"info","section":"mx","message":"Only one MX host; no mail-server redundancy."}]},{"input":"example.com","domain":"example.com","exists":true,"mx":{"present":false,"nullMx":true,"records":[]},"spf":{"present":true,"record":"v=spf1 -all","issues":[],"allMechanism":"-all","policy":"fail","lookupCount":0,"lookupCountExact":true,"mechanisms":1},"dmarc":{"present":true,"record":"v=DMARC1;p=reject;sp=reject;adkim=s;aspf=s","issues":["dmarc_no_rua"],"policy":"reject","subdomainPolicy":"reject","pct":100,"rua":[],"ruf":[],"adkim":"s","aspf":"s"},"dkim":[{"selector":"google","present":true,"keyType":"rsa","status":"revoked"}],"score":95,"grade":"A","issues":[{"code":"mx_null","severity":"info","section":"mx","message":"Null MX (RFC 7505): the domain states it does not accept email."},{"code":"dmarc_no_rua","severity":"info","section":"dmarc","message":"No rua= address: you will not receive aggregate DMARC reports."},{"code":"dkim_key_revoked","severity":"warn","section":"dkim","message":"DKIM selector google has an empty p= (revoked key)."}]},{"input":"nxdomain-listclean-test-123.com","domain":"nxdomain-listclean-test-123.com","exists":false,"score":0,"grade":"F","issues":[{"code":"domain_not_found","severity":"error","section":"domain","message":"Domain does not exist (NXDOMAIN)."}]}],"checked":3}
Check Email DNS Health — CODE SNIPPETS

curl --location --request POST 'https://zylalabs.com/api/15885/email+dns+health+api/43811/check+email+dns+health' --header 'Authorization: Bearer YOUR_API_KEY' --header 'Content-Type: application/json' 

--data-raw '{"domains":["github.com","example.com","nxdomain-listclean-test-123.com"],"dkimSelectors":["google"]}'

    

API Access Key & Authentication

After signing up, every developer is assigned a personal API access key, a unique combination of letters and digits provided to access to our API endpoint. To authenticate with the Email DNS Health API simply include your bearer token in the Authorization header.

Headers
Header Description
Authorization Required Should be Bearer access_key. See "Your API Access Key" above when you are subscribed.

No long-term commitment. Upgrade, downgrade, or cancel anytime. Free Trial includes up to 50 requests.

Starts at
$10,000/Year


  • Custom Volume
  • Custom Rate Limit
  • Specialized Customer Support
  • Real-Time API Monitoring

Overview

Audit email DNS for up to 10 domains: MX, SPF (lookup count, +all), DMARC policy, optional DKIM selectors, with a 0-100 score and an issues list.

Email DNS Health API FAQs

For up to 10 domains per request it reads public DNS and reports MX records, SPF (policy, DNS lookup count, +all and ptr flags), DMARC (p=, sp=, pct, report addresses) and optionally DKIM selectors you name, plus a 0-100 score, A-F grade and an issues list.

No. It only reads public DNS records via DNS-over-HTTPS. It never connects to mail servers or sends mail.

Large SPF include chains can exceed the per-request DNS query budget; then lookupCount is a lower bound. Send fewer domains per call to get exact counts.

No. Only the exact _dmarc.<domain> record is checked for each domain you submit.

DKIM selectors cannot be discovered from DNS. Pass the selectors you use (for example google or selector1), up to 5 per request, and the API reports whether each exists, is revoked, and the estimated RSA key size.

Up to 10 domains and 5 DKIM selectors per request. Domains x (3 + selectors) must fit the per-request query budget of about 44 lookups.

The endpoint returns a JSON object with a `results` array. Each entry corresponds to a submitted domain and includes its input, normalized domain, DNS findings, score, grade, and issues.

Each domain has its own object in `results`, so you can evaluate domains independently. Use the `input` field to match a result to the submitted value and `domain` to see the domain that was checked.

`mx.present` indicates whether MX records were found, while `mx.nullMx` identifies an explicit null MX record. When records are present, `mx.records` lists each mail exchanger’s priority and host.

`spf.lookupCount` reports the SPF DNS lookup count, and `lookupCountExact` indicates whether it is exact. `mechanisms` counts SPF mechanisms. `allMechanism` and `policy` describe the record’s final `all` mechanism, such as `~all` and `softfail`.

The `dmarc` object reports whether a record is present, its policy (`policy`) and subdomain policy (`subdomainPolicy`), the percentage applied (`pct`), and reporting addresses in `rua` and `ruf` arrays.

Use the 0–100 score and A–F grade for a quick summary, then review `issues` for specific findings that may need attention. An empty issues list means the API reported no issues for that section.

It indicates the submitted domain was not found in DNS. Treat its DNS checks as unavailable rather than assuming missing MX, SPF, or DMARC records are configuration errors.

Review MX for mail routing, SPF for authorized sending sources and its ending policy, and DMARC for enforcement and reporting settings. If you provide DKIM selectors, use their results alongside these checks for a broader assessment.

General FAQs

To obtain your API key, first sign in to your account and navigate to the API you want to use. From the API's Pricing section, choose a plan and complete the subscription process. Once subscribed, return to the API page and you will see your API Access Key displayed at the top of the documentation page. You can use this key to authenticate your requests.

You can’t switch APIs during the free trial. If you subscribe to a different API, your trial will end and the new subscription will start as a paid plan.

The free trial lasts for 7 days and allows you to make up to 50 API requests.

No, the free trial is available only once, so we recommend using it on the API that interests you the most. Most of our APIs offer a free trial, but some may not include this option.

Yes. If the API offers a free trial, you will see a "Free 7-Day Trial" option in its Pricing section. The trial lasts for 7 days and allows up to 50 API requests, enabling you to evaluate the API before subscribing to a paid plan.

Zyla API Hub is like a big store for APIs, where you can find thousands of them all in one place. We also offer dedicated support and real-time monitoring of all APIs. Once you sign up, you can pick and choose which APIs you want to use. Just remember, each API needs its own subscription. But if you subscribe to multiple ones, you'll use the same key for all of them, making things easier for you.

Prices are listed in USD (United States Dollar), EUR (Euro), CAD (Canadian Dollar), AUD (Australian Dollar), and GBP (British Pound). We accept all major debit and credit cards. Our payment system uses the latest security technology and is powered by Stripe, one of the world's most reliable payment companies. If you have any trouble paying by card, just contact us at [email protected]

Additionally, if you already have an active subscription in any of these currencies (USD, EUR, CAD, AUD, GBP), that currency will remain for subsequent subscriptions. You can change the currency at any time as long as you don't have any active subscriptions.
The local currency shown on the pricing page is based on the country of your IP address and is provided for reference only. The actual prices are in USD (United States Dollar). When you make a payment, the charge will appear on your card statement in USD, even if you see the equivalent amount in your local currency on our website. This means you cannot pay directly with your local currency.
Occasionally, a bank may decline the charge due to its fraud protection settings. We suggest reaching out to your bank initially to check if they are blocking our charges. Also, you can access the Billing Portal and change the card associated to make the payment. If these does not work and you need further assistance, please contact our team at [email protected]
Prices are determined by a recurring monthly or yearly subscription, depending on the chosen plan.
API calls are deducted from your plan based on successful requests. Each plan comes with a specific number of calls that you can make per month. Only successful calls, indicated by a Status 200 response, will be counted against your total. This ensures that failed or incomplete requests do not impact your monthly quota.
Zyla API Hub works on a recurring monthly subscription system. Your billing cycle will start the day you purchase one of the paid plans, and it will renew the same day of the next month. So be aware to cancel your subscription beforehand if you want to avoid future charges.
To upgrade your current subscription plan, simply go to the pricing page of the API and select the plan you want to upgrade to. The upgrade will be instant, allowing you to immediately enjoy the features of the new plan. Please note that any remaining calls from your previous plan will not be carried over to the new plan, so be aware of this when upgrading. You will be charged the full amount of the new plan.
To check how many API calls you have left for the current month, refer to the 'X-Zyla-API-Calls-Monthly-Remaining' field in the response header. For example, if your plan allows 1,000 requests per month and you've used 100, this field in the response header will indicate 900 remaining calls.

You can monitor your API usage through the response headers included with every request:

x-zyla-api-calls-monthly-used: Shows the total number of API requests you have used during the current billing period.
x-zyla-api-calls-monthly-remaining: Shows the number of API requests you have remaining for the current billing period.

The 'X-Zyla-RateLimit-Reset' header shows the number of seconds until your rate limit resets. This tells you when your request count will start fresh. For example, if it displays 3,600, it means 3,600 seconds are left until the limit resets.

Yes, you can cancel your subscription at any time. Simply go to the Pricing section of the API you're subscribed to and click the "Unsubscribe" button.

Please note that upgrades, downgrades, and cancellations take effect immediately. Once your subscription is canceled, access to the service will end immediately, regardless of any remaining API calls in your quota.

After 7 days, you will be charged the full amount for the plan you were subscribed to during the trial. Therefore, it's important to cancel before the trial period ends. Refund requests for forgetting to cancel on time are not accepted.
When you subscribe to an API free trial, you can make up to 50 API calls. If you wish to make additional API calls beyond this limit, the API will prompt you to perform an "Start Your Paid Plan." You can find the "Start Your Paid Plan" button in your profile under Subscription -> Choose the API you are subscribed to -> Pricing tab.
You can contact us through our chat channel to receive immediate assistance. We are always online from 8 am to 5 pm (EST). If you reach us after that time, we will get back to you as soon as possible. Additionally, you can contact us via email at [email protected]

Please have a look at our Refund Policy: https://zylalabs.com/terms#refund