quillphp / request-id
Quill PHP request-id middleware
dev-main
2026-04-06 10:03 UTC
Requires
- php: >=8.3
- quillphp/quill: ^0.0.2
Requires (Dev)
- phpunit/phpunit: ^11.0
This package is auto-updated.
Last update: 2026-04-06 11:56:10 UTC
README
Request ID middleware for the Quill PHP Framework. Injects a unique identifier into every request/response for distributed tracing and log correlation.
Installation
composer require quillphp/request-id
Usage
use Quill\RequestId\RequestId; $app->use(RequestId::new([ 'header' => 'X-API-Request-ID', 'context_key' => 'trace_id', ]));
Configuration
| Option | Default | Description |
|---|---|---|
| `context_key` | `'request_id'` | Context key to store the ID in the Request object. |
| `generator` | `callable` | Optional: custom UUID generator. |
License
MIT