2017 © Pedro Peláez
 

library sms-otp

SMS OTP for Laravel 5 using iSMS gateway.

image

aqlx86/sms-otp

SMS OTP for Laravel 5 using iSMS gateway.

  • Monday, May 29, 2017
  • by aqlx86
  • Repository
  • 1 Watchers
  • 0 Stars
  • 528 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 4 Versions
  • 2 % Grown

The README.md

Introduction

SMS OTP for Laravel 5. By default this uses iSMS as SMS provider., (*1)

Installation

Add sms-otp to your composer.json file:, (*2)

composer.phar require "aqlx86/sms-otp"

Add the service provider to your Laravel application config/app.php:, (*3)

SMSOTP\SMSOTPServiceProvider::class

Publish

php artisan vendor:publish --provider="SMSOTP\SMSOTPServiceProvider"
php artisan migrate

Usage

To send OTP, remember to include :code this will be replaced with the actual code., (*4)

$sender = app()->make(OTPSender::class);
$sender->send('6399512345678', 'holy shit your otp code is :code');

To verify OTP code, (*5)

$verifier = app()->make(OTPVerifier::class);
$verifier->verify('6399512345678', 'A44E8');

Extending

Using other SMS provider

Create your sms provider, (*6)

class CustomSMSProvider implemnts SMSOTP\Contract\SMSGateway
{
    public function send($number, $message)
    {
        // your implemention
    }
}

Update configuration config/smsotp.php, (*7)

'sms' => CustomSMSProvider::class,

Generating your own OTP code

Do the same as creating your own SMS provider., (*8)

The Versions

29/05 2017

dev-master

9999999-dev https://github.com/aqlx86/sms-otp

SMS OTP for Laravel 5 using iSMS gateway.

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel sms otp isms

29/05 2017

v1.2

1.2.0.0 https://github.com/aqlx86/sms-otp

SMS OTP for Laravel 5 using iSMS gateway.

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel sms otp isms

26/05 2017

v1.1

1.1.0.0 https://github.com/aqlx86/sms-otp

SMS OTP for Laravel 5 using iSMS gateway.

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel sms otp isms

25/05 2017

v1.0

1.0.0.0 https://github.com/aqlx86/sms-otp

SMS OTP for Laravel 5 using iSMS gateway.

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel sms otp isms