Artisan commands
requests:expire
Expire open requests whose deadline has passed — a thin wrapper over Requests::expireDue():
php artisan requests:expire # expire all open, past-due requests
php artisan requests:expire --dry-run # report only, change nothing
php artisan requests:expire --chunk=1000| Option | Default | Effect |
|---|---|---|
--dry-run | off | Report how many requests would expire; change nothing and lapse no approval decisions or rounds. |
--chunk= | 500 | Requests processed per batch (chunkById); values below 1 are raised to 1. |
After expiring requests (not on a dry run), the command calls Approvals::expire() scoped to the request model, lapsing the approval decisions and rounds on requests whose own expiry has passed — the rest of your app’s approvals are left alone. It reports what it did:
Would expire 3 request(s). # --dry-run
Expired 3 request(s).
Lapsed 2 expired approval decision(s). # only when decisions lapsedabout
The package contributes a Requests section to Laravel’s about command — the configured model (class basename only), the transition guard (ENFORCED or OFF), the default TTL (for example 90 min, or NONE) and the facade alias (Requests or DISABLED):
php artisan about --only=requestsShow your open-source love
This package is free and MIT-licensed. If it saves you time, a one-off donation or a Patreon membership keeps it maintained, tested and documented.
More ways to support, including cryptoBy donating, you agree to our donation terms.
Want this built into your product?
We integrate our packages into custom Laravel and AI builds. Tell us what you're working on and we'll reply within 48 hours.