zarulizham/onewaysms

OneWaySMS package

dev-master 2019-01-18 02:57 UTC

This package is auto-updated.

Last update: 2024-05-09 13:02:37 UTC


README

Installation

You can pull in the package via composer:

composer require zarulizham/OneWaySMS

Installation (Laravel 5.5 and below)

Then add this line to config/app.php in providers

OneWaySMS\SmsServiceProvider::class,

Store username and password credentials in .env or simply put in make() (see example below)

Additional .env attributes

ONEWAY_USERNAME=
ONEWAY_PASSWORD=

Usage

Example 1

use OneWaySMS\SMS

SMS::to("0123456789")->message("Hello there!")->send();

There is no need to use make() if credential stored in .env

Example 2

use OneWaySMS\SMS

SMS::make([
    'username' => 'yourusernamehere',
    'password' => 'yourpasswordhere',
])->to("0123456789")->message("Hello there!")->send();