Map Background

Email API Documentation

Introduction

From the creators of vpnapi.io, we bring to you another cybersecurity API. verifymail.io can help our clients prevent spam, fraud, bounce-back emails, and accounts using temporary or disposable emails. Like other email verification systems, we originally started aggregating and blacklisting domain names that were known to be disposable or temporary emails. However, we quickly knew that many of the data that we've received were either outdated or false-positives. So, we began the journey of creating an email API based on dozens of features and variables that we obtain from real-time checks and email providers. We didn't want to limit our email verification technology just to ourselves. So in 2022, we've decided to create a JSON API that can be used for businesses all around the world!

Documentation

To use our API, you must follow the URL structure that is provided below, providing your API key at the end of the key parameter.

https://verifymail.io/api/[email protected]?key=YOUR_API_KEY

After that, you should get an output similar to this:

API Response

block (boolean) - All Clients
Determines if the email domain or email address should be blocked.

catch_all (boolean) - Pro Clients
A catch-all email account, otherwise known as a wildcard email, allows all emails to be successfully delivered within a domain name, even if the email address doesn't exist or belong to anyone. For example, Yahoo! Mail is a notable email provider who has catch-all emails enabled.
* Please note that if the both catch_all and deliverable_email are set to True, there is no guarantee that the email address actually belongs to anyone.

deliverable_email (boolean) - Pro Clients
Validates if an email sent to this address will successfully be delivered to the email's inbox. This can determine if an email will be bounced-back or sucessfully delivered.
* This feature does not verify if the email will be sent to the the spam folder.

disposable (boolean) - All Clients
Determines if the email address is a temporary or disposable email address.

domain (string) - All Clients
Displays the domain name of the email address.

email_address (string) - All Clients
Displays the entire email address.

email_provider (string) - Pro Clients
Displays the email provider or the administrator of the mail server.
* This feature does not work for every email address. If no provider could be found, the email_provider object will not appear.

mx (boolean) - Premium & Pro Clients
Determines if the domain has a mail server and a valid MX record.

mx_fallback (boolean or nested object) - Premium & Pro Clients
Mailserver fallback displays the IP address of either the A or AAAA record of a mail server if the MX record could not be found. See example #3 for reference.
* Please note that an IP address listed in this object does not mean that the A or AAAA record is a valid mail server. In order to determine if the mail server is valid, use the deliverable_email feature to determine if the A or AAAA record is a valid mail server.

mx_host (array) - Premium & Pro Clients
Lists out all of the mail server hosts.

mx_ip (array) - Premium & Pro Clients
Lists out all of the IP addresses for the mail server.

mx_priority (nested object) - Premium & Pro Clients
Displays the mail server host and their MX priority.

related_domains (boolean) - Premium & Pro Clients
For disposable email addresses only. Displays all other domain names associated with the email provider.




NOTE FOR PRO CLIENTS: The catch-all and deliverable email feature are done in real-time. This means that the API response is dependent on the email's mail server speed and certain servers can take more than 30 seconds. To prevent this issue, input only the domain name instead of an email address into the API endpoint.

If you have any other questions, feel free to contact us.

API Example #1: gmail.com (Pro Plan)

                          
{
    "block": false,
    "catch_all": false,
    "deliverable_email": false,
    "disposable": false,
    "domain": "gmail.com",
    "email_address": "[email protected]",
    "email_provider": "Gmail",
    "mx": true,
    "mx_fallback": false,
    "mx_host": [
        "gmail-smtp-in.l.google.com",
        "alt1.gmail-smtp-in.l.google.com",
        "alt2.gmail-smtp-in.l.google.com",
        "alt3.gmail-smtp-in.l.google.com",
        "alt4.gmail-smtp-in.l.google.com"
    ],
    "mx_ip": [
        "142.250.141.27",
        "64.233.171.26",
        "142.250.152.27",
        "172.253.113.27",
        "173.194.77.27",
        "2607:f8b0:4023:c0b::1a",
        "2607:f8b0:4003:c15::1a",
        "2607:f8b0:4001:c56::1a",
        "2607:f8b0:4023:1::1b",
        "2607:f8b0:4023:401::1b"
    ],
    "mx_priority": {
        "gmail-smtp-in.l.google.com": 5,
        "alt1.gmail-smtp-in.l.google.com": 10,
        "alt2.gmail-smtp-in.l.google.com": 20,
        "alt3.gmail-smtp-in.l.google.com": 30,
        "alt4.gmail-smtp-in.l.google.com": 40
    },
    "privacy": false,
    "related_domains": []
}
                          
                        

API Example #2: mailinator.com (Pro Plan)

                          
{
    "block": true,
    "catch_all": true,
    "deliverable_email": true,
    "disposable": true,
    "domain": "mailinator.com",
    "email_address": "[email protected]",
    "email_provider": "mailinator.com",
    "mx": true,
    "mx_fallback": false,
    "mx_host": [
        "mail2.mailinator.com",
        "mail.mailinator.com"
    ],
    "mx_ip": [
        "45.33.83.75",
        "23.239.11.30"
    ],
    "mx_priority": {
        "mail2.mailinator.com": 1,
        "mail.mailinator.com": 1
    },
    "privacy": false,
    "related_domains": [
        "OMITTED FOR DEMO. PURCHASE OUR API TO FIND OUT THIS LIST."
    ]
}
                          
                        

API Example #3: tempmail.dev (Pro Plan)

                          
{
    "block": true,
    "catch_all": true,
    "deliverable_email": true,
    "disposable": true,
    "domain": "mails.omvvim.edu.in",
    "email_address": "[email protected]",
    "email_provider": "tempmail.dev",
    "mx": false,
    "mx_fallback": {
        "A": [
            "208.87.129.235"
        ]
    },
    "mx_host": null,
    "mx_ip": [
        "208.87.129.235"
    ],
    "mx_priority": null,
    "privacy": false,
    "related_domains": [
        "email.omshanti.edu.in",
        "email.ucms.edu.pk",
        "mails.omvvim.edu.in",
        "tempmail.dev"
    ]
}
                          
                        

API Example #4: protonmail.com (Basic Plan)

                          
{
    "block": false,
    "disposable": false,
    "domain": "protonmail.com",
    "email_address": "[email protected]"
}
                          
                        

API Example #5: outlook.com (Premium Plan)

                          
{
    "block": false,
    "disposable": false,
    "domain": "outlook.com",
    "email_address": "[email protected]",
    "mx": true,
    "mx_fallback": false,
    "mx_host": [
        "outlook-com.olc.protection.outlook.com"
    ],
    "mx_ip": [
        "104.47.55.33",
        "104.47.58.33"
    ],
    "mx_priority": {
        "outlook-com.olc.protection.outlook.com": 5
    },
    "privacy": false,
    "related_domains": []
}
                          
                        

verifymail.io Email API via cURL

You can easily access our API using cURL through your command line or within a programming language.

curl "https://verifymail.io/api/EMAIL_ADDRESS?key=YOUR_API_KEY"

verifymail.io Email API via Python 3

You can easily access our API using Python 3.

import requests
import json

# User inputted values
email = "EMAIL_ADDRESS_HERE"
api_key = "YOUR_API_KEY_HERE"

# verifymail.io API endpoint
verifymail = "https://verifymail.io/api/" + email + "?key=" + api_key
r = requests.get(verifymail)
data = json.loads(r.content.decode())

print("Is " + email + " a disposable email?")

if data["disposable"] == True:
  print("Yes")
else:
  print("No")
                                

verifymail.io Email API via PHP

You can easily access our API using PHP.

<?php 
$email = "EMAIL_ADDRESS_HERE";
$api_key = "YOUR_API_KEY_HERE";
$verifymail = "https://verifymail.io/api/$email?key=$api_key";
$json = file_get_contents($verifymail);
$data = json_decode($json, TRUE);
echo "Is $email a disposable email? ";

if($data->disposable) {
echo "Yes";
} else {
echo "No";
}
?>
                                

Want to request or submit more programming language examples? Email us!

Icon