PHPackages                             filipefernandes/laravel-route-retry - 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. filipefernandes/laravel-route-retry

ActiveLibrary

filipefernandes/laravel-route-retry
===================================

A Laravel package to capture and retry failing requests.

0.0.1(4mo ago)2609↓28.6%MITPHPPHP ^8.1CI passing

Since Jan 9Pushed 3mo agoCompare

[ Source](https://github.com/filipefernandes9747/laravel-route-retry)[ Packagist](https://packagist.org/packages/filipefernandes/laravel-route-retry)[ RSS](/packages/filipefernandes-laravel-route-retry/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (8)Versions (2)Used By (0)

Laravel Route Retry
===================

[](#laravel-route-retry)

[![Thumbnail](assets/thumbnail.png)](assets/thumbnail.png)

Laravel Route Retry adds a simple and flexible way to capture failed requests (5xx) and retry them later. It's perfect for handling transient failures in webhooks, external API calls, or any critical route.

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

[](#installation)

You can install the package via composer:

```
composer require filipefernandes/laravel-route-retry
```

You can publish the config file with:

```
php artisan vendor:publish --tag="retry-config"
```

Then, run the migrations:

```
php artisan migrate
```

Usage
-----

[](#usage)

### Simple Route Retry

[](#simple-route-retry)

You can enable retries on any route using the `retry()` macro:

```
use Illuminate\Support\Facades\Route;

Route::post('/webhooks/stripe', function () {
    // If this fails with 5xx, it will be captured
})->retry(3); // Retry up to 3 times
```

### Adding Tags

[](#adding-tags)

Tags help you filter and process retries for specific features:

```
Route::post('/sync-data', [SyncController::class, 'handle'])
    ->retry(5)
    ->tags(['erp', 'priority-high']);
```

### Processing Retries

[](#processing-retries)

To process pending retries, add the following command to your `app/Console/Kernel.php`:

```
$schedule->command('retry:process')->everyMinute();
```

You can also filter retries by tag or ID:

```
php artisan retry:process --tag=erp
php artisan retry:process --id=1 --id=2 --id=3
php artisan retry:process --fingerprint=a8...
```

### Disabling Middleware

[](#disabling-middleware)

If you need to retry requests without running the original route middleware (e.g., if authentication tokens have expired), use the `--without-middleware` option:

```
php artisan retry:process --without-middleware
```

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

[](#configuration)

The published configuration file `config/retry.php` allows you to customize:

- `table_name`: The table where retries are stored.
- `storage_disk`: The disk used for temporary file storage (defaults to `local`).
- `max_retries`: Global default for maximum retry attempts.
- `delay`: The initial delay before the first retry attempt.

Events
------

[](#events)

The package dispatches events throughout the retry lifecycle:

- `LaravelRouteRetry\Events\RequestCaptured`: Dispatched when a failure is first captured.
- `LaravelRouteRetry\Events\RetrySucceeded`: Dispatched when a retry attempt results in a 2xx response.
- `LaravelRouteRetry\Events\RetryFailed`: Dispatched when a retry fails or reaches the maximum limit.

License
-------

[](#license)

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

###  Health Score

37

—

LowBetter than 83% of packages

Maintenance78

Regular maintenance activity

Popularity21

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity33

Early-stage or recently created project

 Bus Factor1

Top contributor holds 80% 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

130d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/44c4a0ab684a6ff2f571c5b6b1db79320570f053120dadb2793c9b8ee41529a3?d=identicon)[filipe9747](/maintainers/filipe9747)

---

Top Contributors

[![ffernandes9747](https://avatars.githubusercontent.com/u/106343739?v=4)](https://github.com/ffernandes9747 "ffernandes9747 (4 commits)")[![filipefernandes9747](https://avatars.githubusercontent.com/u/22693486?v=4)](https://github.com/filipefernandes9747 "filipefernandes9747 (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/filipefernandes-laravel-route-retry/health.svg)

```
[![Health](https://phpackages.com/badges/filipefernandes-laravel-route-retry/health.svg)](https://phpackages.com/packages/filipefernandes-laravel-route-retry)
```

###  Alternatives

[laravel/cashier

Laravel Cashier provides an expressive, fluent interface to Stripe's subscription billing services.

2.5k25.9M107](/packages/laravel-cashier)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[laravel/pulse

Laravel Pulse is a real-time application performance monitoring tool and dashboard for your Laravel application.

1.7k12.1M99](/packages/laravel-pulse)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)[fumeapp/modeltyper

Generate TypeScript interfaces from Laravel Models

196277.9k](/packages/fumeapp-modeltyper)

PHPackages © 2026

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