public void Example_5b() { var response = new TwilioResponse(); response.DialConference("Customer Waiting Room", new { beep = false, endConferenceOnExit = true }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Example_3() { var response = new TwilioResponse(); response.DialConference("SimpleRoom", new { muted = true }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Example_4() { var response = new TwilioResponse(); response.DialConference("NoMusicNoBeepRoom", new { beep = false, waitUrl = "", startConferenceOnEnter = true, endConferenceOnExit = false }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Example_1() { var response = new TwilioResponse(); response.DialConference("1234"); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Example_2b() { var response = new TwilioResponse(); response.DialConference("1234", new { startConferenceOnEnter = false, endConferenceOnExit = true }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Can_Generate_Dial_Conference() { var response = new TwilioResponse(); response.DialConference("room1"); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Can_Generate_Dial_Conference_And_Attributes() { var response = new TwilioResponse(); response.DialConference("room1", new { muted = true, beep = false, waitUrl = "wait.xml", waitMethod = "GET" }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Example_2a() { var response = new TwilioResponse(); response.DialConference("1234", new { startConferenceOnEnter = "false" }); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Example_2a() { var response = new TwilioResponse(); response.DialConference("1234", new { startConferenceOnEnter = "false" }); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Example_3() { var response = new TwilioResponse(); response.DialConference("SimpleRoom", new { muted = true }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Example_2b() { var response = new TwilioResponse(); response.DialConference("1234", new { startConferenceOnEnter = false, endConferenceOnExit = true }); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public void Can_Generate_Dial_Conference() { var response = new TwilioResponse(); response.DialConference("room1"); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Can_Generate_Dial_Conference_And_Attributes() { var response = new TwilioResponse(); response.DialConference("room1", new { muted = true, beep = false, waitUrl = "wait.xml", waitMethod = "GET" }); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Example_1() { var response = new TwilioResponse(); response.DialConference("1234"); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Example_5b() { var response = new TwilioResponse(); response.DialConference("Customer Waiting Room", new { beep = false, endConferenceOnExit = true }); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Example_4() { var response = new TwilioResponse(); response.DialConference("NoMusicNoBeepRoom", new { beep = false, waitUrl = "", startConferenceOnEnter = true, endConferenceOnExit = false }); Assert.True(IsValidTwiML(response.ToXDocument())); }
public void Can_Generate_Dial_Conference_And_Attributes_And_Dial_Attributes() { var response = new TwilioResponse(); response.DialConference("room1", new { muted = true, beep = false, waitUrl = "wait.xml", waitMethod = "GET" }, new { timeLimit = 30, action = "http://example.com" } ); Assert.IsTrue(IsValidTwiML(response.ToXDocument())); }
public ActionResult PlaceInConference(bool mute) { Debug.WriteLine("Putting caller into conference: {0}", mute); var response = new TwilioResponse(); response.DialConference("Chapter18Conference", new { muted = mute, beep = false, startConferenceOnEnter = true, endConferenceOnExit = false }, new { hangupOnStar = true }); response.BeginGather(new { action = Url.ActionAbsolute("ProcessCommand"), numDigits = "1" }); response.EndGather(); response.Say("Bye"); return(TwiML(response)); }
public async Task <ActionResult> HandleCustomerCall(string CallSid, string From) { var response = new TwilioResponse(); //check the caller ID and try to find a call config that matches it IMobileServiceTable <WarmCall> warmCallTable = MobileService.GetTable <WarmCall>(); var warmCalls = await warmCallTable.ReadAsync <WarmCall>(warmCallTable.Where(w => w.CustomerPhone == From)); var warmCall = warmCalls.FirstOrDefault(); if (warmCall != null) { //update with the call sid warmCall.CustomerCallSid = CallSid; await warmCallTable.UpdateAsync(warmCall); //put the customer into a conference response.Say("Please while while we conjure a support agent"); response.DialConference(CallSid); //dial an agent var client = new TwilioRestClient(Credentials.AccountSid, Credentials.AuthToken); var result = client.InitiateOutboundCall("+17862200728", warmCall.AgentOnePhone, Url.ActionAbsolute("HandleAgentOneCall")); if (result.RestException != null) { Console.WriteLine(result.RestException.Message); } //let the browser know that the customer has connected and we're calling the agent } else { response.Say("Who are you? Go away!"); response.Hangup(); } return(TwiML(response)); }
public void Can_Generate_Dial_Conference_And_Attributes_And_Dial_Attributes() { var response = new TwilioResponse(); response.DialConference("room1", new { muted = true, beep = false, waitUrl = "wait.xml", waitMethod = "GET" }, new { timeLimit = 30, action = "http://example.com" } ); Assert.True(IsValidTwiML(response.ToXDocument())); }