PHPackages                             cline/throw - 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. [Testing &amp; Quality](/categories/testing)
4. /
5. cline/throw

ActiveLibrary[Testing &amp; Quality](/categories/testing)

cline/throw
===========

Fluent conditional exception throwing for Laravel

2.0.2(2mo ago)01.2k↓30.5%MITPHPPHP ^8.5.0CI passing

Since Mar 4Pushed 2mo agoCompare

[ Source](https://github.com/faustbrian/throw)[ Packagist](https://packagist.org/packages/cline/throw)[ RSS](/packages/cline-throw/feed)WikiDiscussions 2.x Synced 1mo ago

READMEChangelog (1)Dependencies (16)Versions (11)Used By (0)

[![GitHub Workflow Status](https://github.com/faustbrian/throw/actions/workflows/quality-assurance.yaml/badge.svg)](https://github.com/faustbrian/throw/actions)[![Latest Version on Packagist](https://camo.githubusercontent.com/2b090873ca0ffccfdac7046af0512652a783d43db7da420915087c68d447be81/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f636c696e652f7468726f772e737667)](https://packagist.org/packages/cline/throw)[![Software License](https://camo.githubusercontent.com/784362b26e4b3546254f1893e778ba64616e362bd6ac791991d2c9e880a3a64e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d677265656e2e737667)](LICENSE.md)[![Total Downloads](https://camo.githubusercontent.com/cbac3d60bd1fec3eed0a8af28391db6fdbec97d9256c678a2fb8e4991942d8de/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f636c696e652f7468726f772e737667)](https://packagist.org/packages/cline/throw)

---

Fluent conditional exception throwing for Laravel. Provides a readable, chainable API for throwing exceptions and aborting requests based on conditions.

Requirements
------------

[](#requirements)

> **Requires [PHP 8.5+](https://php.net/releases/)**

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

[](#installation)

```
composer require cline/throw
```

Documentation
-------------

[](#documentation)

- **[Getting Started](DOCS.md#doc-docs-readme)** - Installation and basic usage
- **[Basic Usage](DOCS.md#doc-docs-basic-usage)** - Throwing exceptions conditionally
- **[HTTP Responses](DOCS.md#doc-docs-http-responses)** - Aborting requests with status codes
- **[Integration Patterns](DOCS.md#doc-docs-integration-patterns)** - Using with Laravel exceptions

Change log
----------

[](#change-log)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

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

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) and [CODE\_OF\_CONDUCT](CODE_OF_CONDUCT.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please use the [GitHub security reporting form](https://github.com/faustbrian/throw/security) rather than the issue queue.

Credits
-------

[](#credits)

- [Brian Faust](https://github.com/faustbrian)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

46

—

FairBetter than 93% of packages

Maintenance88

Actively maintained with recent releases

Popularity20

Limited adoption so far

Community6

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

Every ~12 days

Recently: every ~26 days

Total

10

Last Release

61d ago

Major Versions

1.4.1 → 2.0.02026-03-04

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/22145591?v=4)[Brian Faust](/maintainers/faustbrian)[@faustbrian](https://github.com/faustbrian)

---

Top Contributors

[![faustbrian](https://avatars.githubusercontent.com/u/22145591?v=4)](https://github.com/faustbrian "faustbrian (9 commits)")

---

Tags

php

###  Code Quality

TestsPest

Static AnalysisPHPStan, Rector

Code StyleLaravel Pint

Type Coverage Yes

### Embed Badge

![Health badge](/badges/cline-throw/health.svg)

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

###  Alternatives

[vimeo/psalm

A static analysis tool for finding errors in PHP applications

5.8k77.5M6.7k](/packages/vimeo-psalm)[larastan/larastan

Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel

6.4k43.5M5.2k](/packages/larastan-larastan)[dave-liddament/sarb

Provides tools for baselining static analysis results and comparing against that baseline

1651.4M](/packages/dave-liddament-sarb)[letsdrink/ouzo-goodies

Utility classes, test assertions and mocking framework extracted from Ouzo framework.

132617.9k7](/packages/letsdrink-ouzo-goodies)[quizlet/hammock

Hammock is a stand-alone mocking library for Hacklang.

27445.5k](/packages/quizlet-hammock)[doppiogancio/mocked-client

A simple way to mock a client

2174.9k3](/packages/doppiogancio-mocked-client)

PHPackages © 2026

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