Skip to content

RECORD FILE

Synopsis

Records to a given file.

Description

Record to a file until a given dtmf digit in the sequence is received. Returns '-1' on hangup or error. The format will specify what kind of file will be recorded. The timeout is the maximum record time in milliseconds, or '-1' for no timeout. offset samples is optional, and, if provided, will seek to the offset without exceeding the end of the file. beep can take any value, and causes Asterisk to play a beep to the channel that is about to be recorded. silence is the number of seconds of silence allowed before the function returns despite the lack of dtmf digits or reaching timeout. silence value must be preceded by 's=' and is also optional.

Syntax

RECORD FILE FILENAME FORMAT ESCAPE_DIGITS TIMEOUT OFFSET_SAMPLES BEEP S=SILENCE 
Arguments
  • filename - The destination filename of the recorded audio.

  • format - The audio format in which to save the resulting file.

  • escape_digits - The DTMF digits that will terminate the recording process.

  • timeout - The maximum recording time in milliseconds. Set to -1 for no limit.

  • offset_samples - Causes the recording to first seek to the specified offset before recording begins.

  • beep - Causes Asterisk to play a beep as recording begins. This argument can take any value.

  • s=silence - The number of seconds of silence that are permitted before the recording is terminated, regardless of the escape_digits or timeout arguments. If specified, this parameter must be preceded by 's='.

See Also

Generated Version

This documentation was generated from Asterisk branch certified/20.7 using version GIT