PHPackages                             igorw/stack-oauth - 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. igorw/stack-oauth

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

igorw/stack-oauth
=================

OAuth stack middleware.

37597[1 PRs](https://github.com/igorw/stack-oauth/pulls)1PHP

Since Jul 3Pushed 11y ago9 watchersCompare

[ Source](https://github.com/igorw/stack-oauth)[ Packagist](https://packagist.org/packages/igorw/stack-oauth)[ RSS](/packages/igorw-stack-oauth/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (1)

Stack/OAuth
===========

[](#stackoauth)

OAuth stack middleware.

Requirements
------------

[](#requirements)

- **session**: The request must have session handling accounted for. You can do this by prepending the `stack/session` middleware to this one.
- **credentials**: You need to have some sort of OAuth server. By default, `stack/oauth` will use twitter. But you can change that through the `oauth_service.class` config parameter.

Usage
-----

[](#usage)

```
use Igorw\Stack\OAuth;

$app = new OAuth($app, [
    'key'           => 'foo',
    'secret'        => 'bar',
    'callback_url'  => 'http://localhost:8080/auth/verify',
    'success_url'   => '/',
    'failure_url'   => '/auth',
]);

```

Pre-defined URLs
----------------

[](#pre-defined-urls)

- /auth
- /auth/verify

TODO
----

[](#todo)

- config validation
- tests
- more flexible path config (?)

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

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

### Community

Maintainers

![](https://www.gravatar.com/avatar/3afcc18d00fff840775bbf9570b3e9cd3997ca4820b9bfb14caf6da3ae580370?d=identicon)[igorw](/maintainers/igorw)

---

Top Contributors

[![igorw](https://avatars.githubusercontent.com/u/88061?v=4)](https://github.com/igorw "igorw (20 commits)")[![simensen](https://avatars.githubusercontent.com/u/191200?v=4)](https://github.com/simensen "simensen (6 commits)")[![cordoval](https://avatars.githubusercontent.com/u/328359?v=4)](https://github.com/cordoval "cordoval (1 commits)")[![staabm](https://avatars.githubusercontent.com/u/120441?v=4)](https://github.com/staabm "staabm (1 commits)")

### Embed Badge

![Health badge](/badges/igorw-stack-oauth/health.svg)

```
[![Health](https://phpackages.com/badges/igorw-stack-oauth/health.svg)](https://phpackages.com/packages/igorw-stack-oauth)
```

###  Alternatives

[namshi/jose

JSON Object Signing and Encryption library for PHP.

1.8k99.6M101](/packages/namshi-jose)[league/oauth1-client

OAuth 1.0 Client Library

99698.8M106](/packages/league-oauth1-client)[bezhansalleh/filament-shield

Filament support for `spatie/laravel-permission`.

2.8k2.9M88](/packages/bezhansalleh-filament-shield)[gesdinet/jwt-refresh-token-bundle

Implements a refresh token system over Json Web Tokens in Symfony

70516.4M35](/packages/gesdinet-jwt-refresh-token-bundle)[league/oauth2-google

Google OAuth 2.0 Client Provider for The PHP League OAuth2-Client

41721.2M118](/packages/league-oauth2-google)[illuminate/auth

The Illuminate Auth package.

9327.3M1.0k](/packages/illuminate-auth)

PHPackages © 2026

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