New to twilio. I am trying to make a twilio call to my company's IVR and record the voice chunks. For example, when I dial the IVR, I get: Hello, welcome to ... Press 1 for ... Our menu has recently changed, for ... Press 1
I can dial using:
static void Main(string[] args)
{
string accountSid = "xxxxxxxx";
string authToken = "xxxxxxx";
Twilio.TwilioClient.Init(accountSid, authToken);
var call = CallResource.Create( 9876543210, 1234567890,
record: true,
recordingChannels: "dual",
url: new Uri("http://www.mycompany.com/DialOption"),
sendDigits: "wwww1234wwww1234567890")
}
On my webserver, I have:
public class DialOptionController : TwilioController
{
[HttpPost]
public TwiMLResult Index(VoiceRequest request)
{
var response = new VoiceResponse();
response.Pause(19);
response.Play(digits: "1");
response.Pause(19);
response.Play(digits: "1");
response.Pause(9);
response.Play(digits: "1");
return TwiML(response);
}
}
How do I get the recording to give me the chunks before I select the option and not the whole recording in one file?