PHPackages                             mcbankske/filament-sms-notifier - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. mcbankske/filament-sms-notifier

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

mcbankske/filament-sms-notifier
===============================

A reusable Filament plugin for sending SMS notifications via multiple drivers.

v1.4.0(11mo ago)0151MITPHPPHP ^8.2

Since May 31Pushed 11mo agoCompare

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

READMEChangelogDependencies (7)Versions (10)Used By (0)

Filament SMS Notifier
=====================

[](#filament-sms-notifier)

**Filament SMS Notifier** is a flexible and reusable [Filament](https://filamentphp.com) plugin that allows you to send SMS messages using configurable drivers. It includes a simple widget for sending test SMS directly from the Filament admin panel.

[![Latest Version on Packagist](https://camo.githubusercontent.com/0e2bf09e5a6a44a8caecfa648918e3e345fe38dd871a169355958d34434cf868/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d6362616e6b736b652f66696c616d656e742d736d732d6e6f7469666965722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/mcbankske/filament-sms-notifier)[![Total Downloads](https://camo.githubusercontent.com/2bcf295c6cb519dadcd7a1b439a05d2f5ea2ca478cd06361059f712a53870c6b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d6362616e6b736b652f66696c616d656e742d736d732d6e6f7469666965722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/mcbankske/filament-sms-notifier)[![License](https://camo.githubusercontent.com/1f76237950c7ecacc50b718b4749ee45752efcdc917157b5181443e737e89fec/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6d6362616e6b736b652f66696c616d656e742d736d732d6e6f746966696572)](LICENSE.md)[![PHP Version](https://camo.githubusercontent.com/d61aae8206a0da942e26112c0e8ad62801c548973f7a9db1f25468b471752bb8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6d6362616e6b736b652f66696c616d656e742d736d732d6e6f746966696572)](composer.json)

✨ Features
----------

[](#-features)

- ✅ Send SMS from any part of your Laravel application
- 📦 Built-in support for [TextSMS](https://textsms.co.ke)
- 🔌 Easily extendable with custom drivers
- 🛠️ Includes Filament widget for manual SMS testing
- ⚙️ Configurable via `.env` and `config/smsnotifier.php`
- 🚀 Seamless integration with Filament v3

🚀 Quick Start
-------------

[](#-quick-start)

### 1. Installation

[](#1-installation)

Install the package via Composer:

```
composer require mcbankske/filament-sms-notifier
```

### 2. Publish Configuration

[](#2-publish-configuration)

Publish the configuration file:

```
php artisan vendor:publish --tag=filament-sms-notifier-config
```

### 3. Configure Credentials

[](#3-configure-credentials)

Add your TextSMS API credentials to your `.env` file:

```
SMSNOTIFIER_API_KEY=your_api_key_here
SMSNOTIFIER_PARTNER_ID=your_partner_id_here
SMSNOTIFIER_SHORTCODE=YourBrandName  # Optional, defaults to 'TextSMS'
```

⚙️ Configuration
----------------

[](#️-configuration)

The configuration file `config/smsnotifier.php` allows you to customize the SMS gateway settings:

```
return [
    'default' => env('SMSNOTIFIER_DRIVER', 'textsms'),

    'drivers' => [
        'textsms' => [
            'api_key' => env('SMSNOTIFIER_API_KEY'),
            'partner_id' => env('SMSNOTIFIER_PARTNER_ID'),
            'shortcode' => env('SMSNOTIFIER_SHORTCODE', 'TextSMS'),
        ],
        // Add your custom drivers here
    ],
];
```

💡 Basic Usage
-------------

[](#-basic-usage)

### Option 1: Using the Facade (Recommended)

[](#option-1-using-the-facade-recommended)

```
use MCBANKSKE\FilamentSmsNotifier\Facades\SmsNotifier;

// Send an SMS
$response = SmsNotifier::send('254700000000', 'Hello from Filament SMS Notifier!');

if ($response['success']) {
    // SMS sent successfully
} else {
    // Handle error
    logger()->error('Failed to send SMS: ' . $response['message']);
}
```

### Option 2: Using the Helper Function

[](#option-2-using-the-helper-function)

```
// Send an SMS using the helper function
$response = sms('254700000000', 'Hello from the helper function!');

if ($response['success']) {
    // SMS sent successfully
} else {
    // Handle error
    logger()->error('Failed to send SMS: ' . $response['message']);
}
```

### Option 3: Using Dependency Injection

[](#option-3-using-dependency-injection)

```
use MCBANKSKE\FilamentSmsNotifier\Services\SmsService;

public function sendWelcomeSms(SmsService $smsService)
{
    $phoneNumber = '254700000000'; // E.164 format
    $message = 'Welcome to our service!';

    $response = $smsService->send($phoneNumber, $message);

    if ($response['success']) {
        // SMS sent successfully
    } else {
        // Handle error
        logger()->error('Failed to send SMS: ' . $response['message']);
    }
}
```

📊 Filament Integration
----------------------

[](#-filament-integration)

### Adding the Test SMS Widget

[](#adding-the-test-sms-widget)

Add the test SMS widget to any Filament page:

```
use MCBANKSKE\FilamentSmsNotifier\Filament\Widgets\SendTestSmsWidget;

protected function getHeaderWidgets(): array
{
    return [
        SendTestSmsWidget::class,
    ];
}
```

🧩 Creating a Custom Driver
--------------------------

[](#-creating-a-custom-driver)

1. Create a new driver class:

```
namespace App\SmsDrivers;

use MCBANKSKE\FilamentSmsNotifier\Contracts\SmsGatewayDriver;

class MyCustomDriver implements SmsGatewayDriver
{
    public function send(string $to, string $message): array
    {
        // Your implementation here

        return [
            'success' => true,
            'message' => 'SMS sent successfully',
            'data' => [/* response data */]
        ];
    }
}
```

2. Register your driver in `config/smsnotifier.php`:

```
'drivers' => [
    'textsms' => [
        // ... existing config
    ],
    'mycustom' => [
        'driver' => 'mycustom',
        // Add any custom configuration
    ],
],
```

📝 Requirements
--------------

[](#-requirements)

- PHP 8.2 or higher
- Laravel 9.0, 10.0, 11.0, or 12.0
- Filament 3.0 or higher
- GuzzleHTTP 7.0 or higher (installed automatically)

🔐 Security
----------

[](#-security)

If you discover any security related issues, please email  instead of using the issue tracker.

```

2. Register your driver in a service provider's `boot` method:

```php
use App\SmsDrivers\MyCustomDriver;
use MCBANKSKE\FilamentSmsNotifier\Services\SmsService;

public function boot()
{
    app()->when(MyCustomDriver::class)
        ->needs('$config')
        ->giveConfig('smsnotifier.drivers.my-custom');

    app(SmsService::class)->extend('my-custom', function ($app) {
        return new MyCustomDriver(config('smsnotifier.drivers.my-custom'));
    });
}

```

🧱 Package Structure
-------------------

[](#-package-structure)

```
filament-sms-notifier/
├── config/                    # Configuration files
│   └── smsnotifier.php        # Main configuration
├── src/                       # Source files
│   ├── Contracts/             # Interfaces
│   │   └── SmsGatewayDriver.php
│   ├── Drivers/               # Built-in drivers
│   │   └── TextSmsGatewayDriver.php
│   ├── Services/              # Core services
│   │   └── SmsService.php
│   ├── Filament/              # Filament integration
│   │   └── Widgets/
│   │       └── SendTestSmsWidget.php
│   └── SmsNotifierServiceProvider.php  # Service provider
└── resources/                 # Views and assets
    └── views/
        └── widgets/
            └── send-test-sms-widget.blade.php

```

🤝 Contributing
--------------

[](#-contributing)

Contributions are welcome! Please feel free to submit a Pull Request.

1. Fork the repository
2. Create your feature branch (`git checkout -b feature/AmazingFeature`)
3. Commit your changes (`git commit -m 'Add some AmazingFeature'`)
4. Push to the branch (`git push origin feature/AmazingFeature`)
5. Open a Pull Request

📄 License
---------

[](#-license)

This project is open-sourced under the [MIT License](LICENSE.md).

🔗 Links
-------

[](#-links)

- [GitHub Repository](https://github.com/mcbankske/filament-sms-notifier)
- [Packagist](https://packagist.org/packages/mcbankske/filament-sms-notifier)
- [Filament Documentation](https://filamentphp.com/docs)

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance51

Moderate activity, may be stable

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity55

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

Total

9

Last Release

346d ago

PHP version history (3 changes)v1.0.0PHP ^8.0

v1.2.0PHP ^8.1

v1.4.0PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/ea7dacc975a176e4ac4cca9af3d21a703c7a7511b8fd4b18110d8c4098f5880c?d=identicon)[mcbankske](/maintainers/mcbankske)

---

Top Contributors

[![MCBANKSKE](https://avatars.githubusercontent.com/u/154880732?v=4)](https://github.com/MCBANKSKE "MCBANKSKE (17 commits)")

---

Tags

laravelnotificationssmsfilamenttextsms

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/mcbankske-filament-sms-notifier/health.svg)

```
[![Health](https://phpackages.com/badges/mcbankske-filament-sms-notifier/health.svg)](https://phpackages.com/packages/mcbankske-filament-sms-notifier)
```

###  Alternatives

[tzsk/sms

A robust and unified SMS gateway integration package for Laravel, supporting multiple providers.

320244.3k6](/packages/tzsk-sms)[gr8shivam/laravel-sms-api

A modern, flexible Laravel package for integrating any SMS gateway with REST API support

10138.4k](/packages/gr8shivam-laravel-sms-api)[usamamuneerchaudhary/filament-notifier

A powerful notification system for FilamentPHP that handles multi-channel notifications with template management, scheduling, and real-time delivery. Built for developers who need enterprise-grade notifications without the complexity.

321.1k](/packages/usamamuneerchaudhary-filament-notifier)[ghanem/laravel-smsmisr

Send SMS and SMS Notification via SMS Misr for Laravel

194.8k](/packages/ghanem-laravel-smsmisr)

PHPackages © 2026

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