Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Fri Apr 19, 2024 9:26 pm
VoIP Billing solution


All times are UTC




Post new topic Reply to topic  [ 13 posts ] 
Author Message
 Post subject: DID external database interation
PostPosted: Sat Nov 11, 2006 4:25 am 
Offline
Moderator
User avatar

Joined: Tue Jun 06, 2006 12:14 pm
Posts: 685
Location: florida
Hey - has anyone ever used like DIDX API or some method to integrate with them and A2billing?

Can you post how to do it ??


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 30, 2006 2:13 am 
Offline

Joined: Thu Nov 30, 2006 2:04 am
Posts: 40
I am also trying to implement the above scenarion relating to DIDX integration. Any help from the veterans would be useful.

Have you any luck so far Kryskat?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 30, 2006 2:48 am 
Offline
Moderator
User avatar

Joined: Tue Jun 06, 2006 12:14 pm
Posts: 685
Location: florida
Nope - no success right now. My current plan is to wait for the new A2B version to come out since I hear that it might have better DID integration with regards to automatic monthly billing and such. At that point, I guess we'll look into how hard the DID integration will be. I don't think it'll be that hard at that point. One thing to keep in mind will be the different pricing on DIDX and limiting your customers buying to not selecting real expensive routes.

Still looking, and glad to hear what others have to say. A couple people I know using A2B and DID are doing the DID portion by hand. (ugghh)


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 30, 2006 3:41 am 
Offline

Joined: Thu Nov 30, 2006 2:04 am
Posts: 40
I am still having trouble seting up the customer DID manually. I am new to a2billing (have been messing around for about 2 days now).I have created the DID groups,destinations etc however i would like to know how to activate the DID for the customer. The DID listed on the admin interface is active however after selecting the the DID on the customer interface the DID is stated as inactive.

How do I activate it manualy?

I have been thinkin, and I am sure that I must be wrong but do you think the following implementation of the DIDx API would work....

Instead of creating DID's in the admin may we...

1. Edit the DID php page ( the page where the customer usually selects the set up DIDs) to intergrate with the DIDX api ie.setup so that all DIDX available numbers are listed using the API

2.The customer has a look at the avaialble DID's and selects their choice eg 44208123456. At this point the selected DID is reserved (on your DIDX account) as normal with the DIDx API scripts

Then the same "number" selected eg. 44208123456 is posted to the database and linked to the customer account
and at the same time a DID is automatically created in the config files and allocated to the cutomer as usual (ie When the customer selects the DID in the current system)

3.Once payment is made for, example via paypal, the DID "number" is posted with the IP (or domain) using the DIDX API to set the sip uri for the DIDX number.
example: 44208123456@IP/domain is posted and set on the DIDX system as the sip URI. This is done via the DIDX API

4. Thus
>the DIDX number is forwarded to SIP URI 44208123456@IP/domain .
>DID set in the a2billing cofig files upon purchase ,44208123456 is linked to the customer. Similar to seting up IVR with DIDX number forwarded to sip uri which is infacted the DID number setup in a2billing
>The DID is setup now for the customer and all that is needed for him to complete is to set the destination number.

Well I am just fishing here and I am still a novice at a2billing as well as using API, asterisk and linux and I am sure that there are many things that I have either confused due to ignorance or misinformation, however I would like to know what you think and if this may work.

Please dont laugh if you think I am foolish. We all have to start somewhere I guess :wink:


Top
 Profile  
 
 Post subject:
PostPosted: Thu Nov 30, 2006 4:38 am 
Offline
Moderator
User avatar

Joined: Tue Jun 06, 2006 12:14 pm
Posts: 685
Location: florida
Basically I agree with you. But there is a lot of customization that has to be done in order for it to work properly (which is why I'm just waiting). The problem is a couple of the limitations currently in A2B. (I could be wrong so if I am please correct me) but I believe your issues are:

#1) having a DID selected for a client - others still get to try to select it - so you need to lock it down so that only that clients sees it. Since you are using the DIDx AGI anyhow, I'd simply eliminate the one portion of A2B that allows customers to select their DID to purchase from the available list.

#2) How do you bill your customers for the DID ? I know there is a section that say's bill minutes + monthly ... but as far as i've tried, there is no CRON or anything that can properly do the billing at this point.

Honestly I don't think you're out of line with what you want to do and accomplish, but it'll take some work.

To activate it manually just to see it work, you need to setup in A2billing a DID, then setup a DID destination - which will basically say priority = 1, and then the card # its attached to, and then the destination for it - such as SIP/12345
Next, you must make sure that the call coming in knows where its supposed to go. This means modifying your sip.conf to have incoming calls going toa context such as a2billing-DID then having that context exist in extensions.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Dec 01, 2006 2:04 am 
Offline

Joined: Thu Nov 30, 2006 2:04 am
Posts: 40
I do understand a little of what you are saying however I cant get it to work... I will try again

I would just like to know what happens when the customer selects the DID from the customer interface.

Is the DID alocated to the customer?

Does the system setup the sip.config and extensions files automatically when the DID is selected? If not then what is the actual use of the DID page on the customer interface.

By the way, do you have a working example of the DIDX API or know where I might find one?

Again... thank you for your time... Most times posts on this forum dont get answered


Top
 Profile  
 
 Post subject:
PostPosted: Fri Dec 01, 2006 3:23 am 
Offline
Moderator
User avatar

Joined: Tue Jun 06, 2006 12:14 pm
Posts: 685
Location: florida
I Might be wrong, but my knowledge is:

#1) DID selected from interface ... -> nothing - I never got it to write anything for it.

#2) DID allocated to customer - I didn't see where it does that, although there is a field in the database for customer ID.

#3) Sip.conf or extensions.conf updated - NOPE - doesn't do that - that's your job and responsibility. Use of the DID page on ustomer interface ... well to me its the setup for what it WILL DO in future. The DID destination part works though.

#4) DIDX API sample code with A2B, no clue - never seen or heard of one.

#5) posts don't get answered ... I think the reason is that most questions are already answered if someone takes the time to research questions and people get tired of answering already answered questions. Additionally, I think some people find that they busted their ass with trial and error, and they just think that others should go through the same efforts.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Dec 01, 2006 4:15 am 
Offline

Joined: Mon May 29, 2006 7:07 pm
Posts: 287
Location: Denver
My DID experience - most of everything i have to do manually.
I create DID group, add DID number, make sure custumer has DIDGROUP enabled.

Then customer is able to see it in the interface ( the problem he sees all the available and taken DIDs!!!!). Then he can select and purchase it. At this point DID is inactive and system sends an email to me.
-------------
The following Destinaton-DID has been added:

INSERT INTO cc_did_destination (activated, id_cc_card, id_cc_did, destination, priority, voip_call) VALUES ('0', '1', '6', '12001211212', '1', '1')
-------------------
The next i log in, activate the DID destination and edit extensions.conf file.
I add line
exten => 12001211212,3,DeadAGI(a2billing.php|1|did)

The call out, call history is working. The billing ( fix rate for DID ) is not. There is no cron service. Also don't know anything about DIDX API.


Top
 Profile  
 
 Post subject: solution to no 1
PostPosted: Fri Dec 01, 2006 4:54 pm 
Offline

Joined: Fri Sep 22, 2006 1:56 pm
Posts: 5
krzykat wrote:
Basically I agree with you. But there is a lot of customization that has to be done in order for it to work properly (which is why I'm just waiting). The problem is a couple of the limitations currently in A2B. (I could be wrong so if I am please correct me) but I believe your issues are:

#1) having a DID selected for a client - others still get to try to select it - so you need to lock it down so that only that clients sees it. Since you are using the DIDx AGI anyhow, I'd simply eliminate the one portion of A2B that allows customers to select their DID to purchase from the available list.


Solution to number 1 if your Mysql version is greater than bersion 4 is

Look in A2BCustomer_UI/A2B_entity_did.php for


// $instance_table_did = new Table("cc_did", "id, did, fixrate");
// $FG_TABLE_CLAUSE = "id_cc_country=$choose_country and id_cc_didgroup='".$_SESSION["id_didgroup"]."' and activated='1' and id NOT IN (select id_cc_did from cc_did_destination)";

// FIX SQL for Mysql < 4 that doesn't support subqueries
$instance_table_did = new Table("cc_did LEFT JOIN cc_did_destination ON cc_did.id!=cc_did_destination.id", "DISTINCT cc_did.id, did, fixrate");
$FG_TABLE_CLAUSE = " id_cc_country=$choose_country and id_cc_didgroup='".$_SESSION["id_didgroup"]."' and cc_did.activated='1'";


and replace with

$instance_table_did = new Table("cc_did", "id, did, fixrate");
$FG_TABLE_CLAUSE = "id_cc_country=$choose_country and id_cc_didgroup='".$_SESSION["id_didgroup"]."' and activated='1' and id NOT IN (select id_cc_did from cc_did_destination)";

// FIX SQL for Mysql < 4 that doesn't support subqueries
// $instance_table_did = new Table("cc_did LEFT JOIN cc_did_destination ON cc_did_destination.id != cc_did.id", "DISTINCT cc_did.id, did, fixrate");
// $FG_TABLE_CLAUSE = " id_cc_country=$choose_country and id_cc_didgroup='".$_SESSION["id_didgroup"]."' and cc_did.activated='1'";


basically uncomment the top sql statement and comment the old one


Top
 Profile  
 
 Post subject:
PostPosted: Sat Dec 02, 2006 1:52 am 
Offline

Joined: Mon May 29, 2006 7:07 pm
Posts: 287
Location: Denver
Thanks brosdee, 1 fixed, 12 bugs to go. :D


Top
 Profile  
 
 Post subject: DID ordering API
PostPosted: Tue May 13, 2008 4:42 am 
Offline
User avatar

Joined: Tue May 13, 2008 4:37 am
Posts: 22
Location: Coeur d Alene, Id
Has anyone got anything new on this??? Im looking to use my providers API for DID access to allow my customers to select DIDs and then provision to their account, thoughts?


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 07, 2008 6:41 am 
Offline
User avatar

Joined: Tue May 13, 2008 4:37 am
Posts: 22
Location: Coeur d Alene, Id
**Bump**


Top
 Profile  
 
 Post subject: Re: DID ordering API
PostPosted: Mon Jul 07, 2008 2:05 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
ajohnson353 wrote:
Has anyone got anything new on this??? Im looking to use my providers API for DID access to allow my customers to select DIDs and then provision to their account, thoughts?
Sure, if you're handy with PHP there's nothing stopping you from doing this.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 13 posts ] 
Predictive Dialer


All times are UTC


Who is online

Users browsing this forum: No registered users and 17 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