shadow_variables

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
shadow_variables [2018/12/11 18:01]
admin
shadow_variables [2019/03/07 13:05] (current)
admin
Line 3: Line 3:
 VoiceXML uses standard variable systems. This means that Fuse+ does too, because it is built on VoiceXML. Standard variable systems allow users to create their own variables and manipulate them directly. ​ VoiceXML uses standard variable systems. This means that Fuse+ does too, because it is built on VoiceXML. Standard variable systems allow users to create their own variables and manipulate them directly. ​
  
-When collecting input or interacting with a REST web service, oftentimes information exists in addition to the “response” data that users may want to access. Shadow variables allow users to access this additional data. 
- 
-Adding a ‘$’ symbol to the end of a variable, automatically creates a shadow variable for that variable. The shadow variable will contain different member variables depending on the type of input or web service it is being used with. For example, with an input "​credit_card"​ you can determine the confidence of the grammar engine match by accessing "​credit_card$.confidence"​. 
  
  
Line 11: Line 8:
 ==== Global Shadow Variables ==== ==== Global Shadow Variables ====
  
 +Fuse+ allow access to global session variables that contains information about the current call. The //session// variable is a complex object that contains properties. Sometimes those properties have properties of their own. 
  
-When collecting input, one of the global ​shadow ​variables ​created is "​lastresult$"​. This variable is filled in the case of both a match or a nomatch. Lastresultallows users to get the list of all possible matches, not just the best match+Because these variables are global variables, there will be no need to use the '$' notation ​to access them.
  
-In the event that speech input exists for the variable in use, lastresult$ can also provide a recording of the utterance spoken by the user (for speech input).+ 
 +\\ In Fuse, users might want to access the following session properties:  
 +\\  
 +\\  
 +{{tablelayout?​colwidth="​260px"​}} 
 +^ Global Variable ^ Explanation ^ 
 +| session.connection.ani | Caller'​s number, the phone number where the call was made from |  
 +| session.connection.dnis | Dialed number for this call. This is useful for applications that have multiple number deployments and would need to identify which number the caller has dialed. |  
 +| session.connection.callee_type | Only for outbound calls, see [[outbound#​callee-type-detection|Callee Type Detection]] |  
 +| session.id | Unique ID for this call |  
 +| session.name | Name of the current active Fuse+ application |  
 +| session.connection.protocol.sip.headers | only for SIP-in calls |  
 + 
 + 
 + 
 +---- 
 +==== Last Result Shadow Variables ==== 
 + 
 +When collecting input or interacting with a REST web service, oftentimes information exists in addition to the “response” data that users may want to access. Shadow variables allow users to access this additional data. 
 + 
 +Adding a ‘$’ symbol to the end of a variable, automatically creates a shadow variable for that variable. The shadow variable will contain different member variables depending on the type of input or web service it is being used with. For example, with an input "​credit_card"​ you can determine the confidence of the grammar engine match by accessing "​credit_card$.confidence"​. 
 + 
 + 
 +This variable is filled in the case of both a match or a nomatch. Lastresult$ allows users to get the list of all possible matches, not just the best match. ​In the event that speech input exists for the variable in use, lastresult$ can also provide a recording of the utterance spoken by the user (for speech input).
  
 Having access to this data, even in the "​nomatch"​ case, allows users to send DTMF input off without requiring a match, or to send the utterance recording somewhere (perhaps to transcription). Having access to this data, even in the "​nomatch"​ case, allows users to send DTMF input off without requiring a match, or to send the utterance recording somewhere (perhaps to transcription).
Line 33: Line 54:
   * lastresult$[i].inputmode   * lastresult$[i].inputmode
   * lastresult$[i].interpretation   * lastresult$[i].interpretation
- 
-In addition to these various shadow variables, there is a global session variable that contains information about the current call. The variable application.connection is a complex object that contains properties. Sometimes those properties have properties of their own. In Fuse, users might want to access the following session properties: ​ 
-\\ 
-\\ 
-  * session.connection.ani (caller ID for this call) 
-  * session.connection.dnis (dialed number for this call) 
-  * session.connection.callee_type (only for outbound calls) 
-  * session.id (unique ID for this call) 
-  * session.connection.protocol.sip.headers (only for SIP-in calls) 
-  * session.name (name of the current active Fuse+ application) 
  
  
shadow_variables.1544569301.txt.gz · Last modified: 2018/12/11 18:01 by admin