VoiceXML and SIP Outgoing Header Access

You can specify the values of the outbound headers using the following functions that are automatically available within a VoiceXML application:

Removes all values from the outbound array. This will stop them being used on subsequent VoiceXML transfers and disconnects for the same call.
setOutboundHeader(name, value)
Multi-functional method for adding outbound headers either from the inbound headers or by the user supplying a value. name is the header name to add to the outbound headers in session.connection.protocol.sip.outbound. value if specified is the value to assign to that header's .value attribute. If not specified, the whole header object is copied from the inbound array.

Returns the outbound header object to which you can then assign additional attributes if you need to (this would be uncommon), or null if the outbound header could not be created due to invalid name or a null value coupled with no such named header being in the inbound array.

The outbound headers values can be specified manually by manipulating the session.connection.protocol.sip.outbound object itself.

The headers are not cleared between actions, so if a call is transferred and as a result hung up Blueworx Voice Response sends whatever headers have been configured on both the TRANSFER and BYE messages unless you clear them.

If you are using VoiceXML started from CCXML, the headers are instead handled by the CCXML tag that initiates the message as explained in CCXML and SIP Outgoing Header Access. Note that values set as described for VoiceXML, not initiated by CCXML, transfers will appear on the dialog.transfer event received by the CCXML application but will not automatically be added as headers to the SIP REFER message, as this is the responsibility of the CCXML application.