Skip to content
OSINTtools.io

MxToolbox API

Web toolkit for MX, DNS, SPF, DMARC, blacklist, WHOIS and SMTP lookups on a domain or IP, with monitoring and an API.

Base URL
https://api.mxtoolbox.com/api/v1
Sign-in
API key
Free tier
Free tier
Pricing
Subscription
Format
REST
Endpoints
3

Compiled by OSINTtools.io editors from mxtoolbox.com · updated Nov 29, 2026Work on this API? Claim it to keep these docs currentReport a mistake

Introduction

The MxToolbox API runs the same DNS, email and network checks as the website and returns the results as JSON. An investigator can use it to read a domain's MX, SPF, DKIM, DMARC and other records, or to check an IP or domain against blacklists.

Calls go to https://api.mxtoolbox.com/api/v1/. The API key is sent in the Authorization header as a plain UUID, with no "Bearer" prefix. The Lookup endpoint runs one command per call; each result is split into Failed, Warnings, Passed and Timeouts arrays.

DNS commands (a, aaaa, asn, bimi, dkim, dmarc, dns, mta-sts, mx, ptr, soa, spf, tlsrpt, txt) and network commands (blacklist, http, https, ping, smtp, tcp, trace) have separate daily quotas that reset at 12:00 AM UTC. The docs' own tables disagree in places (free DNS quota 68 vs 64; Monitor access paid vs included), so check the plan page before relying on a figure.

Quick start

  1. Get a key

    Create an account with MxToolbox and copy your api key (free tier). Where to get it

  2. Make your first request

    Run one DNS, email, network or blacklist check against a domain or IP.. Replace YOUR_API_KEY and run it in a terminal, or use Try it on the endpoint.

    curl 'https://api.mxtoolbox.com/api/v1/Lookup/mx?argument=example.com' \
      -H 'Authorization: YOUR_API_KEY'
  3. Read the response

    A 200 response looks like this.

    {
      "UID": "00000000-0000-0000-0000-000000000000",
      "Command": "mx",
      "CommandArgument": "example.com",
      "TimeRecorded": "2026-01-01T00:00:00Z",
      "ReportingNameServer": "ns1.example.org",
      "TimeToComplete": "42",
      "Failed": [],
      "Warnings": [],
      "Passed": [
        {
          "ID": 1,
          "Name": "DNS Record Published",
          "Info": "DNS Record found",
          "Url": ""
        }
      ],
      "Timeouts": []
    }

Authentication

Send your API key in the Authorization header of every request.

Plain API key UUID, no Bearer prefix.

Get a key from MxToolbox

Try it on this page keeps your key in your browser; it is never sent to OSINTtools.io.

Rate limits and pricing

Separate daily quotas for DNS and network lookups, reset at 12:00 AM UTC; HTTP 429 after the limit. The free plan lists 64 DNS lookups a day and no network lookups.

Free tier. Pricing: subscription.

Errors

StatusMeaning
401Missing or invalid API key
429Rate limit or quota exceeded
500Server error

Lookups

Runs the named command and returns passed, warning, failed and timed-out checks. DKIM needs the argument as domain:selector; TCP needs the port parameter. Network commands (blacklist, http, https, ping, smtp, tcp, trace) contact the target and are not available on the free plan.

Path parameters

commandstringrequired

The check to run

Example: mxOne of: a, aaaa, asn, bimi, dkim, dmarc, dns, mta-sts, mx, ptr, soa, spf, tlsrpt, txt, blacklist, http, https, ping, smtp, tcp, trace

Query parameters

argumentstringrequiredtakes your domain

Domain or IP address to check

Example: example.com
portinteger

Port, required for the tcp command

Example: 25
Response fields · 10Show

UIDstring

Identifier of the lookup

Commandstring

The command that was run

CommandArgumentstring

The argument that was checked

TimeRecordedstring

When the lookup ran

ReportingNameServerstring

Name server that answered

TimeToCompletestring

How long the lookup took

Failed[]object

Failed checks, each with ID, Name, Info and Url

Warnings[]object

Checks that raised a warning

Passed[]object

Checks that passed

Timeouts[]object

Checks that timed out

curl 'https://api.mxtoolbox.com/api/v1/Lookup/mx?argument=example.com' \
  -H 'Authorization: YOUR_API_KEY'
Replace YOUR_API_KEY with your key
Response
{
  "UID": "00000000-0000-0000-0000-000000000000",
  "Command": "mx",
  "CommandArgument": "example.com",
  "TimeRecorded": "2026-01-01T00:00:00Z",
  "ReportingNameServer": "ns1.example.org",
  "TimeToComplete": "42",
  "Failed": [],
  "Warnings": [],
  "Passed": [
    {
      "ID": 1,
      "Name": "DNS Record Published",
      "Info": "DNS Record found",
      "Url": ""
    }
  ],
  "Timeouts": []
}

Account

  • Passive: the target is not contacted

Returns the DNS and network request counts for the key next to the plan's maximums.

Response fields · 2Show

DnsRequestsinteger

DNS lookups counted

NetworkRequestsinteger

Network lookups counted

curl 'https://api.mxtoolbox.com/api/v1/Usage' \
  -H 'Authorization: YOUR_API_KEY'
Replace YOUR_API_KEY with your key
Response
{
  "DnsRequests": 3,
  "NetworkRequests": 0
}

Monitors

  • Passive: the target is not contacted

Returns the account's monitors. The command, name and tag filters can be combined.

Query parameters

commandstring

Filter by monitor command

Example: mx
namestring

Filter by monitor name

Example: example monitor
tagstring

Filter by tag

Example: prod
Response fields · 1Show

MonitorUIDstring

Identifier of the monitor

curl 'https://api.mxtoolbox.com/api/v1/Monitor' \
  -H 'Authorization: YOUR_API_KEY'
Replace YOUR_API_KEY with your key
Response
[
  {
    "MonitorUID": "00000000-0000-0000-0000-000000000000"
  }
]