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

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

flametrench/laravel
===================

Laravel adapter for Flametrench: ServiceProvider + facades + middleware bridging the flametrench/{ids,identity,tenancy,authz} PHP SDKs into Laravel applications.

v0.2.0(1mo ago)011Apache-2.0PHPPHP ^8.3

Since May 1Pushed 4d agoCompare

[ Source](https://github.com/flametrench/laravel)[ Packagist](https://packagist.org/packages/flametrench/laravel)[ Docs](https://flametrench.dev)[ RSS](/packages/flametrench-laravel/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (9)Versions (2)Used By (0)

Flametrench Laravel SDK
=======================

[](#flametrench-laravel-sdk)

Laravel adapter for [Flametrench](https://github.com/flametrench/spec) — wires the four PHP SDK packages (`flametrench/{ids,identity,tenancy,authz}`) into Laravel's service container.

Status
------

[](#status)

Pre-release scaffold. Targets Laravel 11+ on PHP 8.3+. Spec tracking [v0.2.0](https://github.com/flametrench/spec/releases).

Install
-------

[](#install)

```
composer require flametrench/laravel:^0.2.0
```

The package auto-registers `Flametrench\Laravel\FlametrenchServiceProvider` and the `Flametrench` facade alias via Laravel's package discovery.

Configuration
-------------

[](#configuration)

Publish the config file:

```
php artisan vendor:publish --tag=flametrench-config
```

This drops `config/flametrench.php` into your app, where you select drivers per capability:

```
return [
    'identity' => ['driver' => env('FLAMETRENCH_IDENTITY_DRIVER', 'in-memory')],
    'tenancy'  => ['driver' => env('FLAMETRENCH_TENANCY_DRIVER',  'in-memory')],
    'authz'    => ['driver' => env('FLAMETRENCH_AUTHZ_DRIVER',    'in-memory')],
];
```

The default `in-memory` driver wires the reference implementations from the per-capability SDKs — fine for tests and local development.

Production binding
------------------

[](#production-binding)

This package does not ship Postgres-backed stores; those live in the per-capability SDKs as they land. For production, override the bindings in your own `AppServiceProvider::register()`:

```
use Flametrench\Identity\IdentityStore;
use App\Identity\PostgresIdentityStore;

public function register(): void
{
    $this->app->singleton(IdentityStore::class, function ($app) {
        return new PostgresIdentityStore($app->make(\PDO::class));
    });
}
```

`AppServiceProvider` runs before package providers, so your binding wins.

Usage
-----

[](#usage)

Type-hint the Flametrench store interfaces in controller / job constructors:

```
use Flametrench\Tenancy\TenancyStore;

class OrgController
{
    public function __construct(private readonly TenancyStore $tenancy) {}

    public function store(Request $request): JsonResponse
    {
        $result = $this->tenancy->createOrg(
            $request->user()->id,
            name: $request->input('name'),
            slug: $request->input('slug'),
        );
        return response()->json($result['org']);
    }
}
```

Or use the `Flametrench` facade for one-liners:

```
use Flametrench\Laravel\Facades\Flametrench;

$user = Flametrench::identity()->getUser($usrId);
```

Testing
-------

[](#testing)

```
composer install
composer test
composer test:coverage
```

The test suite uses [Orchestra Testbench](https://github.com/orchestral/testbench) to boot a Laravel application around the package, so the service provider binds against a real container.

License
-------

[](#license)

Apache License 2.0. Copyright 2026 NDC Digital, LLC.

###  Health Score

38

—

LowBetter than 83% of packages

Maintenance96

Actively maintained with recent releases

Popularity7

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity38

Early-stage or recently created project

 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

Unknown

Total

1

Last Release

39d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/19826928?v=4)[Nathan Call](/maintainers/nathancall)[@nathancall](https://github.com/nathancall)

---

Top Contributors

[![nathancall](https://avatars.githubusercontent.com/u/19826928?v=4)](https://github.com/nathancall "nathancall (6 commits)")

---

Tags

laravelidentityauthorizationmulti-tenancytenancyflametrench

###  Code Quality

TestsPest

### Embed Badge

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

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

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3325.1M337](/packages/psalm-plugin-laravel)[laravel/ai

The official AI SDK for Laravel.

9782.1M153](/packages/laravel-ai)[moonshine/moonshine

Laravel administration panel

1.3k239.9k72](/packages/moonshine-moonshine)[auth0/login

Auth0 Laravel SDK. Straight-forward and tested methods for implementing authentication, and accessing Auth0's Management API endpoints.

2795.2M3](/packages/auth0-login)[illuminate/auth

The Illuminate Auth package.

9327.9M1.2k](/packages/illuminate-auth)[api-platform/laravel

API Platform support for Laravel

59156.3k10](/packages/api-platform-laravel)

PHPackages © 2026

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