PHPackages                             stopreg/laravel - 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. [API Development](/categories/api)
4. /
5. stopreg/laravel

ActiveLibrary[API Development](/categories/api)

stopreg/laravel
===============

The official Laravel SDK for StopReg.

v1.0.0(2mo ago)00MITPHPPHP ^8.1

Since May 14Pushed 1mo agoCompare

[ Source](https://github.com/stopreg/stopreg-laravel)[ Packagist](https://packagist.org/packages/stopreg/laravel)[ RSS](/packages/stopreg-laravel/feed)WikiDiscussions main Synced 1w ago

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

StopReg Laravel SDK
===================

[](#stopreg-laravel-sdk)

[![Latest Version on Packagist](https://camo.githubusercontent.com/661d969829a48ed5b37b1125ab6d641b1d1039a94502c31f1330343abd4f1a16/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f73746f707265672f6c61726176656c2e737667)](https://packagist.org/packages/stopreg/laravel)[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://opensource.org/licenses/MIT)

The official Laravel SDK for [StopReg](https://stopreg.com), providing seamless email and domain verification to protect your Laravel applications from fraudulent registrations.

Features
--------

[](#features)

- **Facade Support**: Simple `StopReg::checkEmail()` syntax.
- **Auto-Discovery**: Automatic service provider and facade registration.
- **Configurable**: Easily publish and manage your API tokens.
- **Validation-Ready**: Perfect for use within Laravel request validation.

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

[](#installation)

Install the package via composer:

```
composer require stopreg/laravel
```

Configuration
-------------

[](#configuration)

Publish the configuration file:

```
php artisan vendor:publish --tag="stopreg-config"
```

Then, add your StopReg API token to your `.env` file:

```
STOPREG_API_TOKEN=your_api_token_here
```

Usage
-----

[](#usage)

### Using the Facade

[](#using-the-facade)

You can use the `StopReg` facade to verify emails and domains anywhere in your application.

```
use StopReg;

// 1. Verify an email address
$result = StopReg::checkEmail('user@disposable.com');

if ($result['data']['classification']['is_disposable']) {
    return back()->withErrors(['email' => 'Please use a permanent email address.']);
}

// 2. Verify a domain
$domainResult = StopReg::checkDomain('gmail.com');
echo $domainResult['data']['domain']['email_provider']; // "google"
```

### In a Controller

[](#in-a-controller)

```
public function register(Request $request)
{
    $verification = StopReg::checkEmail($request->email);

    if ($verification['data']['classification']['is_disposable']) {
        // Block registration
    }
}
```

### Domain Verification

[](#domain-verification)

```
$result = StopReg::checkDomain('example.com');

$provider = $result['data']['domain']['email_provider'];
$mxFound = $result['data']['mail_server']['mx_found'];
```

Error Handling
--------------

[](#error-handling)

The SDK throws an `InvalidArgumentException` for invalid inputs and `StopRegException` for API-level errors.

```
try {
    StopReg::checkEmail('not-an-email');
} catch (\InvalidArgumentException $e) {
    echo $e->getMessage();
}
```

License
-------

[](#license)

MIT © [StopReg](https://stopreg.com)

###  Health Score

36

—

LowBetter than 79% of packages

Maintenance89

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

71d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/284555463?v=4)[stopreg](/maintainers/stopreg)[@stopreg](https://github.com/stopreg)

---

Top Contributors

[![stopreg](https://avatars.githubusercontent.com/u/284555463?v=4)](https://github.com/stopreg "stopreg (3 commits)")

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/stopreg-laravel/health.svg)

```
[![Health](https://phpackages.com/badges/stopreg-laravel/health.svg)](https://phpackages.com/packages/stopreg-laravel)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3345.3M347](/packages/psalm-plugin-laravel)[defstudio/telegraph

A laravel facade to interact with Telegram Bots

813336.8k3](/packages/defstudio-telegraph)[api-platform/laravel

API Platform support for Laravel

58174.6k17](/packages/api-platform-laravel)[simplestats-io/laravel-client

Server-side analytics for Laravel that follows the full funnel from visit to registration to payment, attributed to the channel that drove it. Revenue, MRR, churn and ad-spend profit (ROAS/CAC) per channel. GDPR compliant, ad-blocker proof.

5022.6k](/packages/simplestats-io-laravel-client)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
