emaillistverify/emaillistverify-sdk

PHP SDK for EmailListVerify API

Installs: 68

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Open Issues: 0

pkg:composer/emaillistverify/emaillistverify-sdk

dev-master 2025-09-02 19:42 UTC

This package is not auto-updated.

Last update: 2025-12-23 21:24:39 UTC


README

Official PHP SDK for the EmailListVerify API - Email validation and verification service.

Installation

Install via Composer:

composer require emaillistverify/emaillistverify-sdk

Usage

Basic Usage

<?php
require_once 'vendor/autoload.php';

use EmailListVerify\EmailListVerify;

// Initialize client with your API key
$client = new EmailListVerify('your-api-key-here');

// Verify a single email
$result = $client->verifyEmail('test@example.com');
echo $result; // Returns: ok, invalid, invalid_mx, accept_all, ok_for_all, disposable, role, email_disabled, dead_server, or unknown

// Verify multiple emails
$emails = ['test@example.com', 'invalid@domain.com', 'user@gmail.com'];
$results = $client->verifyEmails($emails);

foreach ($results as $email => $status) {
    echo "Email: $email - Status: $status\n";
}

Response Values

The API returns simple text responses:

  • ok - Valid email address
  • invalid - Invalid email format or domain
  • invalid_mx - Domain has no valid MX records
  • accept_all - Server accepts all emails (catch-all)
  • ok_for_all - Valid but may be catch-all
  • disposable - Temporary/disposable email address
  • role - Role-based email (e.g., admin@, info@)
  • email_disabled - Email account is disabled
  • dead_server - Mail server is not responding
  • unknown - Unable to determine status

Error Handling

try {
    $result = $client->verifyEmail('test@example.com');
    echo "Result: $result";
} catch (\EmailListVerify\EmailListVerifyException $e) {
    echo "Error: " . $e->getMessage();
}

Requirements

  • PHP 7.2 or higher
  • cURL extension
  • JSON extension

API Endpoint

This SDK uses the EmailListVerify API endpoint:

License

MIT License - see LICENSE file for details.

Support

For API documentation and support, visit EmailListVerify.com