---
agentTools:
  projectIndex: https://validto.readme.io/llms.txt
---

# Single Validation API

The Single Email Validation API does validation on a single email address and returns all the validation results in JSON format.

## Response Parameters

| Parameter          | Type           | Definition                                                                             |
| :----------------- | :------------- | :------------------------------------------------------------------------------------- |
| **`"result"`**     | \[string]      | The verified results will be: deliverable, undeliverable, unknown, accept-all          |
| **`"message"`**    | \[string]      | Describes API result                                                                   |
| **`"email"`**      | \[email]       | The email that was verified.                                                           |
| **`"user"`**       | \[string]      | The user part of the provided email address.                                           |
| **`"domain"`**     | \[string]      | The domain of the provided email address.                                              |
| **`"accept_all"`** | \[Integer]     | Remote host accepts mail at any address.                                               |
| **`"role"`**       | \[0, 1]        | Whether the email is considered a role address. (e.g. "sales@, info@, help@, etc.)     |
| **`"free_email"`** | \[0, 1]        | Whether the email is hosted by a free email provider like Gmail, Yahoo!, Hotmail etc.. |
| **`"disposable"`** | \[0, 1]        | Whether this is a temporary email.                                                     |
| **`"spamtrap"`**   | \[0, 1]        | Is this a honeytrap email                                                              |
| **`"success"`**    | \[true, false] | Whether the API request call was successful or not.                                    |

## Other Responses

The response you get when the API key is invalid:

```json
HTTP/1.1 401 Unauthorized
{   
   "success":"false",
   "result":"Invalid API Key"
}
```

The response you get when your credits have been used:

```json
HTTP/1.1 402 Payment Required
{   
   "success":"false",
   "result":"Insufficient verification credits"
}
```

The response you get when your call rate is high (more than 120 concurrent calls):

```json
HTTP/ 429 Too Many Requests
{   
   "success":"false",
   "result":"Too many requests"
}
```

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Single Validation",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.validto.com/v1/"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/verify": {
      "get": {
        "summary": "Single Validation API",
        "description": "The Single Email Validation API does validation on a single email address and returns all the validation results in JSON format.",
        "operationId": "single-validation-api",
        "parameters": [
          {
            "name": "apikey",
            "in": "query",
            "description": "API Key that you obtained from your validTo account.",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "email",
            "in": "query",
            "description": "The email address to be validated.",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "accept",
            "in": "header",
            "schema": {
              "type": "string",
              "default": "application/json"
            }
          },
          {
            "name": "timeout",
            "in": "query",
            "description": "Set the maximum wait time (in milliseconds) for the API response. The default is 180000, the minimum is 30000, and the maximum is 180000.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 180000
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"result\": \"deliverable\",\n    \"message\": \"This address can receive emails.\",    \n    \"email\": \"support@validto.com\",\n    \"user\": \"support\",\n    \"domain\": \"validto.com\",\n    \"accept_all\": 2,\n    \"role\": 1,\n    \"free_email\": 0,\n    \"disposable\": 0,\n    \"spamtrap\": 0,\n    \"success\": true\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "result": {
                      "type": "string",
                      "example": "deliverable"
                    },
                    "message": {
                      "type": "string",
                      "example": "This address can receive emails."
                    },
                    "email": {
                      "type": "string",
                      "example": "support@validto.com"
                    },
                    "user": {
                      "type": "string",
                      "example": "support"
                    },
                    "domain": {
                      "type": "string",
                      "example": "validto.com"
                    },
                    "accept_all": {
                      "type": "integer",
                      "example": 2,
                      "default": 0
                    },
                    "role": {
                      "type": "integer",
                      "example": 1,
                      "default": 0
                    },
                    "free_email": {
                      "type": "integer",
                      "example": 0,
                      "default": 0
                    },
                    "disposable": {
                      "type": "integer",
                      "example": 0,
                      "default": 0
                    },
                    "spamtrap": {
                      "type": "integer",
                      "example": 0,
                      "default": 0
                    },
                    "success": {
                      "type": "boolean",
                      "example": true,
                      "default": true
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false,
        "x-readme": {
          "code-samples": [
            {
              "language": "node",
              "code": "var request = require('request');\nvar options = {\n  'method': 'GET',\n  // Replace API_KEY with your API Key\n  'url': 'https://api.validto.com/v1/verify?apikey=API_KEY&email=test@example.com',\n  'headers': {}\n};\nrequest(options, function (error, response) {\n  if (error) throw new Error(error);\n  console.log(response.body);\n});"
            },
            {
              "language": "php",
              "code": "<?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, array(\n  CURLOPT_URL => 'https://api.validto.com/v1/verify?apikey=API_KEY&email=test@example.com',\n  CURLOPT_RETURNTRANSFER => true,\n  CURLOPT_ENCODING => '',\n  CURLOPT_MAXREDIRS => 10,\n  CURLOPT_TIMEOUT => 0,\n  CURLOPT_FOLLOWLOCATION => true,\n  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n  CURLOPT_CUSTOMREQUEST => 'GET',\n));\n\n$response = curl_exec($curl);\n\ncurl_close($curl);\necho $response;\n?>"
            },
            {
              "language": "go",
              "code": "package main\n\nimport (\n  \"fmt\"\n  \"net/http\"\n  \"io/ioutil\"\n)\n\nfunc main() {\n\n  url := \"https://api.validto.com/v1/verify?apikey=API_KEY&email=test@example.com\"\n  method := \"GET\"\n\n  client := &http.Client {\n  }\n  req, err := http.NewRequest(method, url, nil)\n\n  if err != nil {\n    fmt.Println(err)\n    return\n  }\n\n  res, err := client.Do(req)\n  if err != nil {\n    fmt.Println(err)\n    return\n  }\n  defer res.Body.Close()\n\n  body, err := ioutil.ReadAll(res.Body)\n  if err != nil {\n    fmt.Println(err)\n    return\n  }\n  fmt.Println(string(body))\n}"
            }
          ],
          "samples-languages": [
            "node",
            "php",
            "go"
          ]
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true,
  "_id": "6006d60fb359e80012d9a28a:6006db159145c50081091142"
}
```