PHPackages                             upbond/laravel-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. upbond/laravel-auth

ActiveLibrary

upbond/laravel-auth
===================

Laravel plugin that helps authenticate with the upbond auth service

v2.0.6(3y ago)06.9kMITPHPPHP ^7.3 | ^8.0

Since Aug 5Pushed 3y ago4 watchersCompare

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

READMEChangelog (10)Dependencies (8)Versions (32)Used By (0)

Laravel Upbond Auth Plugin
==========================

[](#laravel-upbond-auth-plugin)

This package is inspired by Auth0

Documentation
-------------

[](#documentation)

Please see the [Laravel webapp quickstart](https://auth0.com/docs/quickstart/webapp/laravel) for a complete guide on how to install this in an existing project or to download a pre-configured sample project. Additional documentation on specific scenarios is below.

### Setting up

[](#setting-up)

```
$this->app->bind(
    \Upbond\Auth\Login\Contract\AuthUserRepository::class,
    \Upbond\Auth\Login\Repository\AuthUserRepository::class
);

```

### Setting up a JWKs cache

[](#setting-up-a-jwks-cache)

In the `register` method of your `AppServiceProvider` add:

```
// app/Providers/AppServiceProvider.php
use Illuminate\Support\Facades\Cache;
// ...
    public function register()
    {
        // ...
        $this->app->bind(
            '\Auth\SDK\Helpers\Cache\CacheHandler',
            function() {
                static $cacheWrapper = null;
                if ($cacheWrapper === null) {
                $cache = Cache::store();
                $cacheWrapper = new LaravelCacheWrapper($cache);
            }
            return $cacheWrapper;
        });
    }
```

### Setting up for lumen

[](#setting-up-for-lumen)

```
$app->register(Upbond\Auth\Login\LoginServiceProvider::class);

```

### Update .env for your env default to api.upbond.io

[](#update-env-for-your-env-default-to-apiupbondio)

```
UPBOND_API_URI=api.dev.upbond.io

```

You can implement your own cache strategy by creating a new class that implements the `Auth\SDK\Helpers\Cache\CacheHandler` contract, or just use the cache strategy you want by picking that store with `Cache::store('your_store_name')`;

### Storing users in your database

[](#storing-users-in-your-database)

You can customize the way you handle the users in your application by creating your own `UserRepository`. This class should implement the `Auth\Login\Contract\AuthUserRepository` contract. Please see the [Custom User Handling section of the Laravel Quickstart](https://auth0.com/docs/quickstart/webapp/laravel#optional-custom-user-handling) for the latest example.

### Using auth guard

[](#using-auth-guard)

To protect APIs using an access token generated by Auth, there is an `upbond` API guard provided ([Laravel documentation on guards](https://laravel.com/docs/7.x/authentication#adding-custom-guards)). To use this guard, add it to `config/auth.php` with the driver `upbond`:

```

'providers' => [

    'users' => [
        'driver' => 'upbond',
    ],
],

```

Once that has been added, add the guard to the middleware of any API route and check authentication during the request:

```
// get user
auth('upbond')->user();
// check if logged in
auth('upbond')->check();
// protect routes via middleware use
Route::group(['middleware' => 'auth:upbond'], function () {});

Route::get( '/auth/callback', '\Upbond\Auth\Login\AuthController@callback' )->name( 'auth-callback' );

```

env file
--------

[](#env-file)

```
UPBOND_API_URI
UPBOND_AUTH_DOMAIN
UPBOND_AUTH_CLIENT_ID
UPBOND_AUTH_CLIENT_SECRET

```

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

[](#installation)

Install this plugin into a new or existing project using [Composer](https://getcomposer.org/doc/00-intro.md):

```
$ composer require upbond/laravel-auth
```

Additional steps to install can be found in the [quickstart](https://auth0.com/docs/quickstart/webapp/laravel#integrate-auth0-in-your-application).

Contributing
------------

[](#contributing)

We appreciate feedback and contribution to this repo! Before you get started, please see the following:

- [Auth's Contribution guidelines](https://github.com/auth0/.github/blob/master/CONTRIBUTING.md)
- [Auth's Code of Conduct](https://github.com/auth0/open-source-template/blob/master/CODE-OF-CONDUCT.md)

Support + Feedback
------------------

[](#support--feedback)

Include information on how to get support. Consider adding:

- Use [Community](https://community.auth0.com/tags/laravel) for usage, questions, specific cases
- Use [Issues](https://github.com/auth0/upbond-auth/issues) for code-level support

What is Auth?
-------------

[](#what-is-auth)

Auth helps you to easily:

- implement authentication with multiple identity providers, including social (e.g., Google, Facebook, Microsoft, LinkedIn, GitHub, Twitter, etc), or enterprise (e.g., Windows Azure AD, Google Apps, Active Directory, ADFS, SAML, etc.)
- log in users with username/password databases, passwordless, or multi-factor authentication
- link multiple user accounts together
- generate signed JSON Web Tokens to authorize your API calls and flow the user identity securely
- access demographics and analytics detailing how, when, and where users are logging in
- enrich user profiles from other data sources using customizable JavaScript rules

[Why Auth?](https://auth0.com/why-auth0)

License
-------

[](#license)

The Auth Laravel Login plugin is licensed under MIT - [LICENSE](LICENSE.txt)

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community22

Small or concentrated contributor base

Maturity71

Established project with proven stability

 Bus Factor3

3 contributors hold 50%+ of commits

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 ~24 days

Recently: every ~36 days

Total

31

Last Release

1389d ago

Major Versions

v1.1.6 → v2.02022-02-15

PHP version history (2 changes)v1.0.0PHP ^7.1

v2.0.2PHP ^7.3 | ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/5f4813cf07aaf71e065c44e7c6b7344b6157c632250d0f7ed7c2bc433c16cd51?d=identicon)[upbond](/maintainers/upbond)

---

Top Contributors

[![glena](https://avatars.githubusercontent.com/u/5647310?v=4)](https://github.com/glena "glena (96 commits)")[![joshcanhelp](https://avatars.githubusercontent.com/u/855223?v=4)](https://github.com/joshcanhelp "joshcanhelp (31 commits)")[![ginsleepy](https://avatars.githubusercontent.com/u/6890882?v=4)](https://github.com/ginsleepy "ginsleepy (25 commits)")[![gineign](https://avatars.githubusercontent.com/u/7449955?v=4)](https://github.com/gineign "gineign (17 commits)")[![hrajchert](https://avatars.githubusercontent.com/u/2634059?v=4)](https://github.com/hrajchert "hrajchert (14 commits)")[![mgonto](https://avatars.githubusercontent.com/u/723723?v=4)](https://github.com/mgonto "mgonto (12 commits)")[![nstapelbroek](https://avatars.githubusercontent.com/u/3368018?v=4)](https://github.com/nstapelbroek "nstapelbroek (10 commits)")[![lbalmaceda](https://avatars.githubusercontent.com/u/3900123?v=4)](https://github.com/lbalmaceda "lbalmaceda (10 commits)")[![jimmyjames](https://avatars.githubusercontent.com/u/276225?v=4)](https://github.com/jimmyjames "jimmyjames (7 commits)")[![damieng](https://avatars.githubusercontent.com/u/118951?v=4)](https://github.com/damieng "damieng (6 commits)")[![seanmangar](https://avatars.githubusercontent.com/u/6080053?v=4)](https://github.com/seanmangar "seanmangar (6 commits)")[![cocojoe](https://avatars.githubusercontent.com/u/928115?v=4)](https://github.com/cocojoe "cocojoe (4 commits)")[![thijsvdanker](https://avatars.githubusercontent.com/u/429548?v=4)](https://github.com/thijsvdanker "thijsvdanker (4 commits)")[![ntotten](https://avatars.githubusercontent.com/u/282782?v=4)](https://github.com/ntotten "ntotten (4 commits)")[![Annyv2](https://avatars.githubusercontent.com/u/5016479?v=4)](https://github.com/Annyv2 "Annyv2 (3 commits)")[![adamgoose](https://avatars.githubusercontent.com/u/611068?v=4)](https://github.com/adamgoose "adamgoose (2 commits)")[![devjack](https://avatars.githubusercontent.com/u/3516066?v=4)](https://github.com/devjack "devjack (2 commits)")[![dmyers](https://avatars.githubusercontent.com/u/207171?v=4)](https://github.com/dmyers "dmyers (2 commits)")[![FreekVR](https://avatars.githubusercontent.com/u/417416?v=4)](https://github.com/FreekVR "FreekVR (2 commits)")[![irieznykov](https://avatars.githubusercontent.com/u/48024435?v=4)](https://github.com/irieznykov "irieznykov (2 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

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

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

###  Alternatives

[illuminate/pipeline

The Illuminate Pipeline package.

9446.6M210](/packages/illuminate-pipeline)[illuminate/pagination

The Illuminate Pagination package.

10532.5M858](/packages/illuminate-pagination)[spatie/laravel-prometheus

Export Laravel metrics to Prometheus

2651.3M6](/packages/spatie-laravel-prometheus)[pressbooks/pressbooks

Pressbooks is an open source book publishing tool built on a WordPress multisite platform. Pressbooks outputs books in multiple formats, including PDF, EPUB, web, and a variety of XML flavours, using a theming/templating system, driven by CSS.

44643.1k1](/packages/pressbooks-pressbooks)[api-platform/laravel

API Platform support for Laravel

59126.4k6](/packages/api-platform-laravel)[dragon-code/migrate-db

Easy data transfer from one database to another

15717.4k](/packages/dragon-code-migrate-db)

PHPackages © 2026

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