https://github.com/netesy/yii2-bulksms
Access bulksms api for the popular nigerian bulksms websites
https://github.com/netesy/yii2-bulksms
yii2-extension
Last synced: 2 months ago
JSON representation
Access bulksms api for the popular nigerian bulksms websites
- Host: GitHub
- URL: https://github.com/netesy/yii2-bulksms
- Owner: netesy
- License: mit
- Created: 2018-01-18T20:33:54.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-13T20:11:59.000Z (over 6 years ago)
- Last Synced: 2025-02-09T22:29:28.900Z (4 months ago)
- Topics: yii2-extension
- Language: PHP
- Size: 7.81 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://packagist.org/packages/netesy/yii2-bulksms)
[](https://packagist.org/packages/netesy/yii2-bulksms)
[](https://packagist.org/packages/netesy/yii2-bulksms)
[](https://www.github.com/netesy)
[](https://www.github.com/netesy)
[](https://www.yiiframework.com/)A Yii2 extension to handle sending messages for most Nigerian bulksms http api connections
===================================================================================
A Yii2 extension to handle sending messages for most Nigerian bulksms http api connectionsInstallation
------------The preferred way to install this extension is through [composer](http://getcomposer.org/download/).
Either run
```
php composer require netesy/yii2-bulksms
```or add
```
"netesy/yii2-bulksms": "*"
```to the require section of your `composer.json` file.
Supported websites
-----
[NigerianBulkSMS](http://nigerianbulksms.com/)[BetaSMS](http://betasms.com/)
Usage
-----Once the extension is installed, simply use it in your code by :
first add to config.php
```php
[
'bulksms' => [
'class' => 'netesy\bulksms\BulkSms',
'username' => 'xxxxxxxx',
'password' => 'xxxxxxxx',
'sender' => 'sender number',
'url' => 'the api address',
],
]
?>
```Once the extension is installed, simply use it in your code by :
to send a message
```php
bulksms->sendMessage([
'number' => $number,
'message' => 'message',
]);
?>
```
to send a call
```php
bulksms->sendCall([
'number' => $number,
'message' => 'message',
]);
?>
```to get your account balance
```php
bulksms->getBalance();
?>
```