What you're asking for is fairly complex. I think if you want step-by-step guidance or implementation, you're going to have to look to commercial consulting.
On 08/05/2016 11:04 PM, Infinicalls Infinicalls wrote:
Hi, Can somebody give a step by step tutorial on this. I am still not able to get it working. Thanks.
regards Ganesh Kumar
On 8/4/16, Infinicalls Infinicalls infinicalls@gmail.com wrote:
Hi Daniel, Thanks. I have added credits in Subscriber. But where exactly should I insert the SQL statements in kamailio.cfg so that it gets executed for each and every call. The rate_unit multiplied with time_unit in billing_rates should be done in realtime, I guess.
Also is it possible to check for credits > 0 in Auth and disconnect the user if this condition is not met.
regards Ganesh Kumar
On 8/3/16, Daniel-Constantin Mierla miconda@gmail.com wrote:
Hello,
On 02/08/16 07:36, Infinicalls Infinicalls wrote:
Hi, I am still struggling to get a prepaid system for my service.
After installing SIREMIS, I am able to get the CDRs updated. But even after adding the cron settings, the call duration doesn't get updated.
And also in
http://lists.sip-router.org/pipermail/sr-users/2012-January/071517.html
it has been mentioned that
"If it is the case of 1 call per user at a time, then practically can be done from kamailio config only. When call starts, compute the max duration for that call based on caller/destination (e.g., call a stored procedure via sqlops) and set the dialog timeout to that duration. When call ends (BYE in main route or timeout route) update the credit accordingly."
Can somebody let me know if my understanding is correct.
Add a field called "credits" in the database. And topup that field.
First compute max permitted duration for that user by multiplying
the cost for number prefix (say +91) and pulse.
- And finally add this value to timeout of dialog. modparam("dialog",
"default_timeout", 100000) $dlg_ctx(timeout_bye) = 1;
Will this work? Any help would be appreciated.
That should work, you also need to deduct the used credit when the call is ended.
Cheers, Daniel
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users