PHPackages                             progalaxyelabs/stone-script-php - 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. [Framework](/categories/framework)
4. /
5. progalaxyelabs/stone-script-php

AbandonedLibrary[Framework](/categories/framework)

progalaxyelabs/stone-script-php
===============================

Core Framework Library - Use progalaxyelabs/stonescriptphp-server to create new projects. Modern PHP backend framework for building APIs with PostgreSQL. Installed automatically as a dependency when you create projects with stonescriptphp-server.

7.6.1(2w ago)0111[1 issues](https://github.com/progalaxyelabs/StoneScriptPHP/issues)MITPHPPHP ^8.2CI failing

Since May 1Pushed 2w ago1 watchersCompare

[ Source](https://github.com/progalaxyelabs/StoneScriptPHP)[ Packagist](https://packagist.org/packages/progalaxyelabs/stone-script-php)[ Docs](https://stonescriptphp.org)[ RSS](/packages/progalaxyelabs-stone-script-php/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (3)Dependencies (63)Versions (168)Used By (0)

StoneScriptPHP
==============

[](#stonescriptphp)

[![Packagist Version](https://camo.githubusercontent.com/c3aa467f0614f7e383a2d99c82ed9118f0f6fc2a42d2d77a4b5eeb313453f104/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f70726f67616c617879656c6162732f73746f6e65736372697074706870)](https://packagist.org/packages/progalaxyelabs/stonescriptphp)[![License](https://camo.githubusercontent.com/7e34bdc018f3ef53031052907b081eb92db5d5682b57dca80a9634f60c9a6b63/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f70726f67616c617879656c6162732f53746f6e65536372697074504850)](LICENSE)

A PHP backend framework for building PostgreSQL-backed APIs, with Angular-inspired routing, a `stone` CLI for code generation, and improved developer ergonomics.

This repository is the **core framework library** — the routing, auth, validation, and database-binding code that everything else in the ecosystem is built on.

Which package do I want?
------------------------

[](#which-package-do-i-want)

I want to...Use thisStart a new API project[`stonescriptphp-server`](https://github.com/progalaxyelabs/StoneScriptPHP-Server) — `composer create-project progalaxyelabs/stonescriptphp-server my-api`Contribute to the framework, build a custom project template, or integrate StoneScriptPHP into an existing appThis repository — `composer require progalaxyelabs/stonescriptphp`If you're just getting started, go create your project with `stonescriptphp-server`first — it already depends on this package, so you'll get it automatically. Come back here if you need to read or modify the framework's own code.

Features
--------

[](#features)

- **PostgreSQL-first** — business logic lives in SQL functions; PHP models wrap them with types
- **JWT authentication** — RSA &amp; HMAC, built-in Google OAuth, pluggable auth modes
- **RBAC** — role-based permissions
- **Request validation** — 12+ built-in rules
- **Redis caching** — optional, with tag-based invalidation
- **CLI code generation** — routes, models, migrations, TypeScript clients, all via `php stone`
- **Structured logging** — PSR-3 compatible, colorized console output
- **VS Code extension** — snippets for the framework's conventions

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

[](#requirements)

- PHP &gt;= 8.2, with `pdo`, `pdo_pgsql`, `json`, `openssl`
- PostgreSQL &gt;= 13
- Composer
- Redis (optional, for caching)

Architecture in one paragraph
-----------------------------

[](#architecture-in-one-paragraph)

Routes handle HTTP concerns only (validation, auth, response shaping). Each route calls a generated PHP model, which calls a PostgreSQL function — that's where the actual business logic and queries live. This keeps the PHP layer thin and puts logic close to the data it operates on. See [HLD.md](HLD.md) for the full picture.

Auth Service clients (backend-to-backend)
-----------------------------------------

[](#auth-service-clients-backend-to-backend)

If your app needs to manage memberships or invitations from backend code (e.g. a payment webhook creating a membership, or a bulk-invite CLI job), the framework ships thin HTTP clients for the Auth Service:

```
use StoneScriptPHP\Auth\Client\MembershipClient;

$client = new MembershipClient('http://auth-service:5000');
$client->createMembership([
    'identity_id' => $userId,
    'tenant_id' => $tenantId,
    'role' => 'premium_member',
], $systemAdminToken);
```

`InvitationClient` works the same way for invite/bulk-invite/cancel. These are for backend automation only — for frontend login and token handling, use the Angular client (`ngx-stonescriptphp-client`) instead.

Contributing to the framework
-----------------------------

[](#contributing-to-the-framework)

```
git clone https://github.com/progalaxyelabs/StoneScriptPHP.git
cd StoneScriptPHP
composer install
composer test
```

To test local framework changes against a real project without publishing a release, point that project's `composer.json` at this checkout:

```
{
    "repositories": [
        { "type": "path", "url": "../StoneScriptPHP", "options": {"symlink": false} }
    ],
    "require": { "progalaxyelabs/stonescriptphp": "@dev" }
}
```

then run `composer update progalaxyelabs/stonescriptphp` in that project.

Versioning
----------

[](#versioning)

[Semantic Versioning](https://semver.org/) — patch releases are safe to take anytime, minor releases add backward-compatible features, major releases may break things (read the migration guide first). Check [Packagist](https://packagist.org/packages/progalaxyelabs/stonescriptphp) or this repo's tags for the current version — don't rely on a hardcoded number in this README, it goes stale.

Documentation
-------------

[](#documentation)

The `stonescriptphp.org` marketing site doesn't have a `/docs` section live yet — the documentation that exists today lives in this repo:

- [High-Level Design](HLD.md)
- [Framework contract / SPEC](SPEC.md)
- [Changelog](CHANGELOG.md)
- [stonescriptphp.org](https://stonescriptphp.org) — overview, features, ecosystem
- [stonescriptphp-server README](https://github.com/progalaxyelabs/StoneScriptPHP-Server#readme) — getting-started walkthrough for new projects

Support
-------

[](#support)

- [GitHub Issues](https://github.com/progalaxyelabs/StoneScriptPHP/issues)
- [stonescriptphp.org](https://stonescriptphp.org)

License
-------

[](#license)

MIT — see [LICENSE](LICENSE).

###  Health Score

48

—

FairBetter than 94% of packages

Maintenance96

Actively maintained with recent releases

Popularity6

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity69

Established project with proven stability

 Bus Factor1

Top contributor holds 99.4% 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 ~3 days

Total

166

Last Release

19d ago

Major Versions

v2.12.1 → v3.0.02026-02-20

v3.33.0 → 4.0.02026-06-14

4.8.1 → 5.0.02026-06-26

5.10.1 → 6.0.02026-07-08

6.1.1 → 7.0.02026-07-15

PHP version history (2 changes)v1.0.0PHP &gt;=8.2

v1.1.0PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/395201d5852ab3828cb1de9eda82667c405c5dd11b55d9b5be4d768f93955c1d?d=identicon)[pradeepkumardesk](/maintainers/pradeepkumardesk)

---

Top Contributors

[![pradeepkumardesk](https://avatars.githubusercontent.com/u/131523495?v=4)](https://github.com/pradeepkumardesk "pradeepkumardesk (350 commits)")[![pradeepdsmk](https://avatars.githubusercontent.com/u/7545127?v=4)](https://github.com/pradeepdsmk "pradeepdsmk (2 commits)")

---

Tags

phpapiframeworkrestpostgresqltypescriptcode-generation

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/progalaxyelabs-stone-script-php/health.svg)

```
[![Health](https://phpackages.com/badges/progalaxyelabs-stone-script-php/health.svg)](https://phpackages.com/packages/progalaxyelabs-stone-script-php)
```

###  Alternatives

[zemit-cms/core

Build Phalcon REST APIs faster with database-first scaffolding, model relationships, eager loading, identity, permissions, CLI, and WebSocket support.

138.5k1](/packages/zemit-cms-core)[quantum/framework

The Quantum PHP Framework

393.6k3](/packages/quantum-framework)

PHPackages © 2026

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