[Asterisk-Users] Options for 3rd party call control
Mark Johnston
mjohnston at skyweb.ca
Tue Nov 25 14:25:55 MST 2003
Alistair Cunningham <ac at gnu.org> wrote:
> I am working on a project on 3rd party call control for a call center, for
> which I think Asterisk may be useful. What I would like to do is:
This is something I've given some thought to lately, with the goal of
writing a queueing engine to replace the basic Asterisk one. I'll
describe how I envision it inline.
> - Have a call come in to Asterisk.
>
> - Asterisk asks another machine, over a slow IP link, such as a modem, how it
> should route the call. Asterisk passes the called and calling numbers.
>
> - This other machine looks up the destination, based on called and calling
> numbers, in an SQL database, and responds to Asterisk.
>
> - When Asterisk gets a reply, it routes the call.
>
This could be handled in a couple of ways. You can use AGI to do
something like this:
[ answer, etc. ]
exten => s,5,AGI(router|getCallDestination)
exten => s,6,Dial(Something/${CallDestination})
which essentially treats your AGI script as a library. Your script
communicates with the remote machine and uses SET VARIABLE to set
CallDestination to whatever you like, and logic is handled in the
dialplan.
The other way I was considering is to use the management interface
remotely. Your dialplan would just be:
exten => s,1,Answer
exten => s,2,MusicOnHold
The remote server would be notified of the incoming call via the IP
management interface, decide where it should be routed, and issue the
commands to transfer the call itself. This, it seems to me, is less
clear, as it moves a lot of logic into your management script. Also,
it could be more bandwidth-intensive and slower, as you use Asterisk's
verbose management protocol.
> - During the call, this other machine may ask Asterisk to re-route the call.
>
> - If this happens, Asterisk hangs up on the party it called, plays a 'please
> hold' message to the caller, then connects them to the new destination.
I would do this through the management interface.
> - All this happens over a mixture of basic rate ISDN, analogue lines, H.323,
> and SIP.
I believe Asterisk makes this fairly transparent.
> Looking at the Asterisk website, I don't see any options to do this. Has
> anyone given this any thought? Would such a thing be difficult to write?
I'm hoping it wouldn't (won't), since I have to write it. :)
Please share any brilliant ideas you have, and best of luck with your
project.
Mark
More information about the asterisk-users
mailing list