{"_id":"55cba6d437edd823001a85e1","user":"55ca76068705a70d00b8fbef","version":{"_id":"55cba6d237edd823001a85d7","project":"55c80e130300460d00c91c1d","__v":3,"createdAt":"2015-08-12T20:04:34.776Z","releaseDate":"2015-08-12T20:04:34.776Z","categories":["55cba6d337edd823001a85d8","55cba6d337edd823001a85d9","55cba6d337edd823001a85da","55cba6d337edd823001a85db","55cbd8e84cf2180d00bb1c15","561312bc41a9ec0d00a3fdfc"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"2.0.0","version":"2"},"editedParams2":true,"parentDoc":null,"category":{"_id":"55cba6d337edd823001a85da","__v":1,"pages":["55cba6d437edd823001a85e0","55cba6d437edd823001a85e1","55cba6d437edd823001a85e2","55cba6d437edd823001a85e3","55cba6d437edd823001a85e4","55cba6d437edd823001a85e5"],"project":"55c80e130300460d00c91c1d","version":"55cba6d237edd823001a85d7","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-08-11T19:40:06.209Z","from_sync":false,"order":2,"slug":"lead-validation-end-api","title":"LEAD VALIDATION END API"},"editedParams":true,"project":"55c80e130300460d00c91c1d","__v":1,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-08-12T17:38:37.603Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"examples":{"codes":[{"language":"php","name":"","code":"<?php\n    \n$licensekey = \"YOURKEYHERE\";\n\n//       https://api.accurateappend.com/Services/V2/ValidateEmail/\n$url =  \"https://api.accurateappend.com/Services/V2/ValidateEmail/\" . $licensekey . \"/?\";\n$querystring = \"email=johnsmith:::at:::gmail.com\" .\n               \"&verifysupression=true\" .\n               \"&verifydeliverable=true\";\n\n$url .= $querystring;\n//echo \"request url: \" . $url . \"<br>\\n<br>\\n\";\n\nif(strtoupper(substr(PHP_OS, 0, 3)) === 'WIN')\n{\n    // windows operating system as the requesting server\n    $cacert_path_file = dirname(__FILE__) . \"\\cacert.pem\";\n}\nelse\n{\n    // other os\n    $cacert_path_file = \"cacert.pem\";\n}\n\n$ch = curl_init();\ncurl_setopt($ch, CURLOPT_URL, $url);\ncurl_setopt($ch, CURLOPT_HTTPGET, true);\ncurl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));\ncurl_setopt($ch, CURLOPT_SSLVERSION, 'CURL_SSLVERSION_DEFAULT');  // on a windows server the single quotes are required on 3rd parameter\ncurl_setopt($ch, CURLOPT_CAINFO, $cacert_path_file);\ncurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\ncurl_setopt($ch, CURLOPT_VERBOSE, true);\n\n$json_string = curl_exec($ch);\n$curl_err = curl_error($ch);\n\nif($curl_err)\n{\n    echo \"curl error: $curl_err\";\n}\nelse\n{\n    curl_close($ch);\n\n    // decode json\n    $parsed_json = json_decode($json_string);\n\n    // instantiate an associative array\n    $response = array();\n    // load json data into associative array\n    $response = json_to_associative($parsed_json);\n\n    // print the associative array to the screen\n    foreach ($response as $key => $value)\n    {\n        echo $key . \" = \" . $value . \"<br>\\n\";\n    }\n}\n\n\necho \"<br>\\n\";\necho \"<br>\\n\";\necho \"<br>\\n\";\necho \"<br>\\n\";\necho \"<br>\\n\";\necho \"<br>\\n\";\necho \"<br>\\n\";\n\n\n\n// --------------------------------------------------------- //\n//\n// --------------------------------------------------------- //\nfunction json_to_associative($parsed_json)\n{\n    $response = array();\n\n    // load the associative array with all response key/value pairs\n    $response['Host'] = $parsed_json->{'Criteria'}->Host;\n    $response['RequestDate'] = $parsed_json->{'Criteria'}->RequestDate;\n    $response['RequestIP'] = $parsed_json->{'Criteria'}->RequestIP;\n    $response['TransactionId'] = $parsed_json->{'Criteria'}->TransactionId;\n    $response['Email'] = $parsed_json->{'Criteria'}->Email;\n\n\n\n    // typecast the stdClass to array\n    $obj_arr = (array)$parsed_json->{'EmailResult'};\n\n    if(!empty($obj_arr))\n    {\n        $response['Domain'] = $obj_arr['Domain'];\n        $response['User'] = $obj_arr['User'];\n\n\n        // iteration required for mulitple Phones response\n        for($i = 0; $i < count($parsed_json->{'EmailResult'}->{'Codes'}); $i++)\n        {\n\n            $keynum = $i + 1;\n\n            $response['Code' . $keynum] = $parsed_json->{'EmailResult'}->{'Codes'}[$i]->Code;\n            $response['Description' . $keynum] = $parsed_json->{'EmailResult'}->{'Codes'}[$i]->Description;\n            $response['Status' . $keynum] = $parsed_json->{'EmailResult'}->{'Codes'}[$i]->Status;\n        }\n    }\n    return $response;\n}\n\n/*\nCopyright (c) 2015, AccurateAppend Corp\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without modification, are permitted \nprovided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this list of conditions \n   and the following disclaimer.\n\n2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions \n   and the following disclaimer in the documentation and/or other materials provided with the distribution.\n\n3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse \n   or promote products derived from this software without specific prior written permission.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR \nIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND \nFITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS \nBE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, \nBUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS \nINTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR \nTORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF \nADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/\n\n?>"},{"code":"using System;\nusing System.Collections.Generic;\nusing System.Net;\nusing RestSharp;\n\nnamespace Samples\n{\n    // This example uses the RestSharp NuGet package (https://www.nuget.org/packages/RestSharp)\n  \n    public static class Program\n    {\n        private const String Key = \"YOURKEYHERE\";\n        private const String RootUri = @\"http://api.accurateappend.com/Services/V2\";\n\n        public static void Main(String[] args)\n        {\n            ValidateEmail();\n        }\n\n        #region Validate Email\n\n        private static void ValidateEmail()\n        {\n            const String Resource =\n                \"/ValidateEmail/\" + Key +\n                \"/?email=johnsmith@gmail.com&verifysupression=true&verifydeliverable=true\";\n\n            var request = new RestRequest(Resource) { Method = Method.GET };\n\n            var client = new RestClient(RootUri);\n            var response = client.Execute<ValidateEmailResponse>(request);\n            if (response.StatusCode != HttpStatusCode.OK)\n            {\n                // Error Handling Omitted For Brevity\n            }\n            var data = response.Data;\n            Console.WriteLine(\"{0} {1}\", data.EmailResult.User, data.EmailResult.Domain);\n        }\n\n        public class ValidateEmailResponse\n        {\n            public EmailValidationResult EmailResult { get; set; }\n        }\n\n        public class EmailValidationResult\n        {\n            public String User { get; set; }\n\n            public String Domain { get; set; }\n\n            public List<Result> Codes { get; set; }\n        }\n\n        #endregion\n    }\n\n}\n\n/*\nCopyright (c) 2015, AccurateAppend Corp\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without modification, are permitted \nprovided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this list of conditions \n   and the following disclaimer.\n\n2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions \n   and the following disclaimer in the documentation and/or other materials provided with the distribution.\n\n3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse \n   or promote products derived from this software without specific prior written permission.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR \nIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND \nFITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS \nBE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, \nBUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS \nINTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR \nTORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF \nADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/","language":"csharp"}]},"method":"get","results":{"codes":[{"name":"","code":"{\n     \"Criteria\": {\n          \"Host\": \"XXXX\",\n           \"RequestDate\": \"2015-08-12T22:27:56.1587884Z\",\n           \"RequestIP\": \"192:168:1:1\",\n           \"TransactionId\": \"95ad31e8-917e-4067-aa37-599b8489b4bb\",\n           \"Email\": \"johnsmith@gmail.com\" }\n,\n      \"EmailResult\": {\n          \"Codes\": [\n               {\n                    \"Code\": \"E11\",\n                     \"Description\": \"Syntax OK\",\n                     \"Status\": \"Status\" }\n          ,\n                {\n                    \"Code\": \"E6\",\n                     \"Description\": \"Email found in supression file\",\n                     \"Status\": \"Error\" }\n           ]\n     ,\n           \"Domain\": \"gmail.com\",\n           \"User\": \"johnsmith\" }\n}","language":"json","status":200}]},"settings":"","auth":"required","params":[{"_id":"55cbc8219d3dc20d009494a0","ref":"","in":"path","required":true,"desc":"License key issued by customer support.","default":"","type":"string","name":"licensekey"},{"_id":"55cbc8219d3dc20d0094949f","ref":"","in":"query","required":true,"desc":"Search subject's email address.","default":"","type":"string","name":"email"},{"_id":"55cbc8219d3dc20d0094949e","ref":"","in":"query","required":true,"desc":"Indicates whether the input email address should be matched against our internal suppression database, which will indicate whether email address has been undeliverable in the past or has made SPAM complaints.","default":"true","type":"string","name":"verifysupression"},{"_id":"55cbc8219d3dc20d0094949d","ref":"","in":"query","required":true,"desc":"Verifies current email address delivery status by contacting the ISP’s email server and checking for existence of the mailbox.","default":"true","type":"string","name":"verifydeliverable"}],"url":"/ValidateEmail/:licensekey/?"},"isReference":false,"order":1,"body":"[block:callout]\n{\n  \"type\": \"warning\",\n  \"title\": \"HTTP Headers\",\n  \"body\": \"When making a call to this API, the HTTP header \\\"content-type\\\" MUST be supplied with a value of \\\"application/json\\\". Failure to include this header will result in an HTTP 400 Bad Request response. Your choice of client library may automatically include this header. Please consult your documentation.\"\n}\n[/block]\n## EmailResult\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Field name\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"User\",\n    \"0-1\": \"string\",\n    \"0-2\": \"Parsed username\",\n    \"1-0\": \"Domain\",\n    \"1-2\": \"Parsed domain name\",\n    \"1-1\": \"string\",\n    \"2-0\": \"Codes\",\n    \"2-1\": \"array\",\n    \"2-2\": \"Parsing and validation results. See Status codes.\"\n  },\n  \"cols\": 3,\n  \"rows\": 3\n}\n[/block]\n## ValidateEmail Status Codes\nThis section lists the following types of status codes for the the ValidateEmail method.\n## Result Codes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Code\",\n    \"h-1\": \"Description\",\n    \"0-0\": \"E10\",\n    \"0-1\": \"Email address verified with ISP as deliverable\",\n    \"1-0\": \"E11\",\n    \"1-1\": \"Syntax OK\"\n  },\n  \"cols\": 2,\n  \"rows\": 2\n}\n[/block]\n## Error Codes\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Code\",\n    \"h-1\": \"Description\",\n    \"0-0\": \"E1\",\n    \"0-1\": \"Syntax failure\",\n    \"1-0\": \"E2\",\n    \"1-1\": \"Domain is unreachable\",\n    \"2-0\": \"E3\",\n    \"2-1\": \"Email address is disposable\",\n    \"3-0\": \"E4\",\n    \"3-1\": \"Email address is undeliverable\",\n    \"4-0\": \"E5\",\n    \"4-1\": \"Email address is illegitimate\",\n    \"5-0\": \"E6\",\n    \"5-1\": \"Email found in suppression file\",\n    \"6-0\": \"E7\",\n    \"6-1\": \"Email delivery status is unknown\"\n  },\n  \"cols\": 2,\n  \"rows\": 7\n}\n[/block]\n## Error Messages\nFor a list of codes and descriptions click [here](http://docs.accurateappend.com/docs/error-messages).","excerpt":"This section describes request parameters, responses and potential error messages for the ValidateEmail method.\n\nParses email address into username and domain.\n- Features a complete syntactical email validation engine that obeys current IETF standards, including RFC 1123, RFC 2821, RFC 2822, RFC 3490, RFC 3696, RFC 4291, RFC 5321, RFC 5322 and RFC 5336.\n- Detects temporarily email addresses generated by certain free services on the Internet collectively known as disposable email address providers.\n- Actively verifies delivery status of email address including the detection of known SPAM traps and inboxes that are simply out of space.","slug":"validateemail","type":"endpoint","title":"Validate Email"}

getValidate Email

This section describes request parameters, responses and potential error messages for the ValidateEmail method. Parses email address into username and domain. - Features a complete syntactical email validation engine that obeys current IETF standards, including RFC 1123, RFC 2821, RFC 2822, RFC 3490, RFC 3696, RFC 4291, RFC 5321, RFC 5322 and RFC 5336. - Detects temporarily email addresses generated by certain free services on the Internet collectively known as disposable email address providers. - Actively verifies delivery status of email address including the detection of known SPAM traps and inboxes that are simply out of space.

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Path Params

licensekey:
required
string
License key issued by customer support.

Query Params

email:
required
string
Search subject's email address.
verifysupression:
required
stringtrue
Indicates whether the input email address should be matched against our internal suppression database, which will indicate whether email address has been undeliverable in the past or has made SPAM complaints.
verifydeliverable:
required
stringtrue
Verifies current email address delivery status by contacting the ISP’s email server and checking for existence of the mailbox.

Examples


Result Format


Documentation

[block:callout] { "type": "warning", "title": "HTTP Headers", "body": "When making a call to this API, the HTTP header \"content-type\" MUST be supplied with a value of \"application/json\". Failure to include this header will result in an HTTP 400 Bad Request response. Your choice of client library may automatically include this header. Please consult your documentation." } [/block] ## EmailResult [block:parameters] { "data": { "h-0": "Field name", "h-1": "Type", "h-2": "Description", "0-0": "User", "0-1": "string", "0-2": "Parsed username", "1-0": "Domain", "1-2": "Parsed domain name", "1-1": "string", "2-0": "Codes", "2-1": "array", "2-2": "Parsing and validation results. See Status codes." }, "cols": 3, "rows": 3 } [/block] ## ValidateEmail Status Codes This section lists the following types of status codes for the the ValidateEmail method. ## Result Codes [block:parameters] { "data": { "h-0": "Code", "h-1": "Description", "0-0": "E10", "0-1": "Email address verified with ISP as deliverable", "1-0": "E11", "1-1": "Syntax OK" }, "cols": 2, "rows": 2 } [/block] ## Error Codes [block:parameters] { "data": { "h-0": "Code", "h-1": "Description", "0-0": "E1", "0-1": "Syntax failure", "1-0": "E2", "1-1": "Domain is unreachable", "2-0": "E3", "2-1": "Email address is disposable", "3-0": "E4", "3-1": "Email address is undeliverable", "4-0": "E5", "4-1": "Email address is illegitimate", "5-0": "E6", "5-1": "Email found in suppression file", "6-0": "E7", "6-1": "Email delivery status is unknown" }, "cols": 2, "rows": 7 } [/block] ## Error Messages For a list of codes and descriptions click [here](http://docs.accurateappend.com/docs/error-messages).

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}