[cisco-voip] converting called numbers using TCL
tele
tele at plexialab.it
Thu Jun 28 09:19:43 EDT 2007
One missed thing, how we can pass called number to the server side
script or to the voicexml script.
personally i don't know if this can work:
leg vxmldialog leg_incoming -u http://test/get_did.php?cld=$did
Cause it's an HTTP GET this should work but i'm not sure or you can pass
parameter directly to the voicexml script
leg vxmldialog leg_incoming -u http://test/si_demo_disconnect.vxml -p
parameters
http://www.cisco.com/en/US/products/sw/voicesw/ps2192/products_programming_reference_guide_chapter09186a00800de1ec.html#wp1043672
i don't really know if this can work. sorry
:tele
On Thu, 2007-06-28 at 14:52 +0200, tele wrote:
> Hi,
>
> shortly, you can doing a hybrid combination of TCL and VoiceXML.
> Basically you can do a request via HTTP for a voicexml script, you can
> create a HTTP server side script in PHP/Java or whatever you want that
> return as output a simple voicexml script.
>
> from the server side script you access to the database and do your
> processing, then you return as output, the voiceXML script with for
> example a simple variable set.
>
> <?php
> // database processing
> // .......
> $mynewdid = resultfromdatabase;
>
> print "<?xml version=\"1.0\"?>
> <vxml version=\"2.0\">
> <form>
> <var name=\"newdid\" expr="$mynewdid"/>
> </form>
> </vxml>\";
> ?>
>
> then you call from the tcl the voicexml and when process is finished you
> can retrive from the TCL the value of var "newdid" and setup a new call
> with the new did.
>
> BE CAREFUL about the caching of http request for the voicexml script
> look:
>
> http://www.cisco.com/en/US/products/sw/custcosw/ps1846/products_programming_reference_guide_chapter09186a00800c49db.html#1014331
>
> and for example hybrid application:
>
> http://www.cisco.com/univercd/cc/td/doc/product/software/ios122/rel_docs/vxmlprg/refgde3.htm
>
> and hybrid tcl/vxml info:
>
> http://www.cisco.com/univercd/cc/td/doc/product/access/acs_serv/vapp_dev/tclivrv2/chapter1.htm#wp1026915
>
> but you don't need to insert voicexml in the TCL, you need to call an
> external voicexml via HTTP (see "leg vxmldialog").
>
>
> :tele
>
> On Wed, 2007-06-27 at 15:45 +0200, Erik Goppel wrote:
> > Hi,
> >
> > I am trying to write a TCL app, that will translate an original called
> > number to a full DDI number.
> > This because i want to build an AAR like application on CME.
> > So call going out a dial-peer 1000 pref 1 (no bandwith via Gatekeeper
> > or WAN failure), then hits my second dialpeer with pref 2, this hits
> > the app, and translates the original called number to a full ddi
> > number, sets up a call to this number and transfer it.
> > example:
> > phone calls 1000, gatekeeper rejects, hit app, convert 1000 to
> > +4412345678 set up call and connect phone and destination if
> > succesfull, otherwise play message (temp failure,etc..).
> > Now i can do this with including all the DN`s and the DDI number
> > within the TCL script, however, i would like to do a db lookup to an
> > sql server
> > because the entries will be around 2000 dn`s (and dynamic)
> > Now i am stuck, i can`t find anything that on using TCL within IOS and
> > connecting to a SQL DB.
> >
> > Can anyone assist?
> >
> >
> > Thnx
> >
> > Erik
> > _______________________________________________
> > cisco-voip mailing list
> > cisco-voip at puck.nether.net
> > https://puck.nether.net/mailman/listinfo/cisco-voip
>
> _______________________________________________
> cisco-voip mailing list
> cisco-voip at puck.nether.net
> https://puck.nether.net/mailman/listinfo/cisco-voip
More information about the cisco-voip
mailing list