Skip to main content
POST
/
v1
/
calls
/
{uuid}
/
collect
Collect DTMF input
curl --request POST \
  --url https://api.wavix.com/v1/calls/{uuid}/collect \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "max_digits": 5,
  "timeout": 10,
  "termination_character": "#",
  "max_attempts": 3,
  "prompt": {
    "play": "https://examples.com/prompt.wav",
    "say": {
      "text": "Please enter your PIN",
      "voice": "Ivy",
      "language": "ru"
    }
  }
}
'
{
  "success": true
}

Authorizations

Authorization
string
header
required

Bearer token using appid (Authorization: Bearer )

Path Parameters

uuid
string<uuid>
required

Call ID.

Body

application/json

DTMF collection parameters

max_digits
integer

Specifies the maximum number of digits to collect

Required range: 1 <= x <= 20
Example:

5

timeout
integer

Timeout for digit collection, in seconds

Required range: 1 <= x <= 60
Example:

10

termination_character
string

Character that ends digit collection

Example:

"#"

max_attempts
integer

The maximum number of attempts to collect digits

Example:

3

prompt
object

The prompt to play before collecting digits. You can play a prerecorded audio file or use Wavix Text-To-Speech.

Response

DTMF collection successfully started.

success
boolean
Example:

true