# Email Verification (`email.verify`)

Deliverability verdict (good, risky or bad) for one email address, with catch-all, disposable, role and free-provider signals and a confidence score.

Docs: https://primaryapi.com/docs/api-reference/email/verify

- Endpoint: `POST https://api.primaryapi.com/v1/run/email.verify`
- Category: Validation · Platform: `email` · Kind: validation · Status: live
- Price: 1 credit per call; up to 5 credits if a call is retried elsewhere. A quote’s `maxCredits` is the most a given call can cost.
- Billing unit: per successful call
- Reliability: routed to a healthy upstream and retried automatically when an attempt fails; live 30-day status: `GET https://api.primaryapi.com/v1/status/apis?sku=email.verify`
- Execution: synchronous (answers 202 only if it outlives the wait window)

## Input

| Field | Type | Required | Default | Constraints | Description |
|---|---|---|---|---|---|
| `email` | string | yes |  | max 254 chars; format: email | Email address to verify, for example "jane.doe@acme.com". Addresses on reserved TLDs (.invalid, .test, .example, .localhost, .local) are rejected with no charge. |
| `mode` | enum | no | "standard" | one of: standard, deep | standard = cheapest healthy source first; deep = only the catch-all-resolving premium source, at its higher price. |

Unknown fields are rejected with `400 invalid_input`. The routing controls `preferLatencyUnderMs` and `maxCredits` may be sent in the same JSON body.

## Output

When `output.found` is `true`, `output.data` has this shape:

| Field | Type | Description |
|---|---|---|
| `email` | string | Address as verified (domain lower-cased). |
| `status` | enum | good \| risky \| bad. "unknown" verdicts from a verifier map to risky. |
| `score` | integer | 0-100 confidence; coarse when the source only returns a verdict (good 95, risky 50, bad 0). |
| `reason` | string \| null | Machine reason code from the source (accepted_email, catch_all, disposable, …). |
| `domain` | string | Domain part. |
| `catchAll` | boolean \| null | Domain accepts mail for every local part; null when unknown. |
| `disposable` | boolean \| null | Throw-away mailbox provider. |
| `role` | boolean \| null | Role account such as info@ or sales@. |
| `free` | boolean \| null | Free mailbox provider such as gmail.com. |
| `mxProvider` | string \| null | Mail host family (Google, Microsoft, …). |
| `mxRecords` | string[] | MX host names (empty when the source does not return them). |
| `didYouMean` | string \| null | Typo suggestion when the source provides one. |
| `partial` | boolean | true only for the in-process pre-filter verdict (syntax / DNS / disposable list; mailbox not probed). |

When the thing you asked about does not exist (or a search matches nothing) the call still succeeds: `output.found` is `false`, `output.data` is `null` and `output.reason` says why (`not_found`, `private`, `no_results`, …). Misses are free unless the notes below say misses are billed.

## Example request

```bash
curl -sS -X POST "https://api.primaryapi.com/v1/run/email.verify" \
  -H "Authorization: Bearer $PRIMARYAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"email":"jane.doe@acme.com"}'
```

## Example response

_Values are placeholders that follow the output schema; `credits` is what this call would cost at the usual price._

```json
{
  "output": {
    "found": true,
    "data": {
      "email": "jane.doe@acme.com",
      "status": "good",
      "score": 0,
      "reason": "string",
      "domain": "string",
      "catchAll": true,
      "disposable": true,
      "role": true,
      "free": true,
      "mxProvider": "string",
      "mxRecords": [
        "string"
      ],
      "didYouMean": "string",
      "partial": true
    }
  },
  "provider": "PrimaryAPI",
  "credits": 1,
  "items": 1,
  "requestId": "req_01JBXK6Y2N9V8T4R3Q2P1M0A7Z"
}
```

## Pricing and reliability

- Usual price: 1 credit per call
- Price ceiling: up to 5 credits if a call is retried elsewhere. A quote’s `maxCredits` is the most a given call can cost; the `maxCredits` routing control caps it per call
- Live 30-day status, success rate, uptime and latency: `GET https://api.primaryapi.com/v1/status/apis?sku=email.verify`

## Errors to handle

`invalid_input`, `unauthorized`, `insufficient_balance`, `key_limit_reached`, `trial_cap_reached`, `forbidden`, `not_found`, `idempotency_conflict`, `rate_limited`, `all_sources_failed`, `service_unavailable`, `timeout`. See https://primaryapi.com/docs/errors.

## Notes

No "not found": every syntactically valid address gets a billable verdict (undeliverable = status bad). Addresses with no mail host, a null MX, a non-existent domain or a disposable provider are answered in-process (partial=true).

