T
trueuser
API Reference  /  POST /api/v1/verify
← HomeDashboard
Endpoint

Verify an email

POSThttps://trueuser.dev/api/v1/verify

Submits a single email for verification. Returns a verdict computed from your custom rules over the underlying detection signals, plus reasoning. Default mode can use AI and recent signup context; latency varies. Local mode skips the AI call.

Request body

email
stringrequired
The email address to check, up to 254 characters. Format is assessed as a signal; a successful HTTP response does not mean the address is valid.
username
string
The username the customer chose at signup. Helps the model spot collisions across distinct emails (a strong batch-attack signal).
ip
string
Optional client IP from your trusted server/proxy context. It can help assess recent registration patterns; it is not a dedicated IP reputation lookup.
user_agent
string
Optional client User-Agent for verification context. Send only user data appropriate for your privacy policy.
local_mode
boolean
When true, evaluate the email against your rules using only local signals (format, disposable list, role/alias/relay, suspicious-pattern heuristic) — no AI call. Faster and free of credit cost, but may miss cases that only the model would catch (novel disposable providers, batch-cluster patterns). Defaults to false.

Response

verdict
enum
One of allow, review, or block — derived from your account's verdict rule applied to the signals below. Edit the rule at /dashboard/rules.
signals
object
Detection booleans and scores: format_valid, disposable, public_domain, relay_domain, alias, role_account, spam, suspicious_pattern, batch_cluster.
reasoning
string
One short sentence summarizing the strongest signals.
latency_ms
number
Server-side latency for this verification.

Errors

400invalid_json / missing_email / invalid_emailBody must be JSON with an email of at most 254 characters. Invalid format can return HTTP 200 with format_valid: false and a rule-based verdict.
401unauthorizedProvide a valid Bearer API key or an authenticated session.
Other non-2xxunavailableHandle unexpected errors and timeouts. Keep costly benefits pending; do not assume a retry is free or idempotent.

Integrate safely

Keep the API key server-side. Validate responses and set a timeout. A failed request should leave costly trial benefits pending, with a real retry or review path. An AI failure can return local signals with HTTP 200; there is no structured degraded flag. An allow verdict does not prove identity or inbox ownership.

Persist eligibility and grant credits atomically with a unique grant key. Use a durable job queue for background checks. Read the Next.js guide and download the helper →

Build with your coding agent

Copy a prompt. Add signup protection.

Paste this into Claude Code, Codex, Cursor, or your preferred coding agent in your project. It covers the API contract, server-side secrets, failure handling, and trial-credit safeguards.

Read the Next.js guide →

Add your real API key to your server environment after reviewing the generated changes.

Request · cURLexample
curl https://trueuser.dev/api/v1/verify \
  -H "Authorization: Bearer $TRUEUSER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "email":    "[email protected]",
    "username": "alex_42",
    "ip":       "203.0.113.42"
  }'
Illustrative response · 200 OKexample
{
  "email": "[email protected]",
  "verdict": "block",
  "signals": {
    "format_valid":  true,
    "disposable":    true,
    "public_domain": false,
    "relay_domain":  false,
    "alias":         false,
    "role_account":  false,
    "spam":          false,
    "suspicious_pattern": 0.84,
    "batch_cluster": 0.91
  },
  "reasoning":  "Disposable provider with batch-shaped local part.",
  "latency_ms": 68
}
Try TrueUser
Free domain checker

The free tool checks blocklist membership. Sign in to try the full verification API.