PHPackages                             bluecloud/route-permissions - 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. bluecloud/route-permissions

ActiveLibrary

bluecloud/route-permissions
===========================

Laravel route based permission system

052PHP

Since Mar 14Pushed 5y ago2 watchersCompare

[ Source](https://github.com/bluecloudafrica/route-permissions)[ Packagist](https://packagist.org/packages/bluecloud/route-permissions)[ RSS](/packages/bluecloud-route-permissions/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependenciesVersions (1)Used By (0)

Route Permissions
=================

[](#route-permissions)

Implement route based permissions in your laravel app.

How to Use
----------

[](#how-to-use)

```
composer require bluecloud/route-pemissions

php artisan migrate

```

- use `Bluecloud\RoutePermissions\Models\Traits\HasRoutePermissions`trait in your `User` model
- Add `role_id` column to your `users` table.
- To restrict access to resources based on the routes, wrap the routes to those resources in `Bluecloud\RoutePermissions\Http\Middleware\PermitRoute`middleware

How it works
------------

[](#how-it-works)

Route permissions package introduces `roles` and `permissions` to your application.

Permissions are actual actions a user can do. They are defined by route uri and http method. Arguably every route of your application should have a corresponding permission. These permissions can be managed under the `Bluecloud\RoutePermissions\Models\Permission` model.

Role are groups of permissions that make up a user's `job`. A role, presented by the `Bluecloud\RoutePermissions\Models\Role` model can have as many permissions as you would like the user to have. Every user should belong to a role. A user can or cannot access a resource based on the permissions the role they belong to have. A user's permission can be changed by changing their role or by changing the permissions attached to their role.

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

[](#configuration)

You can edit the application config by publishing the package's resources `php artisan vendor:publish` and choosing `Bluecloud\RoutePermissions\RoutePermissionsServiceProvider`from the list

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity30

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/8ae7f9eb095fd20322d5d355480326914814d151fbd4955158041b61fe68e73a?d=identicon)[bluecloud](/maintainers/bluecloud)

---

Top Contributors

[![saulchelewani](https://avatars.githubusercontent.com/u/12005903?v=4)](https://github.com/saulchelewani "saulchelewani (10 commits)")

### Embed Badge

![Health badge](/badges/bluecloud-route-permissions/health.svg)

```
[![Health](https://phpackages.com/badges/bluecloud-route-permissions/health.svg)](https://phpackages.com/packages/bluecloud-route-permissions)
```

PHPackages © 2026

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