Vous êtes sur la page 1sur 28

Avaya Aura® Orchestration Designer

Sample Applications
Version 7.2

Disclaimer
The sample applications released with Avaya Aura® Orchestration Designer are intended
to demonstrate specific functions or technologies. While some applications will run “out-
of-the-box” with the Orchestration Designer simulation voice browser or on a voice
platform (Avaya IR or Avaya Voice Portal), these applications are not guaranteed to run
without the proper hardware and telephony setup. These examples are intended to be
used as technical samples for reference only, and not production-ready applications.

Additional sample applications are also available on the Avaya DevConnect portal.

Installation instructions
1) In Eclipse, make sure that the Tomcat home property has been set in the Eclipse
preferences: WindowPreferencesTomcat. Browse for the root directory
where you installed Tomcat (i.e. C:\Program Files\Apache Software
Foundation\Tomcat 6.0, etc.).
2) Locate the sample AAOD_<AAOD version>_SampleApplications.zip and using
WinZIP (or some other compressed file extraction utility) unzip to <eclipse
home>, where <AAOD version> is the Avaya Aura® Orchestration Designer
release version (e.g. 7.0) and <eclipse home> is the base directory of your Eclipse
installation. (Note: The sample application ZIP file is distributed on the Avaya
Aura® Orchestration Designer release CD, so browse to locate the file.).
3) Using Eclipse, import the applications into your Eclipse workspace. Use
FileImportExisting Project into Workspace to select one or more project(s)
and import it into the Eclipse environment. (Note: This assumes that your
workspace is configured to be <eclipse home>/workspace. If you have
configured your Eclipse environment to use a workspace in a different location,
you will have to manually move the sample application projects to your
workspace location).
NOTE: To reduce the size of the sample application ZIP file, the sample applications are
distributed without the scert<version>.jar file. When the applications are imported into
Avaya Aura® Orchestration Designer, it will prompt you to update the runtime libraries,
which will copy the scert<version>.jar into the project.
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

MS Access and Java 1.8 Update

There are couple applications such as IceCreamStore and LexingtonLengend that use MS
Access for database functions. The ODBC configuration demonstrated inside this doc no
longer works with Java 8 due to the fact that it has removed the JDBC-ODBC bridge that
allows developers to use MS Access. For more information:
http://docs.oracle.com/javase/7/docs/technotes/guides/jdbc/bridge.html

To work around this limitation, you can configure OD to use a 3rd-party JDBC driver:

Download the driver files from


http://ucanaccess.sourceforge.net/site.html

Unpack the downloaded zip file

In OD Preferences->Avaya Aura->Orchestration Designer->Database, add the JDBC


drivers from the unpacked UCanAccess directory:
Ucanaccess-3.0.3.jar
Commons-lang-2.6.jar
Commons-logging-1.1.1.jar
Hsqldb.jar
Jackcess-2.1.3.jar

Configure the project Database properties in Properties->Orchestration Designer-


>Pluggable Connectors->Database
Driver Class Name: net.ucanaccess.jdbc.UcanaccessDriver
Connection URL: jdbc:ucanaccess://C:/<path>/<name>.mdb

2 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

Sample applications
The following sample applications and modules have been provided with Avaya Aura®
Orchestration Designer:

 AACCTreatmentCCXML
 AACCTreatmentDigitCollection
 AACCTreatmentContextCreation
 ArrayExample
 ASyncRestHandling
 AvayaIVVR
 BloominBloomsLite
 CallMPSApp
 ConverseExample2
 DDIceCreamStore
 DTMFToneMask
 DynamicPhraseLoading
 EchoSHA
 Events
 InBandTonePulse
 LaunchCCXMLCallPDCTest
 LaunchVXMLCallPDCTest
 LexingtonLegends (requires modules: StadiumDirections & CollectTicketInfo)
 MultilingualHelloWorld
 MyCreditCard
 MyMathQuiz
 MyTreasureMap
 MyTroubleDesk
 NBestExample
 RecordMessage
 RESTConnectorExample
 Spelling
 StockAndWeatherAudio
 TASExample
 UserDefinedVXML
 VisitingSchedule
 VoiceThermostat

3 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

MultilingualHelloWorld
This application is the basic “Hello World” with a few added enhancements. After the
language menu, the application says hello to the caller and prompts the caller for a
greeting response. After collecting the caller’s response, the application repeats the
caller’s utterance. Then the application asks if the user wants to go through the
application again. If caller responds with an affirmative response, then the app goes back
to the language menu to repeat. This language supports English & Spanish prompts and
grammars. One thing to note is the “GoAgain” node uses a multilingual grammar for
yes/no input and the Spanish and English grammar items use “true” and “false” for the
tag values which allows the call flow to branch based on the user input interpretation
rather than the utterance (“yes” is different from “si”, etc.). One other note, if you are
running this application on Microsoft ASR/TTS, the Spanish support is barely functional,
so do not expect very successful recognitions and the TTS is comical. The more recent
Microsoft Speech package (6.0) may treat this better, or if a Spanish TTS/ASR engine has
been installed, you may have better TTS/ASR experiences. (Configuration note: if you
do have a Spanish TTS engine installed, you will have to configure the project so that it
emits the Spanish TTS language tag in the VXML so the Spanish TTS engine is loaded at
runtime. Refer to the Avaya Aura® Orchestration Designer help contents for information
on configuring languages in the workspace and configuring languages for a project).

RecordMessage
This is a simple application that demonstrates how a Record item can be used to let a
caller leave a message, listen to the message, re-record, etc. This application can also be
reused as a module because it returns the URL to the recorded audio file as an output
parameter from the module.

NOTE: Avaya does not provide configuration or troubleshooting support for OSDMs.
OSDMs must be configured prior to attempting to use with Avaya Aura® Orchestration
Designer.

Events
This application demonstrates event handling as well as event-driven call control. There
is an event handler on AppRoot for the custom event type “MyEvent”. A prompt and
collect node catches the NoInput/NoMatch events, plays a prompt and then throws a
“MyEvent”. The third time the MyEvent is caught, the call is routed to a different
disconnect node and the call ends. Important things to note are the use of prompt levels
on the ME.prompt and ME3.prompt.

ArrayExample
One of the features of Avaya Aura® Orchestration Designer is the ability to treat runtime
variables as a collection (or can be thought of as an array). Collections are useful when
working with results from database queries, web service calls, or if the ASR engine
returns more than one recognition result (see NBestExample). This application

4 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

demonstrates working with the collection API to populate a collection variable from both
the GUI and from Java code.

TASExample
This application demonstrates invoking a TAS script via the VXML Object tag. Using
the VXML Object tag to invoke TAS scripts is an important way to leverage existing
and/or legacy scripts on an IR platform. This example invokes the “avftst” TAS script.
For additional information on invoking TAS scripts on IR using the VXML Object tag,
refer to IR/TAS documentation (HelpApplication developmentAdvanced application
developmentUsing VoiceXMLCreating a VoiceXML applicationUsing the
VoiceXML <object> element interface). Note: TAS applications are not compatible with
VoicePortal, so this example is for IR only. Additionally, simulation of the object tag and
TAS scripts are not supported.

NBestExample
This application demonstrates how to handle more than one result from an ASR engine.
While this application simply reads all of the results, another use could be to iterate over
the result and give the caller a chance to accept one of the responses (i.e. “call bill smith”
may return “will smith” and “bill smith”—you could give the caller a chance to accept
one of the responses). If you are using the Microsoft ASR engine, n-best is not supported
so you can’t use speech, but you can simulate n-best by typing in the ASR recognition
and confidence values (comma separated) and using the Send ASR button. For example:

UserDefinedVXML
This application uses the VXMLServlet node to support custom VXML. While this just
plays a text-to-speech prompt, this node could be used to do more advanced VXML.

5 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

InBandTonePulse
This application demonstrates playing DTMF tones from a VXML page. It uses the new
Phrase Variable type “DTMF Tones” to convert the value of the variable into the
corresponding DTMF key. The DTMF tones that are played are 50ms DTMF tone pulses
followed by 50ms of silence. This type of application may be useful in some instances
where a telephony system requires the application to pulse DTMF tones in band (such as
for a transfer, etc.).

NOTE: Playing the DTMF tones in band may not work for all telephony configurations.
It is recommended that you validate the functionality with your IVR platform and switch.
This is just an example of how tones could be played in a VXML application and has no
guarantees.

LaunchCCXMLCallPDCTest
This is a simple application which demonstrates how to use the LaunchCCXMLCall item
in an OD Speech Application. To deploy the sample application follow these instructions:
1) Import the LaunchCCXMLCallPDCTest project into you OD ADE environment.
2) Modify the
APP_HOME/LaunchCCXMLCallPDCTest/Library_Reminder/Library_Reminder
.ccxml file by changing this line to the IP Address and port of the Application
Server.
<var name="prompt_uri"
expr="'http://xxx.xxx.xxx.xxx:XXXX/LaunchCCXMLCallPDCTest/Library_Rem
inder/announcement.wav'"/>
For instance: <var name="prompt_uri" expr="'http://192.168.10.10:8080
/LaunchCCXMLCallPDCTest/Library_Reminder/announcement.wav'"/>
3) In the CallFlow Editor, double-click on the LaunchCCXMLCall Data Node,
select the LaunchCCXMLCall item and change its “toURI Constant” property in
the Properties Tab to the destination phone number.
4) Export the LaunchCCXMLCallPDCTest application and deploy it on your
application server. When you export, on the “Specify Deployment Parameters”
page of the export wizard, make sure you click “Include extra files and folders”
and then in the resulting popup, click on the “Library_Reminder” folder so that it
is included in the war file.
5) Add the Sample application called “LaunchCCXMLCallPDCTest” on your
Experience Portal Platform as a VXML application and configure it as Inbound
and Enabled.
6) Add another application called “LibraryReminder” by using the URL
'http://xxx.xxx.xxx.xxx:XXXX/LaunchCCXMLCallPDCTest/Library_Reminder/
Library_Reminder.ccxml on the same Experience Portal platform as a CCXML
application and set it to Outbound and Enabled.
7) Call the LaunchCCXMLCallPDCTest application. When it answers it will say
"Start launching CCXML outbound call....".
8) The number you configured in the Step 3 of your OD sample application will be
launched. When the phone rings, answer it and then you will hear "Overdue task."

6 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

LaunchVXMLCallPDCTest
This is a simple application that demonstrates how a LaunchVXMLCall item can be used
to let a caller to launch vxml outbound call to another callee via Experience Portal 7.0
web serivce without creating a WSOP or writing Java code. This application plays the
prompt for “starting launch ccxml out bound call” and then launches the call to the
specified phone number. It will write the result for LaunchVXMLCall to the trace.log.

NOTE: You need to configure two applications called “Intro” and


“LaunchVXMLCallPDCTest” in EPM 7.0 machine and make it enabled. The application
“Intro” needs to point to http://yourMPPmachine/mpp/misc/avptestapp/intro.vxml. The
number in “toURI Constant” needs to be changed to your preference.

DynamicPhraseLoading
This is a simple application that demonstrates loading and playing dynamic phrases (pre-
recorded audio) at runtime. The Avaya Aura® Orchestration Designer runtime
framework provides API that allows an application to override the location of an audio
file such that it may be located outside of the project or even on a different application
server (i.e. an HTTP-enabled media server). This sample demonstrates using the API to
load audio files from a different directory within the project; the caller is prompted for a
phrase number (1-4) and based on the caller input, the corresponding phrase number is
loaded from the “myphrases” directory. While the application is not very exciting, it is a
simple demonstration of how dynamic audio can be added to a project. The logic that is
used to load phrases dynamically should be reviewed in WEB-
INF/src/English/phrasesets/DynamicPhraseset.java.

Spelling
This application demonstrates using a Phrase Variable to play audio files based on the
value of a variable. This application acts as a very limited localization bundle and will
“spell” individual letters and numbers from a variable value.

The application contains a phraseset (spell), which contains 36 phrases (A-Z, 0-9). A
simple Java utility class will parse the value of a variable and build a collection variable
that contains the IDs of the phrases to spell the value. For example: “Hello 123” is
parsed into a collection of values:
[0] = “spell:h”
[1] = “spell:e”
[2] = “spell:l”

[7] = “spell:3”

NOTE: This application is a simple example of one way to use a Phrase Variable. This
sample application is not designed to be a multi-lingual application without changes to
the parsing logic. Phrase Variables can be used in a variety of other ways depending on

7 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

the needs of your application. For example, they may be used in a database-driven
application where a database query returns the phrase IDs/URLs for the announcements.

StockAndWeatherAudio
This application is a pretty simple application that uses a web service to get a stock quote
or for the weather of a US city. This application uses dynamic grammars that parse text
files in the project’s data directory (cities.txt and tickersymbols.txt) in order to build the
grammar from items in the files. Also, if you are running the application from behind a
proxy, in order to ensure that the application can invoke the web server be sure to
configure the proxy settings (Window->Preferences->Orchestration Designer):

NOTE: If you do not know the proxy host and port, talk to your network administrator.

VoiceThermostat
This application demonstrates slightly more advanced Java integration that binds Java
objects/beans with a session variable. This project contains a Java object/bean called

8 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

“Thermostat” which implements a thermostat control that stores a temperature value and
methods to raise/lower the temperature. The application creates a Thermostat object and
registers a listener with the object, which, when the temperature changes is notified of the
change event and updates the session variable with the new temperature value.

DDIceCreamStore
This sample application demonstrates many of the more “advanced” features and
capabilities of Avaya Aura® Orchestration Designer. This application speech enables the
menu of a fictional ice cream store. A database (Microsoft Access for simplicity) is used
for storing the flavors, inventory, prices, specials, as well as customer information. The
application heavily uses dynamic grammars and dynamic prompts for listing flavors and
specials as well as speech enabling the database-driven menu. Order costs are calculated
based on the pricing in the database, but it also gives discounts to loyal customers—with
every 10th scoop the order is free. As orders are placed, the database is updated keeping
inventory and customer order data up to date with the each order.

Please refer to the various Java classes to see how the features are implemented.
 English.grammars.scoopsAndFlavors – builds a grammar with two slots that
collects the flavor and number of scoops. The flavors are read from the database.
 English.grammars.flavors – builds a grammar with all of the flavors from the
database.
 English.grammars.specialsGram – builds a grammar from the specials in the
database.
 English.prompts.ListFlavors – overrides updatePrompt to completely build the
prompt in Java code with flavor data from the database. This prompt also only
includes 5 flavors at a time in the prompt, which lets the caller listen to the menu
five flavors at a time.
 English.prompts.ListSpecials – overrides updatePrompt to completely build the
prompt using Java code with specials information from the database.

In order to run this application, you must configure the ODBC data source for the
Microsoft Access database that contains the ice cream store data.
Define the data source: Control Panel  Administrative Tools  Data Sources (ODBC).
Select “Microsoft Access Driver”. (See screenshot in the LexingtonLegends section for
this step).
Define “IceCreamStore” and select the database, which should be in <workspace
home>/DDIceCreamStore/data/icecream.mdb.

9 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

StadiumDirections/CollectTicketInfo
These projects are modules that are used by Lexington Legends. They have been
deployed as reusable modules and therefore are available on the call flow palette. The
projects have been distributed so you can look at the contents of the module. You may
also run/simulate these applications as standalone projects in order to test the
functionality and input/output parameters of the module.

LexingtonLegends
This is the largest and most complicated sample application. It uses modules—or sub-
dialogs—to break apart certain parts of the application into smaller applications. These
projects are “StadiumDirections” and “CollectTicketInfo”.

NOTE 1: If you use the Export Wizard to deploy Lexington Legends to a WAR file you
should redeploy the modules “StadiumDirections” and “CollectTicketInfo” prior to
packaging Lexington Legends. The packaging process keeps track of the version
numbers for all modules referenced by the application as they have been installed in the
modules directory. If version numbers or runtime updates are applied to the projects in
the workspace but modules are not redeployed, then deployment of the application may
result in warnings on the application validation page. To ensure that all versions are
correct, you should first deploy (as reusable modules) “StadiumDirections” and
“CollectTicketInfo” and then deploy “LexingtonLegends”.

NOTE 2: This application was designed to run against a Microsoft Access database,
which is not a full SQL DBMS. Due to this restriction, this app can only run in a servlet
container on a Windows machine that can access a Microsoft Access database through
ODBC.

10 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

NOTE 3: In order to run the application, you must define the ODBC data source using
the Windows Data Sources configuration tool. Refer to the Windows Help system for
information on configuring ODBC data sources. (Generally, this tool is accessible from
the Windows Control Panel). Also, when you define the data source, you may have the
choice to define a user data source or a system data source. A user data source is
probably sufficient, but if you will be running tomcat as a Windows service (not
recommended for Avaya Aura® Orchestration Designer development) you may need to
define a system data source.

Define a Microsoft Access Driver:

And define the data source “Legends2005” and browse for the LexingtonLegends.mdb
file, which should be <eclipse
home>/workspace/LexingtonLegends/data/LexingtonLegends.mdb, but this could differ
based on your configuration.

11 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

ConverseExample2
This example application tests converse on data as well as converse data return. This
example collects 5 DTMF digits and then a second set of digits (0-10 digits). After
collecting the digits from the converse on data, the caller is prompted to enter their 10-
digit phone number. After collecting the caller’s phone number, there is a menu to
disconnect the call or to transfer to another VDN (currently using feature access code
*77) and the collected phone number is returned to the vector.

NOTE: This application is primarily provided to demonstrate collecting 2 sets of data


from a vector step. No Communication Manager directions or vector programming
instructions are provided. It is assumed that users are capable of setting up the
appropriate vectors. It is recommended that users download and look at the
ConverseStep sample application on DevConnect which has in depth documentation
about setting up and configuring the vectors, etc.

BloominBloomsLite
This example application demonstrates the video (IVVR) features of Avaya Aura®
Orchestration Designer 7.0. It utilizes the Avaya Aura® Orchestration Designer media
and prompt extensions for a multi-media application that allows callers to view and order
flower bouquets from their video-enabled mobile phone.

NOTE: This application will run in the simulator using the embedded Ambulant media
player. To run this application on a real phone requires Voice Portal 5.x as well as a
telephony network that supports 3G video gateways and devices to support QSIG/SIG
videos. Voice Portal Video Server setup is outside the scope of this document.

12 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

AvayaIVVR
The AvayaIVVR sample application demonstrates different video features essential for
the creation of IVVR (Interactive Voice and Video Response) applications using Avaya
Aura® Orchestration Designer.

Application Details

The application begins with an Avaya splash screen followed by a menu node. The user
needs to provide DTMF input to access the different menu choices.

If the user selects general information (DTMF 1), a video prompt is displayed with
information about Avaya like location and contact details.

If the user decides to search for Avaya partners (DTMF 2), they will be prompted to enter
a five digit zip code in the next prompt. After entering the zip code, the user can view the
partner details close to the entered zip code. As this is a sample application, the partner
details are the same for any zip code entered.

If the view Avaya videos option is selected (DTMF 3), another menu prompt is displayed
to select a video. Once a selection is made, the selected 3gp video is displayed in the
media preview view.

If the user enters the DTMF for the other option (DTMF 4), the call is transferred to an
agent. AvayaIVVR being a sample application, there is no actual transfer of the call to an
agent.

If the exit option is selected (DTMF 5), the application ends.

Application Features
This sample application demonstrates the following video features:

Video session variables – The AvayaIVVR sample application teaches you how to utilize
video session variables and determine connection details. Each prompt has if/else
statements to configure the prompt content based on the values of these video session
variables. AvayaIVVR application will run as an audio only application if

13 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

session.video,enabled is set to false. The different video session variables that can be
used are as follows:
session:videobitrate
session:videocodec
session:videoenabled
session:videofarfmtp
session:videoformat
session:videofps
session:videoheight
session:videonearfmtp
session:videowidth

Use of coordination parallel and sequence - Coordination parallel and sequence can be
used to effectively combine audio and video content. Refer to the start prompt of
AvayaIVVR sample application for an example. It is recommended to set the “endsync”
attribute for the coordination parallel prompt segment.

Dynamic video text – The searchresults prompt demonstrates how to generate dynamic
video text in a prompt. In this prompt, the media page has a GetZipcode variable. This
variable gets a value at runtime which is used to generate the video text. The user can see
the zipcode that he entered in the previous step in this prompt. This is a useful feature for
implicit user confirmation and saves the additional step of a creating a confirmation
prompt for the application developer.

Video image overlays – Video overlays can be created by creating multiple regions in a
media page and setting different media content for each region. Refer to the menuprompt
for an example. In this prompt, for the CIF case, there are two regions in the media page
named menuprompt. The main region displays the menu, while the banner region
displays a banner image at the bottom of the prompt that changes after a few seconds.

Prompts with 3gp videos – 3gp videos can be played in a prompt by using a media page
having a media element with video as the media type. Refer to the speech prompt in
AvayaIVVR sample application for an example.

Adjusting prompts for different screen sizes – If/else statements can be used within a
prompt to define video content based on the screen size (QCIF, CIF etc). The screen size
can be obtained via the video session variable session.connection.videoformat

14 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

Running the application with Avaya Application Simulator

NOTE: AvayaIVVR sample application should be run with Avaya Application Simulator
provided with Dialog Designer 5.1 or Avaya Aura® Orchestration Designer 6.0 and
above, as some of the features used in this application are not available in the previous
versions.

1. Import AvayaIVVR sample application into Avaya Aura® Orchestration Designer


2. Install Storm Codec 7.01.19 available in the Avaya Aura® Orchestration Designer
Release to view 3gp videos in simulation.
3. Open simulation profiles’ settings by either going to:
 Window-Preferences->Avaya Aura ->Application Simulation-> Simulation
Profiles
OR
 clicking the edit button next to the “Default “simulation profile in the
Application Simulator.
4. Create a simulation profile by clicking on the New button.

15 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

5. Enter a name for the new profile, say Video. Click ok.

6. In the DD Runtime Session tab, under Speech Session Parameters, enter details
for a new parameter as follows:
Param Name: connection.video.enabled
Param Value: true
Click Add Param and Ok.

16 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

7. This is an optional step. If you want to change the screen format size, you need to
add another speech application parameter as follows:
Param Name: connection.video.format
Param Value: QCIF
By default, AvayaIVVR sample application will run with the CIF video format
size.
Click Add Param and Ok.

8. Now select the new simulation profile (named Video) in the Application
Simulator and click run application.

Running the application with Avaya Voice Portal

Avaya Voice Portal 5.0 or higher is needed to run this application. Create a WAR file for
AvayaIVVR sample application and deploy it on a web server just like any other
Orchestration Designer application.
For details on this, refer to the tutorial for deploying speech applications on Avaya Voice
Portal (https://devconnect.avaya.com/secure/download/tutorials/VXML_CCXML_Dep.pdf ).
Voice Portal Video Server setup is outside the scope of this document.

17 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

To run this application on a real phone requires Voice Portal 5.0 or above as well as
telephony network that supports 3G video gateways and devices to support QSIG/SIG
videos

DTMFToneMask
This application demonstrates how to use “hotword” barge-in to play prompts while
collecting caller input. Hotword barge-in means that the platform will not interrupt the
prompt until there is a complete recognition of an active grammar. This example plays a
randomly generated set of DTMF tones while listening for a 4 digit PIN number as a
means to “mask” or obfuscate the PIN number.

NOTE: While the DTMF simulator does support barge-in, this application will queue
many audio tones to play which makes it difficult to enter a four digit pin while the tones
are playing. This application is best run on a VXML platform.

NOTE 2: Tone masking does not provide fool proof security for collecting sensitive data
– it really only prevents somebody from listening/recording DTMF tones and then trying
to translate the tones into their respective digits. The audible DTMF tones that you hear
on the phone are usually generated by the phone. These tones are typically separated into
a data channel on the network (highly dependant on carrier networks) and the tones are
then recognized by the far end DTMF receiver. Emitting DTMF tones in-band from the
IVR may actually result in DTMF recognizer problems if the IVR-generated tones are
picked up by the recognizer, which will result in false matches or false recognitions.
Lastly, if an interloper on the line is listening with a DTMF recognizer, the data signal
can be intercepted regardless if the DTMF tone is echoed in the telephone or not. If an
interloper is prevented from receiving the DTMF tones, the IVR will also be prevented
from receiving the tones. Avaya is providing this application to demonstrate how “tone
masking” can be implemented in a VoiceXML application, with the disclaimer that “tone
masking” is not a true security solution.

MyCreditCard
This application collects a credit card number, type and expiration date for a credit card,
and then performs a credit card number validation to test if the credit card number is
valid.

MyMathQuiz
This application demonstrates using the Data node to perform mathematical calculations
in the form of a math quiz. The caller selects an operation type and is then quizzed on
simple math problems. The caller’s score is then reported at the end of the call.

MyTreasureMap
This application reads in a properties file (see data/treasuremap.properties) to get the
directions to a pirate’s treasure. The caller then must speak directions and paces to find
the pirate’s treasure. This application also uses pre-recorded audio rather than Text-to-
Speech.

18 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

MyTroubleDesk
This application utilizes database operations to report trouble tickets and allows engineers
to update the status of trouble tickets. The concepts demonstrated are:
General Concept of MyTroubleDesk:

- Customers can call in to report a problem with one of our products. They will
record a message, and it will be emailed to an engineer. The app will also insert
the message into a database as a blob, and generate a unique ticket number for the
customer.
- Customers can also check the status of their ticket and see whether their problems
have been solved. If a problem is solved, then they can listen to the engineer’s
message.
- Engineers can call in and record a solution to the customer’s problem. It gets
stored in the database, where the customer can call back to listen to that message.
NOTE: “kings” is the password to access the “hidden” engineer menu. To change
the password, edit English/grammars/GetChoices.gram and change “kings” to
another word. Also, in SendEmailMessage.java, the variable “email_body” must
be changed to the new password.

Functionality it demonstrates:

- This uses the database operations: Add, Update, Delete, Query, and Execute.
- Some java code is written that can take a .wav file, turn it into a blob, and then
insert into a database.
- Likewise, there’s some java code that will query the database for the blob, turn it
into a .wav file, and play it back over the phone.
- There is also java code that will email the .wav file to an engineer.

Required setup and configuration:


 PROPERTIES:
1. Locate the avaya.properties file in MyTroubleDesk/data/.
2. Fill in the mail and sql.jdbc properties with the appropriate information.
Contact your Oracle database administrator and your SMTP server
administrator. The default values given are dummy values and will not
work.

 DATASOURCE:
1. Import and Open the MyTroubleDesk application in the navigator if you
haven't done it yet.
2. Right mouse click MyTroubledDesk in the Navigator view. Select menu
item Properties.
3. Click on Orchestration Designer on the left view. Click the Datasources
tab. Then, click the Database tab. Press the Add button.
4. In the Name: textbox, type TroubleDesk. In the Driver Class Name:
textbox, type oracle.jdbc.driver.OracleDriver. For the rest of the boxes,
contact your Oracle database administrator.

19 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

NOTE: The Connection URL is formatted [driver]:@[server]:[port]:[name]. For


example, jdbc:oracle:thin:@198.162.1.100:1521:MyDatabase.

 JAR FILES:
1. Add ojdbc14.jar and mail.jar to the Tomcat/common/lib directory. (Note:
The mail.jar and ojdbc14.jar are not provided. You must get these from
your Oracle database administrator or some other source.)
2. Right mouse click MyTroubledDesk in the Navigator view. Select menu
item Properties.
3. Click on Java Build Path on the left view. Click the Libraries tab on the
right.
4. Press Add External JARs. Then, add odjbc.jar, mail.jar, and activation.jar.

 SQL SCRIPT: Run the SQL statements on your Oracle database. This will set up
the 2 tables, the stored procedure, and the sequence.
create table TroubleDesk (
IDnum number(6) not null,
cust_msg blob,
status varchar2(16),
ret_msg blob,
product varchar2(16),
constraint pk_troubledesk primary key(IDnum));

create table Reports (


IDnum number(6) not null,
the_month varchar2(10),
the_day number(2),
the_year number(4),
the_hour number(2),
the_minute number(2),
constraint pk_Reports primary key(IDnum));

create sequence unique_ID


increment by 1
start with 100000
order;

create or replace procedure delete_record(ticket NUMBER) is


BEGIN
delete from Reports where IDnum = ticket;
END delete_record;

 SECRET CODE(optional): To access the engineer's menu, the caller will need to
say the code word when the first menu is prompted. "KINGS" is the code word.
To change the engineer code word, you will need to do 2 things:
1. In the english/grammars/GetChoices.gram, change "kings" to another
word.

20 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

2. In SendEmailMessage.java servlet, find the variable "email_body" and


change "KINGS" to the new word.
NOTE: This allows the engineer receiving the message to know what the new
word is.

CallMPSApp
This application demonstrates the interoperability between OD application and MPS
Developer applications. OD 7.0 features a template tool item named MPS Developer
Application in the call flow editor palette, which this application uses to call a MPS
Developer application. The functionality of this application is similar to the example
given in the Interoperability chapter (5) ->Invoking MPS Developer from VXML section
of the VXML Browser User Guide (Software Release 2.3.0 on MPS 2.1 and MPS 3.0)
document. The application takes the offset from the caller, and sets up the Object tag with
required parameters that calls the MPS Developer application. The call is then handed off
to the MPS Developer application specified by the offset. Upon the return of the call to
the application, the application announces the returned data.

VisitingSchedule
This application simulates a business scenario where caller is inquiring about the
operating schedule. The application takes the date and time the caller enters, and checks
them against conditions for exceptions such holidays, vacation, weekends and business
hours. The application utilizes several new features in OD 7.0 including the date-time
functions, local variables and complex conditions. By using the combination of these new
features, the application demonstrates how a call flow can create branching based on the
date & time of various formats. This application may not ideally demonstrate a live
situation since it has some of the dates and times hard coded for events such as holidays
and vacation. The dates and times would most likely come from database or configurable
variables. As long as you have this in mind, it’s not difficult to adapt the logic provided
here for live use.

RESTConnectorExample
This application uses the REST protocol to connect to either a stock or weather web
service, similar to StockAndWeatherAudio. This example requires proxy settings to first
be configured (Window->Preferences->Orchestration Designer). Because OD does not
use a contract file, WSDL for example, to connect to a REST service, the return from the
server is generally in either XML or JSON format. A servlet is provided within the
application flow as a skeleton and custom code to parse data can be inserted there. OD
uses a String representation of the object by default, but this can be changed within the
Web Service Operation file to other formats. Please note that this example is a very
simple demonstration of how REST services may be used and is not intended to be an
exhaustive exploration of the connector’s options.

21 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

AACCTreatmentCCXML
Requires: an AACC Treatment enabled speech application such as
AACCTreatmentDigitCollection or AACCTreatementContextCreation or you may add
your own.

This ccxml sample application is a generic aacctreatment ccxml application that can be
used to invoke any AACC Treatment enabled speech application and return the result.
When you add the AACC Treatments PDC to a speech project, a ccxml.jsp file will be
automatically added to the project. This ccxml.jsp is what you invoke from AAEP
however, the simulator is unable to invoke an embedded ccxml.jsp file in a speech
project, so this project exists to support the simulator. You can simply copy that ccxml.jsp
into a ccxml project to accomplish the same result.

You must configure a simulation profile with the following settings:


- Edit your simulation profile and go to OD Runtime Session tab
- select Call Control Protocol Parameters
- protocol name should be "sip" (version doesn't matter).
- If using the AACCTreatmentDigitCollection sample app add the following parameters:
requestparams.returns=true
requestparams.treatmenttype=digitcollection
requestparams.numberofdigits=5
requestparams.voicexml=AACCTreatmentDigitCollection

- If using the AACCTreatementContextCreation sample app add the following


parameters:
requestparams.returns=true
requestparams.treatmenttype=contextcreation
requestparams.voicexml=AACCTreatementContextCreation

Run the AACCTreatmentCCXML and it will invoke the speech application you have set
in requestparams.voicexml.

In order to verify the results, you will need to look at OD logs for both the ccxml
and speech application.

This data is obtained from executing AACCTreatmentDigitCollection:

Logging request parameters received:


Session:uid_148: request parameters received:
[
voicexml:AACCTreatmentDigitCollection
numberofdigits:5
returns:true
treatmenttype:digitcollection

22 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

Invoking speech app:


Session:uid_148: VXML app type
Session:uid_148: invoking
http://localhost:8080/AACCTreatmentDigitCollection/Start

Once the app has completed, the ccxml will attempt to send the data to AACC. Key
information is the return data and sip msg type and preamble. You will notice at this time
the simulator does not support SIP Endpoint as a valid Target Type, and indicates so in
the log.
Session:uid_148: AACC Raw Return Value: 65329
Session:uid_148: sip msg type : application/vnd.nortelnetworks.digits
Session:uid_148: sip msg preamble encoded : p%3DDigit-Collection%0D%0Ay
%3DDigits%0D%0Ad%3DDigits%253D
Session:uid_148: sip msg preamble decoded : p=Digit-Collection
y=Digits
d=Digits%3D
Session:uid_148: AACC return value decoded : 65329
Session:uid_148 Sending Event's Target Type is not simulated

AACCTreatmentDigitCollection
Requires: This application requires AACCTreatmentCCXML sample application in order
to execute. Do not invoke this application directly. Please see readme.txt in
AACCTreatmentCCXML for more details.

This application will gather a dynamic number of digits and return them back to AACC.
This is facilitated by the AACCTreatmentCCXML sample application which is required
for this to execute.

You must configure a simulation profile with the following settings:


- Edit your simulation profile and go to OD Runtime Session tab
- select Call Control Protocol Parameters
- protocol name should be "sip" (version doesn't matter).
- add the following parameters:
requestparams.returns=true
requestparams.treatmenttype=digitcollection
requestparams.numberofdigits=5
requestparams.voicexml=AACCTreatmentDigitCollection

23 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

Run the AACCTreatmentCCXML and it will invoke this speech application.

In order to verify the results, you will need to look at OD logs for both the ccxml
and speech application.

Logging request parameters received:


Session:uid_148: request parameters received:
[
voicexml:AACCTreatmentDigitCollection
numberofdigits:5
returns:true
treatmenttype:digitcollection
]

Invoking speech app:


Session:uid_148: VXML app type
Session:uid_148: invoking
http://localhost:8080/AACCTreatmentDigitCollection/Start

Once the app has completed, the ccxml will attempt to send the data to AACC. Key
information is the return data and sip msg type and preamble. You will notice at this time
the simulator does not support SIP Endpoint as a valid Target Type, and indicates so in
the log.
Session:uid_148: AACC Raw Return Value: 65329
Session:uid_148: sip msg type : application/vnd.nortelnetworks.digits
Session:uid_148: sip msg preamble encoded : p%3DDigit-Collection%0D%0Ay
%3DDigits%0D%0Ad%3DDigits%253D
Session:uid_148: sip msg preamble decoded : p=Digit-Collection
y=Digits
d=Digits%3D
Session:uid_148: AACC return value decoded : 65329
Session:uid_148 Sending Event's Target Type is not simulated

AACCTreatmentContextCreation
Requires: This application requires AACCTreatementCCXML sample application in
order to execute. Do not invoke this application directly. Please see readme.txt in
AACCTreatementCCXML for more details.

This application will gather data from the user and pass back to AACC as name/value
pairs.

24 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

This is facilitated by the AACCTreatementCCXML sample application which is required


for this to execute.

You must configure a simulation profile with the following settings:


- Edit your simulation profile and go to OD Runtime Session tab
- select Call Control Protocol Parameters
- protocol name should be "sip" (version doesn't matter).
- add the following parameters:
requestparams.returns=true
requestparams.treatmenttype=contextcreation
requestparams.voicexml=AACCTreatmentContextCreation

Run the AACCTreatementCCXML and it will invoke this speech application.

In order to verify the results, you will need to look at OD logs for both the ccxml and
speech application.

Logging request parameters received:


Session:uid_148: request parameters received:
[
voicexml:AACCTreatmentContextCreation
returns:true
treatmenttype:contextcreation
]

Invoking speech app:


Session:uid_148: VXML app type
Session:uid_148: invoking http://localhost:8080/AACCTreatmentContextCreation/Start

Response formatted to send to AACC:


AACCTreatments:generateContextReturnData: context data raw:
<cc><i>flavor=vanilla</i>
<i>topping=fudge</i><cad>This cad data will be added to the SIP msg sent to
AACC</cad></cc>
*************

Once the app has completed, the ccxml will attempt to send the data to AACC. You will
notice at this time the simulator does not support SIP Endpoint as a valid Target Type,
and indicates so in the log.
Session:uid_186: sip msg type : application/x-aacc-info
Session:uid_186: sip msg preamble encoded : p%3DContext-Creation%0D%0Ay
%3DString%0D%0Ad%3DContext%253D

25 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

Session:uid_186: sip msg preamble decoded : p=Context-Creation


y=String
d=Context%3D
Session:uid_148 Sending Event's Target Type is not simulated

EchoSHA
This application demonstrates how the SHA-2 algorithm can be used for SOAP based
web service calls that require Username Token authentication. The default behavior of
the Username Token profile, as defined by the WS-Security specification, is to utilize
SHA-1 to generate the password hash. However, by instead choosing to send the
password without any encryption, but encrypting it via custom code prior to the send, any
level of security can be used. In this case, we use SHA-256, the 256 bit version of SHA-
2. This method can be used to create higher bit hashes using SHA-2, as well as other
algorithms altogether, provided the web service has been created to understand the
chosen implementation.

The EchoSHA application works in the following way:

1. The user is asked to choose a version of client, Axis or Axis2


2. The user is asked to choose a version of SHA
3. The string "Hello Axis(2), SHA-1!" or "Hello Axis(2), SHA-2!", depending on the
choice of Axis and SHA made, is stored in the request variable.
4. The web service call is made using the chosen authentication algorithm. The
return value for this web service is an echo of whatever text was provided for the
request.
5. If using SHA-1, the call will fail. If using SHA-2, the call will succeed.
6. The return value will be the string "Hello Axis(2), SHA-1!" or "Hello Axis(2),
SHA-2!", again depending on what is chosen.
7. Failure to authenticate will result in a return value of nothing (in the case of Axis),
or the exception encountered (in the case of Axis2).
8. The application terminates if the user speaks "exit", and loops infinitely
otherwise.

Note that while the string "Hello Axis..." is set to send for both web service calls, because
only passwords created using this specific SHA-2 algorithm are accepted, only the SHA-
2 call will ever succeed.

To run the sample application, first the web service must be installed.

1. Open the SampleServer.zip file, located in the root of this application


2. Unzip the server file into any directory of your choosing
3. Find the start Tomcat script (startup.bat) within \bin of the server directory and
double-click to run

26 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

a. The default port used is 9999, so as to not conflict with OD's default port
of 8080. If 9999 is in use on your machine, feel free to modify the
server.xml file, located at:
<server_root>\apache-tomcat-7.0.26\conf\server.xml
b. The client WSOP files must also be modified to use the new port value in
the Endpoint URL.
4. Once the server is running, the application may be launched.
5. Once finished, double-click the stop Tomcat script (shutdown.bat) within \bin to
shut down the server

The default username is "avaya" and the default password is also "avaya", no quotes.
You can modify the password the server uses by copying the included password.txt file to
the root of your main hard drive. If your main hard drive is C:\, the path to the password
file would be:

C:\password.txt

The WSOPs must be modified to utilize the new password, especially the SHA-2 WSOP,
as the exception from an incorrect password is the same exception generated if the wrong
security algorithm is used, and therefore could be confusing. Use of the password.txt file
is purely optional. The application and server will run fine without it.

The algorithm used in this sample is an almost copy of that used by WS-Security,
substituting SHA-256 for SHA-1. You can find the code for the algorithm in the Java file
corresponding to the WSOP. It is normally located at:

EchoSHA\WEB-INF\src\connectivity.ws.operations\SHA<1 or 2>WS<Axis or
Axis2>.java

While this algorithm can be modified to almost anything else, doing so will make this
application non-functional. In order to modify the code, a web service that uses the same
algorithm must be available. The included web service only recognizes SHA-2 encrypted
hashes. When creating a custom algorithm, make sure to check the "Send Password in
clear" check box in the Authentication section of the WSOP. This will prevent the
internal hashing algorithm from being used.

These instructions and further references are also available in the README file located
in the root of the EchoSHA application.

AsyncRestHandling
This application demonstrates sending an asynchronous web service request and
receiving the asynchronous web service reply. See the project readme.docx for
additional details of the application.

Requires: Experience Portal 7.1 or greater.

27 of 28
Avaya Aura® Orchestration Designer Sample Applications Version 7.2

28 of 28