<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">Thanks.<DIV><BR class="khtml-block-placeholder"></DIV><DIV>I understand your POV. However, in addition to usage-based billing (which is what you refer to), I need to bill for the account. So, if the user placed two simultaneous calls with the same account, that may be fine because it could have been the call-waiting feature. However, if the user placed more than 2 simultaneous calls, then I should bill the user for an additional account or something like CEILING(n/2) accounts where n is the number of simultaneous calls.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Note that a simultaneous calls is a call which overlaps the another call. For example, call A starts at 10:30AM and lasts 15 minutes. Call B starts at 10:34AM and lasts for 20 minutes. Call C starts at 10:44AM and lasts for 3 minutes. In this case, I should bill the user for 2 accounts plus usage.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Does astbill allow me to do this?</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Thanks,</DIV><DIV>Waldo</DIV><DIV><BR><DIV><DIV>On Oct 11, 2005, at 6:17 AM, Are wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"><P class="MsoNormal">Have a look at <A href="http://astbill.com">http://astbill.com</A> it is FREE and Open SOURCE.<BR> <BR> 4) Because this (item 3) has already happened to me, is there any<BR> free tool out there that will allow me to parse the CDR logs in order<BR> to determine the maximum number of simultaneous calls that a<BR> particular SIP peer has made within a specific timeframe? That way, I<BR> could potentially bill the client for 2 accounts instead of 1.<BR> <BR> AstBill is a FREE real time billing engine for Asterisk. By using AstBill to process your Asterisk calls you get real time credit control of your customers.<BR> <BR> When any SIP or IAX client places a call AstBill will do a credit control. If the account has Sufficient founds to place a call then AstBill will calculate the amount needed for the duration of the call. (By default calls disconnect after max 60 minutes. You can change that.) AstBill will create a record in the MySQL table 'astcreditres' with the uniqueid, user and MAX COST of the call. Next time somebody are using the same account to make a call AstBill will check that there are founds available for the customer and deduct any entry reserved for that customer in the MySQL table 'astcreditres' before AstBill decide the max length of the call the client is allowed to use.</P><P class="MsoNormal">The CDR in AstBill have two parts. When the call is initiated the CDR info available is stored in the table 'astcdr'. When the call is terminated the rest of the information about the call is updated in the CDR. The cost of the call is calculated and deducted from the customers balance. The record for reserved founds in 'astcreditres' is deleted <SPAN style=""> </SPAN>There are some advantages to this as it allows us to query the database at any time to know how many calls are currently being processed without using the Asterisk Manager Interface.<BR> <BR> I hope this is useful information and if you have more questions about AstBill please feel free to use the forums at <A href="http://astbill.com/forum/3">http://astbill.com/forum/3</A> </P><P class="MsoNormal">Please download AstBill now and have a look. <A href="http://astbill.com/">http://astbill.com</A></P> Are Casilla<BR> <A href="http://astartelecom.com">http://astartelecom.com</A> - Independent VOIP Telecoms Broker. Asterisk and Drupal Consultants<BR> <A href="http://astbill.com">http://astbill.com</A> - Billing, Routing and Management software for Asterisk and VOIP<BR> AstBill DEMO: <A href="http://demo.astbill.com">http://demo.astbill.com</A><BR> <BR> <BR> <BR></BLOCKQUOTE></DIV><BR></DIV></BODY></HTML>