\app\common\service\sms\driver\alidySmsApi

Summary

Methods
Properties
Constants
__construct()
sendSms()
queryDetails()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$accessKeyId
$accessKeySecret
N/A

Properties

$accessKeyId

$accessKeyId : 

Type

$accessKeySecret

$accessKeySecret : 

Type

Methods

sendSms()

sendSms(string  $signName, string  $templateCode, string  $phoneNumbers, array|null  $templateParam = null, string|null  $outId = null, string|null  $smsUpExtendCode = null) : \stdClass

发送短信

Parameters

string $signName

必填, 短信签名,应严格"签名名称"填写,参考:短信签名页

string $templateCode

必填, 短信模板Code,应严格按"模板CODE"填写, 参考:短信模板页 (e.g. SMS_0001)

string $phoneNumbers

必填, 短信接收号码 (e.g. 12345678901)

array|null $templateParam

选填, 假如模板中存在变量需要替换则为必填项 (e.g. Array("code"=>"12345", "product"=>"阿里通信"))

string|null $outId

[optional] 选填, 发送短信流水号 (e.g. 1234)

string|null $smsUpExtendCode

[optional] 选填,上行短信扩展码(扩展码字段控制在7位或以下,无特殊需求用户请忽略此字段)

Returns

\stdClass

queryDetails()

queryDetails(string  $phoneNumbers, string  $sendDate, integer  $pageSize = 10, integer  $currentPage = 1, string  $bizId = null) : \stdClass

短信发送记录查询

Parameters

string $phoneNumbers

必填, 短信接收号码 (e.g. 12345678901)

string $sendDate

必填,短信发送日期,格式Ymd,支持近30天记录查询 (e.g. 20170710)

integer $pageSize

必填,分页大小

integer $currentPage

必填,当前页码

string $bizId

选填,短信发送流水号 (e.g. abc123)

Returns

\stdClass