The <Play> verb plays an audio file, which SignalWire fetches from the URL you configured, back to the caller.
An example of an audio file set to loop 15 times:
An example which plays an RTMP stream into the call:
The digits attribute allows you to play DTMF tones throughout a call. If pauses are required in between your DTMF tones, the character w can be used. w adds a pause of 0.5 seconds for each occurrence, so www would render a pause of 1.5 seconds. Note that this attribute simply plays tones into a call. To enter an extension when making a call, use the sendDigits attribute for the noun <Number> of the verb <Dial>.
The loop attribute determines how many times an audio file is played. If loop is set to 0, <Play> will continue looping until the call has ended.
The noun of an XML verb is nested within the verb upon which the verb acts. <Play> has the following noun:
The following are the MIME types supported by SignalWire:
No other verbs can be nested within <Play>. However, <Play> can be nested within <Gather>. In this case, the verb attribute digits is not supported.
The simplest case for <Play>: SignalWire downloads the specified audio file and plays it to the caller.
As described in the attributes section, the character w produces a 0.5 second pause. In this example, SignalWire will wait 2.5 seconds before playing the digit ‘9’.
Cache-Control: no-cache. This enables your server to respond with a new version, or with a ‘304 Not Modified’, which tells SignalWire to use the cached version.*Twilio and TwiML are trademarks of Twilio, Inc. SignalWire, Inc. and its products are not affiliated with or endorsed by Twilio, Inc.