Header Bag is a small library which helps manage headers. It's useful in HTTP request or response classes. This library covers part of PSR-7: HTTP message.

What are headers?

Headers are part of the request and the response in HTTP. It's not just a simple array of values. Field names are case-insensitive, you can overwrite any header. You can also use multiple values, so you decide if you need to retrieve a header as an array or a string.


To install this package, run the standard command using Composer:

  • composer require quillstack/header-bag

The package will be ready to use after that.