PHPackages                             infocyph/webrick - 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. infocyph/webrick

ActiveLibrary[Framework](/categories/framework)

infocyph/webrick
================

A fast, modern PHP router with production-grade middleware, signed &amp; temporary URLs, smart responses and first-class route caching.

2.01(3w ago)11.8k↓78.1%MITPHPPHP &gt;=8.4CI passing

Since Oct 22Pushed 3w ago1 watchersCompare

[ Source](https://github.com/infocyph/Webrick)[ Packagist](https://packagist.org/packages/infocyph/webrick)[ RSS](/packages/infocyph-webrick/feed)WikiDiscussions main Synced yesterday

READMEChangelog (5)Dependencies (14)Versions (11)Used By (0)

Webrick Router
==============

[](#webrick-router)

A modern PHP router with route caching, signed URLs, production middleware, and response helpers.

[![Security & Standards](https://github.com/infocyph/Webrick/actions/workflows/security-standards.yml/badge.svg)](https://github.com/infocyph/Webrick/actions/workflows/security-standards.yml)[![Packagist Downloads](https://camo.githubusercontent.com/e81eea4af3244d79b1c4c4d0de073202a55225be0ed006ceb4a507c369db4fb6/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f696e666f637970682f7765627269636b3f636f6c6f723d677265656e266c696e6b3d68747470732533412532462532467061636b61676973742e6f72672532467061636b61676573253246696e666f637970682532467765627269636b)](https://camo.githubusercontent.com/e81eea4af3244d79b1c4c4d0de073202a55225be0ed006ceb4a507c369db4fb6/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f696e666f637970682f7765627269636b3f636f6c6f723d677265656e266c696e6b3d68747470732533412532462532467061636b61676973742e6f72672532467061636b61676573253246696e666f637970682532467765627269636b)[![License: MIT](https://camo.githubusercontent.com/784362b26e4b3546254f1893e778ba64616e362bd6ac791991d2c9e880a3a64e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d677265656e2e737667)](https://opensource.org/licenses/MIT)[![Packagist Version](https://camo.githubusercontent.com/ad56b0a2a41c9d9dc85f3bca6c67431c53e6f8370a954a23968bcf70ca208af7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f696e666f637970682f7765627269636b)](https://camo.githubusercontent.com/ad56b0a2a41c9d9dc85f3bca6c67431c53e6f8370a954a23968bcf70ca208af7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f696e666f637970682f7765627269636b)[![Packagist PHP Version](https://camo.githubusercontent.com/e0e6814e2cd3d85beec2f7c9ba79f0e9696bc93d2a3b17bb5f1ffee267187edd/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f696e666f637970682f7765627269636b2f706870)](https://camo.githubusercontent.com/e0e6814e2cd3d85beec2f7c9ba79f0e9696bc93d2a3b17bb5f1ffee267187edd/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f696e666f637970682f7765627269636b2f706870)[![GitHub Code Size](https://camo.githubusercontent.com/2916b8628d87dc996bc42a8e574825c3fe6f553a1a867c6bd718029948fda050/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c616e6775616765732f636f64652d73697a652f696e666f637970682f5765627269636b)](https://camo.githubusercontent.com/2916b8628d87dc996bc42a8e574825c3fe6f553a1a867c6bd718029948fda050/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c616e6775616765732f636f64652d73697a652f696e666f637970682f5765627269636b)[![Documentation](https://camo.githubusercontent.com/ea5425f990b45c310432223acddf7d89af769d24a1fd44a27e6332889871279d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f446f63756d656e746174696f6e2d5765627269636b2d626c75653f6c6f676f3d72656164746865646f6373266c6f676f436f6c6f723d7768697465)](https://docs.infocyph.com/projects/webrick/en/latest/)

Highlights
----------

[](#highlights)

- Fast routing: named routes, groups, domains, resources, attribute discovery
- Signed URLs: permanent, TTL-based, or explicit-expiry links
- Rich signing controls: relative or absolute payloads, ignored query params, key rotation, custom signature params and algorithms
- Central error boundary: framework middleware throws typed HTTP exceptions and the kernel renders them just before emission
- User controllers and user middleware can still return `Response` directly; only framework-owned rejection paths are exception-driven
- Response helpers: JSON, plaintext, redirects, streaming, ranged file/download responses, views
- Route caching: sharded, fused, or generated matchers
- Middleware pipeline: negotiation, compression, throttling, validators, telemetry, cookie encryption, and more

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

[](#requirements)

- PHP 8.4+
- Composer 2.x

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

[](#installation)

```
composer require infocyph/webrick
```

Minimal Boot Example
--------------------

[](#minimal-boot-example)

```
