PHPackages                             alcamo/http - 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. alcamo/http

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

alcamo/http
===========

Extension of some laminas classes, in particular to stream process output

0.11.2(3mo ago)0154↓50%2Apache-2.0PHPPHP 7.3 - 8.0

Since Jun 30Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/rv1971/alcamo-http)[ Packagist](https://packagist.org/packages/alcamo/http)[ RSS](/packages/alcamo-http/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (7)Versions (22)Used By (2)

Usage examples
==============

[](#usage-examples)

FileResponse
------------

[](#fileresponse)

```
use alcamo\http\FileResponse;

$response = FileResponse::newFromPath('/srv/www/htdocs/foo.xml');

$response->emit();

```

This sends an HTTP response with `Content-Type` and `Content-Length`headers. It may be more efficient than doing the same thing simply with `Laminas\Diactoros\Response` because is sends the file via `fpassthru()`, without need to keep the entire file content in memory.

PipeStream
----------

[](#pipestream)

```
use alcamo\http\{PipeStream, Response};
use alcamo\process\OutputProcess;

$stream = new PipeStream(new OutputProcess('/usr/bin/convert foo.png jpeg:-'));

$response = new Response(
    [ [ 'dc:format', 'image/jpeg' ] ],
    $stream
);

$response->emit();

```

This sends an HTTP response with `Content-Type` header. Again, it may be more efficient than doing the same thing simply with `Laminas\Diactoros\Response` because is sends the file via `fpassthru()`, without need to keep the entire data in memory.

The example also illustrates a possible use of the `Response` class, giving RDFa metadata which is automatically converted into HTTP headers.

Simple status page
------------------

[](#simple-status-page)

```
use alcamo\http\Response;

$response = Response::newFromStatusAndText(403);

$response->emit();

```

This will send an HTTP response with `Content-Type: text/plain` and `Content-Length` header, with status code 403 and the text "Forbidden".

###  Health Score

43

—

FairBetter than 91% of packages

Maintenance81

Actively maintained with recent releases

Popularity13

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity56

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

Every ~88 days

Recently: every ~10 days

Total

20

Last Release

99d ago

PHP version history (2 changes)0.1PHP 7.3 - 7.4

0.1.1PHP 7.3 - 8.0

### Community

Maintainers

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

---

Top Contributors

[![rv1971](https://avatars.githubusercontent.com/u/39520256?v=4)](https://github.com/rv1971 "rv1971 (26 commits)")

---

Tags

httpprocess

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

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

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

###  Alternatives

[hhxsv5/laravel-s

🚀 LaravelS is an out-of-the-box adapter between Laravel/Lumen and Swoole.

3.9k676.0k10](/packages/hhxsv5-laravel-s)[http-interop/http-factory-guzzle

An HTTP Factory using Guzzle PSR7

581167.2M519](/packages/http-interop-http-factory-guzzle)[kevinrob/guzzle-cache-middleware

A HTTP/1.1 Cache for Guzzle 6. It's a simple Middleware to be added in the HandlerStack. (RFC 7234)

43417.4M104](/packages/kevinrob-guzzle-cache-middleware)[mezzio/mezzio

PSR-15 Middleware Microframework

3883.6M97](/packages/mezzio-mezzio)[graham-campbell/guzzle-factory

Provides A Simple Guzzle Factory With Good Defaults

916.4M49](/packages/graham-campbell-guzzle-factory)[laminas/laminas-psr7bridge

Bidirectional conversions between PSR-7 and laminas-http messages

117.9M18](/packages/laminas-laminas-psr7bridge)

PHPackages © 2026

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