new SmsMultiSender(appid, appkey)
SmsMultiSender
Parameters:
Name | Type | Description |
---|---|---|
appid |
string | sdk appid |
appkey |
string | sdk appkey |
Methods
send(number, nationCode, phoneNumber, msg, extend, ext, callback)
Send a SMS messages to multiple phones at once
Parameters:
Name | Type | Description |
---|---|---|
number |
number | SMS message type, Enum{0: normal SMS, 1: marketing SMS} |
nationCode |
string | nation dialing code, e.g. China is 86, USA is 1 |
phoneNumber |
array | phone number array |
msg |
string | SMS message content |
extend |
string | extend field, default is empty string |
ext |
string | ext field, content will be returned by server as it is |
callback |
function | request handler, method signature: function(error, response, responseData) |
sendWithParam(nationCode, phoneNumbers, templId, params, sign, extend, ext, callback)
Send a SMS messages with template parameters to multiple phones at once
Parameters:
Name | Type | Description |
---|---|---|
nationCode |
string | nation dialing code, e.g. China is 86, USA is 1 |
phoneNumbers |
array | multiple phone numbers |
templId |
number | template id |
params |
array | template parameters |
sign |
string | SMS user sign |
extend |
string | extend field, default is empty string |
ext |
string | ext field, content will be returned by server as it is |
callback |
function | request handler, signature: function(error, response, responseData) |