PHPackages                             nekofar/slim-jsend - 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. nekofar/slim-jsend

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

nekofar/slim-jsend
==================

Slim Framework response helper for JSend specification.

v1.0.0-alpha.21(2y ago)13.4k[5 PRs](https://github.com/nekofar/slim-jsend/pulls)MITPHPPHP &gt;=8.1

Since Sep 26Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/nekofar/slim-jsend)[ Packagist](https://packagist.org/packages/nekofar/slim-jsend)[ Fund](https://ud.me/nekofar.crypto)[ RSS](/packages/nekofar-slim-jsend/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (7)Versions (30)Used By (0)

Slim JSend Helper
=================

[](#slim-jsend-helper)

[![Packagist Version](https://camo.githubusercontent.com/a189d94667e05f883f1c2fa261ffd72c643bd666cef7687b64eec9b97739df42/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6e656b6f6661722f736c696d2d6a73656e643f696e636c7564655f70726572656c6561736573)](https://packagist.org/packages/nekofar/slim-jsend)[![PHP from Packagist](https://camo.githubusercontent.com/6770a635a3dfbe2725ba8cfc03b0157d948b5e3ea517f6da9323d77b11f963e0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6e656b6f6661722f736c696d2d6a73656e642e737667)](https://packagist.org/packages/nekofar/slim-jsend)[![Tests Status](https://camo.githubusercontent.com/222509ac351baab413681b6363048241c30befd32914b615f3c31f0daf686aa0/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6e656b6f6661722f736c696d2d6a73656e642f74657374732e796d6c)](https://github.com/nekofar/slim-jsend/actions/workflows/tests.yml)[![Coverage Status](https://camo.githubusercontent.com/9a1f8156752065491fcbe62cc3d5fd27a663c69b0c89eca8d7419efc2d45f5c0/68747470733a2f2f636f6465636f762e696f2f67682f6e656b6f6661722f736c696d2d6a73656e642f67726170682f62616467652e737667)](https://codecov.io/gh/nekofar/slim-jsend)[![License](https://camo.githubusercontent.com/69a38953edf28594bb73bc4f98262fdb4bebca65794f5eaea14938b467fc8bab/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6e656b6f6661722f736c696d2d6a73656e642e737667)](https://github.com/nekofar/slim-jsend/blob/master/LICENSE.md)[![Twitter: nekofar](https://camo.githubusercontent.com/57201a0ecd7d9a2b7fe07039ddd3b199b96f44859a6e3c70b582a9d8d33cd535/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f666f6c6c6f772d2534306e656b6f6661722d3144413146323f6c6f676f3d74776974746572267374796c653d666c6174)](https://twitter.com/nekofar)[![Donate](https://camo.githubusercontent.com/37edcc3611ba8f5c0bbb34b51d9be5652f211c0df2eaaa2d078b6a3b640b0d5b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f646f6e6174652d6e656b6f6661722e63727970746f2d6132623962633f6c6f676f3d6b6f2d6669266c6f676f436f6c6f723d7768697465)](https://ud.me/nekofar.crypto)

> Slim Framework response helper for JSend specification.

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

[](#installation)

To get started, install the package using composer:

```
composer require nekofar/slim-jsend
```

Requires Slim Framework 4 and PHP 8.1 or newer.

Usage
-----

[](#usage)

```
use Nekofar\Slim\JSend\ResponseFactoryDecorator;

$responseFactoryDecorator = new ResponseFactoryDecorator(/* ... */);
$response = $responseFactoryDecorator->createResponse();

// Set success payload
$response = $response->withSuccessPayload($data);
echo $response->getBody()->getContents(); // The response body
```

The resulting response will have the HTTP status code 200 OK and the JSON payload in the JSend format:

```
{
  "status": "success",
  "data": {
    /* Your data here */
  }
}
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE) for more information.

---

###  Health Score

38

—

LowBetter than 85% of packages

Maintenance59

Moderate activity, may be stable

Popularity18

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 83.9% 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 ~30 days

Recently: every ~10 days

Total

22

Last Release

1046d ago

PHP version history (3 changes)v1.0.0-alpha.0PHP ^7.3 || ^8.0

v1.0.0-alpha.9PHP ^7.4 || ^8.0

v1.0.0-alpha.10PHP &gt;=8.1

### Community

Maintainers

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

---

Top Contributors

[![nekofar](https://avatars.githubusercontent.com/u/147401?v=4)](https://github.com/nekofar "nekofar (177 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (34 commits)")

---

Tags

helperjsendphpslimslim-framework

### Embed Badge

![Health badge](/badges/nekofar-slim-jsend/health.svg)

```
[![Health](https://phpackages.com/badges/nekofar-slim-jsend/health.svg)](https://phpackages.com/packages/nekofar-slim-jsend)
```

###  Alternatives

[bryanjhv/slim-session

Session middleware and helper for Slim framework 4.

233961.5k16](/packages/bryanjhv-slim-session)[docler-labs/codeception-slim-module

Codeception Module for Slim framework.

13178.0k1](/packages/docler-labs-codeception-slim-module)

PHPackages © 2026

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