PHPackages                             hpolthof/sneaker - 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. hpolthof/sneaker

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

hpolthof/sneaker
================

An easy way to send emails with stack trace whenever an exception occurs on the server for Laravel Applications.

v5.1.0(6y ago)011MITPHPPHP &gt;=5.4.0

Since Sep 25Pushed 6y agoCompare

[ Source](https://github.com/hpolthof/sneaker)[ Packagist](https://packagist.org/packages/hpolthof/sneaker)[ RSS](/packages/hpolthof-sneaker/feed)WikiDiscussions master Synced yesterday

READMEChangelog (1)Dependencies (6)Versions (22)Used By (0)

Laravel Exception Notifications
===============================

[](#laravel-exception-notifications)

An easy way to send emails with stack trace whenever an exception occurs on the server for Laravel applications.

[![sneaker example image](sneaker.png?raw=true "Sneaker")](sneaker.png?raw=true)

Install
-------

[](#install)

### Install via Composer

[](#install-via-composer)

#### For Laravel &lt;= 5.2, please use the [v1 branch](https://github.com/squareboat/sneaker/tree/v1)!

[](#for-laravel--52-please-use-the-v1-branch)

```
$ composer require squareboat/sneaker

```

### Configure Laravel

[](#configure-laravel)

> If you are using **laravel 5.5** or higher you should skip this step.

If you are using laravel 5.3 or 5.4, simply add the service provider to your project's `config/app.php` file:

#### Service Provider

[](#service-provider)

```
SquareBoat\Sneaker\SneakerServiceProvider::class,

```

### Add Sneaker's Exception Capturing

[](#add-sneakers-exception-capturing)

Add exception capturing to `app/Exceptions/Handler.php`:

```
public function report(Exception $exception)
{
    app('sneaker')->captureException($exception);

    parent::report($exception);
}
```

### Configuration File

[](#configuration-file)

Create the Sneaker configuration file with this command:

```
$ php artisan vendor:publish --provider="SquareBoat\Sneaker\SneakerServiceProvider"
```

The config file will be published in `config/sneaker.php`

Following are the configuration attributes used for the Sneaker.

#### silent

[](#silent)

The package comes with `'silent' => true,` configuration by default, since you probably don't want error emailing enabled on your development environment. Especially if you've set `'debug' => true,`.

```
'silent' => env('SNEAKER_SILENT', true),
```

For sending emails when an exception occurs set `SNEAKER_SILENT=false` in your `.env` file.

#### capture

[](#capture)

It contains the list of the exception types that should be captured. You can add your exceptions here for which you want to send error emails.

By default, the package has included `Symfony\Component\Debug\Exception\FatalErrorException::class`.

```
'capture' => [
    Symfony\Component\Debug\Exception\FatalErrorException::class,
],
```

You can also use `'*'` in the `$capture` array which will in turn captures every exception.

```
'capture' => [
    '*'
],
```

To use this feature you should add the following code in `app/Exceptions/Handler.php`:

```
public function report(Exception $exception)
{
    if ($this->shouldReport($exception)) {
        app('sneaker')->captureException($exception);
    }

    parent::report($exception);
}
```

#### to

[](#to)

This is the list of recipients of error emails.

```
'to' => [
    // 'hello@example.com',
],
```

#### ignored\_bots

[](#ignored_bots)

This is the list of bots for which we should NOT send error emails.

```
'ignored_bots' => [
    'googlebot',        // Googlebot
    'bingbot',          // Microsoft Bingbot
    'slurp',            // Yahoo! Slurp
    'ia_archiver',      // Alexa
],
```

Customize
---------

[](#customize)

If you need to customize the subject and body of email, run following command:

```
$ php artisan vendor:publish --provider="SquareBoat\Sneaker\SneakerServiceProvider"
```

> Note - Don't run this command again if you have run it already.

Now the email's subject and body view are located in the `resources/views/vendor/sneaker` directory.

We have passed the thrown exception object `$exception` in the view which you can use to customize the view to fit your needs.

Sneak
-----

[](#sneak)

### Test your integration

[](#test-your-integration)

To verify that Sneaker is configured correctly and our integration is working, use `sneaker:sneak` Artisan command:

```
$ php artisan sneaker:sneak
```

A `SquareBoat\Sneaker\Exceptions\DummyException` class will be thrown and captured by Sneaker. The captured exception will appear in your configured email immediately.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Amit Gupta](https://github.com/akaamitgupta)
- [All Contributors](../../contributors)

About SquareBoat
----------------

[](#about-squareboat)

[SquareBoat](https://squareboat.com) is a startup focused, product development company based in Gurgaon, India. You'll find an overview of all our open source projects [on GitHub](https://github.com/squareboat).

License
=======

[](#license)

The MIT License. Please see [License File](LICENSE.md) for more information. Copyright © 2016 [SquareBoat](https://squareboat.com)

###  Health Score

29

—

LowBetter than 60% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 82.2% 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

Every ~69 days

Recently: every ~149 days

Total

20

Last Release

2203d ago

Major Versions

v0.1.2 → v2.0.02017-03-30

v1.x-dev → v2.0.22017-04-01

v2.x-dev → v3.0.02017-09-05

v3.x-dev → v4.0.02018-02-17

v4.0.0 → v5.0.02018-09-12

### Community

Maintainers

![](https://www.gravatar.com/avatar/de1aeabf860985f978f94da5a6fe0fee1df693abb2ab2453375bdfc013b3f8ac?d=identicon)[hpolthof](/maintainers/hpolthof)

---

Top Contributors

[![akaamitgupta](https://avatars.githubusercontent.com/u/7375462?v=4)](https://github.com/akaamitgupta "akaamitgupta (37 commits)")[![cfreak](https://avatars.githubusercontent.com/u/202342?v=4)](https://github.com/cfreak "cfreak (2 commits)")[![csernikmarton](https://avatars.githubusercontent.com/u/134829?v=4)](https://github.com/csernikmarton "csernikmarton (1 commits)")[![hpolthof](https://avatars.githubusercontent.com/u/1415623?v=4)](https://github.com/hpolthof "hpolthof (1 commits)")[![jkniest](https://avatars.githubusercontent.com/u/15618191?v=4)](https://github.com/jkniest "jkniest (1 commits)")[![jslim89](https://avatars.githubusercontent.com/u/797182?v=4)](https://github.com/jslim89 "jslim89 (1 commits)")[![lex111](https://avatars.githubusercontent.com/u/4408379?v=4)](https://github.com/lex111 "lex111 (1 commits)")[![bryanrscott](https://avatars.githubusercontent.com/u/4473505?v=4)](https://github.com/bryanrscott "bryanrscott (1 commits)")

---

Tags

laravelemailexceptions

### Embed Badge

![Health badge](/badges/hpolthof-sneaker/health.svg)

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

###  Alternatives

[squareboat/sneaker

An easy way to send emails with stack trace whenever an exception occurs on the server for Laravel Applications.

220191.2k](/packages/squareboat-sneaker)[propaganistas/laravel-disposable-email

Disposable email validator

5762.6M6](/packages/propaganistas-laravel-disposable-email)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[s-ichikawa/laravel-sendgrid-driver

This library adds a 'sendgrid' mail driver to Laravel.

4139.3M1](/packages/s-ichikawa-laravel-sendgrid-driver)[erag/laravel-disposable-email

A Laravel package to detect and block disposable email addresses.

226102.4k](/packages/erag-laravel-disposable-email)

PHPackages © 2026

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