tags:

views:

35

answers:

2

one of my client want following functionality in his site.

Person 1 will call person 2 from our website When person 2 answers person 1 will hear his voice on website person 1 will click on any mp3 file on website while call is going on and person 2 will listen to that mp3 file and what person 2 speak will be played on our website so that person 1 can hear it.

how this thing is possible ? i am using twilio for an year but this functionality is not available in that.

please help me out. I develop in PHP

A: 

You do know it's illegal to record a telephone conversation without the other person knowing it or unless you have a wiretap permit. Don't you?

amphetamachine
i will pass this message to my client, actually i need technical help here. but i did't mention any thing that i will record call. i will just run live voice on website
Simer
i think you did't understood problem
Simer
Illegal... depending on your legal framework. South African law: http://www.internet.org.za/ricpci.html#interceptionofcommunicationbypartytocommunication It might be rude, and some might argue unethical, but it's still legal.
Frank Shearar
A: 

Generally the voice application services like twilio, tropo etc. work by requesting the controlling application what to do based on events that happen during the call. For example when a new call arrives they will send a request to the pre-designated controlling application asking what they should do and then when the call is answered they will ask for further actions etc.

In your case you want it to work the other way around and you want to tell the server processing the call to do something in response to an event from your end. There may be an API call you can execute on the twilio, tropo etc. platforms to initiate actions but I can't recall it. More likely you will need to use something like the Asterisk AGI protocol which allows actions to be pushed to the server while it's processing the call. Cloudvox is one provider I know of that supports a hosted service that supports an AGI interface so they'd be worth a look, certainly a lot easier than building your own Asterisk server.

I'd also recommend checking out Anveo as their offerings are generally a bit more sophisticated than the others and they will often implement features very quickly so you could always ask for a web API that will play an mp3 during a live call.

sipwiz