PHPackages                             mailsniper/mailsniper-php - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Mail &amp; Notifications](/categories/mail)
4. /
5. mailsniper/mailsniper-php

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

mailsniper/mailsniper-php
=========================

Official PHP SDK for the MailSniper Email Verification API

1.0.0(7mo ago)02MITPHPPHP ^8.1CI passing

Since Oct 1Pushed 7mo agoCompare

[ Source](https://github.com/mailsniper/mailsniper-php)[ Packagist](https://packagist.org/packages/mailsniper/mailsniper-php)[ RSS](/packages/mailsniper-mailsniper-php/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (7)Versions (2)Used By (0)

MailSniper PHP SDK
==================

[](#mailsniper-php-sdk)

[![PHP Version](https://camo.githubusercontent.com/cc9cdea9aa96b40a822425e981b0a030e3371202973c7d57b74e8e99834f81dc/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253545382e312d626c7565)](https://php.net)[![PSR-18](https://camo.githubusercontent.com/ec2562a0e5dbe8cff738a33527848261f8d0883e540baeedcdfaccab31d34325/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5053522d2d31382d48545450253230436c69656e742d677265656e)](https://www.php-fig.org/psr/psr-18/)[![PSR-12](https://camo.githubusercontent.com/b2539494e429ff4853389cc07957695b86dbd089f28b69d69f17e9e743734feb/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5053522d2d31322d436f64696e672532305374796c652d677265656e)](https://www.php-fig.org/psr/psr-12/)

---

**Get 10,000 Free API Calls** - Stop fake signups and disposable emails before they hurt your business. [Create your free account →](https://mailsniperapp.com?utm_source=github&utm_medium=readme)

---

Official PHP SDK for the [MailSniper Email Verification API](https://mailsniperapp.com?utm_source=github&utm_medium=readme). Verify email addresses, detect disposable emails, check domain reputation, and manage your API usage with a clean, type-safe interface.

Features
--------

[](#features)

- ✅ **PSR-18 HTTP Client** - Use any HTTP client you prefer (Guzzle included by default)
- ✅ **PSR-12 Compliant** - Follows modern PHP coding standards
- ✅ **Flexible** - Easy to extend and customize
- ✅ **Email Verification** - Validate email addresses with detailed analysis
- ✅ **Quota Management** - Track and monitor API usage
- ✅ **Error Handling** - Specific exceptions for different error types

Requirements
------------

[](#requirements)

- PHP 8.1 or higher
- A PSR-18 HTTP client (Guzzle recommended and included in dev dependencies)

Installation
------------

[](#installation)

Install via Composer:

```
composer require mailsniper/mailsniper-php
```

For the recommended HTTP client (Guzzle):

```
composer require guzzlehttp/guzzle
composer require php-http/discovery
```

Getting Your API Key
--------------------

[](#getting-your-api-key)

To use this SDK, you'll need an API key. [Create a free account at mailsniperapp.com](https://mailsniperapp.com?utm_source=github&utm_medium=readme) to get your API token with 10,000 free API calls included.

Quick Start
-----------

[](#quick-start)

### Basic Usage with Auto-Discovery

[](#basic-usage-with-auto-discovery)

The simplest way to get started is using the `create()` factory method, which auto-discovers available HTTP clients:

```
