PHPackages                             daacreators/pennant-manager - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. daacreators/pennant-manager

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

daacreators/pennant-manager
===========================

A Filament plugin for managing Laravel Pennant feature flags

v1.0.0(1mo ago)4831MITPHPPHP ^8.2

Since May 31Pushed 1mo agoCompare

[ Source](https://github.com/jabirmayar/pennant-manager)[ Packagist](https://packagist.org/packages/daacreators/pennant-manager)[ Docs](https://github.com/jabirmayar/pennant-manager)[ RSS](/packages/daacreators-pennant-manager/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependencies (14)Versions (2)Used By (0)

pennant-manager
===============

[](#pennant-manager)

[![Latest Version on Packagist](https://camo.githubusercontent.com/b1d70e37c56324dd3f47d7a2ee5c6bffb90f4b393220e5a3fbb8ba2ae6e5dc31/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f64616163726561746f72732f70656e6e616e742d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/daacreators/pennant-manager)[![GitHub Tests Action Status](https://camo.githubusercontent.com/a40bc5abc90d264997cab232efd9627d76681fa5ef185c7cf979129039e479c2/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f64616163726561746f72732f70656e6e616e742d6d616e616765722f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/jabirmayar/pennant-manager/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/4c5c0eedc8cc76f62a2fefc9573dd1e0cd41176a137f9a948200ad516fc5d8c8/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6a616269726d617961722f70656e6e616e742d6d616e616765722f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/jabirmayar/pennant-manager/actions?query=workflow%3A%22Fix+PHP+code+styling%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/9f56048966076edf6be603f2e09682096d5bd637efd3ab52be298cdb559f8ce7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f64616163726561746f72732f70656e6e616e742d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/daacreators/pennant-manager)

A Filament panel plugin for managing [Laravel Pennant](https://laravel.com/docs/pennant) feature flags - toggle globally, per user or team, bulk import scopes, discover defined features, and track adoption - all without leaving your admin panel.

---

Screenshots
-----------

[](#screenshots)

[![Feature List](screenshots/features-list.png)](screenshots/features-list.png)[![Feature Settings](screenshots/settings.png)](screenshots/settings.png)[![Manage Scopes](screenshots/manage-scopes.png)](screenshots/manage-scopes.png)

---

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

[](#requirements)

- PHP 8.2+
- Laravel 11+
- Filament 4.x
- Laravel Pennant (`laravel/pennant`)

---

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

[](#installation)

Install via Composer:

```
composer require daacreators/pennant-manager
```

If you haven't already, install Pennant and run its migration:

```
composer require laravel/pennant
php artisan migrate
```

Publish the plugin config:

```
php artisan vendor:publish --tag="pennant-manager-config"
```

Optionally publish the views to customise them:

```
php artisan vendor:publish --tag="pennant-manager-views"
```

---

Setup
-----

[](#setup)

Register the plugin in your Filament panel provider:

```
use daacreators\PennantManager\PennantManagerPlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            PennantManagerPlugin::make(),
        ]);
}
```

---

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

[](#configuration)

```
// config/pennant-manager.php

return [
    'navigation_group' => 'Settings',

    /*
    |--------------------------------------------------------------------------
    | Scope Models
    |--------------------------------------------------------------------------
    | Models that can be used as feature flag scopes.
    | Extended format lets you configure per-model search and display columns.
    */
    'scope_models' => [
        'User' => [
            'model'           => \App\Models\User::class,
            'search_column'   => 'email',   // column used when searching for a scope
            'label_column'    => 'name',    // column shown in the scopes table
            'segment_columns' => ['plan', 'role', 'country'], // optional - restricts Activate by Segment to these columns
        ],
        // 'Team' => [
        //     'model'         => \App\Models\Team::class,
        //     'search_column' => 'name',
        // ],
    ],

    // Global fallback search column - used when a scope_models entry is a plain class string
    'scope_search_column' => 'email',

    /*
    |--------------------------------------------------------------------------
    | Feature Discovery
    |--------------------------------------------------------------------------
    | Paths scanned for Feature::define() calls (files or directories).
    | Scanned features are merged with the manual list in discovered_features.
    */
    'discovery_paths' => [
        app_path('Providers/AppServiceProvider.php'),
        // app_path('Features'),
    ],

    // Manually list features here - useful for features defined dynamically
    // or inside packages that cannot be reliably scanned.
    'discovered_features' => [
        // 'some-dynamic-feature',
    ],
];
```

---

Features
--------

[](#features)

### Feature List

[](#feature-list)

The main table shows all globally-scoped features. For each feature you can:

- Toggle it **globally on or off** - affects everyone who does not have an explicit scope row
- See how many **per-scope overrides** exist (individual users or teams)
- Open **Settings** for advanced configuration
- Navigate to **Manage Scopes** for per-user or per-team control
- Delete the feature entirely

### Global Toggle vs Scopes

[](#global-toggle-vs-scopes)

The global toggle is the **fallback for everyone without a scope row**. Pennant always resolves the scope-specific row first:

```
User checks feature
 ├── Has a scope row? → use that value (global is ignored)
 └── No scope row?   → fall back to the global toggle

```

This means you can keep the global toggle **off** while individually activating the feature for specific users via scopes - those users still get access.

---

### Settings

[](#settings)

Each feature has a Settings modal with three sections. All three can be configured together in a single save.

#### Schedule

[](#schedule)

Set a future date and time. The feature stays off until that moment. When the scheduled time arrives, the `pennant:activate-scheduled` command flips it on automatically.

```
Feature is OFF → schedule set for Jun 15 00:00 → command runs → feature turns ON

```

#### Variant Value

[](#variant-value)

Instead of returning `true` or `false`, the feature returns a custom string. Useful for A/B testing, UI themes, or API versioning.

Set the variant in Settings and read it in your code using the plugin helper:

```
use daacreators\PennantManager\Support\FeatureValue;

$value = FeatureValue::resolveValue('theme');
// Returns the variant string if active  → 'dark', 'v2', 'beta'
// Returns true if active with no variant set
// Returns false if the feature is inactive
```

You can also check a specific scope (e.g. a user):

```
$value = FeatureValue::resolveValue('theme', 'App\Models\User|42');
```

#### Percentage Rollout

[](#percentage-rollout)

Randomly activates the feature for a percentage of your users by creating individual scope rows for them. Only users who do not already have a scope row are eligible.

**Apply immediately ON** - scope rows are created the moment you save Settings.

**Apply immediately OFF** - the percentage and model are stored, and the rollout is applied by the scheduled command when the activation date arrives. Use this to combine a rollout with a launch date.

A typical launch flow:

```
Set 30% rollout + Jun 15 activation date + Apply immediately OFF
→ On Jun 15, the command picks 30% of users and activates for them automatically

```

---

### Manage Scopes

[](#manage-scopes)

Per-feature page for activating or removing the feature for individual users or teams.

**Manual search** - search by the configured column (e.g. email), select one or more records, and activate.

**Bulk import** - paste a list of values (one per line, matching the search column) to activate for many users at once without uploading a file.

**Activate by Segment** - activate for all records matching a column condition, e.g. all users where `plan = pro` or `country = US`. If `segment_columns` is configured for the model, a dropdown restricts which columns can be filtered on. Otherwise any column name can be entered freely.

The scopes table shows each activated record, their model type, and whether their scope is currently active or inactive.

---

### Feature Discovery

[](#feature-discovery)

Scans your configured `discovery_paths` for `Feature::define()` calls - both string-keyed and class-based - and merges results with any features listed manually in `discovered_features`. Opens a modal showing features found in code but not yet in the database, all pre-selected for one-click import.

```
// Both of these are detected automatically
Feature::define('new-dashboard', fn (User $user) => false);
Feature::define(BetaFeature::class, fn (User $user) => false);
```

---

### Adoption Stats

[](#adoption-stats)

A stats widget at the top of the feature list showing per-feature adoption - what percentage of each model type has that feature currently active.

---

Defining Features
-----------------

[](#defining-features)

Define features the standard Pennant way in your `AppServiceProvider`:

```
use Laravel\Pennant\Feature;

public function boot(): void
{
    Feature::define('new-dashboard', fn (User $user) => $user->isOnProPlan());

    Feature::define(BetaFeature::class, fn (User $user) => false);
}
```

After defining features, open the **Discover Features** action in the panel to import them into the database.

---

Scheduling
----------

[](#scheduling)

To activate scheduled features and apply deferred rollouts automatically, add the command to your scheduler:

```
// routes/console.php
use Illuminate\Support\Facades\Schedule;

Schedule::command('pennant:activate-scheduled')->everyMinute();
```

You can also run it manually at any time:

```
php artisan pennant:activate-scheduled
```

---

Support the Project
-------------------

[](#support-the-project)

If this package saves you time or helps your business, consider supporting its development.

[Support the Project](https://jabirmayar.gumroad.com/coffee)

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

[](#contributing)

Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](.github/SECURITY.md) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Jabir Khan](https://github.com/jabirmayar)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

43

—

FairBetter than 89% of packages

Maintenance89

Actively maintained with recent releases

Popularity18

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity46

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

Unknown

Total

1

Last Release

54d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0e8c4bd89144533bc0454808d22455e9daeacff09f9746b30a23dd8c638b2235?d=identicon)[jabirmayar](/maintainers/jabirmayar)

---

Top Contributors

[![jabirmayar](https://avatars.githubusercontent.com/u/55909170?v=4)](https://github.com/jabirmayar "jabirmayar (1 commits)")

---

Tags

feature-flagsfilamentfilament-pluginlaravelpennantlaravelfilamentfilament-pluginfilamentphpJabir Khanpennant-manager

###  Code Quality

TestsPest

Static AnalysisPHPStan, Rector

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/daacreators-pennant-manager/health.svg)

```
[![Health](https://phpackages.com/badges/daacreators-pennant-manager/health.svg)](https://phpackages.com/packages/daacreators-pennant-manager)
```

###  Alternatives

[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3914.8k](/packages/rawilk-profile-filament-plugin)[stephenjude/filament-feature-flags

Filament implementation of feature flags and segmentation with Laravel Pennant.

123177.8k1](/packages/stephenjude-filament-feature-flags)[croustibat/filament-jobs-monitor

Background Jobs monitoring like Horizon for all drivers for FilamentPHP

274333.4k9](/packages/croustibat-filament-jobs-monitor)[stephenjude/filament-jetstream

A Laravel starter kit built with Filament inspired by Jetstream.

17760.2k3](/packages/stephenjude-filament-jetstream)[dotswan/filament-map-picker

Easily pick and retrieve geo-coordinates using a map-based interface in your Filament applications.

128192.3k3](/packages/dotswan-filament-map-picker)[stephenjude/filament-debugger

About

104162.2k2](/packages/stephenjude-filament-debugger)

PHPackages © 2026

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