Page 1 of 1

XMLHttpRequest from VXML page?

Posted: Thu Dec 03, 2015 6:30 pm
by emyhre
I think I've seen (in some rather old threads) that XMLHttpRequest is not supported in Voice XML. Is that universally true or is that a Plum-specific policy?

Is there any way to make a call to a remote server using client-side javascript, from a VXML page?

The use case we're looking to solve is to pass card credentials on to a card processor for tokenization, without accepting the card numbers into our own server environment.

Thanks

Re: XMLHttpRequest from VXML page?

Posted: Fri Dec 04, 2015 4:43 pm
by support
XMLHttpRequest is not supported in VoiceXML. This is universally true because asynchronous calls are not part of the VXML specification, it is not a Plum specific policy. Depending on your card processor's API, there are several ways you can integrate with them directly.

First, if your card processor can return XML, you can use <data> tag as documented here: http://www.plumvoice.com/docs/dev/voice ... ta&s[]=tag

Secondly, you can use a language of your choice in conjuction with VXML. We use PHP here at Plum, here is an example how: http://www.plumvoice.com/docs/dev/devel ... e:tutorial (scroll down to the submit.php part)

Re: XMLHttpRequest from VXML page?

Posted: Fri Dec 04, 2015 5:10 pm
by emyhre
Thanks for the response. Our processor's API returns JSON, not XML.

If I'm reading it right, that example shows a server-side script being deployed on our environment. This would defeat the point of using Plum services to maintain PCI compliance when gathering card data. Is it possible to deploy our own server-side scripts to a Plum server in your PCI environment? It could be stateless, since we'd only need it to act as a proxy between the VXML client and our card processor.

If it is possible, what languages and platforms do you support in addition to PHP? Ruby, for example?

Thanks

Re: XMLHttpRequest from VXML page?

Posted: Mon Dec 07, 2015 9:53 am
by support
We do not allow customers to deploy scripts to any of our servers at this time. Non-PCI static VoiceXML, audio and grammars can be hosted in our file repository which is included with a standard Plum DEV account.