# Mail Verifier API

> Check whether email addresses can actually receive mail.

Verifies addresses by talking to the receiving mail server over SMTP, without sending a message. Send up to ten addresses per request and get a `valid` or `invalid` verdict for each.

- **Endpoint:** `POST https://api.zactonz.com/mverifier/`
- **Category:** Email
- **Version:** 1
- **Status:** stable
- **Authentication:** `Authorization: Bearer YOUR_API_KEY`
- **Reference page:** https://developers.zactonz.com/apis/mail-verifier/

## Parameters

Send parameters as `application/x-www-form-urlencoded` form fields in the request body.

| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| `key` | string | yes |  | Your API key, repeated as a form field. Kept for existing integrations; the `Authorization: Bearer` header is the supported way to authenticate. |
| `emails` | string | yes |  | One or more addresses separated by commas. At most ten per request. |

## Example request

```bash
curl -X POST "https://api.zactonz.com/mverifier/" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  --data-urlencode "key=YOUR_API_KEY" \
  --data-urlencode "emails=jane@example.com, sales@zactonz.com"
```

## Response

A verdict per address and the time the check took.

| Field | Type | Description |
|---|---|---|
| `status` | string | `"200"` on success (a string). See status codes below. |
| `message` | string \| null | Explanation when the request could not be processed, otherwise `null`. |
| `mails` | object | Map of address to `valid` or `invalid`. |
| `ttr` | number | Seconds the verification took. |

```json
{
    "status": "200",
    "message": null,
    "reason": "",
    "mails": {
        "jane@example.com": "invalid",
        "sales@zactonz.com": "valid"
    },
    "ttr": 4.1823
}
```

## Status codes

The outcome is reported in the JSON `status` field. General rules: https://developers.zactonz.com/apis/errors.md

| status | Meaning | Description |
|---|---|---|
| `200` | OK | Processed. If `mails` is absent, `message` explains why (no addresses sent, or more than ten). |
| `400` | Missing API key | `key` was absent. |
| `403` | Invalid key | `key` is not recognised. |
| `406` | Key expired | The key's validity period has ended. Contact support to renew it. |

## Notes

SMTP verification involves a live conversation with each recipient's mail server, so a request with ten addresses can take tens of seconds. Set your client timeout accordingly.

Some providers accept every address at the SMTP stage (catch-all domains); those come back `valid` even when the mailbox does not exist.
