donwel-systems/clickatell
Composer 安装命令:
composer require donwel-systems/clickatell
包简介
A package to send sms via Clickatell Sms Gateway
README 文档
README
PhP Package for sennding sms via Clickatell on both the old Communicator Central (http://api.clickatell.com) and the new Clickatell Platorm (https://platform.clickatell.com) using the https(s) protocol The Rest API for the new Clickatell Platform is not supported in this Package #Usage
- Run composer require donwel-systems/clickatell
- Run php artisan vendor:publish
- Choose the DonwelSystems\Clickatell\ClickatellServiceProvider and hit enter.
- Edit the config/clickatell.php file accordingly
- Edit config/app.php and add the ClickatellServiceProvider and 'ClickatellFacade' classes to the providers and aliases arrays
'providers' => [ ..... DonwelSystems\Clickatell\ClickatellServiceProvider::class ] 'aliases' => [ ... 'Clickatell' => DonwelSystems\Clickatell\Facades\ClickatellFacade::class,
- In your code, to send an Sms use
Clickatell::send($to,$message)
The Clickatell::send method returns an associative array i) If the message is successfully sent, the array
["result"=>'success', "code"=>'$code'];
is returned; where $code contains the unqiue message ID from clickatell
ii) If the message is no successfully sent, or an error occurs, the array
["result"=>'error', "code"=>'$code'];
is returned; where $code contains the error message.
统计信息
- 总下载量: 6
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-09-18