PHPackages                             montopolis/laravel-magic-auth - 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. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. montopolis/laravel-magic-auth

AbandonedArchivedPackage[Authentication &amp; Authorization](/categories/authentication)

montopolis/laravel-magic-auth
=============================

Package for implementing magical authentication (URL and token) in Laravel 5.2+

1.5.0(8y ago)4277MITPHPPHP &gt;=5.6.4

Since Jul 4Pushed 8y ago2 watchersCompare

[ Source](https://github.com/montopolis/laravel-magic-auth)[ Packagist](https://packagist.org/packages/montopolis/laravel-magic-auth)[ RSS](/packages/montopolis-laravel-magic-auth/feed)WikiDiscussions master Synced yesterday

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

Laravel Magic Auth package
==========================

[](#laravel-magic-auth-package)

Package for implementing Slack-style "magic auth" links in Laravel

Set up
------

[](#set-up)

### Install the package via composer

[](#install-the-package-via-composer)

```
$ composer require montopolis/laravel-magic-auth

```

### Add the service provider

[](#add-the-service-provider)

In config/app.php inside the providers array...

```
    /*
     * Application Service Providers...
     */
    App\Providers\AppServiceProvider::class,
    App\Providers\AuthServiceProvider::class,
    App\Providers\EventServiceProvider::class,
    App\Providers\RouteServiceProvider::class,

    /*
     * Third-party Service Providers...
     */
    Montopolis\MagicAuth\Providers\ServiceProvider::class,

```

### Publish (and update) configuration

[](#publish-and-update-configuration)

```
$ php artisan vendor:publish
$ vi config/montopolis_magic_auth.php

```

### API

[](#api)

#### Create a token

[](#create-a-token)

Use this endpoint to trigger creation of an OTP for the user. The user will be notified via the preselected channel (see `montopolis_magic_auth.php`) with either the password, a magic auth link or both (also see config).

```
POST magic-auth/create
{
    "email": "johnny@depp.com",
    "_token": "ABCDEFghijklmnOPQRStuvwxyz1234567890"
}

200 OK
{
    "message": {
        "email": "johnny@depp.com"
    }
}

```

#### Verify a token

[](#verify-a-token)

After the OTP has been received and forwarded by the user, you can attempt authentication using this endpoint:

```
POST magic-auth/verify
{
    "email": "johnny@depp.com",
    "_token": "ABCDEFghijklmnOPQRStuvwxyz1234567890",
    "key": "12345"
}

301 Redirect

```

Note: After posting to this endpoint, the Laravel session will be authenticated (if successful).

#### Magic link

[](#magic-link)

The user can also be redirected as such to automatically sign them in:

```
GET magic-auth/login?email=johnny@depp.com&_token=ABCDEFghijklmnOPQRStuvwxyz1234567890&key=12345

301 Redirect

```

### License

[](#license)

Laravel Magic Auth is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT).

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity61

Established project with proven stability

 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

Every ~168 days

Total

4

Last Release

3142d ago

PHP version history (2 changes)1.2.0PHP &gt;=5.5.9

1.3.0PHP &gt;=5.6.4

### Community

Maintainers

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

---

Top Contributors

[![coreymcmahon](https://avatars.githubusercontent.com/u/700486?v=4)](https://github.com/coreymcmahon "coreymcmahon (22 commits)")

---

Tags

laravelotpAuthenticationslackmagic

### Embed Badge

![Health badge](/badges/montopolis-laravel-magic-auth/health.svg)

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

###  Alternatives

[laravel/framework

The Laravel Framework.

34.8k532.1M19.5k](/packages/laravel-framework)[statamic/cms

The Statamic CMS Core Package

4.8k3.5M925](/packages/statamic-cms)[bagisto/bagisto

Bagisto Laravel E-Commerce

27.6k169.0k9](/packages/bagisto-bagisto)[laravel/octane

Supercharge your Laravel application's performance.

4.0k24.7M207](/packages/laravel-octane)[unopim/unopim

UnoPim Laravel PIM

10.5k2.2k](/packages/unopim-unopim)[ellaisys/aws-cognito

AWS Cognito package that allows Auth and other related features using the AWS SDK for PHP

121242.9k1](/packages/ellaisys-aws-cognito)

PHPackages © 2026

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