Email Verification API

Validates and verifies an email address assessing deliverability and quality.

Authentication

Email Verification API uses API keys to authenticate requests. You can view and manage your API keys (Domain Keys) in the Domains page.

Your API keys carry many privileges, so be sure to keep them secure! Do not share your secret API keys in publicly accessible areas such as GitHub, client-side code, and so forth.
All requests made to the API must hold a custom HTTP header named "apikey". Implementation differs with each programming language. Below are some samples.
All API requests must be made over HTTP/HTTPS. API requests without authentication will fail.

PHP CURL Integration

<?php $email = isset($_POST['email'])?$email=$_POST['email']:''; $data = array('email' => $email, 'domain' => $_SERVER['SERVER_NAME']); function checkBounce($method, $data){ define("api_key", 'Your_API_Key_Here'); $url = "https://bounceinspector.com/api1/api.php"; $curl_url = $url.'?'.http_build_query($data); $curl = curl_init($curl_url); curl_setopt($curl, CURLOPT_URL, $curl_url); if ($method == 'POST') { curl_setopt($curl, CURLOPT_POST, 1); } curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); $headers = array( "api_key: ".api_key, "Content-Type: application/json", ); curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); //for debug only! curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false); curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); $resp = curl_exec($curl); curl_close($curl); return $resp; } $getResult = checkBounce('GET', $data); print_r($getResult); ?>

For Other Languages Integration

For other languages integration you should send GET request to the following URL
https://bounceinspector.com/api1/api.php?email=EMAIL_ADRESS_TO_VERIFY&domain=Your_Domain_Name
And set a custom header to the requested URL
["API_KEY: ".API_KEY, "Content-Type: application/json"]

Curl

curl --request GET \ --url 'https://bounceinspector.com/api1/api.php?email=EMAIL_ADRESS_TO_VERIFY&domain=Your_Domain_Name' \ --header 'api_key: API KEY HERE' \ --header 'Content-Type: application/json'

Python

import requests
headers = {
'api_key': 'Your_API_KEY_HERE',
'Content-Type': 'application/json',
}
params = {
'email': 'EMAIL_TO_VERIFY',
'domain': 'YOUR_DOMAIN_NAME',
}
response = requests.get('https://bounceinspector.com/api1/api.php', params=params, headers=headers)
print(response.content)

Javascript

fetch('https://bounceinspector.com/api1/api.php?email=EMAIL_TO_VERIFY&domain=YOUR_DOMAIN_NAME', {
headers: {
'api_key': 'Your_API_KEY_HERE',
'Content-Type': 'application/json'
}
}).then(response => response.text()).then(data => console.log(data));

JAVA

import java.io.IOException;
import java.io.InputStream;
import java.net.HttpURLConnection;
import java.net.URL;
import java.util.Scanner;
class Main {
 public static void main(String[] args) throws IOException {
    URL url = new URL("https://bounceinspector.com/api1/api.php?email=EMAIL_ADRESS_TO_VERIFY&domain=Your_Domain_Name");
    HttpURLConnection httpConn = (HttpURLConnection) url.openConnection();
    httpConn.setRequestMethod("GET");

    httpConn.setRequestProperty("api_key", "Your_API_KEY_HERE");
    httpConn.setRequestProperty("Content-Type", "application/json");

    InputStream responseStream = httpConn.getResponseCode() / 100 == 2
        ? httpConn.getInputStream()
        : httpConn.getErrorStream();
    Scanner s = new Scanner(responseStream).useDelimiter("\\A");
    String response = s.hasNext() ? s.next() : "";
    System.out.println(response);
  }
}

GO

package main

import (
  "fmt"
  "io/ioutil"
  "log"
  "net/http"
)
func main() {
  client := &http.Client{}
  req, err := http.NewRequest("GET", "https://bounceinspector.com/api1/api.php?email=EMAIL_ADRESS_TO_VERIFY&domain=Your_Domain_Name", nil)
  if err != nil {
    log.Fatal(err)
  }
  req.Header.Set("api_key", "API KEY HERE")
  req.Header.Set("Content-Type", "application/json")
  resp, err := client.Do(req)
  if err != nil {
    log.Fatal(err)
  }
  defer resp.Body.Close()
  bodyText, err := ioutil.ReadAll(resp.Body)
  if err != nil {
    log.Fatal(err)
  }
  fmt.Printf("%s\n", bodyText)
}

Node.JS Axios

const axios = require('axios');

const response = await axios.get('https://bounceinspector.com/api1/api.php', {
     params: {
           'email': 'EMAIL_ADRESS_TO_VERIFY',
           'domain': 'Your_Domain_Name'
     },
     headers: {
           'api_key': 'API KEY HERE',
           'Content-Type': 'application/json'
     }
});

Response

Response structure
{
"error_status":0,
"score":99,
"result":1,
"email":"example@email.com"
}

Errors status
error_status:0 => There is no error
error_status:1 => Invalid API KEY
error_status:2 => Invalid Domain
error_status:3 => Invalid User
error_status:4 => Credit Insufficient

Score result
score:0 => Email address is incorrect
score:10 => Email Syntax is correct but email Not exists
score:50 => Email Syntax is correct but cannot determine the email existence
score:75 => Email is probably good
score:99 => Email is good