Hello,

On 28/03/14 19:58, Ryan Brindley wrote:
Hey community,

I'm trying to get a 2nd leg custom header value stored in my acc table.

Right now I'm appending the header with append_hf in a failure route and trying to use:

modparam("acc","db_extra","custom=$hdr(Custom)")

A sip trace shows the header was properly added and xlog output shows the proper $hdr(Custom) value just after I append the header, but the value doesn't show in acc.

are you using msg_apply_changes()? If not, then the appended header should not show up in xlog()


Does acc only read from the INVITE of the incoming leg?

Yes, the $hdr(...) points to headers in incoming request.

Any suggestions on how to get this 2nd leg INVITE header in acc is greatly appreciated.

Store the value in an $avp(...) or $xavp(...) and use it for accounting.

Cheers,
Daniel

Thanks in advance,

Ryan


_______________________________________________
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

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference - April 2-4, 2014, Berlin, Germany
http://www.kamailioworld.com