Download the PHP package toonday/laravel-bulksmsnigeria-notification without Composer
On this page you can find all versions of the php package toonday/laravel-bulksmsnigeria-notification. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download toonday/laravel-bulksmsnigeria-notification
More information about toonday/laravel-bulksmsnigeria-notification
Files in toonday/laravel-bulksmsnigeria-notification
Package laravel-bulksmsnigeria-notification
Short Description A laravel channel for bulk nigeria sms provider.
License MIT
Informations about the package laravel-bulksmsnigeria-notification
Laravel Bulk SMS Nigeria(.com)
This is a laravel package for sending sms (or bulk sms) to local (Nigerian) phone numbers for Laravel >=5.3.*.
Installation is pretty straight forward: use either
or add to your composer.json
file:
if using laravel <=5.3.*, add the provider to your app.php
file like so:
Please do not forget to publish the config file with the artisan
command like so:
and you're all good to go.
If you haven't, please proceed to the bulksmsnigeria to register and get your api token
. Then include in your .env
file the following:
The package works just like your typical laravel built in notification package. Just add the notifiable trait to the model using the notification (typically the User model) as highlighted here. Further, you should add this method to the same model so the package can know which property of the model to target:
In your notification class, add the following lines:
To compose your message, you can follow the example below:
The BulkSMSMessage class provides the following methods for you:
Methods | Usage |
---|---|
body |
Content of the message |
from |
If not specified in the .env file, this method will set the from parameter. In the case where it has already been set, it'll take precedence and reset the parameter. |
With all that in place you can proceed to sending your text messages.
Happy coding.
All versions of laravel-bulksmsnigeria-notification with dependencies
illuminate/notifications Version 5.*
guzzlehttp/guzzle Version 5.*|6.*