Hello, As per your valuable suggestions and provided sample codes, i am trying to write an Auto Attendant Script which will be hooked up with an Inbound Line. When a callers call to that number, Caller will be greeted first then asked for a Selection, after caller selects for Self Service, we will be validating caller by it's account ID present in our DB and also if caller's services are stale or not. If all goes well caller can go to Self service and can Choose only 1 service at a time out of 3 service that we offer.
Let's say we provide 3 services and under each service we have 4-5 service lines (child Services). For each service line Caller can record message and submit it to us.
I have few problems, may be minor but i could not figure out what i am doing wrong here in the below code. It is giving following error when i check my Call Logs.
Issue 1 ->
Error Details ->
Thu 24 Dec 2015 03:53:55 PM EST:
Click here to view saved VoiceXML script
GrammarManager::CreateGrammarFromString(application/srgs+xml):
---------
<?xml version='1.0'?>
<grammar root="voice_options" xml:lang="en-us" mode="voice">
<rule id="voice_options_6" scope="private"><one-of><item>Service</item><item>Sales</item><item>Support</item></one-of></rule>
</grammar>
---------
Message from ASR engine:
---------
SWI_PARSER_XML_SYNTAX_ERROR| XML grammar failed XML validation| SWIxendElement | Specified root rule not found in XML file 'STRING_GRAMMAR'
SWI_PARSER_GEN_ERROR| XML parse error| SWIgramHandlers::endElement | ... in XML file at line 4 char 11
---------
bargein set to true
INPUTMODES set to "DTMF VOICE"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
A serious error of type </speak>
---------
bargein set to true
INPUTMODES set to "DTMF VOICE"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>error.grammar.inlined</speak>
---------
bargein set to true
INPUTMODES set to "DTMF VOICE"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak> has occurred. Exiting. </speak>
---------
VXI::exit_element()
Newly queued prompts are now being played
Thu 24 Dec 2015 03:54:01 PM EST:
Call End Event
Ending session
Ending Session On Channel 74
VXML that is giving above error ->
Code: Select all
<?xml version="1.0"?>
<vxml version="2.0">
<!-- *************************************************************************** -->
<!-- Auto Attendant VXML -->
<!-- *************************************************************************** -->
<!-- declare page variables -->
<var name="AccountID"/>
<var name="RecordingType"/>
<var name="recorded_message"/>
<form id="introduction">
<block>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/WelcomeIVRMessage.wav">
<voice name="crystal">
Hello, Welcome to Our Company, a Leader in XXX Solutions.
</voice>
</audio>
</prompt>
<goto next="#MainMenu"/>
</block>
</form>
<form id="MainMenu">
<field name="MainMenuselection">
<grammar type="application/srgs+xml" root="voice_options" mode="voice">
<rule id="voice_options_6">
<one-of>
<item>Service</item>
<item>Sales</item>
<item>Support</item>
</one-of>
</rule>
</grammar>
<grammar type="application/srgs+xml" root="dtmf_options" mode="dtmf">
<rule id="dtmf_options_6">
<one-of>
<item>1</item>
<item>2</item>
<item>3</item>
</one-of>
</rule>
</grammar>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/MainMenuOptions.wav">
<voice name="crystal">
Please choose one of the following options
For Self Service, press 1 or say Service.
For Sales related queries, press 2 or say Sales.
For Application related Issues or Support, press 3 or say Support.
</voice>
</audio>
</prompt>
<filled>
<if cond="MainMenuselection == 1 || selection == 'Service'">
<!-- <prompt>You selected.</prompt> -->
<goto next="#SelfService"/>
<elseif cond="MainMenuselection == 2 || selection == 'Sales'"/>
<!-- <prompt>You selected.</prompt> -->
<goto next="#Sales"/>
<elseif cond="MainMenuselection == 3 || selection == 'Support'"/>
<!-- <prompt>You selected.</prompt> -->
<goto next="#Support"/>
</if>
</filled>
</field>
</form>
<!-- Record the callers Account ID -->
<form id="SelfService">
<field name="Account_ID" type="digits?length=5">
<prompt bargein="false" count="1">
<audio src="http://AbsoluePathofOurServer/WaveFiles/SelfServiceMsg1.wav">
<voice name="crystal">
Please Enter your Account ID.
</voice>
</audio>
</prompt>
<prompt bargein="true" count="2">
<audio src="http://AbsoluePathofOurServer/WaveFiles/SelfServiceMsg2.wav">
<voice name="crystal">
Please Enter your five digit Account ID.
</voice>
</audio>
</prompt>
<prompt bargein="true" count="3">
<audio src="http://AbsoluePathofOurServer/WaveFiles/SelfServiceMsg3.wav">
<voice name="crystal">
Your five digit Account ID can be found on your membership page at our website, Please Enter your five digit Account ID.
</voice>
</audio>
</prompt>
<filled>
<assign name="AccountID" expr="Account_ID"/>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/YouEntered.wav">
<voice name="crystal">
You have entered <value expr="Account_ID"/>.
</voice>
</audio>
</prompt>
<goto next="#validate_caller"/>
</filled>
<catch event="nomatch noinput" count="1,2">
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/NoMatchNoInputCount12.wav">
<voice name="crystal">
Your input was not valid.
</voice>
</audio>
</prompt>
<reprompt/>
</catch>
<catch event="nomatch noinput" count="3">
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/NoMatchNoInputCount3.wav">
<voice name="crystal">
It seems you are having difficulty with your Account ID, Let me transfer you to our Support department.
Please stay on the line while we connect you to the next available Support Analyst.
</voice>
</audio>
</prompt>
<goto next="#Support"/>
</catch>
</field>
</form>
<!-- Validate callers Account ID -->
<form id="validate_caller">
<subdialog name="result" namelist="AccountID" method="post" src="http://AbsoluePathofOurServer/validatecaller.aspx"/>
<block>
<if cond="result.valid && result.service == 1">
<goto next="#valid_caller_Service1"/>
</if>
<if cond="result.valid && result.service == 3">
<goto next="#valid_caller_Service3"/>
</if>
<if cond="result.invalid || result.service != 3 || result.service != 1">
<goto next="#invalid_caller"/>
</if>
</block>
</form>
<form id="invalid_caller">
<block>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/InvalidCaller.wav">
<voice name="crystal">
Sorry, you do not have access to use our system.
</voice>
</audio>
</prompt>
<goto next="#Finish" />
<disconnect/>
</block>
</form>
<form id="valid_caller_Service1">
<block>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/ValidCallerService1.wav">
<voice name="crystal">
You have been validated successfully, Our system indicates that You have subscribed for Service 1.
</voice>
</audio>
</prompt>
<goto next="#Service1menu" />
</block>
</form>
<form id="Service1menu">
<field name="Service1RecordingTypeSelection">
<grammar type="application/srgs+xml" root="voice_options" mode="voice">
<rule id="voice_options_1">
<one-of>
<item>Welcome</item>
<item>Event</item>
<item>Cancellation</item>
<item>Followup</item>
<item>ABC</item>
<item>XYZ</item>
<item>Switch Service</item>
<item>Main Menu</item>
<item>Hangup</item>
</one-of>
</rule>
</grammar>
<grammar type="application/srgs+xml" root="dtmf_options" mode="dtmf">
<rule id="dtmf_options_1">
<one-of>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
</one-of>
</rule>
</grammar>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/Service1MenuOptions.wav">
<voice name="crystal">
To record your personalised Welcome Message, Press 1 or say Welcome.
To record your personalised Event related Message, Press 2 or say Event.
To record your personalised Cancellation Message, Press 3 or say Cancellation.
To record your personalised Followup Message, Press 4 or say Followup.
To record your personalised ABC Message, Press 5 or say ABC.
To record your Provider Name, XYZ Press 6 or say XYZ.
To switch between services, Press 7 or say Switch Service.
To go back to the main menu, Press 8 or say Main Menu.
To terminate this call simply hang up or Press 9 or say Hangup.
</voice>
</audio>
</prompt>
<filled>
<if cond="Service1RecordingTypeSelection == 1 || selection == 'Welcome'">
<goto next="#Welcome"/>
<elseif cond="Service1RecordingTypeSelection == 2 || selection == 'Event'"/>
<goto next="#Event"/>
<elseif cond="Service1RecordingTypeSelection == 3 || selection == 'Cancellation'"/>
<goto next="#Cancellation"/>
<elseif cond="Service1RecordingTypeSelection == 4 || selection == 'Followup'"/>
<goto next="#Followup"/>
<elseif cond="Service1RecordingTypeSelection == 5 || selection == 'ABC'"/>
<goto next="#ABC"/>
<elseif cond="Service1RecordingTypeSelection == 6 || selection == 'XYZ'"/>
<goto next="#XYZ"/>
<elseif cond="Service1RecordingTypeSelection == 7 || selection == 'Switch Service'"/>
<goto next="#SelfService"/>
<elseif cond="Service1RecordingTypeSelection == 8 || selection == 'Main Menu'"/>
<goto next="#MainMenu"/>
<elseif cond="Service1RecordingTypeSelection == 9 || selection == 'Hangup'"/>
<goto next="#Finish"/>
</if>
</filled>
</field>
</form>
<form id="Sales">
<transfer dest="tel:+1OURTELEPHONE;postd=EXTENSIONNUMBER">
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/TransferToSales.wav">
<voice name="crystal">
Please stay on the line while we connect you to the next available Sales Representitive.
</voice>
</audio>
</prompt>
</transfer>
</form>
<form id="Support">
<transfer dest="tel:+1OURTELEPHONE;postd=EXTENSIONNUMBER">
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/TransferToSupport.wav">
<voice name="crystal">
Please stay on the line while we connect you to the next available Support Analyst.
</voice>
</audio>
</prompt>
</transfer>
</form>
<form id="Finish">
<block>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/goodbye.wav">
<voice name="crystal">
Thank you. Goodbye!
</voice>
</audio>
</prompt>
</block>
</form>
</vxml>
Issue 2 ->
I am inserting code for a Service Line called "Welcome" which is placed between <form id="Service1menu"> and <form id="Sales"> from the above code. I am asking caller to record a message for "Welcome" Service Line of Sevice 1. Once he finished recording, I need to save Callers AccountID, Service Line Type and Callers Recording as soon as he press 1 or say submit. I will be writing same kind of code for each service line.
When i am inserting code for a Service Line called "Welcome", The error for Issue 1 goes away and It gave me couple of other errors, listing few of them here -
DocumentParser::FetchDocument - Parse error in file "
http://74.208.43.153:8080/starturl.aspx ... PROCESS!20", line 331, column 12 - Element 'field' is not valid for content model: '(#PCDATA|audio|enumerate|value|catch|help|noinput|nomatch|error|filled|grammar|prompt|property)*'
errno: 205 uri
http://74.208.43.153:8080/starturl.aspx ... PROCESS!20
bargein set to true
INPUTMODES set to "DTMF VOICE"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
A serious error of type </speak>
DocumentParser::FetchDocument - Parse error in file "
http://74.208.43.153:8080/starturl.aspx ... PROCESS!20", line 329, column 11 - Element 'record' is not valid for content model: '(#PCDATA|audio|enumerate|value|catch|help|noinput|nomatch|error|filled|grammar|link|option|prompt|property)*'
errno: 205 uri
http://74.208.43.153:8080/starturl.aspx ... PROCESS!20
bargein set to true
INPUTMODES set to "DTMF VOICE"
Audio segment added to prompt queue from TTS application/synthesis+ssml for:
---------
<?xml version='1.0'?><speak>
A serious error of type </speak>
Code that is giving error for a Service Line called Welcome which is placed between <form id="Service1menu"> and <form id="Sales">
Code: Select all
<form id="Welcome">
<!-- <assign name="RecordingType" expr="RecordingType"/> -->
<record name="myrecording" type="audio/x-wav" maxtime="300s" finalsilence="30s" beep="true" dtmfterm="true">
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/Welcome.wav">
<voice name="crystal">
Please record your Welcome Message after the beep. Try speaking louder, hold the phone closer to your mouth.
Press any key when you are finished recording.
</voice>
</audio>
</prompt>
<field name="WelcomeMessageSelection">
<grammar type="application/srgs+xml" root="voice_options" mode="voice">
<rule id="voice_options_2">
<one-of>
<item>Submit</item>
<item>Record</item>
<item>Cancel</item>
<item>Replay</item>
</one-of>
</rule>
</grammar>
<grammar type="application/srgs+xml" root="dtmf_options" mode="dtmf">
<rule id="dtmf_options_2">
<one-of>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</one-of>
</rule>
</grammar>
<filled>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/JustRecorded.wav">
<voice name="crystal">
You have just recorded the following message
</voice>
</audio>
</prompt>
<prompt bargein="true">
<value expr="myrecording"/>
</prompt>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/WelcomeCallMessageRecordingConfirmation.wav">
<voice name="crystal">
To Submit your personalised Welcome Message, Press 1 or say Submit.
To Re record your personalised Welcome Message, Press 2 or say Record.
To Cancel your personalised Welcome Message, Press 3 or say Cancel.
To Replay your personalised Welcome Message, Press 4 or say Replay.
</voice>
</audio>
</prompt>
<if cond="WelcomeMessageSelection == 1 || selection == 'Submit'">
<submit next="http://AbsoluePathofOurServer/submitrecording.aspx" namelist="digitalID RecordingType myrecording" method="post" enctype="multipart/form-data"/>
<elseif cond="WelcomeMessageSelection == 2 || selection == 'Record'"/>
<goto next="#Welcome"/>
<elseif cond="WelcomeMessageSelection == 3 || selection == 'Cancel'"/>
<goto next="#Service1menu"/>
<elseif cond="WelcomeMessageSelection == 4 || selection == 'Replay'"/>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/JustRecorded.wav">
<voice name="crystal">
You have just recorded the following message
</voice>
</audio>
</prompt>
<prompt bargein="true">
<value expr="myrecording"/>
</prompt>
</if>
</filled>
</field>
</record>
<goto next="#Finish" />
<disconnect/>
</form>
As you suggested before that to keep Recording Part in a separate form and confirmation_Message on other form, in my case it may not be possible becausee i have to submit Service Line in the DB along with Recording + AccountID. So i have to Repeat Record Tag for each Service Line forms like i did in <form id="Welcome">.
Issue 3 - >
When user wants to RE-RECORD the message by pressing 2 or saying record.
I wrote this piece of code which i am pretty sure is wrong.
<elseif cond="WelcomeMessageSelection == 2 || selection == 'Record'"/>
<goto next="#Welcome"/>
So what i am trying here is, Within the <form id="Welcome">, if Caller did not like the message he recorded and wants to RE-record, i want him to start over and record in the same <form id="Welcome">. Go to is like to anchor tag, wish it can go to line number instead. Please guide me How can i write something like this.
Issue 4 ->
I am trying to validate caller, in this code <form id="validate_caller">. I am trying to validate that if User has a valid Account ID and also Subscribed for any one of the Service out of 3 that we offer. Even if the Account ID is valid but Service Subscription is Stale (Failed) or AccountID is invalid, then we have to throw error. Please guide me how to do grouping in IF condition. <if cond="result (is Valid but result.service != 3 || result.service != 1)" or result is inValid).
Code: Select all
<form id="validate_caller">
<subdialog name="result" namelist="AccountID" method="post" src="http://AbsoluePathofOurServer/validatecaller.aspx"/>
<block>
<if cond="result.valid && result.service == 1">
<goto next="#valid_caller_Service1"/>
</if>
<if cond="result.valid && result.service == 3">
<goto next="#valid_caller_Service3"/>
</if>
<if cond="result (is Valid but result.service != 3 || result.service != 1)" or result is inValid) --> need grouping here.
<goto next="#invalid_caller"/>
</if>
</block>
</form>
Hope i am detailed enough to present my problems to you, Please help.
Here is the full vxml for your review.
Code: Select all
<?xml version="1.0"?>
<vxml version="2.0">
<!-- *************************************************************************** -->
<!-- Auto Attendant VXML -->
<!-- *************************************************************************** -->
<!-- declare page variables -->
<var name="AccountID"/>
<var name="RecordingType"/>
<var name="recorded_message"/>
<form id="introduction">
<block>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/WelcomeIVRMessage.wav">
<voice name="crystal">
Hello, Welcome to Our Company, a Leader in XXX Solutions.
</voice>
</audio>
</prompt>
<goto next="#MainMenu"/>
</block>
</form>
<form id="MainMenu">
<field name="MainMenuselection">
<grammar type="application/srgs+xml" root="voice_options" mode="voice">
<rule id="voice_options_6">
<one-of>
<item>Service</item>
<item>Sales</item>
<item>Support</item>
</one-of>
</rule>
</grammar>
<grammar type="application/srgs+xml" root="dtmf_options" mode="dtmf">
<rule id="dtmf_options_6">
<one-of>
<item>1</item>
<item>2</item>
<item>3</item>
</one-of>
</rule>
</grammar>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/MainMenuOptions.wav">
<voice name="crystal">
Please choose one of the following options
For Self Service, press 1 or say Service.
For Sales related queries, press 2 or say Sales.
For Application related Issues or Support, press 3 or say Support.
</voice>
</audio>
</prompt>
<filled>
<if cond="MainMenuselection == 1 || selection == 'Service'">
<!-- <prompt>You selected.</prompt> -->
<goto next="#SelfService"/>
<elseif cond="MainMenuselection == 2 || selection == 'Sales'"/>
<!-- <prompt>You selected.</prompt> -->
<goto next="#Sales"/>
<elseif cond="MainMenuselection == 3 || selection == 'Support'"/>
<!-- <prompt>You selected.</prompt> -->
<goto next="#Support"/>
</if>
</filled>
</field>
</form>
<!-- Record the callers Account ID -->
<form id="SelfService">
<field name="Account_ID" type="digits?length=5">
<prompt bargein="false" count="1">
<audio src="http://AbsoluePathofOurServer/WaveFiles/SelfServiceMsg1.wav">
<voice name="crystal">
Please Enter your Account ID.
</voice>
</audio>
</prompt>
<prompt bargein="true" count="2">
<audio src="http://AbsoluePathofOurServer/WaveFiles/SelfServiceMsg2.wav">
<voice name="crystal">
Please Enter your five digit Account ID.
</voice>
</audio>
</prompt>
<prompt bargein="true" count="3">
<audio src="http://AbsoluePathofOurServer/WaveFiles/SelfServiceMsg3.wav">
<voice name="crystal">
Your five digit Account ID can be found on your membership page at our website, Please Enter your five digit Account ID.
</voice>
</audio>
</prompt>
<filled>
<assign name="AccountID" expr="Account_ID"/>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/YouEntered.wav">
<voice name="crystal">
You have entered <value expr="Account_ID"/>.
</voice>
</audio>
</prompt>
<goto next="#validate_caller"/>
</filled>
<catch event="nomatch noinput" count="1,2">
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/NoMatchNoInputCount12.wav">
<voice name="crystal">
Your input was not valid.
</voice>
</audio>
</prompt>
<reprompt/>
</catch>
<catch event="nomatch noinput" count="3">
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/NoMatchNoInputCount3.wav">
<voice name="crystal">
It seems you are having difficulty with your Account ID, Let me transfer you to our Support department.
Please stay on the line while we connect you to the next available Support Analyst.
</voice>
</audio>
</prompt>
<goto next="#Support"/>
</catch>
</field>
</form>
<!-- Validate callers Account ID and the Services he subscribed for-->
<form id="validate_caller">
<subdialog name="result" namelist="AccountID" method="post" src="http://AbsoluePathofOurServer/validatecaller.aspx"/>
<block>
<if cond="result.valid && result.service == 1">
<goto next="#valid_caller_Service1"/>
</if>
<if cond="result.valid && result.service == 3">
<goto next="#valid_caller_Service3"/>
</if>
<if cond="result (is Valid but result.service != 3 || result.service != 1)" or result is inValid) --> need grouping here.
<goto next="#invalid_caller"/>
</if>
</block>
</form>
<form id="invalid_caller">
<block>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/InvalidCaller.wav">
<voice name="crystal">
Sorry, you do not have access to use our system.
</voice>
</audio>
</prompt>
<goto next="#Finish" />
<disconnect/>
</block>
</form>
<form id="valid_caller_Service1">
<block>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/ValidCallerService1.wav">
<voice name="crystal">
You have been validated successfully, Our system indicates that You have subscribed for Service 1.
</voice>
</audio>
</prompt>
<goto next="#Service1menu" />
</block>
</form>
<form id="Service1menu">
<field name="Service1RecordingTypeSelection">
<grammar type="application/srgs+xml" root="voice_options" mode="voice">
<rule id="voice_options_1">
<one-of>
<item>Welcome</item>
<item>Event</item>
<item>Cancellation</item>
<item>Followup</item>
<item>ABC</item>
<item>XYZ</item>
<item>Switch Service</item>
<item>Main Menu</item>
<item>Hangup</item>
</one-of>
</rule>
</grammar>
<grammar type="application/srgs+xml" root="dtmf_options" mode="dtmf">
<rule id="dtmf_options_1">
<one-of>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
</one-of>
</rule>
</grammar>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/Service1MenuOptions.wav">
<voice name="crystal">
To record your personalised Welcome Message, Press 1 or say Welcome.
To record your personalised Event related Message, Press 2 or say Event.
To record your personalised Cancellation Message, Press 3 or say Cancellation.
To record your personalised Followup Message, Press 4 or say Followup.
To record your personalised ABC Message, Press 5 or say ABC.
To record your Provider Name, XYZ Press 6 or say XYZ.
To switch between services, Press 7 or say Switch Service.
To go back to the main menu, Press 8 or say Main Menu.
To terminate this call simply hang up or Press 9 or say Hangup.
</voice>
</audio>
</prompt>
<filled>
<if cond="Service1RecordingTypeSelection == 1 || selection == 'Welcome'">
<goto next="#Welcome"/>
<elseif cond="Service1RecordingTypeSelection == 2 || selection == 'Event'"/>
<goto next="#Event"/>
<elseif cond="Service1RecordingTypeSelection == 3 || selection == 'Cancellation'"/>
<goto next="#Cancellation"/>
<elseif cond="Service1RecordingTypeSelection == 4 || selection == 'Followup'"/>
<goto next="#Followup"/>
<elseif cond="Service1RecordingTypeSelection == 5 || selection == 'ABC'"/>
<goto next="#ABC"/>
<elseif cond="Service1RecordingTypeSelection == 6 || selection == 'XYZ'"/>
<goto next="#XYZ"/>
<elseif cond="Service1RecordingTypeSelection == 7 || selection == 'Switch Service'"/>
<goto next="#SelfService"/>
<elseif cond="Service1RecordingTypeSelection == 8 || selection == 'Main Menu'"/>
<goto next="#MainMenu"/>
<elseif cond="Service1RecordingTypeSelection == 9 || selection == 'Hangup'"/>
<goto next="#Finish"/>
</if>
</filled>
</field>
</form>
<form id="Welcome">
<record name="myrecording" type="audio/x-wav" maxtime="300s" finalsilence="30s" beep="true" dtmfterm="true">
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/Welcome.wav">
<voice name="crystal">
Please record your Welcome Message after the beep. Try speaking louder, hold the phone closer to your mouth.
Press any key when you are finished recording.
</voice>
</audio>
</prompt>
<field name="WelcomeMessageSelection">
<grammar type="application/srgs+xml" root="voice_options" mode="voice">
<rule id="voice_options_2">
<one-of>
<item>Submit</item>
<item>Record</item>
<item>Cancel</item>
<item>Replay</item>
</one-of>
</rule>
</grammar>
<grammar type="application/srgs+xml" root="dtmf_options" mode="dtmf">
<rule id="dtmf_options_2">
<one-of>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
</one-of>
</rule>
</grammar>
<filled>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/JustRecorded.wav">
<voice name="crystal">
You have just recorded the following message
</voice>
</audio>
</prompt>
<prompt bargein="true">
<value expr="myrecording"/>
</prompt>
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/WelcomeCallMessageRecordingConfirmation.wav">
<voice name="crystal">
To Submit your personalised Welcome Message, Press 1 or say Submit.
To Re record your personalised Welcome Message, Press 2 or say Record.
To Cancel your personalised Welcome Message, Press 3 or say Cancel.
To Replay your personalised Welcome Message, Press 4 or say Replay.
</voice>
</audio>
</prompt>
<if cond="WelcomeMessageSelection == 1 || selection == 'Submit'">
<submit next="http://AbsoluePathofOurServer/submitrecording.aspx" namelist="digitalID RecordingType myrecording" method="post" enctype="multipart/form-data"/>
<elseif cond="WelcomeMessageSelection == 2 || selection == 'Record'"/>
<goto next="#Welcome"/>
<elseif cond="WelcomeMessageSelection == 3 || selection == 'Cancel'"/>
<goto next="#Service1menu"/>
<elseif cond="WelcomeMessageSelection == 4 || selection == 'Replay'"/>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/JustRecorded.wav">
<voice name="crystal">
You have just recorded the following message
</voice>
</audio>
</prompt>
<prompt bargein="true">
<value expr="myrecording"/>
</prompt>
</if>
</filled>
</field>
</record>
<goto next="#Finish" />
<disconnect/>
</form>
<form id="Sales">
<transfer dest="tel:+1OURTELEPHONE;postd=EXTENSIONNUMBER">
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/TransferToSales.wav">
<voice name="crystal">
Please stay on the line while we connect you to the next available Sales Representitive.
</voice>
</audio>
</prompt>
</transfer>
</form>
<form id="Support">
<transfer dest="tel:+1OURTELEPHONE;postd=EXTENSIONNUMBER">
<prompt bargein="false">
<audio src="http://AbsoluePathofOurServer/WaveFiles/TransferToSupport.wav">
Please stay on the line while we connect you to the next available Support Analyst.
</voice>
</audio>
</prompt>
</transfer>
</form>
<form id="Finish">
<block>
<prompt bargein="true">
<audio src="http://AbsoluePathofOurServer/WaveFiles/goodbye.wav">
<voice name="crystal">
Thank you. Goodbye!
</voice>
</audio>
</prompt>
</block>
</form>
</vxml>