2017 © Pedro Peláez
 

library sms

Send SMS easy

image

socialconnect/sms

Send SMS easy

  • Thursday, April 14, 2016
  • by ovr
  • Repository
  • 2 Watchers
  • 1 Stars
  • 78 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

SocialConnect SMS

Supported providers

  • [x] Nexmo
  • [x] MessageBird
  • [x] SMS.RU

Installation

Add a requirement to your composer.json:, (*1)

{
    "require": {
        "socialconnect/sms": "*"
    }
}

Run the composer installer:, (*2)

php composer.phar install

How to work

First, you need to setup ProviderFactory:, (*3)

use SocialConnect\Common\Http\Client\Curl;
use SocialConnect\SMS\ProviderFactory;

include_once __DIR__ . '/vendor/autoload.php';

$service = new ProviderFactory(
    array(
        'provider' => array(
            'smsru' => array(
                'appId' => 12345
            )
        )
    ),
    new Curl()
);

Next, you need to get provider:, (*4)

/** @var \SocialConnect\SMS\Provider\SMSRU $provider */
$provider = $service->factory('smsru');

You can send sms:, (*5)

$provider->send('+79999999', 'Hello, World!');

Or get balance:, (*6)

var_dump($provider->getBalance());

License

This project is open-sourced software licensed under the MIT License., (*7)

See the LICENSE file for more information., (*8)

The Versions

14/04 2016

dev-master

9999999-dev

Send SMS easy

  Sources   Download

MIT

The Requires

 

The Development Requires

14/04 2016

0.1.1

0.1.1.0

Send SMS easy

  Sources   Download

MIT

The Requires

 

The Development Requires

19/01 2016

dev-scrutinizer-patch-1

dev-scrutinizer-patch-1

Send SMS easy

  Sources   Download

MIT

The Requires

 

The Development Requires

05/11 2015

0.1.0

0.1.0.0

Send SMS easy

  Sources   Download

MIT

The Requires