PHPackages                             protoframework/proto - 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. protoframework/proto

ActiveProject[Framework](/categories/framework)

protoframework/proto
====================

The Proto Framework - A modular monolith framework for PHP.

1.3.11(1mo ago)26.1k1MITPHPPHP &gt;=8.4

Since Apr 4Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/chrisdurfee/proto)[ Packagist](https://packagist.org/packages/protoframework/proto)[ RSS](/packages/protoframework-proto/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (16)Versions (227)Used By (1)

Proto Framework
===============

[](#proto-framework)

Introduction to Proto
---------------------

[](#introduction-to-proto)

Proto is an open-source modular monolith framework for building scalable server applications quickly and securely. It's secure, performant, and designed for developer productivity. It includes an AI document to help agents build with Proto.

Overview
--------

[](#overview)

Distributed systems are great, except when they are not. Building large, team-based systems that scale presents many challenges—testing, conflicts, build times, response times, developer environments, etc. Proto was created to allow scalable server applications to be built rapidly and securely. Its modular design enables teams to develop specific features without many of the common pitfalls of distributed systems. Proto auto-bootstraps and loads modules on demand, and configuration is managed in the **Common/Config** `.env` file.

Framework Features
------------------

[](#framework-features)

Proto includes a comprehensive set of features for creating complex applications, including:

- **Modules system** to encapsulate features
- **API Systems** with REST Router
- **Validation** with sanitization
- **Server-Sent Events (SSE)**
- **Websockets &amp; Sockets**
- **HTTP Resources**
- **Security Gates and Policies**
- **Error Tracking and Handling**
- **Authentication** using roles, permissions, and organizations
- **Controllers**
- **Caching (Redis)**
- **Configs** with .env JSON support
- **Models** with complex relationships (eager and lazy)
- **Collections** for data manipulation
- **Storage Layers** to abstract data storage from data sources
- **Session Management** (database and file support)
- **Services &amp; Service Providers**
- **Events, Event Loops** with async support
- **Jobs** with event queues (database, Kafka support)
- **Design Patterns**
- **HTML Templates** using components
- **Email Rendering** with Templates
- **Dispatching Email, SMS, and Web Push**
- **Resource Generators** for quick code scaffolding
- **Database Abstractions**
- **Database Adapters** with MySQLi support
- **Query Builders**
- **Database Migrations** with seeding support
- **Seeding** for testing
- **Factories** for generating test data
- **Testing** with PHPUnit, data faking, and robust utilities
- **Automations** to create routine tasks
- **File Storage** (local, AWS S3 support)
- **Integrations** to third-party services (REST, JWT, Oauth2 support)
- **Utilities** for dates, strings, files, encryption, and more

File Structure
--------------

[](#file-structure)

A typical Proto application is structured as follows:

- **common/**The root for your application code and shared components between modules.
- **modules/**Contains self-contained modules for each major domain or feature.
- **public/**Front-end assets and public resources.
- **vendor/protoframework/proto/**The core framework. This folder is accessible but should not be modified.

Bootstrapping
-------------

[](#bootstrapping)

Proto auto bootstraps when interfacing with an API, Controller, Model, Storage, or Routine. Simply include `/vendor/autoload.php` and call the namespaced classes you need.

```
