huangdijia/laravel-sms

sms for laravel
7,340 2
Install
composer require huangdijia/laravel-sms
Latest Version:1.1.7
PHP:>=7.2.0
License:MIT
Last Updated:Nov 24, 2020
Links: GitHub  ·  Packagist
Maintainer: huangdijia

Laravel-sms

Latest Stable Version Total Downloads GitHub license

Installation

Install package

composer require huangdijia/laravel-sms

Install configure

php artisan sms:install

Uage

Simple to send a message

use Huangdijia\Sms\Facades\Sms;

Sms::to('phone number')->content('message content')->send();

Check send result

$response = Sms::to('phone number')->content('message content')->send();

if ($response->successful()) {
    // success
}

Throwing Exceptions

$response = Sms::to('phone number')->content('message content')->send();

$response->throw();

Switch sms factory

Sms::use('another')->to('phone number')->content('message content')->send();

With Validate Rules

Sms::withRules([
    'to'      => 'required|numeric|....',
    'content' => 'required|...',
], [
    'to.required'      => ':attribute cannot be empty!',
    'content.required' => ':attribute cannot be empty!',
    // more messages
])->to()->content()->send();

Related Packages

laravel-notification-channels/twilio

Provides Twilio notification channel for Laravel

9,360,230 259
rinvex/laravel-authy

Rinvex Authy is a simple wrapper for Authy TOTP, the best rated Two-Factor Authe...

78,344 32
toplan/laravel-sms

A mobile phone number validation solution based on laravel

80,792 836
laravel-notification-channels/authy

Authy notification channel for Laravel, with the ability to send in-app, sms, an...

46,708 57
kavenegar/laravel

laravel 4 and 5 kavenegar integration

373,485 86

Version History

Version Released PHP Laravel License
1.1.7 >=7.2.0 ^7.0|^8.0 MIT
1.1.6 >=7.2.0 ^7.0|^8.0 MIT
1.1.5 >=7.2.0 ^7.0|^8.0 MIT
1.1.4 >=7.2.0 ^7.0|^8.0 MIT
1.1.3 >=7.2.0 ^7.0|^8.0 MIT