Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Wed Jun 03, 2026 5:29 am
VoIP Billing solution


All times are UTC




Post new topic Reply to topic  [ 13 posts ] 
Author Message
 Post subject: Incoming Trunk, context issue
PostPosted: Wed Jun 11, 2008 10:26 pm 
Offline

Joined: Thu May 15, 2008 1:29 pm
Posts: 70
Location: Miami
I am testing an Inphonex DID for incoming call to trixbox.

Outgoing Setting:

[inphonex]
username=xxxxxxx
type=peer
secret=secret
host=sip.inphonex.com
fromuser=xxxxxxx
fromdomain=sip.inphonex.com
context=from-inphonex
canreinvite=no

Incoming settings:

[sip.inphonex.com]
context=from-pstn
username=xxxxxxx
user=xxxxxxx
type=friend
insecure=very
host=sip.inphonex.com
fromdomain=sip.inphonex.com


Registration:

user:[email protected]

I can make and receive calls, but when I change context=a2billing can't receive calls. How can I make this trunk work with A2Billing?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 12, 2008 12:14 am 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
Create a new inbound route that delivers the call to a Custom App set to: a2billing,$EXTEN,1


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 12, 2008 11:28 pm 
Offline

Joined: Thu May 15, 2008 1:29 pm
Posts: 70
Location: Miami
I create and inbound route with custom-a2billing,${EXTEN},1

But call don't go thru. This is the log:


Executing [s@from-pstn:1] Set("SIP/3884000-0a0ac9a8", "__FROM_DID=s") in new stack
-- Executing [s@from-pstn:2] GotoIf("SIP/3884000-0a0ac9a8", "1 ?cidok") in new stack
-- Goto (from-pstn,s,4)
-- Executing [s@from-pstn:4] NoOp("SIP/3884000-0a0ac9a8", "CallerID is "Unknown" <xxxxxxxxx>") in new stack
-- Executing [s@from-pstn:5] Goto("SIP/3884000-0a0ac9a8", "custom-a2billing|s|1") in new stack
-- Goto (custom-a2billing,s,1)


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 12, 2008 11:39 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
That all looks good so far. What did it say next? Can we see your custom-a2billing context?


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 13, 2008 12:58 am 
Offline

Joined: Thu May 15, 2008 1:29 pm
Posts: 70
Location: Miami
You mean this on extensions_a2billing.conf


[custom-a2billing]
exten => _X.,1,Answer
exten => _X.,n,Wait(1)
exten => _X.,n,DeadAGI(a2billing.php|1)
exten => _X.,n,Hangup


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 13, 2008 1:13 am 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
Again that looks good.
So what did it say after those earlier messages you quoted? From what I can see so far it should be working.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 13, 2008 2:35 am 
Offline

Joined: Thu May 15, 2008 1:29 pm
Posts: 70
Location: Miami
It just give me a network busy signal (Not a recording)


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 13, 2008 2:51 am 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
What did the Asterisk console say after those messages you quoted earlier?
It might help to diagnose the problem if you increase Asterisk's verbosity level to it's maximum:
Code:
core set verbose 15


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 13, 2008 4:03 am 
Offline
User avatar

Joined: Mon Apr 30, 2007 6:43 am
Posts: 1060
Location: Canada
This type of situation has been resolved in the paste and here is how.

First of all, keep in mind that freepbx does not allow the use of asterisk's extension matching patterns when calling a custom application.

You might need to create a custom or misc destination that matches the DID number from which the call is going to come from; for instance: 2345678901

Now in freepbx, use the inbound menu to send the incoming call to the right place. Instead of sending the call to custom_yourcontext,s,1 ... send it to custom_yourcontext,2345678901,1

and somewhere create an extension that will be within reach.

[custom_yourcontext]
...
exten => 2345678901,1,Goto(a2billing,${EXTEN},1)

This should send the call successfully to a2billing assuming that you have a context called [a2billing].

Cheers


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 17, 2008 10:10 pm 
Offline

Joined: Thu May 15, 2008 1:29 pm
Posts: 70
Location: Miami
asiby I finally got a chance to test your config and it does work. One of the issues I have is that Inphonex is not sending DID info on the call. Thanks


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 19, 2008 1:09 am 
Offline
User avatar

Joined: Mon Apr 30, 2007 6:43 am
Posts: 1060
Location: Canada
Ok. Some providers have a check box somewhere in the DID settings that makes it send the DID information during the call.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Sep 25, 2008 7:45 pm 
Offline

Joined: Wed Sep 24, 2008 12:59 am
Posts: 8
This is kind of weird that it works this way. . .

http://pbxinaflash.com/forum/showthread ... #post13482

I implemented the outgoing trunk fine, but I couldn't for the life of me get the incoming to route correctly. It was driving me mad.

Then I just did this routing game as seen above in asiby's post and it works.

Is there a post that explains why we have to go through this process?

Added after 6 minutes:

I figured out a more straightforward way to do this.

My "Custom Destination" is this:

custom-a2billing,9876,1


Then under extensions_a2billing.conf I put this in:

[custom-a2billing]
exten => 9876,1,Answer
exten => 9876,n,Wait(1)
exten => 9876,n,DeadAGI(a2billing.php|1)
exten => 9876,n,Hangup


And it seems to work with incoming calls to route it that way. The installation guide originally has _X. instead of 9876. But it seems if I manually assign the extension it work, whereas when I kept it at the tutorial version, it wouldn't. THe ones that didn't seem to work were these:

[custom-a2billing]
exten => _X.,1,Answer
exten => _X.,n,Wait(1)
exten => _X.,n,DeadAGI(a2billing.php|1)
exten => _X.,n,Hangup

"Custom Destionation:
custom-a2billing,${EXTEN},1


I don't really know the default doesn't work. . .


asiby wrote:
This type of situation has been resolved in the paste and here is how.

First of all, keep in mind that freepbx does not allow the use of asterisk's extension matching patterns when calling a custom application.

You might need to create a custom or misc destination that matches the DID number from which the call is going to come from; for instance: 2345678901

Now in freepbx, use the inbound menu to send the incoming call to the right place. Instead of sending the call to custom_yourcontext,s,1 ... send it to custom_yourcontext,2345678901,1

and somewhere create an extension that will be within reach.

[custom_yourcontext]
...
exten => 2345678901,1,Goto(a2billing,${EXTEN},1)

This should send the call successfully to a2billing assuming that you have a context called [a2billing].

Cheers


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 20, 2008 12:14 am 
Offline

Joined: Wed Feb 13, 2008 11:11 am
Posts: 224
Quote:
jeffersonkim
My "Custom Destination" is this:

custom-a2billing,9876,1


Then under extensions_a2billing.conf I put this in:

[custom-a2billing]
exten => 9876,1,Answer
exten => 9876,n,Wait(1)
exten => 9876,n,DeadAGI(a2billing.php|1)
exten => 9876,n,Hangup


I have custom destination on extensions_a2billing.conf as

[custom-trunk]
exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,DeadAGI(a2billing.php|1)
exten => s,n,Hangup()

and my custom destination under in FreePBX is,

custom-trunk,s,1

It seems to work :wink:


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 13 posts ] 
VoIP Billing solution


All times are UTC


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group