PHPackages                             cherry-project/response - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. cherry-project/response

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

cherry-project/response
=======================

Cherry-project Response class

v1.0.1(7y ago)0741MITPHPPHP &gt;=5.6.0

Since Mar 5Pushed 7y ago1 watchersCompare

[ Source](https://github.com/cherry-framework/response)[ Packagist](https://packagist.org/packages/cherry-project/response)[ Docs](https://github.com/ABGEO07/cherry-response)[ RSS](/packages/cherry-project-response/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (2)DependenciesVersions (4)Used By (1)

Cherry-Response
===============

[](#cherry-response)

The Cherry-project Response wrapper

[![GitHub license](https://camo.githubusercontent.com/2f030eb5bdb3a432e788303c9bf37d783ee49758a326aa65e8b541161a73fb84/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f616267656f30372f6368657272792d726573706f6e73652e737667)](https://github.com/ABGEO07/cherry-response/blob/master/LICENSE)

[![GitHub release](https://camo.githubusercontent.com/6fe721fe460226fd2fac90d789ecc2b5dc43fb45d851e83f80bedcbb848b9829/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f616267656f30372f6368657272792d726573706f6e73652e737667)](https://github.com/ABGEO07/cherry-response/releases)

[![Packagist Version](https://camo.githubusercontent.com/8e2585222290b6a9dcc7a1ceb8e0378eba32d77f92e840988c0be057a2488371/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6368657272792d70726f6a6563742f726573706f6e73652e737667 "Packagist Version")](https://packagist.org/packages/cherry-project/response "Packagist Version")

---

Including
---------

[](#including)

**Install from composer** `composer require cherry-project/response`

**Include Autoloader in your main file** (Ex.: index.php)

```
require_once __DIR__ . '/vendor/autoload.php';
```

Class Request
-------------

[](#class-request)

Import class

```
use Cherry\HttpUtils\Response;
```

Crete class new object

```
$response = new Response();
```

Prepare data for transmission (Ex.: Array)

```
$arr = [
    'test' => 'vTest',
    'test2' => [
        'test2.1' => '2.1',
        'test2.2' => [
            'test2.2.1' => '2.2.1'
        ]
    ]
];
```

For sending response use **sendResponse()** method

The method takes 3 arguments:

- Content (**Required**; Mixed) - The data for returning;
- Status Code (**Optional**; 200 by default; Integer) - The HTTP Status Code;
- HTTP Headers (**Optional**; empty by default; Key `=>` Value Array) - The HTTP Headers;

```
echo $response->sendResponse(json_encode($arr), 200, ['Content-Type' => 'application/json']);
```

**2019 © Cherry-project**

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

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 ~22 days

Total

2

Last Release

2604d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/003cac08dd47c34ad3a5ed454c2968ed6afea9e26d57033867d4166fa08b3555?d=identicon)[ABGEO](/maintainers/ABGEO)

---

Top Contributors

[![ABGEO](https://avatars.githubusercontent.com/u/19558543?v=4)](https://github.com/ABGEO "ABGEO (11 commits)")

---

Tags

cherrycomposerresponseresponsecherry

### Embed Badge

![Health badge](/badges/cherry-project-response/health.svg)

```
[![Health](https://phpackages.com/badges/cherry-project-response/health.svg)](https://phpackages.com/packages/cherry-project-response)
```

###  Alternatives

[erlandmuchasaj/laravel-gzip

Gzip your responses.

40129.3k2](/packages/erlandmuchasaj-laravel-gzip)

PHPackages © 2026

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