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 <infinica...@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 <mico...@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.

1) Add a field called "credits" in the database. And topup that field.

2) First compute max permitted duration for that user by multiplying
the cost for number prefix (say +91) and pulse.

3) 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



--
Alex Balashov | Principal | Evariste Systems LLC
1447 Peachtree Street NE, Suite 700
Atlanta, GA 30309
United States

Tel: +1-800-250-5920 (toll-free) / +1-678-954-0671 (direct)
Web: http://www.evaristesys.com/, http://www.csrpswitch.com/

_______________________________________________
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

Reply via email to