MailValid email verification
MailValid checks syntax, MX records, the SMTP mailbox, catch-all, disposable and role-based addresses. API base: https://mailvalid.io/api/v1. Auth: header X-API-Key: $MAILVALID_API_KEY.
If MAILVALID_API_KEY is not set, tell the user to sign up free at https://mailvalid.io/register (100 credits, no card), create a key at https://mailvalid.io/dashboard/api-keys, and set it as MAILVALID_API_KEY.
One address (1 credit; unknown results are free)
curl -s -X POST https://mailvalid.io/api/v1/verify/single \
-H "X-API-Key: $MAILVALID_API_KEY" -H "Content-Type: application/json" \
-d '{"email":"name@example.com"}'
Report the status (valid, invalid, risky or unknown), the reason and any catch-all, disposable or role flags.
A list
curl -s -X POST https://mailvalid.io/api/v1/verify/bulk \
-H "X-API-Key: $MAILVALID_API_KEY" -H "Content-Type: application/json" \
-d '{"emails":["a@example.com","b@example.com"]}'
Take job_id from the response, then poll until the job is complete:
curl -s https://mailvalid.io/api/v1/verify/bulk/JOB_ID -H "X-API-Key: $MAILVALID_API_KEY"
Download results as CSV with GET /verify/bulk/JOB_ID/download?format=csv. Summarize counts per status and list the invalid and risky addresses so the user can remove them.
Credits
curl -s https://mailvalid.io/api/v1/credits -H "X-API-Key: $MAILVALID_API_KEY"
Check the balance before a large list and tell the user how many credits it may use.
