zenithbsolutions wrote:Hi,
We have a requirement where the inbound calls are routed to vicidial using IP Authentication. Now we have to do is route all the inbound calls to an external DID number.
My question is how can we transfer the IP Authentication Inbound call to the DID, Cause what we did till now was to setup a Inbound DID number for inbound group and later route it to another DID. But here there is no inbound DID number no inbound group we just need to transfer all the inbound call traffic to a DID number.
Can it be achieved through dial plan or through inbound group itself.
All your suggestions are appreciated.
Thank you.
If your carrier is set up properly, it will have an entry for "context=trunkinbound" in the sip account entry. Since the SIP account also has the IP address, this means you now have "IP => trunkinbound" mapped and you've seen how that works.
"trunkinbound" is in "extensions.conf" in the /etc/asterisk folder. It directs the inbound calls to the Vicidial DID call routing system by invoking an AGI script (read the file, you'll see it). Once the agi script takes control: if the call does not have a specific DID (extension), the call will land in the "default" DID (available in the Vicidial system under "Inbound -> Show DIDs").
Here you have two options:
1) Use the Default DID to perform your forwarding. Pro: Proves that the system will work. Con: Will only allow "all", not specific to an IP address.
2) Modify "context=trunkinbound" to "context=trunkIPxxxxxx" where xxxxxx is an identifier for this IP address. Then you can copy the pertinent lines from trunkinbound that will route the call to the vicidial agi script, but first you can alter the dialplan to send the call to a specific DID using the extension language of Asterisk. "Goto(extension,priority)" willl allow you to change the extension. Then you can send the call to the agi script at the new extension, and set up a DID for that new extension you just made up. A simple method could be to use the Goto(context,extension,priority) version of the command Goto: to send the call to the trunkinbound context and the DID you wanted to route to. Thus the "context=trunkIPxxxxxx" would have only one line in it to bounce the call to the DID of your choice.
Note: In ALL contexts you create in extensions.conf, you should remember to put a copy of the hangup agi line. You'll see it in every context, often right at the end.