2017 © Pedro Peláez
 

library sms

Several Nigerian SMS APIs integration

image

adetoola/sms

Several Nigerian SMS APIs integration

  • Wednesday, March 29, 2017
  • by adetoola
  • Repository
  • 1 Watchers
  • 1 Stars
  • 47 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

SMS

SMS is a succinct and flexible way to add Nigerian SMS providers integration to nodejs apps., (*1)

Contents

Installation

Getting started with SMS is quite easy, just install using your favourite package manager., (*2)

Using Yarn

``` bash yarn add @adetoola/sms, (*3)


##### Using NPM ``` bash npm install @adetoola/sms

Available SMS Gateway

You can specify any of the supported sms gateway from the list below:, (*4)

  • [x] Test (Use as a test account)
  • [x] SMS247Live
  • [ ] XWireless
  • [ ] 50Kobo
  • [ ] SMSTube

``` js import SMS from '@adetoola/SMS';, (*5)

const sms = new SMS('SMSLive247');, (*6)


### SMS Gateway Credentials Each SMS service provider will give authorised users a set of credentials to use when sending SMS or interacting with their services. ```env # Test SMS_SENDER='YOUR_SENDER_NAME_HERE' # SMS247Live SMS_SENDER='YOUR_SENDER_NAME_HERE' SMS_SESSION_ID='YOUR_SESSION_ID_HERE'

Usage

Using SMS is quite simple., (*7)

const sms = new SMS('SMSLive247');
sms.sender(sender).country(country).credentials(credentials);

const messageId = sms.send('08123456789', 'NG', 'Hi, I am using Adetoola SMS package');

console.log(messageId);

Methods

Method SMS247LIVE
SMS::send(recipient, msg [, msg_type]) +
SMS::schedule(recipient, msg, datetime[, msg_type]) +
SMS::balance() +
SMS::charge(msg_id) +
SMS::status(msg_id) +
SMS::coverage(recipient) +
SMS::stop(msg_id) +
SMS::history() +

Valid Formats

Input Description Accepted Formats
recipient Comma separated numbers, number or array +2348012345678, 2348012345678, 8012345678, 0812345678
country "Country" is a two-letter ISO country code (like NG) [AZ]{2}
msg Text message which will be sent to the numbers. [a-zA-Z0-9+_-."'\s]{1,160}
sender Number to display as sender [a-zA-Z0-9_-]{1,11}
msg_type Normal SMS, Flash or MMS TEXT, FLASH, MMS
datetime Datetime in format Y-m-d H:i:s. 2016-03-16 22:40:34
msg_id Message ID, provider by gateway [a-zA-Z0-9]

Example

``` js, (*8)

coming soon!

```, (*9)

Change log

Please see CHANGELOG for more information what has changed recently., (*10)

Contributing

Please see CONTRIBUTING and CONDUCT for details., (*11)

Security

If you discover any security related issues, please email adetola.onasanya@gmail.com instead of using the issue tracker., (*12)

Credits

License

SMS is an open-sourced package licensed under the MIT license., (*13)

The Versions

29/03 2017

dev-feature-guzzle-client

dev-feature-guzzle-client https://github.com/adetoola/sms

Several Nigerian SMS APIs integration

  Sources   Download

MIT

The Requires

 

The Development Requires

sms message adetoola msg sms api

28/03 2017

dev-develop

dev-develop https://github.com/adetoola/sms

Several Nigerian SMS APIs integration

  Sources   Download

MIT

The Requires

  • php ~7.0

 

The Development Requires

sms message adetoola msg sms api

28/03 2017

dev-master

9999999-dev https://github.com/adetoola/sms

Several Nigerian SMS APIs integration

  Sources   Download

MIT

The Requires

  • php ~7.0

 

The Development Requires

sms message adetoola msg sms api

28/03 2017

1.1.1

1.1.1.0 https://github.com/adetoola/sms

Several Nigerian SMS APIs integration

  Sources   Download

MIT

The Requires

  • php ~7.0

 

The Development Requires

sms message adetoola msg sms api

28/03 2017

1.1.0

1.1.0.0 https://github.com/adetoola/sms

Several Nigerian SMS APIs integration

  Sources   Download

MIT

The Requires

  • php ~7.0

 

The Development Requires

sms message adetoola msg sms api

16/03 2016

1.0.0

1.0.0.0 https://github.com/adetoola/sms

Several Nigerian SMS APIs integration

  Sources   Download

MIT

The Requires

 

sms message adetoola msg sms api