PHPackages                             webtheory/http-policy - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. webtheory/http-policy

ActiveLibrary[HTTP &amp; Networking](/categories/http)

webtheory/http-policy
=====================

Contracts for simple validation of psr-7 conditions

0.1.0(4y ago)14672MITPHPPHP ^7.4 || ^8.0

Since Mar 30Pushed 4y ago1 watchersCompare

[ Source](https://github.com/spider-mane/http-policy)[ Packagist](https://packagist.org/packages/webtheory/http-policy)[ Docs](https://github.com/spider-mane/http-policy)[ RSS](/packages/webtheory-http-policy/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (12)Versions (2)Used By (2)

http-policy
===========

[](#http-policy)

[![Latest Version on Packagist](https://camo.githubusercontent.com/c3ad388459a04d936056de8a5aadd0786d3605ade13264ad62612cfda791eeb5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7765627468656f72792f687474702d706f6c6963792e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/webtheory/http-policy)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/e5dea4dd2bb71b40b1596e63680d5d90a40effe8a86e99200be2d7e8900c937c/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7370696465722d6d616e652f687474702d706f6c6963792f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/spider-mane/http-policy)[![Coverage Status](https://camo.githubusercontent.com/3884a7b4095bc87b94718a9c28bcff15ddf14d75b14cfe3d6c17e16a8154b6e3/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f7370696465722d6d616e652f687474702d706f6c6963792e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/spider-mane/http-policy/code-structure)[![Quality Score](https://camo.githubusercontent.com/5767e42d85296fd05dd2024a8fe47f8e49eda97bf90543e397569d907ee30c76/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f7370696465722d6d616e652f687474702d706f6c6963792e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/spider-mane/http-policy)[![Total Downloads](https://camo.githubusercontent.com/ab2aab0b873444ad2a91133e3509550e09a8667707608ba1c3cdc407bf395687/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7765627468656f72792f687474702d706f6c6963792e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/webtheory/http-policy)

Contracts for simple validation of psr-7 conditions

Install
-------

[](#install)

Via Composer

```
composer require webtheory/http-policy
```

Change log
----------

[](#change-log)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Testing
-------

[](#testing)

```
composer test
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) and [CODE\_OF\_CONDUCT](CODE_OF_CONDUCT.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Chris Williams](https://github.com/spider-mane)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

1507d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/42c6c17a141acad92bd90ad7b7e574ea19ecb332f33272a041261566670576cf?d=identicon)[webtheory](/maintainers/webtheory)

---

Top Contributors

[![spider-mane](https://avatars.githubusercontent.com/u/17187449?v=4)](https://github.com/spider-mane "spider-mane (1 commits)")

---

Tags

webtheoryhttp-policy

###  Code Quality

Static AnalysisPHPStan, Psalm

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/webtheory-http-policy/health.svg)

```
[![Health](https://phpackages.com/badges/webtheory-http-policy/health.svg)](https://phpackages.com/packages/webtheory-http-policy)
```

###  Alternatives

[league/uri-interfaces

Common tools for parsing and resolving RFC3987/RFC3986 URI

538204.9M23](/packages/league-uri-interfaces)[shopify/shopify-api

Shopify API Library for PHP

4634.8M16](/packages/shopify-shopify-api)[laudis/neo4j-php-client

Neo4j-PHP-Client is the most advanced PHP Client for Neo4j

184616.9k31](/packages/laudis-neo4j-php-client)[http-interop/response-sender

A function to convert PSR-7 Response to HTTP output

46711.5k40](/packages/http-interop-response-sender)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28137.8k](/packages/phpro-http-tools)[mezzio/mezzio-authentication-oauth2

OAuth2 (server) authentication middleware for Mezzio and PSR-7 applications.

28483.0k2](/packages/mezzio-mezzio-authentication-oauth2)

PHPackages © 2026

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