Authentication
The VerifyEmail API uses API keys to authenticate requests. Pass your secret
key as a Bearer token in the Authorization header.
Authorization: Bearer sk_your_api_keyTest a key
Section titled “Test a key”Call GET /v1/me to check a key before you use it. It costs no
credits and doesn’t count against the rate limit. A 200 returns the account
email, plan, credit balance and the key’s own name. A 401 means the key is
wrong or has been revoked.
curl https://api.tryverifyemail.com/v1/me \ -H "Authorization: Bearer sk_your_api_key"const res = await fetch("https://api.tryverifyemail.com/v1/me", { headers: { Authorization: `Bearer ${process.env.VERIFYEMAIL_API_KEY}` },});import os, requests
res = requests.get( "https://api.tryverifyemail.com/v1/me", headers={"Authorization": f"Bearer {os.environ['VERIFYEMAIL_API_KEY']}"},){ "email": "jane@acme.com", "plan": "growth", "credits_available": 1240, "api_key": { "id": "3f2a9c1e-7b4d-4e8a-9f60-2c1d8e5b7a90", "label": "Zapier", "mode": "live" }}Creating a key
Section titled “Creating a key”Keys are managed from API Keys in the dashboard. Give the key a name you’ll recognise later — one key per service means you can rotate that service’s key without touching anything else.
Revoking takes effect immediately — the next request made with that key gets a
401.
Key types
Section titled “Key types”| Key | Prefix | Where it’s used | Exposable? |
|---|---|---|---|
| Live secret key | sk_ |
Real verifications, billed in credits | No — keep it secret |
| Test secret key | sk_test_ |
Building and testing an integration, free | No — keep it secret |
Test keys
Section titled “Test keys”A test key (sk_test_…) is a sandbox for building your integration. Choose
Test Key when you create a key in the dashboard.
- No real check, no credits. A test key never contacts a mail server and never touches your balance. It works even when your balance is 0.
- The result rotates on every call.
POST /v1/email-verificationsanswers200 completedstraight away. The verdict cycles throughdeliverable→undeliverable→risky→unknownand then starts again, so your code meets every verdict it has to handle. Thesub_status, scores and signals also change from one lap to the next: ariskyresult might becatch_all,disposableorrole_based, and anundeliverableonemailbox_not_foundorno_mail_domain. Each key keeps its own place in the rotation. - Same shape as a live result, plus
"test_mode": trueat the top level. Theemailyou sent is echoed back, and an invalid address returns the usualinvalid_syntaxresult without moving the rotation on. - Ids start with
sbx_. Results are not stored. They don’t appear in your history or API usage, andGET /v1/email-verifications/sbx_…returns404with{"error": "sandbox_result_not_stored"}. - Single checks only. Bulk endpoints answer a test key with
403and{"error": "test_keys_not_supported_for_bulk"}. Idempotency-Keyand?timeout=are ignored.
{ "id": "sbx_6f0c2a9d1e4b4c7a9b3e5d8f2a1c0e7b", "status": "completed", "test_mode": true, "result": { "email": "jane@example.com", "normalized_email": "jane@example.com", "verdict": "risky", "sub_status": "catch_all", "quality_score": 55, "confidence": 90, "provider": "self_hosted", "primary_mx": "mx.sandbox.tryverifyemail.com", "signals": { "syntax": "pass", "domain": "pass", "mx": "pass", "smtp": "pass", "catch_all": "warn", "role_account": "pass", "disposable": "pass", "dnsbl": "pass", "toxic": "pass", "greylisting": "pass" }, "verified_at": "2026-11-18T06:35:01.000Z" }}Switch to a live key (sk_…) when you are ready to verify real addresses.
What a key can do
Section titled “What a key can do”A live secret key acts for your account across the whole API — single verification, bulk jobs, and DMARC monitoring all accept the same key. A test key returns simulated single verifications and is refused by bulk jobs.
One thing it cannot do is manage keys. Creating and revoking keys requires signing in to the dashboard, so an attacker holding a leaked key cannot issue themselves a replacement before you turn the original off.
Keeping keys safe
Section titled “Keeping keys safe”- Never ship a secret key in client-side code, a mobile app, or a public repo.
- Store keys in environment variables or a secrets manager.
- Use separate keys per environment (e.g. test vs. production) and per service, so you can rotate or revoke independently.
- Rotate immediately if a key is exposed — create a new key, deploy it, then revoke the old one.
Errors
Section titled “Errors”| Status | Meaning |
|---|---|
401 |
The key is missing, malformed, revoked, or not a key we issued. |
A request that sends Authorization: Bearer sk_… is always authenticated as
that key. If the key is invalid we return 401 rather than falling back to any
session cookie that happened to ride along, so a broken key never silently acts
as somebody else.