| CCXML Voxeo 1.0 Development Guide | Home | Frameset Home |
|
<dialogstart> element determines what backend it will actually be talking to.<dialogterminate> element being executed. As such, its intended purpose is for short audio prompts, or being used as 'hold music':
<dialogstart src="'WaitingForYou.wav'" type="'audio/wav'"/>
<dialogstart src="'http://MyServer.com/MyFile.wav?termdigits=*#&text=Here is the TTS&voice=English-Male3&maxtime=10s'" type=" 'application/x-fetchdigits' "/>
<dialogstart src="'null://?termdigits=123*#&voice=English-Male2&text=Listen to my groovy male voice'" type="'application/x-fetchdigits'"/>
<dialogstart src="'null://?termdigits=#&text=press some digits, fool'"
type="'application/x-fetchdigits'"
name="D_1"/>
.....
<transition event="dialog.exit" name="evt">
<if cond="'123' == evt.digits">
....
</if>
</transition>
....
<dialogstart> element. There are also two additional parameters that we may use with this extension:
<dialogstart src="'dtmf://1234?pause=200&duration=100'"
type="'application/x-senddtmf'"
name="D_1">
<dialogstart src="'ftp://ftp.foo.org/test.wav&termdigits=1'"
type="'application/x-recordaudio'"
name="R_1"/>
| ANNOTATIONS: EXISTING POSTS |
moshe
|
|
| Strings of the form
null://?termdigits=#&text=press some digits, fool' don't work for me -- it's a "&" in XML, which is results in a fatal parsing error. I use: null://?termdigits=#&text=press some digits, fool' I.e., replace the "&" with the entity "& |
|
moshe
|
|
| Wow, let's try that again.
The & character in the examples cannot be used directly, because the XML parser will complin about a & character. Instead, you must use &amp;. Now let's see if that goes through the HTML parser correctly! |
|
moshe
|
|
| Is it application/x-fetchdigits, as in the code sample, or application/fetchdigits, as in the text? | |
VoxeoBrian
|
|
| Hello Moshe,
The former is correct. Using 'application/x-fetchdigits', as shown in the sample code, should do the trick. I hope this helps clarify. Cheers Brian |
|
moshe
|
|
| In the W3C compliant version of CCXML, the results are available in the event as values.termdigit and values.digits.
Also, please note that the final digit is not part of values.digits. That is, if termdigit is set to "#" and the person presses "123#", then values.digits will be "123" and values.termdigit will be "#." |
|
jbassett
|
|
| Hello,
Thanks for the information. We will review and make the appropriate changes. Thanks Jesse Bassett Voxeo Support |
|
voxeojeff
|
|
| Hi Moshe,
I have whipped up a little sample code to illustrate your point regarding values.digits and values.termdigit in CCXML 1.0. _______________________________________________________ <?xml version="1.0" encoding="UTF-8"?> <ccxml version="1.0" xmlns="http://www.w3.org/2002/09/ccxml"> <var name="state0" expr="'init'"/> <eventprocessor statevariable="state0"> <transition state="init" event="connection.alerting" name="evt"> <accept/> </transition> <transition state="init" event="connection.connected" name="evt"> <dialogstart src="'null://?termdigits=#&text=hey, press some digits, fool'" type="'application/x-fetchdigits'" dialogid="D_1"/> </transition> <transition state="init" event="dialog.exit" name="evt"> <log expr="'values.digits = [' + evt.values.digits + ']'"/> <log expr="'values.termdigit = [' + evt.values.termdigit + ']'"/> <exit/> </transition> <transition event="error.*" name="evt"> <log expr="'an error has occured: [' + evt.reason + ']'"/> </transition> </eventprocessor> </ccxml> _______________________________________________________ Thanks for the input, we appreciate it! ;-) Best, Jeff |
|
moshe
|
|
| I'd like some clarification on how x-recordaudio works. Does the stream flow in real time to the location designated by the src attribute, or does the platform record and then send? If the latter, what are the limitations (if any) on the length of the recording? | |
voxeojeff
|
|
| Hi Moshe,
The 'x-recordaudio' dialog type does not allow for the stream of an active call leg to flow in real time to the src location. The audio is recorded and then sent to it. As for limitations, yes, there is a limit of 10 minutes for the 'maxtime' parameter. Hope this helps. Best, Jeff Menkel Voxeo Corporation |
|
moshe
|
|
| Jeff,
Thanks, that's useful to know. I've read that in VoiceXML, the limit is 120s, but that it can be extended in a production environment. Can CCXML's record also be extended to, say, an hour or more, in a production environment? Moshe |
|
voxeojeff
|
|
| Hi Moshe,
According to our platform engineers, there appears to be no hard-coded limit for the maxtime parameter of x-recordaudio. The 10 minute limit I spoke of applies to VoiceXML, although, it can be configured to record longer by adding a line like 'com.voxeo.voicecenter.maxtime.record=1000000' to the VoiceCenter-VoiceXML.properties file. My apologies for the mistake. :-) Cheers, Jeff Menkel Voxeo Corporation |
|
moshe
|
|
| Does application/x-recordaudio also return other information, such as the duration of the recording? I don't see any such information in the event Object, but perhaps I'm overlooking something. | |
RobGreen
|
|
| x-recordaudio returns back the following via the dialog.exit transition
[code] event$.values.reason - reason for dialog.exit event (noerror,termdigit,maxsilence,maxtime) event$.values.termdigit - if reason is 'termdigit' then the actual digit that was pressed [/code] record time is not specified. rob |
|
fayyazkl
|
|
|
Hi, Can i call a VXML application from within a CCXML application? This is what tried: <createcall dest="'4073862174'"/> </transition> <transition state="'playing'" event="connection.CONNECTION_CONNECTED" name="evt"> <log expr="'CONNECTED TO APPLICATION. NOW ENTERING EXTENSION'"/> <dialogstart src="'dtmf://9990104955?pause=200&amp;amp;duration=200'" type="'application/x-senddtmf'"/> </transition> Since, calling an application needs to enter the PIN after wards. I tried this but the application drops after a few minutes without playing the prompt of VXML application that i am calling. Please note that i am using SKYPE to call the first CCXML application. Could this be the possible reason? Thanks for help. regards, Fayyaz |
|
fayyazkl
|
|
|
A Correction! I mistaken pasted "&" repeatedely. Correct code that i executed was: <dialogstart src="'dtmf://9990104955?pause=200&duration=200'" type="'application/x-senddtmf'"/> Thanks, Fayyaz |
|
MattHenry
|
|
|
Fayyaz, I think that what you would want to do is to dial a direct-dial number instead of the 800+PIN service, which would preclude the need for a dialog extension to play "postdial" digit tones to the answering party, (our PIN system). Is there any reason why this would not work for you, based on the parameters of your application design? ~Matt |
|
fayyazkl
|
|
|
Thanks for response Matt! Actually, i am sitting in Pakistan, and i am calling the first application through SKYPE, which in turn will call the second one. How do i map and dial a direct dial number. From the list of DD locations i saw at the bottom of application page, i understand that you mention your (the caller's current location) to map a direct dial number. But in this case, the caller is another application hosted on your network . How do i manage to do that? Please explain! Thanks, Fayyaz |
|
fayyazkl
|
|
|
Dear Matt, I tried mapping the DD number on my own and got it working. I realized that my assumption of local number is not an issue and i could call any directly mapped number from with in my applicatoin. Thanks for support. - Fayyaz |
|
moshe
|
|
| For x-recordaudio: (a) what does the "name" attribute do? (b) How about a few short words regarding receiving the wav file that's been created? Presumably, I must expect a multipart MIME file similar to the one created by VoiceXML's record element. | |
moshe
|
|
| Please note that type "audio/wav" also accepts the ?text= format for tts. The text "null://?text=This is simple text" plays nicely. |
| login |
|