PHPackages                             harunnryd/gateid - 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. harunnryd/gateid

ActiveProject

harunnryd/gateid
================

API gateway written in PHP7 and Lumen.

501PHP

Since Jul 28Pushed 7y ago2 watchersCompare

[ Source](https://github.com/harunnryd/gateid)[ Packagist](https://packagist.org/packages/harunnryd/gateid)[ RSS](/packages/harunnryd-gateid/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

Gateid - Lumen API Gateway
==========================

[](#gateid---lumen-api-gateway)

[![Latest Stable Version](https://camo.githubusercontent.com/42e366b80e761aec0994253ab95c18fcc2fd861ab3ed2e97daa6acbfc34804f0/68747470733a2f2f706f7365722e707567782e6f72672f686172756e6e7279642f6761746569642f762f737461626c65)](https://packagist.org/packages/harunnryd/gateid)[![Total Downloads](https://camo.githubusercontent.com/157632849c42522f879bc06b4ec468831e7106d927002665b1e8f7c9656e478a/68747470733a2f2f706f7365722e707567782e6f72672f686172756e6e7279642f6761746569642f646f776e6c6f616473)](https://packagist.org/packages/harunnryd/gateid)[![Latest Unstable Version](https://camo.githubusercontent.com/f1e2fa780c5a36a0870f1b900379a5e7ec4f82159eab5ec579fa628f8f78492d/68747470733a2f2f706f7365722e707567782e6f72672f686172756e6e7279642f6761746569642f762f756e737461626c65)](https://packagist.org/packages/harunnryd/gateid)[![License](https://camo.githubusercontent.com/2a3d96213505ad4056b9ff039b73a47188aec2f1726162730bd29886b9412025/68747470733a2f2f706f7365722e707567782e6f72672f686172756e6e7279642f6761746569642f6c6963656e7365)](https://packagist.org/packages/harunnryd/gateid)

What is an API Gateway?
-----------------------

[](#what-is-an-api-gateway)

> *An API Gateway sits in front of your application(s) and/or services and manages the heavy lifting of authorisation, access control and throughput limiting to your services. Ideally, it should mean that you can focus on creating services instead of implementing management infrastructure. For example, if you have written a really awesome web service that provides geolocation data for all the cats in NYC, and you want to make it public, integrating an API gateway is a faster, more secure route than writing your own authorisation middleware.*

Requirements and dependencies
-----------------------------

[](#requirements-and-dependencies)

- PHP &gt;= 7.0
- Lumen 5.6
- Guzzle 6
- Laravel Passport (with [Lumen Passport](https://github.com/dusterio/lumen-passport))
- Spatie Permission (with \[Spatie Permission\] ()

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

[](#how-it-works)

```
$ composer install
$ php artisan passport:install
$ vim storage/app/routes.json

```

> if you need to use Oauth2 (Passport) please tag oauth:api on middleware

```
# example routes.json

{
    "global": {
        "domain": "54.169.181.142:7002"
    },
    "routes": [
        {
            "description": "get specific role",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles/{id}",
            "actions": [
                {
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles/{id}",
                    "outputKey": "role"
                }
            ]
        },
        {
            "description": "get all roles",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles",
            "actions": [
                {
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles",
                    "outputKey": "roles"
                }
            ]
        },
        {
            "description": "create role",
            "method": "post",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles",
            "actions": [
                {
                    "method": "post",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles",
                    "outputKey": "role"
                }
            ]
        },
        {
            "description": "update role",
            "method": "patch",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles/{id}",
            "actions": [
                {
                    "method": "patch",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles/{id}",
                    "outputKey": "role"
                }
            ]
        },
        {
            "description": "delete role",
            "method": "delete",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles/{id}",
            "actions": [
                {
                    "method": "delete",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles/{id}",
                    "outputKey": "role"
                }
            ]
        },
        {
            "description": "get specific permission",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/permissions/{id}",
            "actions": [
                {
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/permissions/{id}",
                    "outputKey": "permission"
                }
            ]
        },
        {
            "description": "get all permission",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/permissions",
            "actions": [
                {
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/permissions",
                    "outputKey": "permissions"
                }
            ]
        },
        {
            "description": "create permission",
            "method": "post",
            "middleware": ["auth:api"],
            "path": "/api/v2/permissions",
            "actions": [
                {
                    "method": "post",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/permissions",
                    "outputKey": "permission"
                }
            ]
        },
        {
            "description": "update permission",
            "method": "patch",
            "middleware": ["auth:api"],
            "path": "/api/v2/permissions/{id}",
            "actions": [
                {
                    "method": "patch",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/permissions/{id}",
                    "outputKey": "permission"
                }
            ]
        },
        {
            "description": "delete permission",
            "method": "delete",
            "middleware": ["auth:api"],
            "path": "/api/v2/permissions/{id}",
            "actions": [
                {
                    "method": "delete",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/permissions/{id}",
                    "outputKey": "permission"
                }
            ]
        },
        {
            "description": "attach role to user",
            "method": "patch",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}/roles",
            "actions": [
                {
                    "method": "patch",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/users/{id}/roles",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "detach role to user",
            "method": "delete",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}/roles",
            "actions": [
                {
                    "method": "delete",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/users/{id}/roles",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "attach permission to user",
            "method": "patch",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}/permissions",
            "actions": [
                {
                    "method": "patch",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/users/{id}/permissions",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "detach permission to user",
            "method": "delete",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}/permissions",
            "actions": [
                {
                    "method": "delete",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/users/{id}/permissions",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "get all role by user",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}/roles",
            "actions": [
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/users/{id}",
                    "outputKey": "user"
                },
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/users/{id}/roles",
                    "outputKey": "user.roles"
                }
            ]
        },
        {
            "description": "get all permission by role",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles/{id}/permissions",
            "actions": [
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/api/v2/roles/{id}",
                    "outputKey": "role"
                },
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles/{id}/permissions",
                    "outputKey": "role.permissions"
                }
            ]
        },

        {
            "description": "get all user by role",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/roles/{id}/users",
            "actions": [
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/api/v2/roles/{id}",
                    "outputKey": "role"
                },
                {
                    "sequence": 1,
                    "method": "get",
                    "hostname": "54.169.181.142:7003",
                    "service": "",
                    "path": "/rbac/v2/roles/{id}/users",
                    "outputKey": "role.users"
                }
            ]
        },
        {
            "description": "register user",
            "method": "post",
            "middleware": [],
            "path": "/api/v2/users",
            "actions": [
                {
                    "method": "post",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/users",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "delete user",
            "method": "delete",
            "middleware": [],
            "path": "/api/v2/users/{id}",
            "actions": [
                {
                    "method": "delete",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/users/{id}",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "update user",
            "method": "patch",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}",
            "actions": [
                {
                    "method": "patch",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/users/{id}",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "get user",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/users/{id}",
            "actions": [
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/users/{id}",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "get user self",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/self-users",
            "actions": [
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/self-users",
                    "outputKey": "user"
                }
            ]
        },
        {
            "description": "get user",
            "method": "get",
            "middleware": ["auth:api"],
            "path": "/api/v2/users",
            "actions": [
                {
                    "sequence": 0,
                    "method": "get",
                    "hostname": "54.169.181.142:7004",
                    "service": "",
                    "path": "/account/v2/users",
                    "outputKey": "users"
                }
            ]
        },
        {
            "description": "get location point",
            "method": "post",
            "middleware": ["auth:api"],
            "path": "/api/v2/location-points",
            "actions": [
                {
                    "sequence": 0,
                    "method": "post",
                    "hostname": "54.169.181.142:7006",
                    "service": "",
                    "path": "/reservation/v2/location-points",
                    "outputKey": "location_points"
                }
            ]
        }
    ]
}
```

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

[](#security-vulnerabilities)

> If you discover a security vulnerability within Gateid, please send an e-mail to harun nur rasyid at ****. All security vulnerabilities will be promptly addressed.

License
-------

[](#license)

> Gateid is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community5

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

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/39ed0612f2da9e2f05c9e191899e364c5e98f6cab731a7629be3da6bc8a06acf?d=identicon)[harunnryd](/maintainers/harunnryd)

### Embed Badge

![Health badge](/badges/harunnryd-gateid/health.svg)

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

PHPackages © 2026

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