Validation API
Check whether an address is real before you send to it. Validate one address in real time, or queue a whole list and poll for progress. Every result carries a verdict, a 0 to 100 score and the reason behind them.
Related:Email validationSignup verificationList cleaning
Checked against the API source on
How a check works
Each address goes through the same pipeline: syntax (RFC 5322 with international domain support and typo suggestions), DNS and MX lookup, a domain reputation check (disposable domains, risky top-level domains, known spam traps), role-address detection, and, in deep mode, an SMTP conversation with the recipient's mail server to ask whether the mailbox exists and whether the domain accepts every address (catch-all).
| Aspect | Deep (default) | Fast (mode=fast) |
|---|---|---|
| Checks | Syntax, DNS, reputation, role, SMTP mailbox check, catch-all | Syntax, DNS, reputation, role. No SMTP. |
| Typical time | Typically 2 to 8 seconds. | Well under a second. |
Can return valid | Yes | No. A clean address is Unknown with sub_status no_smtp_check. |
| Cached | Repeat lookups can return faster with cached: true. | No. |
| Credits | 1 | 1 |
A repeat deep lookup of the same address can be answered from an earlier result (cached: true). Temporary outcomes such as timeout, rate_limited and smtp_unavailable are not reused, so the next call tries again.
Single validation
Validate one address
/validate/validate1 validation creditChecks a single address and returns a verdict, a 0 to 100 score and the evidence behind them. The default is a deep check that includes a live SMTP mailbox check. Add ?mode=fast to skip it.
Deep checks usually take 2 to 8 seconds. If the mailbox server has not answered in time you get an honest unknown with sub_status smtp_unavailable, never a made-up valid. Retrying the same address shortly afterwards usually succeeds, and a repeat lookup can return faster with cached: true.
Fast checks (syntax, DNS and list checks only) return in well under a second. Because no mailbox check runs, a clean address comes back as Unknown with sub_status no_smtp_check and is_valid: false. Use fast mode to catch typos, dead domains, disposable and role addresses while a user types, and deep mode when you need a yes or no.
Every call costs 1 credit, including fast and cached lookups.
Body
| Name | Type | Required | Description |
|---|---|---|---|
string | Yes | The address to check. A malformed value is rejected with 400. |
Query string
| Name | Type | Required | Description |
|---|---|---|---|
| mode | string | No | fast skips the SMTP mailbox check. Any other value, or none, runs a deep check. deep=false is accepted as an alias for mode=fast. |
| details | boolean | No | true adds breakdown and metadata to the response. Default false. |
Request
curl -X POST "https://api.scrubimail.com/scrubimail/api/v1/validate/" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"email": "[email protected]"
}'const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/validate/", {
method: "POST",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
"Content-Type": "application/json",
},
body: JSON.stringify({
"email": "[email protected]"
}),
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
payload = {
"email": "[email protected]",
}
res = requests.post(
"https://api.scrubimail.com/scrubimail/api/v1/validate/",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
json=payload,
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$payload = <<<'JSON'
{
"email": "[email protected]"
}
JSON;
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/validate/');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => $payload,
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"id": "9fa54b0c-ccf6-43a5-8706-522dc42c5e52",
"email": "[email protected]",
"status": "completed",
"score": 96,
"verdict": "Valid",
"is_valid": true,
"verification_status": "valid",
"sub_status": "mailbox_exists",
"mode": "deep",
"cached": false,
"verified_at": "2026-11-16T09:12:04Z",
"suggestions": [],
"warnings": [],
"validation_time": 2.13,
"request_time": 2.27
}Errors
| Status | Code | When |
|---|---|---|
| 400 | validation_error | email is missing or not a valid address. |
| 402 | insufficient_credits | No validation credits left. |
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and validate is not one of them. |
| 429 | rate_limit_exceeded | Your plan's hourly request limit is used up. Wait the number of seconds in the Retry-After header (also error.meta.retry_after). |
Response fields
| Field | Description |
|---|---|
| id | UUID of this validation. Use it with /status/{id}/. |
| The address you sent. | |
| status | State of the request: completed. This is not the verdict. |
| score | Integer 0 to 100. Higher is safer. See the score bands below. |
| verdict | Human label: Valid, Invalid, Catch-All, Unknown or Do Not Mail. |
| is_valid | true only when the mailbox was confirmed by SMTP (verdict Valid). false for everything else, including Unknown. |
| verification_status | Machine-friendly verdict: valid, invalid, catch_all, unknown, do_not_mail. |
| sub_status | The specific reason. See the sub-status tables. |
| mode | deep or fast: the mode that produced this result. |
| cached | true when the result is a repeat of an earlier check. |
| verified_at | ISO 8601 time the address was verified. For a cached result this is when it was originally checked. |
| suggestions | Typo corrections, for example [email protected] for [email protected]. Empty when there is nothing to suggest. |
| warnings | Plain-English flags, for example a disposable domain or a catch-all domain. |
| validation_time | Seconds the verification itself took. Replayed from the original check on a cache hit. |
| request_time | Seconds the request spent on our servers, end to end. |
| timing | Optional. Latency measurements in milliseconds, for diagnostics only. Do not build logic on its contents. |
| breakdown, metadata | Only with ?details=true. The per-check evidence, below. |
Verdicts and scores
The verdict is decided by the evidence, not by the score alone, and the score always matches it. An address we could not verify is never reported as Valid.
| verification_status | verdict | is_valid | score | Meaning |
|---|---|---|---|---|
| valid | Valid | true | 90 to 100 | The mail server confirmed the mailbox exists, and the domain is not catch-all. |
| invalid | Invalid | false | 0 to 20 | Bad syntax, a domain with no DNS, a domain that refuses mail (null MX), or a mailbox the server says does not exist. |
| catch_all | Catch-All | false | 40 to 70 | The domain accepts every address, so this specific mailbox cannot be confirmed. |
| unknown | Unknown | false | 0 to 70 | We could not verify the mailbox: no mailbox check (fast mode), greylisting, a timeout, or the receiving server declined the check. |
| do_not_mail | Do Not Mail | false | 0 to 50 | A known spam trap, a disposable domain or a role address such as info@ or admin@. Do not send marketing mail to it. |
In the rare event of an internal failure the verdict is Error, with unknown and exception_occurred, score 0 and a warning. The credit for that call is still spent, so treat it as a retryable fault.
Sub-status values
sub_status explains the verdict. These are all the values the API returns.
| verification_status | sub_status | What happened |
|---|---|---|
| valid | mailbox_exists | The server accepted the recipient during the SMTP conversation. |
| invalid | bad_syntax | The address is not a valid email address (format or length). |
| invalid | possible_typo | The syntax is invalid and we found a likely correction. See suggestions. |
| invalid | no_dns_entries | The domain has no MX or address records, so mail cannot be delivered. |
| invalid | does_not_accept_mail | The domain publishes a null MX (RFC 7505): it says it accepts no mail. |
| invalid | mailbox_not_found | The mail server rejected the mailbox as unknown. |
| catch_all | accept_all | The server accepts mail for any local part. |
| do_not_mail | spamtrap_detected | The domain is on our spam-trap list. |
| do_not_mail | disposable | A temporary or throwaway email domain. |
| do_not_mail | role_based | A role address such as support@ or sales@, not a person. |
| unknown | no_smtp_check | No mailbox check ran: you used mode=fast. |
| unknown | no_mx_record | The domain has no MX host to check. |
| unknown | greylisted | The server asked us to try again later (SMTP 450). |
| unknown | antispam_block | The server refused the check for policy or anti-spam reasons, which does not prove the mailbox is missing. |
| unknown | unexpected_response | The server answered with a code we could not classify. |
| unknown | failed_smtp_connection | We could not connect to any of the domain's mail servers. |
| unknown | smtp_egress_blocked | Mailbox checks are temporarily unavailable from our side. Try again later. |
| unknown | rate_limited | Checks to that mail provider are being paced. Try again shortly. |
| unknown | timeout | The mailbox did not answer in time. |
| unknown | smtp_unavailable | The mailbox check could not finish in time. The same call a moment later usually succeeds. |
Evidence with details=true
?details=true adds breakdown (one object per check plus the final risk_score) and metadata. The fields differ a little between checks that ran and checks that were skipped, so read them defensively.
{
"id": "9fa54b0c-ccf6-43a5-8706-522dc42c5e52",
"email": "[email protected]",
"status": "completed",
"score": 96,
"verdict": "Valid",
"is_valid": true,
"verification_status": "valid",
"sub_status": "mailbox_exists",
"mode": "deep",
"cached": false,
"verified_at": "2026-11-16T09:12:04Z",
"suggestions": [],
"warnings": [],
"validation_time": 2.13,
"request_time": 2.27,
"breakdown": {
"syntax": {
"valid": true,
"local_part": "user",
"domain": "example.com",
"unicode_domain": null,
"suggestions": []
},
"dns": {
"valid": true,
"mx_records": [
{
"host": "mx.example.com",
"preference": 10,
"score": 50
}
],
"a_records": [
"203.0.113.10"
],
"null_mx": false,
"dnssec_valid": false,
"score": 66
},
"smtp": {
"valid": true,
"status": "deliverable",
"sub_status": "mailbox_exists",
"catch_all": false,
"greylisting": false
},
"reputation": {
"is_disposable": false,
"tld_risk": false,
"is_free_provider": false,
"is_spam_trap": false,
"spam_trap_risk": 0,
"reputation_score": 100,
"risk_level": "low"
},
"role_based": {
"is_role_based": false,
"detected_roles": [],
"has_plus_alias": false,
"role_score": 0,
"risk_level": "low"
},
"risk_score": {
"score": 96,
"verdict": "Valid",
"is_valid": true
}
},
"metadata": {
"validation_time": 2.13,
"status": "valid",
"sub_status": "mailbox_exists",
"verified_at": "2026-11-16T09:12:04Z"
}
}Bulk validation
For lists, queue a job and poll it. Bulk runs deep checks in the background and stores one result per address.
Validate a list
/validate-bulk/validate:bulk1 validation credit per addressQueues a background job that deep-checks every address in the list. The call returns 202 straight away with a job_id; poll the status endpoint for progress.
Credits are not taken up front. The request only checks that your balance covers the whole list, then the job spends 1 credit per address as it processes each one. Per-address results are stored like any other validation, so they show up in history and in the dashboard.
Bulk validation needs a plan that includes it. On a plan without bulk support the call is refused with 429 and no retry time. A list longer than your plan allows per request is refused with an error that states the limit and the number of addresses you requested, so trim the list or split it into several requests.
Body
| Name | Type | Required | Description |
|---|---|---|---|
| emails | string[] | Yes | 1 to 10,000 addresses per request, and never more than your plan's per-request bulk limit. Every entry must be a valid email address, or the whole request is rejected with 400. |
Request
curl -X POST "https://api.scrubimail.com/scrubimail/api/v1/validate-bulk/" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"emails": [
"[email protected]",
"[email protected]",
"[email protected]"
]
}'const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/validate-bulk/", {
method: "POST",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
"Content-Type": "application/json",
},
body: JSON.stringify({
"emails": [
"[email protected]",
"[email protected]",
"[email protected]"
]
}),
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
payload = {
"emails": [
"[email protected]",
"[email protected]",
"[email protected]",
],
}
res = requests.post(
"https://api.scrubimail.com/scrubimail/api/v1/validate-bulk/",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
json=payload,
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$payload = <<<'JSON'
{
"emails": [
"[email protected]",
"[email protected]",
"[email protected]"
]
}
JSON;
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/validate-bulk/');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => $payload,
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"job_id": "5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34",
"total_emails": 3,
"status": "pending",
"message": "Bulk validation job accepted and queued for processing.",
"status_url": "https://api.scrubimail.com/scrubimail/api/v1/bulk-status/5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34/"
}Errors
| Status | Code | When |
|---|---|---|
| 400 | validation_error | emails is empty, has more than 10,000 entries, or contains an invalid address. |
| 402 | insufficient_credits | Balance is lower than the number of addresses. The message says how many you need and how many you have. |
| 429 | rate_limit_exceeded | The list is longer than your plan allows in one request. The message states both numbers, and error.meta.limit and error.meta.requested carry them. There is no retry time: split the list or upgrade. |
| 429 | rate_limit_exceeded | Your plan does not include bulk validation. The message is the generic "Request was throttled." and there is no retry time, so check your plan rather than waiting. |
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and validate:bulk is not one of them. |
Check a bulk job
/bulk-status/{job_id}/validate:bulkProgress and a summary for one bulk job. Poll every few seconds until status is completed or failed.
status is one of pending, processing, completed and failed. progress is a whole number from 0 to 100. The summary buckets count by score, not verdict: valid_emails is score 80 or more, risky_emails is 50 to 79 and invalid_emails is below 50.
Path
| Name | Type | Required | Description |
|---|---|---|---|
| job_id | UUID | Yes | The job_id returned when the job was queued. |
Request
curl -X GET "https://api.scrubimail.com/scrubimail/api/v1/bulk-status/5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34/" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY"const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/bulk-status/5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34/", {
method: "GET",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
},
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
res = requests.get(
"https://api.scrubimail.com/scrubimail/api/v1/bulk-status/5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34/",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/bulk-status/5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34/');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
],
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"job_id": "5d1c2e0a-7f43-4b8e-9a61-2c8f0b7d9e34",
"status": "processing",
"progress": 67,
"total_emails": 3,
"total_processed": 2,
"summary": {
"total_validations": 2,
"completed_validations": 2,
"valid_emails": 1,
"invalid_emails": 0,
"risky_emails": 1,
"avg_score": 72.5
},
"created_at": "2026-11-16T09:15:00Z",
"updated_at": "2026-11-16T09:15:11Z"
}Errors
| Status | Code | When |
|---|---|---|
| 404 | not_found | No job with that id on your account. |
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and validate:bulk is not one of them. |
const base = "https://api.scrubimail.com/scrubimail/api/v1";
const headers = { "X-API-Key": process.env.SCRUBIMAIL_API_KEY, "Content-Type": "application/json" };
const queued = await fetch(`${base}/validate-bulk/`, {
method: "POST",
headers,
body: JSON.stringify({ emails }),
}).then((r) => r.json());
let job;
do {
await new Promise((r) => setTimeout(r, 3000));
job = await fetch(`${base}/bulk-status/${queued.job_id}/`, { headers }).then((r) => r.json());
} while (job.status === "pending" || job.status === "processing");
console.log(job.status, job.summary);import os, time, requests
base = "https://api.scrubimail.com/scrubimail/api/v1"
headers = {"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]}
queued = requests.post(f"{base}/validate-bulk/", headers=headers, json={"emails": emails}, timeout=30).json()
while True:
time.sleep(3)
job = requests.get(f"{base}/bulk-status/{queued['job_id']}/", headers=headers, timeout=30).json()
if job["status"] in ("completed", "failed"):
break
print(job["status"], job["summary"])History and lookups
Get one validation
/status/{validation_id}/historyLooks up a past single validation by the id it returned. Add ?details=true for breakdown and metadata.
Path
| Name | Type | Required | Description |
|---|---|---|---|
| validation_id | UUID | Yes | The id from a validate response or a history row. |
Request
curl -X GET "https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY"const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/", {
method: "GET",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
},
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
res = requests.get(
"https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
],
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"id": "9fa54b0c-ccf6-43a5-8706-522dc42c5e52",
"email": "[email protected]",
"status": "completed",
"score": 96,
"verdict": "Valid",
"is_valid": true,
"suggestions": [],
"warnings": [],
"validation_time": 2.13,
"created_at": "2026-11-16T09:12:04Z",
"updated_at": "2026-11-16T09:12:04Z"
}Errors
| Status | Code | When |
|---|---|---|
| 404 | not_found | No validation with that id on your account. |
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and history is not one of them. |
Delete one validation
/status/{validation_id}/historyRemoves a validation from your history. Billing records are kept, so deleting history never changes what you were charged.
Path
| Name | Type | Required | Description |
|---|---|---|---|
| validation_id | UUID | Yes | The validation to delete. |
Request
curl -X DELETE "https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY"const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/", {
method: "DELETE",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
},
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
res = requests.delete(
"https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/status/9fa54b0c-ccf6-43a5-8706-522dc42c5e52/');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
],
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
204 No Content, empty body
Errors
| Status | Code | When |
|---|---|---|
| 404 | not_found | No validation with that id on your account. |
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and history is not one of them. |
List past validations
/history/historyYour validations, newest first, with a summary of the filtered set. The response is not paginated: it returns every match, so use the date and score filters on large accounts.
Needs the history scope when the key has scopes set. DELETE /history/ clears the history. It deletes exactly the set a GET with the same filters would list, so with no filters it deletes everything. It replies 200 with {"deleted": <count>}. Billing records are untouched.
Query string
| Name | Type | Required | Description |
|---|---|---|---|
| status | string | No | Record state: pending, processing, completed or failed. |
| date_from | date | No | YYYY-MM-DD. Validations created on or after this day. |
| date_to | date | No | YYYY-MM-DD. Validations created on or before this day. |
| min_score | integer | No | Lowest score to include. |
| max_score | integer | No | Highest score to include. |
| details | boolean | No | true adds breakdown and metadata to every row. |
Request
curl -X GET "https://api.scrubimail.com/scrubimail/api/v1/history/?date_from=2026-11-01&min_score=90" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY"const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/history/?date_from=2026-11-01&min_score=90", {
method: "GET",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
},
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
res = requests.get(
"https://api.scrubimail.com/scrubimail/api/v1/history/?date_from=2026-11-01&min_score=90",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/history/?date_from=2026-11-01&min_score=90');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
],
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"results": [
{
"id": "9fa54b0c-ccf6-43a5-8706-522dc42c5e52",
"email": "[email protected]",
"status": "completed",
"score": 96,
"verdict": "Valid",
"is_valid": true,
"suggestions": [],
"warnings": [],
"validation_time": 2.13,
"created_at": "2026-11-16T09:12:04Z",
"updated_at": "2026-11-16T09:12:04Z"
}
],
"summary": {
"total_validations": 1,
"completed_validations": 1,
"valid_emails": 1,
"invalid_emails": 0,
"risky_emails": 0,
"avg_score": 96
}
}Errors
| Status | Code | When |
|---|---|---|
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and history is not one of them. |
Validation analytics
/analytics/historyDaily counts, an overall summary and your ten most-checked domains for a period ending today.
Query string
| Name | Type | Required | Description |
|---|---|---|---|
| days | integer | No | Length of the period in days. Default 30. Must be a whole number. |
Request
curl -X GET "https://api.scrubimail.com/scrubimail/api/v1/analytics/?days=7" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY"const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/analytics/?days=7", {
method: "GET",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
},
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
res = requests.get(
"https://api.scrubimail.com/scrubimail/api/v1/analytics/?days=7",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/analytics/?days=7');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
],
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"period": {
"start_date": "2026-11-09",
"end_date": "2026-11-16",
"days": 7
},
"overview": {
"total_validations": 412,
"completed_validations": 409,
"success_rate": 99.27,
"avg_score": 78.4
},
"daily_stats": [
{
"date": "2026-11-16",
"total": 58,
"valid": 40,
"invalid": 9,
"risky": 9,
"avg_score": 77.2
}
],
"top_domains": [
{
"domain": "gmail.com",
"count": 131,
"avg_score": 91.3
}
]
}Errors
| Status | Code | When |
|---|---|---|
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and history is not one of them. |
Domain reputation
Check a domain
/domain-reputation/{domain}/validateReputation signals for a domain: disposable, risky top-level domain, known spam trap, and a 0 to 100 reputation score. This call does not use credits.
risk_level is low, medium or high; a higher reputation_score means lower risk. is_corporate is kept for backward compatibility and means the domain is a well-known mail provider (the same as is_free_provider). A cached answer (cached: true) carries last_checked and a smaller set of fields than a fresh one.
Path
| Name | Type | Required | Description |
|---|---|---|---|
| domain | string | Yes | A domain such as example.com. |
Request
curl -X GET "https://api.scrubimail.com/scrubimail/api/v1/domain-reputation/example.com/" \
-H "X-API-Key: $SCRUBIMAIL_API_KEY"const res = await fetch("https://api.scrubimail.com/scrubimail/api/v1/domain-reputation/example.com/", {
method: "GET",
headers: {
"X-API-Key": process.env.SCRUBIMAIL_API_KEY,
},
});
const data = await res.json();
if (!res.ok) throw new Error(data.error?.message ?? data.error ?? res.statusText);import os
import requests
res = requests.get(
"https://api.scrubimail.com/scrubimail/api/v1/domain-reputation/example.com/",
headers={"X-API-Key": os.environ["SCRUBIMAIL_API_KEY"]},
timeout=30,
)
data = res.json()
res.raise_for_status()<?php
$ch = curl_init('https://api.scrubimail.com/scrubimail/api/v1/domain-reputation/example.com/');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTPHEADER => [
'X-API-Key: ' . getenv('SCRUBIMAIL_API_KEY'),
],
]);
$data = json_decode(curl_exec($ch), true);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);Response
{
"domain": "example.com",
"is_disposable": false,
"tld_risk": false,
"is_corporate": false,
"is_free_provider": false,
"spam_trap_risk": 0,
"is_spam_trap": false,
"reputation_score": 100,
"risk_level": "low",
"cached": false
}Errors
| Status | Code | When |
|---|---|---|
| 401 | authentication_required | No API key was sent. The response carries a WWW-Authenticate header. |
| 401 | invalid_credentials | The key is unknown, inactive, expired, or the request IP is not on the key's allow-list. The response carries a WWW-Authenticate header. |
| 403 | permission_denied | The key has scopes set and validate is not one of them. |
Something missing or wrong? Email [email protected].