PHPackages                             soloslee/json-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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. soloslee/json-response

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

soloslee/json-response
======================

JSON-API response for Laravel

v1.0.0(9y ago)892MITPHPPHP &gt;=5.3.2

Since Feb 14Pushed 8y ago1 watchersCompare

[ Source](https://github.com/soloslee/json-response)[ Packagist](https://packagist.org/packages/soloslee/json-response)[ RSS](/packages/soloslee-json-response/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (2)Versions (2)Used By (0)

Json Response
=============

[](#json-response)

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

[](#installation)

Install using composer:

```
composer require soloslee/json-response
```

Laravel (optional)
------------------

[](#laravel-optional)

Add the service provider in `config/app.php`:

```
'Soloslee\JsonResponse\JsonResponseServiceProvider::class',
```

And add the JsonResponse alias to `config/app.php`:

```
'JsonResponse' => Soloslee\JsonResponse\Facades\JsonResponse::class,
```

Basic Usage
-----------

[](#basic-usage)

Start by creating an `JsonResponse` instance (or use the `JsonResponse` Facade if you are using Laravel):

```
use Soloslee\JsonResponse\JsonResponse;

return JsonResponse::success();
```

### Success

[](#success)

```
JsonResponse::success([
    'id' => $user->id,
    'phone' => $user->phone,
    'email' => $user->email,
    'authorized' => $user->cleaner,
    'token' => $user->token
]);
```

### Error

[](#error)

```
JsonResponse::error('Fails to send message.', 602);
```

License
-------

[](#license)

Laravel Json Response is licensed under [MIT license](http://opensource.org/licenses/MIT).

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

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

Unknown

Total

1

Last Release

3377d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/262691e70f6f5036b1ab6ed8ee7886a3f783e5d5eafd73002e27cd27de992466?d=identicon)[solo](/maintainers/solo)

---

Top Contributors

[![lzyim](https://avatars.githubusercontent.com/u/22696410?v=4)](https://github.com/lzyim "lzyim (2 commits)")

---

Tags

json-responselaraveljson

### Embed Badge

![Health badge](/badges/soloslee-json-response/health.svg)

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

###  Alternatives

[sbsaga/toon

🧠 TOON for Laravel — a compact, human-readable, and token-efficient data format for AI prompts &amp; LLM contexts. Perfect for ChatGPT, Gemini, Claude, Mistral, and OpenAI integrations (JSON ⇄ TOON).

6115.6k](/packages/sbsaga-toon)[json-mapper/laravel-package

The JsonMapper package for Laravel

25170.4k3](/packages/json-mapper-laravel-package)

PHPackages © 2026

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