https://api.laaffic.com/v3/voice/sendIvr
| Parameter | Description | Required | Type |
|---|---|---|---|
| appId | Audio application ID | Yes | String |
| numberList | Set of numbers | Yes | Array |
| callee | Called number: 7-18 digits composed of national code + mobile phone number. | Yes | String |
| dimensionId | Template ID; specific numerical value must be obtained by contacting the business department. | Yes | Integer |
| text1 | 1. text1-text10 are preset called information variables that can dynamically replace the Text1-{Text10} placeholders in the TTS content of the call template during the call. 2. There are a total of 10 called information variables. You do not need to use all 10 parameters; you can use them as needed. There is no character length limit for individual called information variables, but you must ensure that the combined length of all text variables you use does not exceed 300 characters. 3. After you use the text variables, we will push them back to you in the "calledInfo" field of the [Proactive Voice Status Report Push]. For example, if the request is: "text1":"Tom", "text2":"12", the push format in the acknowledgment will be: "calledInfo":"{"text1":"Tom","text2":"12"}" | No | String |
| text2 | Called information variable 2 | No | String |
| text3 | Called information variable 3 | No | String |
| text4 | Called information variable 4 | No | String |
| text5 | Called information variable 5 | No | String |
| text6 | Called information variable 6 | No | String |
| text7 | Called information variable 7 | No | String |
| text8 | Called information variable 8 | No | String |
| text9 | Called information variable 9 | No | String |
| text10 | Called information variable 10 | No | String |
Request URL:
https://api.laaffic.com/v3/voice/sendIvr
Request Method:
POST
Request Headers:
Content-Type: application/json;charset=UTF-8
Sign: 05d7a50893e22a5c4bb3216ae3396c7c
Timestamp: 1630468800
Api-Key: bDqJFiq9
Request Body:
{
"appId":"4luaKsL2",
"numberList":[
{
"callee":"8613800000000",
"dimensionId":12,
"text1":"tom",
"text2":"12$"
},
{
"callee":"9113800000001",
"dimensionId":12,
"text1":"Olivia",
"text2":"13$"
}
]
}| Parameter | Description | Type |
|---|---|---|
| status | "0"means successful, others than 0 means failure, seeing Status Code description. | String |
| reason | Failure reason description | String |
| data | Submission result set (in the same order as submitted) | JSONArray |
| voiceId | Exclusive recording ID | String |
| callee | Called number | String |
| terminationCode | "0"means successful, others than 0 means failure | String |
| terminationReason | Status code description | String |
{
"status": "0",
"reason": "success",
"data": [
{
"voiceId": "2203031134011000001",
"callee": "8613800000000",
"terminationCode": "0",
"terminationReason": "success"
},
{
"voiceId": "2203031134011000002",
"callee": "9113800000001",
"terminationCode": "101502",
"terminationReason": "Failed to get rates"
}
]
}| status | Response Status Code |
|---|---|
| 0 | success |
| -1 | Authentication error |
| -2 | Restricted IP access |
| -10 | The customer's balance is insufficient |
| -16 | Timestamp expires |
| -18 | Port program unusual |
| -22 | Parameter exception |
| -26 | Getting fee faily |