From Theodor.Scherney@kontron.com Thu Mar 23 08:37:37 2023 From: Scherney Theodor To: sr-dev@lists.kamailio.org Subject: [sr-dev] $avp(id) - AVPs - Problem Date: Thu, 23 Mar 2023 08:37:27 +0000 Message-ID: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0727907996==" --===============0727907996== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hello, http://www.kamailio.org/wiki/cookbooks/5.5.x/pseudovariables#avp_id_-_avps AVPs are special variables that are attached to SIP transactions. It is R/W variable (you can assign values to it directly in configuration fil= e). Call scenario: Alice calls Bob. Here I set the AVP: route[REQINIT] { if (is_method("INVITE")){ $avp(ICID_AVP) =3D $hdr(P-Charging-Vector); } Receiving 200 Ok at onreply_route[term_reply] { } I can access the AVP. Other scenario: Alice calls Bob. Alice cancels the call. In this case I can't access the AVP. route[term_subsequent] { if (is_method("CANCEL")){ if (t_lookup_cancel()) { xlog("L_INFO", "INVITE transaction exists"); xlog("L_INFO", "ICID_AVP [$avp(ICID_AVP)]\n"); } } } 2023-03-23T09:11:56.332778+01:00 172.29.21.53 vict2-scscf[44536] - [logSDID(a= )20306 resource=3D"xlog"] INFO: