Reputation: 429
I am trying to run the code sample given by Twilio devs: https://github.com/TwilioDevEd/ivr-phone-tree-csharp
When I call my test number, the code doesn't execute because of the warning "XML Validation warning" line "1" parserMessage " Cannot find the declaration of element 'html'." ErrorCode "12200" LogLevel "WARN"
and the XML that allegedly has the problem is Twilio's own code that has the "html" tags just fine.
<html>
<head>
<meta charset="utf-8"></meta>
<meta name="viewport" content="width=device-width, initial-scale=1.0"></meta>
<title>IVR Phone Tree</title>
<link href="/Content/site.css" rel="stylesheet"/>
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css" rel="stylesheet" integrity="sha256-k2/8zcNbxVIh5mnQ52A0r3a6jAgMGxFJFE2707UxGCk= sha512-ZV9KawG2Legkwp3nAlxLIVFudTauWuBpC10uEafMHYL0Sarrz5A7G79kXh5+5+woxQ5HM559XX2UZjMJ36Wplg==" crossorigin="anonymous"></link>
</head>
<body>
<div class="body-content"></div>
<footer>
Made with
<i class="fa fa-heart"></i> by your pals
<a href="http://www.twilio.com">@twilio</a>
</footer>
</body>
</html>
Does anyone know what the problem really is? I have already had to add closing tags, comment out DOCTYPE.. I am getting frustrated to find that the sample that is supposed to teach me something doesn't actually work
Upvotes: 3
Views: 634
Reputation: 73027
Twilio developer evangelist here.
When Twilio makes a webhook request to your application to find out what to do with the incoming call, it expects the response to be XML, TwiML in fact. Instead, your application is serving HTML, which Twilio doesn't know what to do with.
I would ensure that your phone number is configured to point to the correct path in the application, which should be http://<your-ngrok-subdomain>.ngrok.io/ivr/welcome
.
Let me know if that helps at all.
Upvotes: 3