PHPackages                             tjventurini/graphql-exceptions - 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. tjventurini/graphql-exceptions

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

tjventurini/graphql-exceptions
==============================

Client save exceptions for lighthouse-php graphql implementation.

v0.0.7(5y ago)31.8k1MITPHP

Since Oct 26Pushed 5y ago1 watchersCompare

[ Source](https://github.com/tjventurini/graphql-exceptions)[ Packagist](https://packagist.org/packages/tjventurini/graphql-exceptions)[ RSS](/packages/tjventurini-graphql-exceptions/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (1)Versions (8)Used By (0)

Graphql Exceptions
==================

[](#graphql-exceptions)

Better client save exceptions for the lighthouse-php graphql implementation.

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

[](#installation)

```
composer require tjventurini/graphql-exceptions

```

Usage
-----

[](#usage)

The `GraphQLExceptions` facade provides a convenient `wrap` method that accepts a `Closure` that you can use to put your logic in. If a thrown error matches the exceptions provided in the configuration it will resolve it to a client save graphql exception.

```
use Tjventurini\GraphQLExceptions\Facades\GraphqlExceptions;

GraphQLExceptions::wrap(function() {
    // your logic
});
```

Configuration
-------------

[](#configuration)

In the `graphql-exceptions` configuration you can define the default exception to throw and an exception map that we use to resolve the thrown exception with a client save exception.

```
    /*
     |--------------------------------------------------------------------------
     | Exception Map
     |--------------------------------------------------------------------------
     |
     | In the following array you can add exceptions to be resolved.
     |
    */

    'exception_map' => [
        Illuminate\Validation\ValidationException::class            => Tjventurini\GraphQLExceptions\Exceptions\ClientSaveValidationGraphQLException::class,
        Illuminate\Database\Eloquent\ModelNotFoundException::class  => Tjventurini\GraphQLExceptions\Exceptions\ClientSaveModelNotFoundGraphQLException::class,
        Illuminate\Auth\AuthenticationException::class              => Tjventurini\GraphQLExceptions\Exceptions\ClientSaveAuthenticationGraphQLException::class,
    ],

    /*
     |--------------------------------------------------------------------------
     | Default Exception
     |--------------------------------------------------------------------------
     |
     | The following exception will be thrown when no matching exception was
     | found in the exception map.
     |
    */

    'default_exception' => Tjventurini\GraphQLExceptions\Exceptions\ClientSaveInternalGraphQLException::class,
```

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity49

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

Recently: every ~9 days

Total

7

Last Release

1947d ago

### Community

Maintainers

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

---

Top Contributors

[![tjventurini](https://avatars.githubusercontent.com/u/4708070?v=4)](https://github.com/tjventurini "tjventurini (12 commits)")

### Embed Badge

![Health badge](/badges/tjventurini-graphql-exceptions/health.svg)

```
[![Health](https://phpackages.com/badges/tjventurini-graphql-exceptions/health.svg)](https://phpackages.com/packages/tjventurini-graphql-exceptions)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[renatomarinho/laravel-page-speed

Laravel Page Speed

2.5k1.7M11](/packages/renatomarinho-laravel-page-speed)[illuminate/pagination

The Illuminate Pagination package.

12234.1M1.0k](/packages/illuminate-pagination)[illuminate/pipeline

The Illuminate Pipeline package.

9349.2M277](/packages/illuminate-pipeline)[illuminate/broadcasting

The Illuminate Broadcasting package.

7127.2M208](/packages/illuminate-broadcasting)[illuminate/redis

The Illuminate Redis package.

8314.6M369](/packages/illuminate-redis)

PHPackages © 2026

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