danaketh/sms-manager
最新稳定版本:v0.2.2
Composer 安装命令:
composer require danaketh/sms-manager
包简介
PHP library for sending SMS via SmsManager.cz
关键字:
README 文档
README
Library for PHP that can send SMS messages via SmsManager.cz gateway. PHP8 fork of SMSManager. (not all API methods are implemented for now)
Installation
composer require danaketh/sms-manager
Usage
Use SmsManager interface in your code, eg.:
public function __construct(SmsManager $smsManager) { ... }
and alias SMSManager to ApiSmsManager for your production usage.
Example with Symfony:
services: SimPod\SmsManager\SmsManager: alias: SimPod\SmsManager\ApiSmsManager
To send message, create new SmsMessage:
$smsMessage = new SmsMessage( 'message text', [ '+420777888999' ], RequestType::getRequestTypeLow() // optional, defaults to High 'sender' // optional 1 // optional, CustomID ); $smsManager->send($smsMessage);
Third parameter of SmsMessage is RequestType that is represented by RequestType class. Eg. low request type is instantiated with RequestType::getRequestTypeLow().
统计信息
- 总下载量: 1.44k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-12-11