Skip to content

HasanAlyazidi/laravel-sendables

Repository files navigation

laravel-sendables

Software License Travis Total Downloads

Install

  1. Add package to your composer.json
composer require hasanalyazidi/laravel-sendables
  1. Migrate package tables or publish migrations first then migrate
php artisan migrate

Publish package files

Publish config file (Required)

php artisan vendor:publish --provider="HasanAlyazidi\Sendables\Providers\SendablesServiceProvider" --tag="config"

Publish migrations (Optional)

php artisan vendor:publish --provider="HasanAlyazidi\Sendables\Providers\SendablesServiceProvider" --tag="migrations"

Publish language resources (Optional)

English

php artisan vendor:publish --provider="HasanAlyazidi\Sendables\Providers\SendablesServiceProvider" --tag="resources-lang-en"

Arabic

php artisan vendor:publish --provider="HasanAlyazidi\Sendables\Providers\SendablesServiceProvider" --tag="resources-lang-ar"

All supported languages

php artisan vendor:publish --provider="HasanAlyazidi\Sendables\Providers\SendablesServiceProvider" --tag="resources-lang-all"

Usage

SMS

$sms = new SMSNotification('SMS Message', '966000000000');
$sms->send();

OTP

$otp = new OtpVerifier('966000000000');
$otp->send();
  • WhatsApp:
    Add a message template named otp_code, type (Authentication) with your app supported languages.

Contributing

Please see CONTRIBUTING for details.

Security

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

License

The MIT License (MIT). Please see License File for more information.