Module: kamailio
Branch: master
Commit: 4a4dbdbe8e683d4f3e081391e54a9f2489c7d5ae
URL:
https://github.com/kamailio/kamailio/commit/4a4dbdbe8e683d4f3e081391e54a9f2…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2019-05-15T14:25:24+02:00
tm: docs for t_get_status_code()
---
Modified: src/modules/tm/doc/functions.xml
---
Diff:
https://github.com/kamailio/kamailio/commit/4a4dbdbe8e683d4f3e081391e54a9f2…
Patch:
https://github.com/kamailio/kamailio/commit/4a4dbdbe8e683d4f3e081391e54a9f2…
---
diff --git a/src/modules/tm/doc/functions.xml b/src/modules/tm/doc/functions.xml
index 67cc5d017c..ce0e84261c 100644
--- a/src/modules/tm/doc/functions.xml
+++ b/src/modules/tm/doc/functions.xml
@@ -1845,6 +1845,24 @@ if (t_is_retr_async_reply()) {
...
t_uac_send("OPTIONS", "sip:alice@kamailio.org", "",
"",
"From: bob(a)kamailio.org;tag=2w3e\r\nTo: bob(a)kamailio.org"quot;, "");
+...
+ </programlisting>
+ </example>
+ </section>
+ <section id="tm.f.t_get_status_code">
+ <title>
+ <function>t_get_status_code()</function>
+ </title>
+ <para>
+ Return the status code for transaction - the most relevant SIP reply status
+ code, or -1 in case of error or no status code was set.
+ </para>
+ <example>
+ <title><function>t_get_status_code</function> usage</title>
+ <programlisting>
+...
+$var(ts) = t_get_status_code();
+if($var(ts) == 500) { ... }
...
</programlisting>
</example>