As well as providing outbound termination with A2Billing it’s also possible to provide DID/DDI numbers to your customers.
Here’s a quick guide to doing this with the SysAdminMan A2B100 template. This guide should be read in conjunction with this post for setting up outbound termination in A2Billing – http://sysadminman.net/blog/2011/a2b100-quick-start-guide-to-wholesale-with-a2billing-3127
First we need to pass the incoming DDI calls from our DDI provider to A2Billing. The exact steps might differ a little depending on your DDI provider. This example uses a free number from http://www.ukddi.com/
First we set the destination of the call with our DDI provider. This will pass the call to our Asterisk/A2Billing server. Here’s how to set the destination with ukddi.com –
Next, on our A2Billing server we need to tell Asterisk to pass the incoming call to A2Billing. We do this by modifying the file /etc/asterisk/extensions.conf. We need to add a couple of lines under the [default] setting. This will match the number we specified to the left of the @ sign in our ukddi destination, and pass the call to A2Billing –
This passes all calls that begin with the number 44203 to A2Billing (and a2billing-did is set to pass the call as a DDI/DID call, rather than, say, a calling card access call).
Next we need to reload the Asterisk dial plan to make those changes take effect –
Next we need to set that DDI/DID number up in A2Billing and assign it to a customer. Go to INBOUND DID, Add::Search, Add DID. Now enter the DID number (in the same format as before) and set any charging information –
Now the customer can either purchase that DDI through the customer interface, or we can allocate it to a customer. I’m going to allocate it to an A2Billing customer and pass the call to them.
Select INBOUND DID, Destination, Add Destination. For the Destination of the call I’m going to set [email protected]_server. This will pass the call to the remote Asterisk server, keeping the DDI number the same. This is a VOIP CALL so set that to Yes –
If everything is set up correctly A2Billing should pass the call through to the remote server and we should see the entry in the A2Billing CDR’s –