getting the dial-peer number/ T1 port number using TCL

Version 1
    This document was generated from CDN thread

    Created by: Farhang Farid on 27-10-2009 10:31:48 PM
    Hi Folks,
     
    I'm very much TCL illiterate and I was hoping that someone here can help me out,
     
    My question: Is there anyway to retrieve the dial-peer number or T1 port number that the call has terminated to using?
     
    Your help is greatly appreicated.

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: VijayPrasad Neelamegam on 28-10-2009 03:19:53 AM
     
    Hi,
     
    I understand that you need to get the outgoing dial-peer tag number,is that correct?
     
    yes you can get the dial-peer tag number using TCL.There is a sample program "Dial-peer Hunting" in the following location.
     
    http://developer.cisco.com/web/vgapi/docs
     
    Hope this helps
     
    and regarding the port number,i am not sure.i will get back to you ASAP .
     
    Thanks
    Vijay

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: Farhang Farid on 28-10-2009 04:10:24 AM
    Thanks  Vijay for getting back to me so quickly, 
     
    I actually need to know the incoming dialpeer number that call terminates to 
     
    We have a complicated architecture so this might be a bit confusing but I'll try to explain to the best of my ability. 
     
    My gateway is sitting behind a Avaya PBX, calls hit Avaya PBX and from there they terminate to the 3845 gateway. On the gateway I have 1 inbound dialpeer that invokes a service ( to CVP VXML server )for all calls that come through that voice port. Once CVP receives the  call it has to go back to the Avaya PBX and base don the voice port that the call has come through request the DNIS and ANI of the call. The initial call does not have an ANI or DNIS.
     
    Because of this, I need to be able to pass either the Voice port or the dial peer number to my service, now I need to figure out if there is any way to do this.
     
    Hope that I havent confused you
     
    Thanks for your help in advance.
     
     
    Here is my dial-peer config , In this case I need to a way to be able to retrieve 21413
     
    dial-peer voice 21413 pots

     service helloworld
     direct-inward-dial
     port 0/0/0:1
     forward-digits all

     
     

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: VijayPrasad Neelamegam on 28-10-2009 08:41:28 AM
     
    Thanks for explaining your topology.
    If  the call does not have ANI or DNIS,then we cant take dial-peer tag number.Because the dialpeers are getting triggered based upon the destiantion.
     
    The object dialpeer create command creates the handle and stores the information about the Dialpeers which matches the destination.If there is no destination,then dial-peer handle will not created and we cant fetch the tag number.
     
     
    How does the dialpeer 21413 is triggered ?is it done by voice port ?
     
    Thanks
    Vijay

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: Farhang Farid on 28-10-2009 11:01:30 AM
    Thats correct Vijay, dialpeer 21413 is invoked by voiceport. 
     
    any ideas on how the voiceport number can be retrieved?

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: VijayPrasad Neelamegam on 28-10-2009 11:26:20 AM
    If that dial-peer is triggered by voice port then you can set a dummy destination pattern on that dial-peer ,by using that destination pattern you can create handle and by using that handle you can fetch voice tag number...
     
    This is just my toughts !!!
     
    i have a doubt here,once the DP got triggered what is the next step?
     
    Will that connects an ip iphone?
     
     
    Thanks
    Vijay
     

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: Farhang Farid on 28-10-2009 01:20:03 PM
    Can I overrid the ANI with dialpeer number , would adding the following line solve the problem:

    clid network-number <number>
     
    Thanks in advance

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: Farhang Farid on 28-10-2009 12:36:51 PM
    Thanks again Vijay.
     
    Once the dialpeer gets triggered it invokes a service, which sends the call to a CVP VXML Server, from there the call will get treated on the IVR.
     
    dial-peer voice 21413 pots
     service helloworld
     direct-inward-dial
     port 0/0/0:1
     forward-digits all

     

    service helloWorld flash:CVPSelfService.tcl
      paramspace english language en
      paramspace english index 0
      paramspace english location flash:
      param CVPSelfService-port 7000
      param CVPSelfService-app HelloWorld
      paramspace english prefix en
      param CVPPrimaryVXMLServer 10.16.119.158

     
    Would the voice tag number contain the port number?

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: VijayPrasad Neelamegam on 29-10-2009 05:09:11 AM
     
     
    You can overide ANI with dial-peer tag number unless,you are not using ANI for any other purpose.
     
    Thanks
    Vijay

    Subject: RE: getting the dial-peer number/ T1 port number using TCL
    Replied by: Farhang Farid on 29-10-2009 12:34:05 PM
    That did the trick.
     
    I'm now overriding the ANI with a unique number (in this case the same as dialpeer number)
    on my CVP VXML server I use this number to map it back to the IVR port controlled by the switch and then I use an external API to go to the switch and get the ANI and DNIS info
     
    Thanks for your help