Skip to content

Latest commit

 

History

History
47 lines (35 loc) · 931 Bytes

README.md

File metadata and controls

47 lines (35 loc) · 931 Bytes

mailgun-php-email-validator

Mailgun V3 API email validation functions for PHP

Please make sure to use your Email Validation Key which can be found by logging in to your Mailgun account and navigating to the following URL https://app.mailgun.com/app/account/security

Calls the Mailgun V3 API and parses a single E-Mail Address for validation

validateEmail($apiPublicKey, $emailAddress) 

Sample JSON response

{  
   "address":"[email protected]",
   "did_you_mean":null,
   "is_valid":true,
   "parts":{  
      "display_name":null,
      "domain":"example.com",
      "local_part":"yourusername"
   }
}

Calls the Mailgun V3 API and parses multiple E-Mail Address for validation

validateEmails($apiPublicKey, $emailAddressArray) 

Sample JSON response

{  
   "parsed":[  
      "[email protected]",
      "[email protected]"
   ],
   "unparseable":[  

   ]
}