Download the PHP package yhshanto/walletmix-sms-channel without Composer
On this page you can find all versions of the php package yhshanto/walletmix-sms-channel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download yhshanto/walletmix-sms-channel
More information about yhshanto/walletmix-sms-channel
Files in yhshanto/walletmix-sms-channel
Package walletmix-sms-channel
Short Description Walletmix Notification Channel for laravel.
License MIT
Informations about the package walletmix-sms-channel
Walletmix Sms Channel
Prerequisites
Before start, you must know about Laravel Notifications. You can check here.. https://laravel.com/docs/5.8/notifications
Before you can send notifications via Walletmix, you need to install the yhshanto/walletmix-sms-channel Composer package:
Next, you will need to add a few configuration options to your config/services.php configuration file. You may copy the example configuration below to get started:
The from option is the phone number or mask that your SMS messages will be sent from. You can contact with Walletmix for more info.
Formatting SMS Notifications
If a notification supports being sent as an SMS, you should define a toWalletmix method on the notification class. This method will receive a $notifiable entity and should return a YHShanto\WalletmixSMS\Messages\WalletmixMessage instance:
Unicode Content
If your SMS message will contain unicode characters, you should call the unicode method when constructing the WalletmixMessage instance:
Customizing The "From" Number
If you would like to send some notifications from a phone number/mask that is different from the phone number/mask specified in your config/services.php file, you may use the from method on a WalletmixMessage instance:
Routing SMS Notifications
When sending notifications via the walletmix channel, the notification system will automatically look for a phone attribute on the notifiable entity. If you would like to customize the phone number the notification is delivered to, define a routeNotificationForWalletmix method on the entity: