![]() |
Avaya Experience Portal provides out-of-the-box integration with Google Dialogflow for voice applications through VXML. Avaya Experience Portal provides a default VXML application on MPP, called def_dialogflow.vxml,which is the main interface for integrating with Dialogflow.
The def_dialogflow.vxml VXML application sends the initial Welcome event and then loops handling responses from Dialogflow that are returned in the recognition result. For example, playing audio responses from Dialogflow, collecting DTMF locally, and DTMF transfers. The def_dialogflow.vxml application also checks if the endInteraction key/value pair being set to true in the response. It it is called as a sub-dialog, the def_dialogflow VXML application exits or returns.
The def_dialogflow.vxml application is available on MPP at the following location:
$MPP/web/misc/dialogflowapp
To access the def_dialogflow.vxml application, use the following URL:
http://xx.xx.xx.xx/mpp/misc/dialogflowapp/def_dialogflow.vxml.
Where, xx.xx.xx.xx is the IP address or FQDN of the MPP server.
![]() | Note: |
|
It is recommended that you use the localhost instead of the FQDN of the MPP server to avoid movement of data traffic from the MPP, which could break failover. |
You can invoke the def_dialogflow.vxml application directly or as a VXML sub-dialog.
See the invoke_def_dialogflow.vxml sample application on MPP at the following location:
$MPP/web/misc/dialogflowapp/test
The following parameters must be passed from the calling VXML application to the default VXML application:
<param name=”calledAsSubDialog” value=”true”/>
<param name=”sipInfoFromParent” value=”session.connection.protocol.sip”/>
The def_dialogflow.vxml application returns an array of responses received from Google Dialogflow.
To understand the interaction between Experience Portal and the Nuance Mix DLGaaS bot, consider the following scenario:
The bot triggers the Welcome intent. For example:
Hello, Welcome. Please use dial pad to enter five digits.
The bot instructs Experience Portal to collect five DTMF digits.
The bot plays the collected digits back to the user and sets it as the end of conversation.
The digits entered are 12345
The following workflow displays the interaction between the def_dialogflow.vxml application and the Dialogflow bot. This workflow shows that the VXML application starts recognition with Dialogflow, and then waits for a response from the Dialogflow bot on what to do next.
The flow of interactions between Experience Portal and Dialogflow bot consists of the following steps:
BUILD_WELCOME: Experience Portal sends the Welcome event to the Dialogflow bot.
The bot receives the event, triggers the Welcome intent, and responds with the audio: “Hello, Welcome. Please use dial pad to enter five digits”.
"telephony_read_dtmf": {
"max_duration": "10s",
"max_digits": 5,
"listen_to_speech": false,
"finish_digit": "DTMF_STAR"
}PARSE_RESPONSE: Experience Portal parses the response and determines that the bot has instructed Experience Portal to collect five DTMF digits.
PLAY_AUDIO_AND_ACTIONS: Experience Portal plays the audio “Hello, Welcome. Please use dial pad to enter five digits” sent back from bot and then sets up local DTMF collection for five digits. Note that Experience Portal also stops sending voice to Dialogflow as listen_to_speech is false.
The user enters five digits: 590227 followed by *.
“event_input”:{
“name”:”TELEPHONY_DTMF”,
“parameters”:{
“telephony_dtmf_digits”:”590227”
}
}
The bot receives the TELEPHONY_DTMF event and sends audio to Experience Portal.
“Got DTMF via dialpad: #TELEPHONY_DTMF.telephony_dtmf_digits”
![]() | Note: |
|
This intent is also marked as End of conversation. |
PARSE_RESPONSE and PLAY_AUDIO_AND_ACTIONS: Experience Portal plays the audio sent by the bot “Got DTMF via dialpad 590227”.
END_INTERACTION: Experience Portal checks if endInteraction is set to true.
VXML exits or returns (if called as a sub-dialog) to finish the interaction.
![]() | Note: |
|
The dialogflowapp directory is overwritten during MPP patch installation and upgrades. If custom changes are required, then the dialogflowapp directory must be copied and changes must be made within this copied directory. The MPP connects to Dialogflow using a TLS connection on port 443 to FQDN dialogflow.googleapis.com |