kop/yii2-turbosms

A Yii2 component for working with TurboSMS.ua SOAP service

Installs: 2 960

Dependents: 0

Suggesters: 0

Security: 0

Stars: 1

Watchers: 2

Forks: 0

Open Issues: 0

Type:yii2-extension

1.0.2 2014-10-20 08:27 UTC

This package is auto-updated.

Last update: 2024-10-10 21:07:36 UTC


README

TurboSMS component gives you an ability to send SMS messages via TurboSMS.ua SMS gateway.

This component is built with use of TurboSMS SOAP service.

Latest Stable Version Code Climate Scrutinizer Code Quality Version Eye License

Requirements

  • Yii 2.0
  • PHP 5.4
  • PHP extension SOAP

Installation

The preferred way to install this extension is through Composer.

Either run

php composer.phar require kop/yii2-turbosms "dev-master"

or add

"kop/yii2-turbosms": "dev-master"

to the require section of your composer.json file.

Setup

All you need is to declare a new component in your application configuration file like follows:

return [
    ...
    'components' => [
        ...
        'sms' => [
            'class' => '\kop\y2ts\TurboSMS',
            'username' => '<<< YOUR USERNAME HERE >>>'
            'password' => '<<< YOUR PASSWORD HERE >>>',
            'alphaName' => 'MyWebsite',
        ]
        ...
    ]
    ...
];

Configuration

username

The username used for authentication on TurboSMS SOAP service.

password

The password used for authentication on TurboSMS SOAP service.

alphaName

The name that users will see as the message sender name.

Usage

As simple as:

Yii::$app->sms->send(['+380501234567', '+380502345678'], 'Hello world!');

Please refer to the class documentation for more methods and options.

Report

License

yii2-turbosms is released under the MIT License. See the bundled LICENSE.md for details.

Resources