The <Wait> element silently waits for a specified number of seconds. If <Wait> is the first element in a XML document, Basix will answer the call and wait the specified number of seconds.

Element Attributes

Attribute Name Description Allowed Values Default Value
length interval in seconds to wait integer > 0 1 second

Examples

Example 1: Simple Wait

1
2
3
4
5
6
<?xml version="1.0" encoding="UTF-8" ?>
<Response>
	<Speak voice="rms">I will Wait 7 seconds starting now!</Speak>
	<Wait length="7"/>
	<Speak voice="rms">I just waited 7 seconds</Speak>
</Response>

Example 2: Waiting for voice path to establish

This examples uses <Wait> to answer the call and wait for 2 seconds before speaking "Hello". This is usually done to add a delay after answer so that the voice path is fully established before we start generating audio.

1
2
3
4
5
<?xml version="1.0" encoding="UTF-8" ?>
<Response>
	<Wait length="2"/>
	<Speak voice="rms">Hello.</Speak>
</Response>