apolinux / kannel
kannel mo/mt 基本功能
v0.7
2024-06-21 15:47 UTC
Requires
- php: >=7.4
- apolinux/curl: ^0.7.6
- apolinux/validator: ^0.5.2
Requires (Dev)
- phpunit/phpunit: 9.*
README
发送MT和读取MO
发送MT
使用SendMt::send函数发送MT消息。
SendMt::send(string $url, string $username, string $password, string $from, string $to, string $text, string $smsc=null, array $params = [], float $timeout=60);
- $url是目标地址
- $username和$password是凭证
- $from是消息的来源,通常是短码
- $to是消息的目标,msisdn
- $text是消息的内容
- $smsc为可选。指定kannel中配置的SMSC中心名称。
- $params是可选值,如charset、udh、flash。
使用apolinux/curl库。
待办事项
ReadMo类的待处理代码