VoxML Reference
Record
Record the call.
The Record verb starts recording the call. The finished recording is stored and available from the Recordings API.
How Record Works
Record starts the recording and returns immediately — the next instruction runs straight away. The recording continues until max_length elapses or the call ends. It is saved as WAV and listed under the call's call_uuid.
Record does not wait for silence or a key press, and does not call back with the result.
Example
A simple voicemail: prompt, beep, record, keep the line open, then hang up.
{
"voxml_version": "1.0",
"instructions": [
{
"verb": "Say",
"text": "Please leave a message after the beep."
},
{
"verb": "Record",
"max_length": 120
},
{
"verb": "Pause",
"length": 120
},
{
"verb": "Hangup"
}
]
}Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| max_length | integer | no | 3600 | Maximum recording duration in seconds |
| play_beep | boolean | no | true | Play a beep before recording starts |
| action_url | string | no | — | Accepted but not called — no callback is sent when the recording finishes |
| method | string | no | POST | Accepted and ignored (see action_url) |
| timeout | integer | no | 5 | Accepted and ignored — silence does not stop the recording |
| finish_on_key | string | no | 1234567890*# | Accepted and ignored — key presses do not stop the recording |
| trim | string | no | trim-silence | Accepted and ignored |
| transcribe | boolean | no | false | Accepted and ignored |
| transcription_url | string | no | — | Accepted and ignored |
Disabling the Beep
{
"verb": "Record",
"max_length": 180,
"play_beep": false
}Retrieving the Recording
Once the call ends or max_length elapses, the recording appears in List Recordings. Filter by call_uuid:
curl "https://api.tryvox.io/v1/account/$TRYVOX_AUTH_ID/recordings?call_uuid=$CALL_UUID" \
-u $TRYVOX_AUTH_ID:$TRYVOX_AUTH_TOKENBest Practices
- Set
max_lengthto the longest message you want to accept. - Keep the call open (for example with
Pause) for as long as you want to record. - Recording calls may require consent from the parties — follow the rules that apply to you.