PHPackages                             zynqa/filament-notifications - 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. [Admin Panels](/categories/admin)
4. /
5. zynqa/filament-notifications

ActiveLibrary[Admin Panels](/categories/admin)

zynqa/filament-notifications
============================

Admin notification management system for FilamentPHP

0.2.0(2mo ago)019MITPHPPHP ^8.2

Since Feb 16Pushed 2mo agoCompare

[ Source](https://github.com/zynqa/filament-notifications)[ Packagist](https://packagist.org/packages/zynqa/filament-notifications)[ RSS](/packages/zynqa-filament-notifications/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (6)Versions (4)Used By (0)

Filament Notifications
======================

[](#filament-notifications)

[![Latest Version on Packagist](https://camo.githubusercontent.com/f41e7fc328fe5ac7d42ec2938ef11d8f15b089b022ee5f9e3db522584d0561b0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7a796e71612f66696c616d656e742d6e6f74696669636174696f6e732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/zynqa/filament-notifications)[![Total Downloads](https://camo.githubusercontent.com/3a996b8bb74743749ee21ea9f387909ee9dcc90ee3477e53ccc1b21c5c95bc16/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7a796e71612f66696c616d656e742d6e6f74696669636174696f6e732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/zynqa/filament-notifications)

A FilamentPHP v3 package for creating and managing custom notifications sent to users through your admin panel. Send database and email notifications with read tracking, customizable templates, and full Shield integration.

Features
--------

[](#features)

- **Database &amp; Email Delivery** - Send notifications via database (notification bell) or email
- **Custom Email Templates** - Create and manage custom email templates with full Blade support
- **Draft &amp; Send Workflow** - Save as draft, review, then send when ready
- **Read Tracking** - Track which users have read each notification
- **Multi-User Selection** - Send to one or multiple users at once
- **Customizable Appearance** - Choose from 13+ heroicons and colors
- **Shield Integration** - Full permission system integration
- **Soft Deletes** - Complete audit trail with soft delete support

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

[](#requirements)

- PHP 8.2+
- Laravel 11.0+
- FilamentPHP 3.2+

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

[](#installation)

### 1. Install via Composer

[](#1-install-via-composer)

```
composer require zynqa/filament-notifications
```

### 2. Run Migrations

[](#2-run-migrations)

```
php artisan migrate
```

This creates:

- `admin_notifications` - Notification content and metadata
- `notification_recipients` - Recipient tracking with read status
- `notification_settings` - Email template preferences

### 3. Register Plugin

[](#3-register-plugin)

Add to your Filament Panel Provider (e.g., `app/Providers/Filament/AppPanelProvider.php`):

```
use Zynqa\FilamentNotifications\FilamentNotificationsPlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            FilamentNotificationsPlugin::make(),
        ])
        ->databaseNotifications(); // Required for notification bell
}
```

### 4. Add User Model Relationships

[](#4-add-user-model-relationships)

Add to `app/Models/User.php`:

```
use Zynqa\FilamentNotifications\Models\AdminNotification;

public function adminNotifications(): \Illuminate\Database\Eloquent\Relations\BelongsToMany
{
    return $this->belongsToMany(AdminNotification::class, 'notification_recipients')
        ->withPivot('read_at')
        ->withTimestamps()
        ->orderByPivot('created_at', 'desc');
}

public function unreadAdminNotifications(): \Illuminate\Database\Eloquent\Relations\BelongsToMany
{
    return $this->adminNotifications()->wherePivotNull('read_at');
}
```

### 5. Configure Permissions (Optional)

[](#5-configure-permissions-optional)

If using Filament Shield:

```
php artisan shield:generate --all
```

Then assign `admin::notification` permissions to roles via the Shield UI.

Usage
-----

[](#usage)

### Creating and Sending Notifications

[](#creating-and-sending-notifications)

1. Navigate to **Notifications** in your admin panel
2. Click **Create**
3. Fill in the form:
    - **Title** - Brief headline
    - **Body** - Detailed message
    - **Delivery Method** - Database (bell) or Email &amp; Database
    - **Type** - Info, Success, Warning, or Danger
    - **Icon** &amp; **Color** - Choose from available options
    - **Recipients** - Select one or more users
4. Click **Create** (saves as draft)
5. Review and click **Send Notification**

Recipients will see the notification in their notification bell (database) or receive an email, depending on the delivery method selected.

### Email Templates

[](#email-templates)

#### Using Existing Templates

[](#using-existing-templates)

1. Navigate to **Settings** → **General Settings**
2. Scroll to **Notification Settings**
3. Select your preferred template from the dropdown
4. Click **Save**

#### Creating Custom Templates

[](#creating-custom-templates)

Email templates are stored in `storage/app/mail-templates/` and are automatically discovered.

**Step 1:** Create a new Blade file in `storage/app/mail-templates/`

Example: `storage/app/mail-templates/urgent-alert.blade.php`

**Step 2:** Use the available variables in your template:

```

    {{ $title }}

        body { font-family: Arial, sans-serif; }
        .container { max-width: 600px; margin: 0 auto; padding: 20px; }
        .alert {
            background-color: {{ $notification_type === 'danger' ? '#fee' : '#efe' }};
            padding: 20px;
            border-radius: 8px;
        }

            {{ $title }}
            {!! nl2br(e($body)) !!}

            @if($url)
                View Details
            @endif

            {{ config('app.name') }}

```

**Available Variables:**

- `$title` (string) - Notification title
- `$body` (string) - Notification body text
- `$url` (string|null) - Optional action URL
- `$notification_type` (string) - 'info', 'success', 'warning', or 'danger'
- `$icon` (string) - Heroicon name (e.g., 'heroicon-o-bell')
- `$icon_color` (string) - 'primary', 'success', 'warning', 'danger', 'info', or 'gray'

**Step 3:** Save the file

The template will automatically appear in the General Settings dropdown with a formatted name (e.g., "Urgent Alert").

**Tips:**

- Use inline CSS for best email client compatibility
- Always escape user content with `e()` or `{!! nl2br(e($body)) !!}`
- Test across different email clients
- Keep designs simple and mobile-friendly

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

[](#configuration)

Optionally publish the config file:

```
php artisan vendor:publish --tag="filament-notifications-config"
```

Customize navigation, permissions, and icons in `config/filament-notifications.php`.

Permissions
-----------

[](#permissions)

When using Filament Shield, these permissions are created:

- `view_any_admin::notification` - View notifications list
- `view_admin::notification` - View individual notification
- `create_admin::notification` - Create new notifications
- `update_admin::notification` - Edit drafts
- `delete_admin::notification` - Delete drafts
- `restore_admin::notification` - Restore soft-deleted notifications
- `force_delete_admin::notification` - Permanently delete notifications

**Note:** Sent notifications are read-only and cannot be edited or deleted.

Support
-------

[](#support)

- **Issues:** [GitHub Issues](https://github.com/zynqa/filament-notifications/issues)
- **Email:**

License
-------

[](#license)

MIT License. See [LICENSE.md](../LICENSE.md) for details.

###  Health Score

36

—

LowBetter than 82% of packages

Maintenance84

Actively maintained with recent releases

Popularity8

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity38

Early-stage or recently created project

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

Total

3

Last Release

81d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1080386?v=4)[Raul Watson](/maintainers/diazwatson)[@diazwatson](https://github.com/diazwatson)

---

Top Contributors

[![diazwatson](https://avatars.githubusercontent.com/u/1080386?v=4)](https://github.com/diazwatson "diazwatson (5 commits)")

### Embed Badge

![Health badge](/badges/zynqa-filament-notifications/health.svg)

```
[![Health](https://phpackages.com/badges/zynqa-filament-notifications/health.svg)](https://phpackages.com/packages/zynqa-filament-notifications)
```

###  Alternatives

[awcodes/filament-quick-create

Plugin for Filament Admin that adds a dropdown menu to the header to quickly create new items.

246177.6k7](/packages/awcodes-filament-quick-create)[guava/filament-knowledge-base

A filament plugin that adds a knowledge base and help to your filament panel(s).

206120.5k1](/packages/guava-filament-knowledge-base)[ralphjsmit/laravel-filament-seo

A package to combine the power of Laravel SEO and Filament Admin.

15398.7k10](/packages/ralphjsmit-laravel-filament-seo)[bezhansalleh/filament-google-analytics

Google Analytics integration for FilamentPHP

205144.8k5](/packages/bezhansalleh-filament-google-analytics)[kirschbaum-development/commentions

A package to allow you to create comments, tag users and more

12369.2k](/packages/kirschbaum-development-commentions)[geo-sot/filament-env-editor

Access .env file though Filament admin panel

2432.3k1](/packages/geo-sot-filament-env-editor)

PHPackages © 2026

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