PHPackages                             middlewares/aura-session - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. middlewares/aura-session

ActiveLibrary[HTTP &amp; Networking](/categories/http)

middlewares/aura-session
========================

Middleware to manage sessions using Aura.Session

v2.1.0(1y ago)558.2k↓39.5%1MITPHPPHP ^7.2 || ^8.0CI failing

Since Oct 8Pushed 1y ago1 watchersCompare

[ Source](https://github.com/middlewares/aura-session)[ Packagist](https://packagist.org/packages/middlewares/aura-session)[ Docs](https://github.com/middlewares/aura-session)[ RSS](/packages/middlewares-aura-session/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (9)Dependencies (9)Versions (10)Used By (0)

middlewares/aura-session
========================

[](#middlewaresaura-session)

[![Latest Version on Packagist](https://camo.githubusercontent.com/5f9af50268d8277d0daac8a9047d53a87fb5f4bc58ae5dfc5bac69b54f729541/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d6964646c6577617265732f617572612d73657373696f6e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/middlewares/aura-session)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE)[![Testing](https://github.com/middlewares/aura-session/workflows/testing/badge.svg)](https://github.com/middlewares/aura-session/workflows/testing/badge.svg)[![Total Downloads](https://camo.githubusercontent.com/f3ecb3239ef3ee3c5025df5294d97adfc23c6422631d17a1174f19f96ed63ba0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d6964646c6577617265732f617572612d73657373696f6e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/middlewares/aura-session)[!\[SensioLabs Insight\]\[ico-sensiolabs\]](https://insight.sensiolabs.com/projects/174fe6b4-f522-49e4-9bab-2c7bf212d389)

Middleware to manage sessions using [Aura.Session](https://github.com/auraphp/Aura.Session).

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

[](#requirements)

- PHP &gt;= 7.2
- A [PSR-7](https://packagist.org/providers/psr/http-message-implementation) http message implementation ([Diactoros](https://github.com/zendframework/zend-diactoros), [Guzzle](https://github.com/guzzle/psr7), [Slim](https://github.com/slimphp/Slim), etc...)
- A [PSR-15 middleware dispatcher](https://github.com/middlewares/awesome-psr15-middlewares#dispatcher)

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

[](#installation)

This package is installable and autoloadable via Composer as [middlewares/aura-session](https://packagist.org/packages/middlewares/aura-session).

```
composer require middlewares/aura-session
```

Example
-------

[](#example)

```
$dispatcher = new Dispatcher([
    new Middlewares\AuraSession(),

    function ($request) {
        //get the session object
        $session = $request->getAttribute('session');
    }
]);

$response = $dispatcher->dispatch(new ServerRequest());
```

Options
-------

[](#options)

#### `__construct(Aura\Session\SessionFactory $factory = null)`

[](#__constructaurasessionsessionfactory-factory--null)

To use a custom session factory. If it's not passed, it will be created automatically.

#### `name(string $name)`

[](#namestring-name)

The session name. If it's not defined, the default `PHPSESSID` will be used.

#### `attribute(string $attribute)`

[](#attributestring-attribute)

The attribute name used to store the session in the server request. By default is `session`.

---

Please see [CHANGELOG](CHANGELOG.md) for more information about recent changes and [CONTRIBUTING](CONTRIBUTING.md) for contributing details.

The MIT License (MIT). Please see [LICENSE](LICENSE) for more information.

###  Health Score

45

—

FairBetter than 91% of packages

Maintenance43

Moderate activity, may be stable

Popularity35

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity74

Established project with proven stability

 Bus Factor1

Top contributor holds 91.3% 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 ~386 days

Recently: every ~671 days

Total

9

Last Release

469d ago

Major Versions

v0.5.0 → v1.0.02018-01-27

v1.1.0 → v2.0.02020-12-03

PHP version history (3 changes)v0.1.0PHP ^5.6 || ^7.0

v0.5.0PHP ^7.0

v2.0.0PHP ^7.2 || ^8.0

### Community

Maintainers

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

![](https://www.gravatar.com/avatar/42e0d72f42eb7d84f67e20d28606da42e5a3248ca908b1eadb4366aafeae2561?d=identicon)[filisko](/maintainers/filisko)

---

Top Contributors

[![oscarotero](https://avatars.githubusercontent.com/u/377873?v=4)](https://github.com/oscarotero "oscarotero (42 commits)")[![filisko](https://avatars.githubusercontent.com/u/8798694?v=4)](https://github.com/filisko "filisko (4 commits)")

---

Tags

aura-sessionhttpmiddlewarepsr-15sessionhttppsr-7middlewareserverpsr-15sessionaura.session

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/middlewares-aura-session/health.svg)

```
[![Health](https://phpackages.com/badges/middlewares-aura-session/health.svg)](https://phpackages.com/packages/middlewares-aura-session)
```

###  Alternatives

[mezzio/mezzio

PSR-15 Middleware Microframework

3923.8M126](/packages/mezzio-mezzio)[middlewares/request-handler

Middleware to execute request handlers

451.8M30](/packages/middlewares-request-handler)[middlewares/fast-route

Middleware to use FastRoute

98205.1k15](/packages/middlewares-fast-route)[middlewares/negotiation

Middleware to implement content negotiation

46458.6k11](/packages/middlewares-negotiation)[middlewares/payload

Middleware to parse the body of the request with support for json, csv and url-encode

33472.0k18](/packages/middlewares-payload)[middlewares/php-session

Middleware to start php sessions using the request data

1627.8k3](/packages/middlewares-php-session)

PHPackages © 2026

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