Whether you're building a sign-up form, cleaning a mailing list, or validating leads in real time, the CheckMail1 email verification API gives you fast, accurate results with minimal code. This tutorial walks you through every endpoint with working examples in curl, Python, and Node.js.
1. Get Your API Key
Create a free account at checkmail1.com and navigate to the Dashboard → API Keys. Copy your key — you'll use it in every request as a query parameter.
2. Single Email Verification
curl
curl -X GET "https://checkmail1.com/api/v1/verify?email=user@example.com&apikey=YOUR_API_KEY"
Sample JSON Response
{
"email": "user@example.com",
"status": "valid",
"score": 98,
"disposable": false,
"role_account": false,
"free_provider": false,
"mx_found": true,
"smtp_check": true,
"did_you_mean": null
}
Response Fields
| Field | Type | Description |
|---|---|---|
| status | string | valid, invalid, risky, or unknown |
| score | integer | Deliverability confidence 0–100 |
| disposable | boolean | Temporary/throwaway address (e.g. Mailinator) |
| role_account | boolean | Generic role address (info@, support@, etc.) |
| mx_found | boolean | Valid MX records exist for the domain |
| smtp_check | boolean | Mailbox confirmed via SMTP handshake |
| did_you_mean | string|null | Suggested correction for typos |
3. Python Integration
Single Verification
import requests
API_KEY = "YOUR_API_KEY"
BASE_URL = "https://checkmail1.com/api/v1"
def verify_email(email: str) -> dict:
resp = requests.get(
f"{BASE_URL}/verify",
params={"email": email, "apikey": API_KEY},
timeout=10
)
resp.raise_for_status()
return resp.json()
result = verify_email("user@example.com")
print(result["status"], result["score"])
# Output: valid 98
Batch Verification (List Cleaning)
import requests, time
API_KEY = "YOUR_API_KEY"
emails = [
"alice@example.com",
"bob@invalid-domain.xyz",
"test@mailinator.com",
"info@company.com",
]
def bulk_verify(emails: list, delay: float = 0.2) -> list:
results = []
for email in emails:
try:
resp = requests.get(
"https://checkmail1.com/api/v1/verify",
params={"email": email, "apikey": API_KEY},
timeout=10
)
data = resp.json()
except Exception as e:
data = {"email": email, "status": "error", "error": str(e)}
results.append(data)
time.sleep(delay)
return results
valid = [r for r in bulk_verify(emails) if r.get("status") == "valid"]
print(f"{len(valid)}/{len(emails)} valid addresses")
4. Node.js Integration
Single Verification (fetch, Node 18+)
const API_KEY = 'YOUR_API_KEY';
async function verifyEmail(email) {
const url = new URL('https://checkmail1.com/api/v1/verify');
url.searchParams.set('email', email);
url.searchParams.set('apikey', API_KEY);
const res = await fetch(url.toString());
if (!res.ok) throw new Error(`HTTP ${res.status}`);
return res.json();
}
(async () => {
const result = await verifyEmail('user@example.com');
console.log(result.status, result.score);
// valid 98
})();
Express.js Middleware (Real-Time Sign-Up Validation)
import express from 'express';
const app = express();
app.use(express.json());
const API_KEY = process.env.CHECKMAIL1_API_KEY;
async function checkEmail(email) {
const url = `https://checkmail1.com/api/v1/verify?email=${encodeURIComponent(email)}&apikey=${API_KEY}`;
const res = await fetch(url, { signal: AbortSignal.timeout(8000) });
return res.json();
}
app.post('/register', async (req, res) => {
const { email } = req.body;
const v = await checkEmail(email);
if (v.status === 'invalid')
return res.status(422).json({ error: 'Email address is invalid.' });
if (v.disposable)
return res.status(422).json({ error: 'Disposable emails are not allowed.' });
res.json({ message: 'Registration successful!' });
});
app.listen(3000);
5. PHP Example
<?php
function verifyEmail(string $email, string $apiKey): array {
$url = sprintf(
'https://checkmail1.com/api/v1/verify?email=%s&apikey=%s',
urlencode($email), $apiKey
);
$ctx = stream_context_create(['http' => ['timeout' => 10]]);
$json = file_get_contents($url, false, $ctx);
return json_decode($json, true);
}
$result = verifyEmail('user@example.com', 'YOUR_API_KEY');
echo $result['status']; // valid
?>
6. Error Codes
| HTTP Code | Meaning | Action |
|---|---|---|
| 200 | Success | Use the response |
| 400 | Invalid email format | Sanitize input before calling |
| 401 | Invalid or missing API key | Check your key in Dashboard |
| 429 | Rate limit exceeded | Add delay or upgrade plan |
| 500 | Server error | Retry after a few seconds |
7. Best Practices
- Cache results — store verification outcomes in your DB so you never pay twice for the same address.
- Verify at sign-up — block invalid emails at the point of entry, not after the fact.
- Treat "risky" carefully — role accounts and catch-all domains may still receive mail; decide based on your use case.
- Always set timeouts — use 10 seconds so a slow SMTP check never hangs your app.
- Batch at off-peak hours — for bulk list cleaning, schedule jobs at night to stay within rate limits.
8. Summary
The CheckMail1 API lets you verify emails or clean entire lists with a single HTTP GET request. With sub-second response times, SMTP-level accuracy, and examples in every major language, it's the fastest way to improve deliverability and protect your sender reputation.
Ready to start? Sign up free and get 200 verifications today — no credit card required.
Start Verifying Emails Today
200 free verifications. No credit card required. 60-second setup.
Get Free API Key →