morpheusadam / elanak
allinone sms sender
This package is auto-updated.
Last update: 2026-06-29 13:21:28 UTC
README
๐จ Elanak โ Unified Laravel SMS Sender
One fluent Laravel/PHP interface to send SMS through multiple providers โ Kavenegar, Melipayamak, IPPanel, SMS.ir and Payamresan โ consolidating every panel into a single repository.
๐ Overview
Elanak is a robust Laravel SMS package that sends text messages through multiple SMS service providers behind one consistent, fluent interface. Rather than juggling a separate SDK and a separate panel for every provider, Elanak consolidates all of them into a single repository โ so you can switch gateways by changing one method call, with no rewrite of your sending logic.
Built for the Laravel framework (with a service provider and Elanak facade for auto-discovery), it aims for better ergonomics and performance than scattering several SMS libraries across a project. It supports both simple text messages and pattern / template-based messages (OTP, verification codes, transactional notifications), making it ideal for authentication, alerts, and notification workflows.
๐ Keywords: Laravel SMS, PHP SMS package, send SMS Laravel, SMS gateway Laravel, Kavenegar Laravel, Melipayamak, IPPanel, SMS.ir, Payamresan, OTP SMS, pattern SMS, multi-provider SMS sender.
โจ Features
- ๐ก Multiple providers, one API โ swap gateways with a single
via()call. - ๐งฉ Fluent builder โ chainable
send()->via()->api()->from()->to()->dispatch()syntax. - ๐ข Pattern / template messages โ send OTP and templated SMS with
pattern($code, $values). - ๐งฑ Laravel-native โ auto-registered service provider and
Elanakfacade. - ๐๏ธ Panels consolidated โ every supported SMS panel lives in one repository.
- ๐ชถ Lightweight โ a thin, focused wrapper over each provider's API.
๐ข Supported SMS Providers
The following gateways are implemented under src/Getways/:
| Provider | Driver name |
|---|---|
| Kavenegar | kavenegar |
| Melipayamak | melipayamak |
| IPPanel | ippanel |
| SMS.ir | smsir |
| Payamresan | payamresan |
๐ ๏ธ Tech Stack
| Component | Technology |
|---|---|
| Language | PHP |
| Framework | Laravel (service provider + Elanak facade) |
| Install | Composer (PSR-4: Morpheusadam\Elanak\) |
๐ Getting Started
Install the package
composer require morpheusadam/elanak
Install the provider SDKs you intend to use
composer require kavenegar/laravel composer require melipayamak/laravel:1.0.0 composer require ippanel/php-rest-sdk
To remove Elanak later:
composer remove morpheusadam/elanak
๐ฆ Usage
Send a simple text message
Elanak::send($messages) ->via($provider) // e.g. 'kavenegar', 'melipayamak', 'ippanel', 'smsir', 'payamresan' ->api($api) ->from($sender) ->to('09185312051') ->dispatch();
Send a pattern / template message
Melipayamak
Elanak::send($messages) ->to($to) ->via($providerName) ->api($api) ->pattern($patternCode, $value) ->dispatch();
IPPanel
Elanak::send($messages) ->to($to) ->via($providerName) ->api($api) ->pattern($patternCode, $value) ->from($sender) ->dispatch();
Switch provider
Change the provider simply by changing the via() argument:
->via('melipayamak') ->via('kavenegar') ->via('ippanel') ->via('payamresan') ->via('smsir')
๐ค Contributing
Contributions are welcome! Open an issue or submit a pull request to add a provider, fix a bug, or improve the documentation.
๐ License
Distributed under the MIT License. See the LICENSE file for full terms.
๐ค Author โ Morpheus Adam
Web developer & cheerful hacker ยท PHP ยท Laravel ยท Go
โญ If Elanak made SMS easier in your project, consider giving it a star! โญ