Piloterr

Inspect the result

Read the address and keep it only when its status is valid.

A successful call answers 200 with the address and its verification status. This is the documented example for query=Alex Martin and company_domain=piloterr.com:

{
  "email": "name@example.com",
  "status": "valid",
  "last_name": "Martin",
  "first_name": "Alex",
  "company_domain": "piloterr.com"
}
FieldDescription
emailThe professional email address found.
statusVerification status of the address. valid means the address was verified; treat any other value as unverified.
first_name, last_nameThe name the API matched from query.
company_domainThe company domain the address belongs to.

Keep the address only when status is valid. Continue from Find an email address:

email  = result.get("email")
status = result.get("status")

if email and status == "valid":
    print(f"Found: {email} (status: {status})")
else:
    print(f"No verified email (status: {status})")