Example: Transferring Data in X-Headers

Before the version SP06 Patch 1, using call attached data (CAD) was limited to the calls within and between contact center systems, but now it is possible to send or receive CAD also in any SIP call to and from the system. To enable sending and receiving CAD, define the appropriate parameters in Call Switching > Trunks > Call Attached Data (CAD) , see Managing Trunks. The following two IVR examples introduce possibilities to filter and transfer data in IVRs. The example files can be found in the Examples and Templates folder in the Install path of the software. To get the example files, contact Sinch.

For more information, see element descriptions in the XML document.

Incoming Call Handler

The incoming call handler (Example_IVR_CallInHandler.xml) processes items in external data subsection of call extra data (EXTDATA from CALL_COMING) that match the configurable prefix. It removes the prefix from key names, and passes the resulting dictionary data in the call’s extra data. When the IVR finds a matching name that ends with the string "Queue", it replaces the destination number with the corresponding value.

Outgoing Call Handler

The outgoing call handler (files Example_IVR_CallOutHandler.xml and CallOutHandlerCustomizer.py in Example_IVR_CallOutHandler.zip) extracts the key/value pairs that originate from SAP CRM and are found in call extra data as CAD (XML) into a dictionary, where key names have a configurable prefix (in the example "X-ACME-" ), and transfers the call to a configurable destination number. The dictionary is added to either to the call’s extra data (transfer to internal number), or passed to bridge in the EXTDATA field (transfer to external number).

The IVR uses the CallOutHandlerCustomizer.py customizer, you must add and activate it before the IVR can be used. For more information, see Managing Customizers for IVRs.