I'm developing a basic call using .ASP.NET feature where the requirement is when I click a button, it will trigger a call to another person. The call is two-way, which I can communicate with my clients for example.
I am using Twilio to do this..
This is my code :
public void OutboundCall(string toPhoneNumber, string fromPhoneNumber)
{
var call = CallResource.Create(
twiml: new Twilio.Types.Twiml(
"<Response><Say voice=\"Polly.Amy\">I am a good programmer</Say>\r\n <Play>https://demo.twilio.com/docs/classic.mp3</Play>\r\n</Response>"
),
to: new PhoneNumber(toPhoneNumber),
from: new PhoneNumber(fromPhoneNumber)
);
Console.WriteLine(call.Sid);
}
It seems like when I call the number, it can only display the predefined message.
My question is, how can I have a two way communication with my clients just like a normal phone call?