PHPackages                             innovatoranant/wirehttp - 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. innovatoranant/wirehttp

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

innovatoranant/wirehttp
=======================

WireHTTP - A blazing-fast, zero-dependency, Fiber-driven PHP 8.2+ HTTP client. The next evolution beyond Guzzle.

v1.1.0(1mo ago)01MITPHPPHP ^8.2

Since Jun 28Pushed 1mo agoCompare

[ Source](https://github.com/innovatoranant/wirehttp)[ Packagist](https://packagist.org/packages/innovatoranant/wirehttp)[ Docs](https://github.com/wirehttp/wirehttp)[ RSS](/packages/innovatoranant-wirehttp/feed)WikiDiscussions main Synced 2w ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

 [![PHP](https://camo.githubusercontent.com/4483bf574aa290f3a83765b3f21279c4478760d0074d01e3a2a79ac14ff4ac7e/68747470733a2f2f75706c6f61642e77696b696d656469612e6f72672f77696b6970656469612f636f6d6d6f6e732f322f32372f5048502d6c6f676f2e737667)](https://camo.githubusercontent.com/4483bf574aa290f3a83765b3f21279c4478760d0074d01e3a2a79ac14ff4ac7e/68747470733a2f2f75706c6f61642e77696b696d656469612e6f72672f77696b6970656469612f636f6d6d6f6e732f322f32372f5048502d6c6f676f2e737667)WireHTTP
========

[](#wirehttp)

 **An Enterprise-Grade, Dependency-Free Asynchronous HTTP Client for PHP 8.1+**

 *Developed by **Anant***

 [![PHP Version](https://camo.githubusercontent.com/600216d73f438f0b3b0145c948ce2795403d012d8d10f2c78f61a2467c244b26/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e312d3737374242343f7374796c653d666c61742d737175617265266c6f676f3d706870266c6f676f436f6c6f723d7768697465)](https://php.net/) [![Zero Dependencies](https://camo.githubusercontent.com/b873ea7799efe02992f5d10f590e80e64d63c339c59a53dfd026c7233465114d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f446570656e64656e636965732d5a45524f2d737563636573733f7374796c653d666c61742d737175617265)](#) [![PHP Fibers](https://camo.githubusercontent.com/d27de22642fd89e2031ba2a469d6723a8801864e33a759f25d7cc4af9442dc69/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f436f6e63757272656e63792d5048505f4669626572732d4646393930303f7374796c653d666c61742d737175617265266c6f676f3d6c696768746e696e67)](#) [![Architecture](https://camo.githubusercontent.com/7a2a02fff069ae2aa508b9d5bfbc495b680cc19aa66164f23beb222414d6dc10/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4172636869746563747572652d5053522d2d372532302537432532305053522d2d31352d626c756576696f6c65743f7374796c653d666c61742d737175617265)](#) [![License](https://camo.githubusercontent.com/7d217ebb91a61cb4d98e70dee31eb08e0a5f71bc518ebd4151a73c6fb1191d00/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d626c75653f7374796c653d666c61742d737175617265)](#)

---

> **WireHTTP** brings true non-blocking concurrency, intelligent fault tolerance, and beautiful object hydration to modern PHP applications. It is engineered from the ground up to handle massive workloads without dragging a single external dependency into your vendor folder.

📊 Feature Matrix
----------------

[](#-feature-matrix)

   ### ⚡ Ultra-Fast

[](#-ultra-fast)

Built natively on `ext-curl`. Send thousands of requests concurrently using Fibers and `curl_multi`.

  ### 🛡️ Resilient

[](#️-resilient)

Built-in **Circuit Breakers**, proactive Rate Limiting, and Exponential Backoff Retries.

  ### 🧬 Intelligent

[](#-intelligent)

Automatically decodes JSON/XML and directly hydrates nested **DTO Objects**.

🏛️ Architecture &amp; Data Flow
-------------------------------

[](#️-architecture--data-flow)

WireHTTP's core is an ultra-fast, array-based `MiddlewareStack`. Requests flow symmetrically through Interceptors, hitting the Transport layer, and returning as beautifully decorated objects.

 ```
graph TD
    %% Styling
    classDef facade fill:#2D3748,stroke:#4A5568,stroke-width:2px,color:#fff,rx:10,ry:10;
    classDef middleware fill:#3182CE,stroke:#2B6CB0,stroke-width:2px,color:#fff,rx:10,ry:10;
    classDef network fill:#38A169,stroke:#2F855A,stroke-width:2px,color:#fff,rx:10,ry:10;
    classDef target fill:#E53E3E,stroke:#C53030,stroke-width:2px,color:#fff,rx:10,ry:10;

    subgraph Application Space
        A["Developer APIWire::get()"]:::facade
    end

    subgraph WireHTTP Pipeline
        B["Middleware Stack(Rate Limit, Retry, Circuit Breaker)"]:::middleware
        C["Transport Layerext-curl / Fibers"]:::network
        D["Response DecoratorJSON / XML / DTO Hydration"]:::middleware
    end

    subgraph External
        E((Remote API)):::target
    end

    A ==>|Build Request| B
    B ==>|Apply Interceptors| C
    C ==>|Execute Asynchronously| E
    E -.->|Raw HTTP Response| C
    C -.->|Reverse Interceptors| D
    D ==>|Hydrated Object| A
```

      Loading
💻 Developer Experience (DX)
---------------------------

[](#-developer-experience-dx)

**1. Clean &amp; Fluent Request Builder**
No more massive configuration arrays. Construct your requests using a highly readable, chainable API.

```
use WireHttp\Wire;

$response = Wire::post('https://api.example.com/billing')
    ->withBearer('secret_token')
    ->withHeader('X-Client', 'MobileApp')
    ->withJson(['plan' => 'enterprise', 'users' => 500])
    ->timeout(5.0) // Request-specific timeout override
    ->send();

if ($response->isClientError()) {
    throw new Exception($response->json()['message']);
}
```

**2. True Asynchronous Concurrency**
Send massive batches of requests concurrently. WireHTTP uses `Fiber` under the hood—no callbacks required, your code stays linear.

```
use WireHttp\Wire;
use WireHttp\Async\Future;

// Dispatch 3 non-blocking network requests
$users   = Wire::get('https://api.example.com/users')->sendAsync();
$stats   = Wire::get('https://api.example.com/stats')->sendAsync();
$reports = Wire::get('https://api.example.com/reports')->sendAsync();

// Block the current Fiber until ALL requests settle
[$resUsers, $resStats, $resReports] = Future::all(...[$users, $stats, $reports]);

echo $resUsers->status(); // 200
```

**3. Direct DTO Hydration**
Skip manual array parsing. WireHTTP maps JSON directly to strongly-typed PHP objects.

```
use WireHttp\Response\Hydrator\Attributes\JsonProperty;

class ProfileDto {
    public int $id;

    // Map mismatched JSON keys seamlessly
    #[JsonProperty('avatar_url')]
    public string $avatarUrl;
}

// Automatically decodes JSON, validates types, and returns the DTO!
$profile = Wire::get('https://api.example.com/me')->send()->into(ProfileDto::class);

echo $profile->avatarUrl;
```

**4. Stateful Cookie &amp; Redirect Interceptors**
WireHTTP behaves like a real browser when you want it to.

```
use WireHttp\Wire;
use WireHttp\Configuration\ClientConfig;
use WireHttp\Middleware\Core\CookieJar;

$client = Wire::with(
    ClientConfig::create()
        ->withFollowRedirects(true, maxRedirects: 5)
        ->withCookies(true, new CookieJar())
);

// 1. Logs in and receives a Set-Cookie header
$client->post('/login')->withForm(['user' => 'admin'])->send();

// 2. Automatically injects the Cookie into subsequent requests!
$dashboard = $client->get('/dashboard')->send()->body();
```

🧪 Zero-Network Mocking Engine
-----------------------------

[](#-zero-network-mocking-engine)

Testing external APIs shouldn't require an internet connection or fragile mock objects. WireHTTP includes a powerful global mock interceptor.

```
use WireHttp\Wire;
use WireHttp\Transport\Mock\MockResponseQueue;
use WireHttp\Http\Response;
use WireHttp\Http\Stream;

$queue = new MockResponseQueue();
$queue->push(new Response(201, [], Stream::fromString('{"status": "created"}')));

// Hijack the transport layer globally
Wire::fake($queue);

// This executes instantly and returns the mock response!
$response = Wire::post('https://api.example.com/charge')->send();

assert($response->json()['status'] === 'created');
```

---

**WireHTTP** - Engineered for Resilience, Built for Speed.

Released under the [MIT License](LICENSE).

###  Health Score

37

—

LowBetter than 81% of packages

Maintenance91

Actively maintained with recent releases

Popularity1

Limited adoption so far

Community2

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

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

Every ~0 days

Total

2

Last Release

45d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/eda7afceac8f0a6f6cd03196ca89ed0928c6400a1c7ac09a8581b6d493322a53?d=identicon)[innovatoranant](/maintainers/innovatoranant)

---

Tags

httppsr-7asyncclientcurlpsr-18psr-14sseretrycircuit breakerfiberzero-dependency

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/innovatoranant-wirehttp/health.svg)

```
[![Health](https://phpackages.com/badges/innovatoranant-wirehttp/health.svg)](https://phpackages.com/packages/innovatoranant-wirehttp)
```

###  Alternatives

[react/http

Event-driven, streaming HTTP client and server implementation for ReactPHP

78028.1M486](/packages/react-http)[amphp/http-client-psr7

PSR-7 adapter for Amp's HTTP client.

1392.6k8](/packages/amphp-http-client-psr7)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28153.9k](/packages/phpro-http-tools)[vultr/vultr-php

The Official Vultr API PHP Wrapper.

2249.3k1](/packages/vultr-vultr-php)[pdeans/http

PSR-7 cURL HTTP client with support for PSR-17 HTTP factories.

1466.6k3](/packages/pdeans-http)[chillerlan/php-httpinterface

A PSR-7/17/18 http message/client implementation

1419.2k8](/packages/chillerlan-php-httpinterface)

PHPackages © 2026

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