Send the given file, allowing playback to be interrupted by the given digits, if any.
Use double quotes for the digits if you wish none to be permitted.
If sample offset is provided then the audio will seek to sample offset before play starts.
Remember, the file extension must not be included in the filename.
Returns:
failure: 200 result=-1 endpos=<sample offset>
failure on open: 200 result=0 endpos=0
success: 200 result=0 endpos=<offset>
digit pressed: 200 result=<digit> endpos=<offset>
<offset> is the stream position streaming stopped. If it equals <sample offset> there was probably an error.
<digit> is the ascii code for the digit pressed.
Bugs
STREAM FILE is known to behave inconsistently, especially when used in conjuction with other languages, i.e. Set(LANGUAGE()=xy).
Workaround: Use EXEC PLAYBACK instead.
STREAM FILE works correctly with respect to languages on 1.6, so use please it! Background has the side effect of jumping to an extension if there is a matching one.
Go back to Asterisk AGI