Skip to content
ProspectAPIs

API reference / Email verification

Verify email addresses

Written and maintained by The ProspectAPIs team

POST/v1/email/verify

POST /v1/email/verify is the ProspectAPIs operation verifyEmails, in the Email verification group of the REST API. Check 1 to 25 email addresses for deliverability. Each result has a status of valid, invalid, catch-all or unknown. A valid or invalid result is charged at the verification price; catch-all and unknown results are free (the charged and free statuses are listed in GET /pricing under email_verification). A paced or timed-out check returns unknown, free. When the balance covers only some addresses, the call verifies as many as it can pay for, the rest come back unknown with reason not_checked_insufficient_credits, free, and the response carries X-Result-Capped: balance. A balance that covers none answers 402. Cost: $0.004 per valid or invalid result; catch-all and unknown are free. Send your API key as a Bearer token in the Authorization header.

How this fits with the rest of the email verification API, with worked examples, is in the email verification guide.

Parameters

Parameters of POST /v1/email/verify
NameInTypeDescription
Idempotency-KeyheaderstringMake a retry safe: the same key and body within 24 hours replays the first answer, unbilled.

Request body

JSON (EmailVerifyRequest).

Request body of POST /v1/email/verify
FieldTypeDescription
emails requiredarray of any1 to 25 addresses. An item may be an object with first_name and last_name to also check the address against the person's name (flag name_match).
depthstring: full, quickfull checks the mailbox; quick never contacts the mail server (DNS, lists and recent results only) and costs $0.001 per address, whatever the status. Default "full".
Example body
{
  "emails": [
    "jane@acme.com",
    "sales@example.com"
  ]
}

Responses

Response codes of POST /v1/email/verify
StatusMeaning
200One result per address.
400The request was invalid (e.g. a bad filter or input); nothing was charged.
401The API key is missing or invalid.
402Out of credits. The body carries top_up_url; nothing was charged.
429Too many requests; retry after the window.

Every error answers with the same JSON body, an error string and sometimes a code; the errors page lists each status and when it happens. A per-key 429 carries Retry-After; see rate limits.

200 response fields

One result per address. The body is a EmailVerifyResponse.

Fields of the 200 response
FieldTypeDescription
data requiredarray of EmailVerifyResult
data[].email requiredstring
data[].status requiredstring: valid, invalid, catch-all, unknown
data[].reason requiredstringWhy the address got its status, e.g. not_checked_insufficient_credits.
data[].reason_text requiredstringThe reason in plain words.
data[].score requiredintegerHow likely mail to this address is to arrive, from every signal the check returned. 0 to 100.
data[].recommendation requiredstring: send, send_with_caution, retry_later, do_not_sendThe action to take with this address.
data[].charged requiredbooleanWhether this result was billed.
data[].flags requiredarray of string
data[].smtp_code requiredinteger or nullThe mail server's reply code, when the check reached one.
data[].catch_all_tier requiredstring or nullFor a catch-all domain, how likely the address is to be real.
data[].did_you_meanstring or nullA likely typo of a common mail domain, for example gmail.com for gmial.com.
data[].mail_providerstring or null: google, microsoft, yahoo, proofpoint, mimecast, other, Who runs the domain's mail.
data[].checked_atstring (date-time)When the mail server was asked; for a cached result, when that check ran.
data[].cache_age_daysintegerPresent when the result came from a check of the same address in the last 30 days (valid) or 90 days (invalid): its age in days. Billed like a fresh check.
count requiredintegerResults returned.
charged_count requiredintegerResults billed.
amount_usd requirednumberWhat this call cost.
Response headers
HeaderMeaning
X-Credits-RemainingUSD credits left after this call settles.
X-Result-CappedPresent and set to balance when some addresses were not checked because the balance ran out; those come back unknown with reason not_checked_insufficient_credits, free.

Code samples

Each sample sends the same request. Set PROSPECTAPIS_KEY in your environment first. Values come from the spec's examples; replace them with your own.

curl
curl -X POST https://api.prospectapis.com/v1/email/verify \
  -H "Authorization: Bearer $PROSPECTAPIS_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "emails": [ "jane@acme.com", "sales@example.com" ] }'
JavaScript (fetch)
const res = await fetch("https://api.prospectapis.com/v1/email/verify", {
  method: "POST",
  headers: { Authorization: `Bearer ${process.env.PROSPECTAPIS_KEY}`, "Content-Type": "application/json" },
  body: JSON.stringify({
    "emails": [
      "jane@acme.com",
      "sales@example.com"
    ]
  }),
});
if (!res.ok) throw new Error(`${res.status}: ${(await res.json().catch(() => ({}))).error ?? res.statusText}`);
const data = await res.json();
console.log(data);
Python (requests)
import os, requests

res = requests.post(
    "https://api.prospectapis.com/v1/email/verify",
    headers={"Authorization": f"Bearer {os.environ['PROSPECTAPIS_KEY']}"},
    json={
        "emails": ["jane@acme.com", "sales@example.com"],
    },
    timeout=30,
)
res.raise_for_status()
data = res.json()
print(data)

Billing

Billing reserves before it serves: the call holds what it may cost, serves at most what that hold covers, and refunds the rest when the response closes. Any non-2xx answer refunds the whole hold, so a failed call costs nothing. The response reports your balance in X-Credits-Remaining.

The email verification guide covers this area end to end. Previous operation: Poll a research brief. Next operation: Your email verification stats. Every operation, grouped by area, is on the API reference index.

Create a free account to get a key, then run the samples above with your own values (this call acts for real, so use real inputs).

Was this page helpful?