[Users] example for Multi Call-Legs accounting please

Andreas Granig andreas.granig at inode.info
Thu Jun 8 01:13:08 CEST 2006


Rafael J. Risco G.V. wrote:
> Hi
> I was searching in the entire list archive but there was not a single
> post about multi call-leg containing a script example to use this
> module, I need call forwarding (busy/no answer) accounting, please
> someone help me.

Don't know an example by heart, but basically you have to set both 
source and destination leg AVPs of each pair {AB}, {BC} in a forward 
scenario. So if for example A calls B and B forwards to C, you may set 
the uuid of A as src-leg-avp and the uuid of B as dst-leg-avp for the 
first accounting record, and after you know that B forwards to C, you 
may set the uuid of B as the src-leg-avp and the uuid of C as 
dst-leg-avp of the second accounting record.

For a real-world example, I don't only set the uuid of the UACs, but use 
avp_printf for creating a CSV-style AVPs which include the client's 
uuid, uri, a call-status (if acc-record is a call, an unconditional 
call-forward etc.) along with some additional information, which is 
evaluated by a mediation software for creating proper CDRs.

Hope this helps,
Andy




More information about the Users mailing list