---
title: "Artisan commands — Notifications for Laravel | Roundly"
description: "notifications:sweep, prune, types, doctor, install and reminders:sync — what each does, the doctor’s checks and the facade equivalents."
url: https://roundly-consulting.com/open-source/docs/notifications-for-laravel/commands
language: en
---

[All packages](https://roundly-consulting.com/open-source.md)

[Notifications for Laravel](https://roundly-consulting.com/open-source/docs/notifications-for-laravel.md)

# Artisan commands

| Command | Does |
| --- | --- |
| `notifications:sweep {--only=}` | Expire stale claims, release due mail (held, trailing, retries, held interop mail), start due digests, fire due reminders and escalations. --only=claims,deliveries,digests,reminders,escalations. Prints the SweepReport. |
| `notifications:prune` | Force-delete old rows in chunks: read and archived (or deleted) inbox items, terminal deliveries, finished digest runs with no live entry, terminal reminders with no pending or firing escalation (after the prune.\* durations), and receipts after idempotency.ttl. |
| `notifications:types` | The registry: key, category, channels, priority, flags, window, reminder rules. |
| `notifications:doctor` | Checks the setup and exits non-zero on an error (see below). |
| `notifications:install` | Publishes the config and the migrations (refuses when a configured table exists) and prints the schedule lines and trait snippets. |
| `notifications:reminders:sync {type?}` | Backfill: schedules reminders for every subject of a type’s class — every type with reminder rules when omitted. |

```bash
php artisan notifications:sweep
php artisan notifications:sweep --only=deliveries,digests
php artisan notifications:prune
php artisan notifications:types
php artisan notifications:doctor
php artisan notifications:install
php artisan notifications:reminders:sync contract.expiring
```

## Scheduling

Nothing is auto-scheduled:

```php
// routes/console.php
use Illuminate\Support\Facades\Schedule;

Schedule::command('notifications:sweep')->everyMinute()->withoutOverlapping(10)->onOneServer();
Schedule::command('notifications:prune')->daily();
```

## From PHP

```php
$report = Notifications::sweep();                   // SweepReport: deliveries, digests, reminders, escalations, expired
Notifications::sweep(['reminders', 'escalations']);
$pruned = Notifications::prune();                   // PruneReport: inboxItems, deliveries, digestRuns, reminders, receipts, total()

Notifications::deliveries()->dispatchDue();         // int
Notifications::digests()->sendDue();                // int
Notifications::reminders()->fireDue();              // FiredReminders: reminders, escalations
```

## What the doctor checks

| Level | Finding |
| --- | --- |
| error | notifications.key\_type differs from options.key\_type. |
| info | The queue connection is sync: mail, digests and fan-out run inline. Also prints the schedule line. |
| warning | The preference lock store uses the array or file driver — not shared across servers. |
| error | A config value that does not read (e.g. invalid default quiet hours). |
| error | A type whose subject has no policy while the ability is not defined — the first send throws. |
| error / warning | Interop: a map to an unknown type or a broken time-critical guard (errors); a digestible mapped type, a subject type without subjectFrom() (warnings). |
| error / warning | The user model cannot be mailed (error) or is not Authenticatable (warning). |

## Show 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 crypto](https://roundly-consulting.com/support-us.md)

By donating, you agree to our [donation terms](https://roundly-consulting.com/donation-terms.md).

[Support our open source work (opens in a new tab)](https://donate.stripe.com/dRmeVe8FX5PF1Qd9pXcEw00) [Join us on Patreon (opens in a new tab)](https://www.patreon.com/cw/roundly)

## 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.

[Get a quote in 48 hours](https://roundly-consulting.com/contact.md) [Browse all packages](https://roundly-consulting.com/open-source/docs/notifications-for-laravel.md)
