NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Packagist, #206 most downloaded on Packagist
HTTPlug, the HTTP client abstraction for PHP
Latest stable
2.4.1
Last release 2 years ago
no release in 18 months
Release timing varies
gaps range from 2 weeks to 2.2 years
Nearly every release is documented
notes for 9 of 9 stable releases
Nothing withdrawn
no release was ever pulled
11 years old
14 releases · first in 2015
Drag across the ruler to compare, or tap a release to open it.
Updated code to not raise warnings for nullable parameters in PHP 8.4.
Deprecate Http\Client\HttpClient , use PSR-18 instead
psr/http-message v2 in addition to v1Http\Client\HttpClient, use PSR-18 insteadYour coding agent can read these notes before it upgrades. Set up the MCP server →
Enabled the $onRejected callback of HttpRejectedPromise to return a promise for implementing a retry mechanism #168
$onRejected callback of HttpRejectedPromise to return a promise for implementing a retryChanged Support PHP 7.1-8.0
Http\Client\Exception\NetworkException no longer extends Http\Client\Exception\RequestException , in accordance with PSR-18
Http\Client\Exception\NetworkException no longer extends Http\Client\Exception\RequestException, in accordance with PSR-18After two years of work the FIG finally accepted our proposal for HTTP Client standard as PSR-18. This is a huge step in the life of HTTPlug.
After two years of work the FIG finally accepted our proposal for HTTP Client standard as PSR-18. This is a huge step in the life of HTTPlug.
Many thanks to @Nyholm who spearheaded the effort from the very first moment and worked extremely hard to pull this off. Thanks to the working group and everyone else, who made this possible.
This version is no BC break for consumers using HTTPlug. However, HTTP clients that implement HTTPlug need to adjust because we add return type declarations.
HttpClient::sendRequest(RequestInterface $request) has a return type annotation. The new
signature is HttpClient::sendRequest(RequestInterface $request): ResponseInterface.RequestException::getRequest() has a return type annotation. The new
signature is RequestException::getRequest(): RequestInterface.During the development of plugins we faced a problem with exceptions thrown in plugins.
During the development of plugins we faced a problem with exceptions thrown in plugins.
Any exceptions not implementing Http\Client\Exception ended up in an invalid argument error because of these lines:
https://github.com/php-http/promise/blob/v1.0.0/src/RejectedPromise.php#L36-L38
This type leak allowed to inject an exception to be passed to the onRejected callback of a Promise.
In the current release we introduced HTTP specific promises which does not catch all exceptions, but HTTP ones. Every other exception will be thrown immediately.
Stability configuration from composer
This release brings a cleaner exception concept which is documented directly in the interfaces.
This release brings a cleaner exception concept which is documented directly in the interfaces.
There is also an initial support for discovering HTTP Clients using Puli.
https://github.com/php-http/promise
https://github.com/php-http/promise
Thanks to @joelwurtz we now have an asynchronous client and a promise in the contract.
Thanks to @joelwurtz we now have an asynchronous client and a promise in the contract.
Our plugin architecture will use this functionality.
After 7 months of work, we are proud to present our HTTP Client contract to the world.
Yay, finally we got here.
After 7 months of work, we are proud to present our HTTP Client contract to the world.
Although this started as a project providing adapters to already existing HTTP Clients, the goal changed to a more general approach.
getName methodUpdated promise dependency to RC1
This is the first preview release of the Http Adapter contract
This is the first preview release of the Http Adapter contract
One column per quarter.