Skip to main content

Send Voice Message (RESTful API)

Call the batchcalls API to send voice messages.

Request Parameters

Parameter nameTypeDescriptionRequired
accountIdnumberAccount IDYes
batch[]BatchModelBatch Submission of InformationYes

BatchModel

Parameter nameTypeDescriptionDefaultRequired
destinationstringPhone number: +12344232311""Yes
templateIdstringFetch from Console: https://console.uspeedo.com/vms/template""Yes
repetitionnumberDefault non-repeating, enumeration values: 1, 2, 31No

Response Elements

Parameter nameTypeDescriptionDefaultRequired
batchIdstringBatch submission of IDYes
totalCountnumberTotal number of submissions0Yes
acceptedCountnumberTotal number of calls0Yes
failureBatch[]FailurBatchPhone numbers with failed submissions[]No
retCodenumberReturn Code: 0 SUCCESS, others ERROR0Yes
messagestringError message when retCode not equals 0""Yes

FailurBatch

Parameter nameTypeDescriptionDefaultRequired
statusFailurBatchStatusInformation on failed callsYes
destinationstringThe phone number for the call""No

FailurBatchStatus

Parameter nameTypeDescriptionDefaultRequired
codenumber0 SUCCESS, others ERROR0Yes
messagestringError message when code not equals 0""No
timestampnumberSubmission Failure Time0No

Request Body Example

{
"accountId": "120023",
"batch": [
{
"destination": "string",
"repetition": 0,
"templateId": "string"
}
]
}

Response Example

{
"retCode": 0,
"message": "string",
"batchId": "string",
"acceptedCount": 0,
"totalCount": 0
"failureBatch": [
{
"destination": "string",
"status": {
"code": 0,
"message": "string",
"timestamp": 0
}
}
]
}