CCXML 1.0-W3C Development GuideHome  |  Frameset Home

  Dialog Extension: x-senddtmf  |  TOC  |  E: Client Side Scripting  

Dialog extension: "x-texttospeech"

The x-texttospeech dialog extension provides the ability to play a simple TTS string to the petrson on the line without having to invoke a fully fleshed out VXML dialog. There are a small number of parameters that allows the developer to customize the behavior of this dialog extension, which are:




An example to this dialog extension in action is listed below for convenience.


<?xml version="1.0" encoding="UTF-8" ?>
<ccxml version="1.0">

<meta name="author" content="Jeff Menkel"/>
<meta name="copyright" content="2007 Voxeo Corporation"/>
<meta name="maintainer" content="YOUR_EMAIL@HERE.COM"/>

  <var name="initState" expr="'state_1'"/>
  <var name="MyCallID"/>

  <eventprocessor statevariable="initState">

    <transition event="connection.alerting" state="state_1">
      <assign name="MyCallID" expr="event$.connectionid"/>
      <send data="'MyEvent'" target="session.id"/>
    </transition>

    <transition event="MyEvent">
        <accept connectionid="MyCallID"/>   
    </transition>

    <transition event="connection.connected" state="state_1">
      <log expr="'***** CALL WAS ANSWERED *****'"/>
      <HL><dialogstart src="'null://?text=This is a test of the Text to Speech dialog extension&amp;termdigits=*'" type="'application/x-texttospeech'"/></HL>
    </transition>
 

    <transition event="error.dialog.notstarted'" state="state_1">
        <log expr="'****** ERROR.DIALOGNOTSTARTED.NAME = ' + event$.name"/>
    </transition>


    <transition event="dialog.exit">
      <log expr="'***** CALL EXITING *****'"/>
      <log expr="'***** TERMINATING CHARACTER = ' + event$.values.termdigit"/>
      <exit/>
    </transition>

  </eventprocessor>
</ccxml>


Note that you may also download the complete code for testing by clicking here. Copy and paste is SO last-century....






  ANNOTATIONS: EXISTING POSTS
0 posts - click the button below to add a note to this page

login
  Dialog Extension: x-senddtmf  |  TOC  |  E: Client Side Scripting  

© 2008 Voxeo Corporation  |  Voxeo IVR  |  VoiceXML & CCXML IVR Developer Site