Twilio TWIML POST request: Document Parse Error Twilio TWIML POST request: Document Parse Error curl curl

Twilio TWIML POST request: Document Parse Error


Megan from Twilio here. Try putting the version and encoding in var xmlData in quotes.

var xmlData = "<?xml version='1.0' encoding='UTF-8'?>";

Hope that does the trick.

Also, I'm testing this locally running ngrok which allows you to tunnel your localhost to a publicly accessible URL. This makes it easy to make sure code works before heading into deployment.

If you're curious to see more about how ngrok works you can check out this post.