问题
i am creating a program for recieving the call, but every time i am calling via phone or browser it says a auto generated message : https://demo.twilio.com/welcome/voice/
i need to answer the call via phone and browser both, and which url i have to giv in twiml app for voice ? outgoing call or incoming?? if i am merging them no effect??
Twilio.Device.incoming(function (conn) {
$("#log").text("Incoming connection from " + conn.parameters.From);
// accept the incoming connection and start two-way audio
conn.accept();
});
回答1:
Twilio evangelist here.
It sounds like you have not configured the Voice Request URL for your Twilio phone number.
This URL should return some TwiML to Twilio that tell it what to do with this inbound phone call. In your case it sounds like you want Twilio to dial another phone number or a Twilio Client, so your TwiML would look something like this to dial another phone:
<Response>
<Dial>
<Number>+1-555-555-5555</Number>
</Dial>
</Response>
or this to dial a client:
<Response>
<Dial>
<Client>[name-of-the-registered-client]</Client>
</Dial>
</Response>
Hop that helps.
来源:https://stackoverflow.com/questions/24430800/how-to-configure-call-url-in-twilio-api