[asterisk-users] prepaid approach

Nhadie nhadie at gmail.com
Mon Oct 20 19:40:32 CDT 2008


hi,

for my multi-tenant pbx, i would like to approach prepaid like this:

when a customer dials number, i have an AGI that will determine what 
country was dialed and retrieve the rate from the rate table,

once the rate is retrieved, i will get the remaining balance of that 
customer nd compute how much time remaining based on the rte and the 
remaining balance. then i set that as an absolute timeout. after the 
call i update the balance depending on how much was used during the call.

my prob is, there are multiple user behind one customer, so when 1 user 
calls  i get the rate,get remaining balance, compute time remaining then 
while user 1 is engaged another user calls, since user 1 is not yet 
finish with the call the remaining balance is still the same for user 2 
even though user 1 has already used up some of the balance. is there 
anyway around this?

regards,
ron



More information about the asterisk-users mailing list