Download the PHP package envoisms/laravel-otp without Composer
On this page you can find all versions of the php package envoisms/laravel-otp. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download envoisms/laravel-otp
More information about envoisms/laravel-otp
Files in envoisms/laravel-otp
Package laravel-otp
Short Description Laravel Notification Channel & OTP Package for EnvoiSMS.ma
License MIT
Homepage https://envoisms.ma/fr/docs
Informations about the package laravel-otp
EnvoiSMS Laravel OTP & Notification Channel
Official Laravel Notification Channel & OTP Package for EnvoiSMS.ma — Passerelle SMS & WhatsApp Business and API SMS Maroc.
For full API documentation, visit the Passerelle SMS & WhatsApp Business. For pricing plans and credit packs, visit API SMS Maroc.
Installation
Install via Composer:
Configuration
Add your API credentials to .env:
Optionally publish or add to config/services.php:
Usage in Laravel Notifications
Create a notification class:
Send the notification to any model with a phone or routeNotificationForEnvoiSMS() method:
Plain-text notifications (order status, reminders, alerts)
The channel defaults to sms, and that is the right choice for any ordinary text — even to a customer who uses WhatsApp. ->channel('whatsapp') sends from your own connected WhatsApp Business number: without one the API answers 403 WHATSAPP_NOT_CONNECTED, and free text outside the 24-hour customer window answers 400 OUT_OF_24H_WINDOW. Nothing is charged in either case. A one-time code on WhatsApp is ->asOtp(...)->channel('whatsapp'): it goes through EnvoiSMS's shared sender and needs no connection.
Sends carry an Idempotency-Key (from the underlying PHP SDK), so a queued notification that is retried never bills twice.
Using the Facade Directly
Documentation & Tarifs
- Guides et référence API : Passerelle SMS & WhatsApp Business
- Tarifs et packs SMS Maroc : API SMS Maroc
License
MIT
All versions of laravel-otp with dependencies
illuminate/support Version ^9.0|^10.0|^11.0
illuminate/notifications Version ^9.0|^10.0|^11.0
envoisms/envoisms-php Version ^1.0