how can I call a webservice from voiceXML?

廉价感情. 提交于 2019-12-11 02:14:01

问题


I'm building a very simple voiceXML app to allow people to make recordings. But first, I need to authenticate callers by phone number and/or PIN.

Can I call a webservice from voiceXML? Looks like I want to use the voiceXML "data" element to call my webservice. However, I need to dynamically calculate the URL, and it looks like it only takes a static string as the "src" parameter.

I'm new to voiceXML, so pointing me to a good tutorial would help too! I'm working from the voxeo documentation.


回答1:


you're right about needing the data element, and i'd have a look at the screxpr attribute of that element.

http://www.vxml.org/frame.jsp?page=data.htm

pretty self-explanatory:

<data srcexpr="'http://example.com/?key=' + myValue" />


来源:https://stackoverflow.com/questions/3102546/how-can-i-call-a-webservice-from-voicexml

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!