PHPackages                             rapiro/oauth2server-lumen - 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. rapiro/oauth2server-lumen

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

rapiro/oauth2server-lumen
=========================

PHP OAuth 2.0 Server for Lumen

0.1.7(10y ago)0301MITPHPPHP &gt;=5.5.0

Since Jun 4Pushed 10y ago1 watchersCompare

[ Source](https://github.com/amaroRafael/oauth2server-lumen)[ Packagist](https://packagist.org/packages/rapiro/oauth2server-lumen)[ RSS](/packages/rapiro-oauth2server-lumen/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (7)Dependencies (2)Versions (7)Used By (0)

PHP OAuth 2.0 Server for Lumen
==============================

[](#php-oauth-20-server-for-lumen)

[OAuth 2.0](http://tools.ietf.org/wg/oauth/draft-ietf-oauth-v2/) authorization server and resource server for the Laravel framework. Standard compliant thanks to the amazing work by [The League of Extraordinary Packages](http://www.thephpleague.com) OAuth 2.0 authorization server and resource server.

The package assumes you have a good-enough knowledge of the principles behind the [OAuth 2.0 Specification](http://tools.ietf.org/html/rfc6749).

Version Compability
-------------------

[](#version-compability)

LumenOAuth ServerPHP5.0.x4.1.x&gt;= 5.5Documentation
-------------

[](#documentation)

This package features an [extensive wiki](https://github.com/amaroRafael/oauth2server-lumen/wiki) to help you getting started implementing an OAuth 2.0 Server in your Laravel app.

Support
-------

[](#support)

Bugs and feature request are tracked on [GitHub](https://github.com/amaroRafael/oauth2server-lumen/issues)

License
-------

[](#license)

This package is released under [the MIT License](LICENSE).

Credits
-------

[](#credits)

\#The code on which this package are based:

- [OAuth2 server](https://github.com/php-loep/oauth2-server/), is principally developed and maintained by [Alex Bilbie](https://twitter.com/alexbilbie).
- [Oauth2 server Laravel](https://github.com/lucadegasperi/oauth2-server-laravel), is principally developed and maintained by [Luca Degasperi](http://www.lucadegasperi.com).

### OAuth2Server-Lumen

[](#oauth2server-lumen)

PHP OAuth 2.0 Server for Lumen

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

[](#installation)

### Via composer

[](#via-composer)

Run `composer require 'rapiro/oauth2server-lumen:0.1.*'`

### Register package

[](#register-package)

In your `bootstrap/app.php` register service providers

```
$app->register('Rapiro\OAuth2Server\Providers\StorageServiceProvider');
$app->register('Rapiro\OAuth2Server\Providers\OAuth2ServerServiceProvider');

```

... and middleware

```
$app->middleware([
    'Rapiro\OAuth2Server\Middleware\OAuthExceptionHandlerMiddleware'
]);

```

... and route middleware

```
$app->routeMiddleware([
    'check-authorization-params' => 'Rapiro\OAuth2Server\Middleware\CheckAuthCodeRequestMiddleware',
    'csrf' => 'Laravel\Lumen\Http\Middleware\VerifyCsrfToken',
    'oauth' => 'Rapiro\OAuth2Server\Middleware\OAuthMiddleware',
    'oauth-owner' => 'Rapiro\OAuth2Server\Middleware\OAuthOwnerMiddleware'
]);

```

### Copy config

[](#copy-config)

Copy `vendor/Rapiro/oauth2server-lumen/config/oauth2.php` to your own config folder (`config/oauth2.php` in your project root). Copy `vendor/Rapiro/oauth2server-lumen/config/auth.php` to your own config folder (`config/oauth2.php` in your project root).

It has to be the correct config folder as it is registered using `$app->configure()`.

### Copy models

[](#copy-models)

Copy `vendor/Rapiro/oauth2server-lumen/Models/` folder to your own app folder (`app/` in your project root).

### Migrate

[](#migrate)

In `bootstrap/app.php` file and uncomment `$app->withFacades();` and `$app->withEloquent();`

Run `php artisan migrate --path=vendor/Rapiro/oauth2server-lumen/database/migrations`

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity52

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

Every ~3 days

Total

6

Last Release

3987d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/56644fa9bf339fd708c1dbdee7f545e89210f9e8945c342bcbb1bcb9f139e38d?d=identicon)[amaroRafael](/maintainers/amaroRafael)

---

Top Contributors

[![amaroRafael](https://avatars.githubusercontent.com/u/28486?v=4)](https://github.com/amaroRafael "amaroRafael (18 commits)")

---

Tags

apilaravellumenserveroauthoauth2

### Embed Badge

![Health badge](/badges/rapiro-oauth2server-lumen/health.svg)

```
[![Health](https://phpackages.com/badges/rapiro-oauth2server-lumen/health.svg)](https://phpackages.com/packages/rapiro-oauth2server-lumen)
```

###  Alternatives

[league/oauth2-server

A lightweight and powerful OAuth 2.0 authorization and resource server library with support for all the core specification grants. This library will allow you to secure your API with OAuth and allow your applications users to approve apps that want to access their data from your API.

6.6k136.0M248](/packages/league-oauth2-server)[chervand/yii2-oauth2-server

OAuth 2.0 server for Yii 2.0 with MAC tokens support.

1524.2k1](/packages/chervand-yii2-oauth2-server)

PHPackages © 2026

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