[Freeswitch-users] JavaScript control Transfer

David Swardstrom dswardstrom at remotelink.com
Wed Jun 9 16:05:03 PDT 2010


I have been working on a small Javascript application to determine 
the specific Javascript application to execute based on the DNIS.
The goal is:
* Provide an entry in a dialplan public XML file to invoke the application.
* Use a database lookup (ODBC) using DNIS.
* Fail if the DNIS is not found (hangup the session)
* If the DNIS is found:
** use another entry in the database to determine 
** the working application and any static parameters.
* Invoke/Transfer to/Activate the other application.

It is fairly simple to do all but the first step.
I have been having problems trying to get the last step to work.

What I would like is something like this:
session.execute("transfer", transfer_string);
Where transfer_string is the string from the Database.
Or where transfer_string is the string from the DB 
plus some fixed options.

I would prefer not to have to add entries into 
the dialplan/pubic/00_xx.xml file but will if I have to.
I did notice an option called "inline" which potentially avoid this.

I suspect part of my problem is not quite understanding the transfer syntax.

If I ever get this running properly, I will provide a Wiki example of a
simplified version of this (ie, without some of work specific code).

Regards,
David Swardstrom
(profile)http://wiki.freeswitch.org/wiki/User:Dswardstrom



More information about the FreeSWITCH-users mailing list