0

Sorry for the terribly worded question. Im using Twilio and im trying to create some reporting for users. I have a few different numbers that are called and then depending on what the caller does during the call, they may be transferred to our call center.

I need to know the number of calls that are transferred for each number.

When they call, a CallSid is created. Once the caller is transferred, a second CallSid is created with a new property called ParentCallSid. The ParentCallSid of the second call matches the CallSid of the first call.

I need to take that ParentCallSid and find the original CallSid so i can see which number they called. I will be doing this for each call in the list. So it will need to be some kind of loop. Thank You.

user1289451
  • 911
  • 8
  • 22

1 Answers1

0

I don't think this one is too difficult, it's just a matter of pulling the pieces together. If you look at this example: http://www.twilio.com/docs/api/rest/call#instance-get-example-1 (select C#), you should get back a "call" object.

One of the properties on that object will be ParentCallSid so you can change the above example from this:

Console.WriteLine(call.StartTime);

to this:

Console.WriteLine(call.ParentCallSid);

Then you can get information on that Call including the ParentCallSid and repeat until you get to the first call.

CaseySoftware
  • 3,105
  • 20
  • 18