<disconnect>

Description

Disconnects the user's phone call.  As a result, the interpreter context will throw the connection.disconnect.hangup event.  A <disconnect> differs from an <exit> in that it forces the interpreter context to drop the call.

Syntax


<disconnect reasonexpr="ECMAScript_Expression" expr="ECMAScript_Expression" namelist="variable1 variable2 ..."/>

Attributes

Attribute

Description

reasonexpr

An ECMAScript expression to be evaluated and used as the reason (ISDN disconnect cause code) for this disconnection.  Optional.

A platform extension.

expr

An ECMAScript expression to be evaluated and returned to the calling context.  See below for details on General Usage.  Optional.  (Only one of expr or namelist can be specified.)

A platform extension.

namelist

A space-separated list of variables to be returned to the interpreter context when the hang up request is sent.  Returns nothing by default. See below for details on General Usage.  Optional.

(Only one of expr or namelist can be specified.)

A VoiceXML 2.1 extension.

Attribute Notes

Parents

Block Catch Error Filled ForEach Help If Noinput Nomatch

Children

None

VoiceGenie Extensions

General Usage

Note that the expr and namelist attributes can be specified but are not useful in PSTN environments.  These attributes are only useful when used in a VoIP platform, where the SIP BYE message is used to terminate a call.  Additional information (in this case, attribute/value pairs) can be sent with the terminating SIP BYE message.  In the case of a PSTN hangup/disconnect, additional information cannot be sent.  These attributes are useful for advanced applications that use external elements (such as an external call control server) in addition to the VoiceXML server.  In such applications, calls are routed to the VoiceXML server from the external servers whenever VoiceXML must be executed to collect user input.  After input has been collected, information can be passed back to the external servers with a <disconnect> tag.

Limitations/Restrictions

Example


<?xml version="1.0"?> <vxml version="2.0" xmlns="http://www.w3.org/2001/vxml"> <form> <block> Thanks for calling. Goodbye. <disconnect/> </block> </form> </vxml>