PHPackages                             jfalque/http-mock-guzzle - 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. [Testing &amp; Quality](/categories/testing)
4. /
5. jfalque/http-mock-guzzle

AbandonedArchivedLibrary[Testing &amp; Quality](/categories/testing)

jfalque/http-mock-guzzle
========================

Integrates jfalque/http-mock into Guzzle

v1.0.0(9y ago)07.1k1MITPHPPHP &gt;=7

Since Feb 5Pushed 5y ago1 watchersCompare

[ Source](https://github.com/julienfalque/http-mock-guzzle)[ Packagist](https://packagist.org/packages/jfalque/http-mock-guzzle)[ RSS](/packages/jfalque-http-mock-guzzle/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (6)Versions (2)Used By (0)

HttpMock Guzzle Integration
===========================

[](#httpmock-guzzle-integration)

[![Build status](https://camo.githubusercontent.com/e1421681be3c6af38868e18f5942b7e50fa65aa756c62a9a0b7865dcb35daaa7/68747470733a2f2f7472617669732d63692e6f72672f6a756c69656e66616c7175652f687474702d6d6f636b2d67757a7a6c652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/julienfalque/http-mock-guzzle)[![Latest Stable Version](https://camo.githubusercontent.com/e7a1609986a5aa10655aaaf7269ea74b505e03a8050539381ca07a84db71815e/68747470733a2f2f706f7365722e707567782e6f72672f6a66616c7175652f687474702d6d6f636b2d67757a7a6c652f762f737461626c65)](https://packagist.org/packages/jfalque/http-mock-guzzle)[![License](https://camo.githubusercontent.com/ee02942750520c4d22ba513262d6a8019dddf76c82f8d9304e53a7c7b3f6f14f/68747470733a2f2f706f7365722e707567782e6f72672f6a66616c7175652f687474702d6d6f636b2d67757a7a6c652f6c6963656e7365)](https://packagist.org/packages/jfalque/http-mock-guzzle)

**This package is archived and not maintained anymore.**

Provides a [Guzzle](https://github.com/guzzle/guzzle) handler that integrates [HttpMock](https://github.com/julienfalque/http-mock).

Installation
------------

[](#installation)

Run the following [Composer](https://getcomposer.org) command:

`$ composer require --dev jfalque/http-mock-guzzle`

Usage
-----

[](#usage)

The easiest way to use the HttpMock handler is to create a default stack with the dedicated `HttpMockHandler::createStack()` method:

```
use GuzzleHttp\Client;
use Jfalque\HttpMock\Guzzle\HttpMockHandler;
use Jfalque\HttpMock\Server;

$server = new Server();

$client = new Client([
    'handler' => HttpMockHandler::createStack($server),
]);
```

The handler can be created manually and used with an existing stack:

```
$server = new Server();
$handler = new HttpMockHandler($server);
$stack->setHandler($handler);
```

Or injected in a client without using a stack:

```
$server = new Server();
$client = new Client([
    'handler' => new HttpMockHandler($server),
]);
```

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

Established project with proven stability

 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

3435d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1736542?v=4)[Julien Falque](/maintainers/julienfalque)[@julienfalque](https://github.com/julienfalque)

---

Top Contributors

[![julienfalque](https://avatars.githubusercontent.com/u/1736542?v=4)](https://github.com/julienfalque "julienfalque (15 commits)")

---

Tags

guzzlehttpmockpsr-7testhttptestGuzzlemock

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/jfalque-http-mock-guzzle/health.svg)

```
[![Health](https://phpackages.com/badges/jfalque-http-mock-guzzle/health.svg)](https://phpackages.com/packages/jfalque-http-mock-guzzle)
```

###  Alternatives

[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k38](/packages/neuron-core-neuron-ai)[blastcloud/guzzler

Supercharge your app or SDK with a testing library specifically for Guzzle.

272469.9k42](/packages/blastcloud-guzzler)[ikwattro/guzzle-stereo

Guzzle Recorder for recording Request/Responses and replay them back in a Mock

782.6k1](/packages/ikwattro-guzzle-stereo)[aeris/guzzle-http-mock

A mock library for verifying requests made with the Guzzle Http Client, and mocking responses.

2613.1k1](/packages/aeris-guzzle-http-mock)[doppiogancio/mocked-client

A simple way to mock a client

1975.8k5](/packages/doppiogancio-mocked-client)[protomock/protomock

Mocking native PHP requests (file\_get\_contents(), ...)

2027.9k](/packages/protomock-protomock)

PHPackages © 2026

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