<div dir="ltr">Hi again,<div><br></div><div>Thanks for help Daniel, it helps much</div><div><br></div><div>Regards,</div><div>Melek</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Sep 24, 2019 at 10:53 AM Daniel-Constantin Mierla <<a href="mailto:miconda@gmail.com">miconda@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div bgcolor="#FFFFFF">
<p>Hello,</p>
<p>have you looked at jansson module? Is it not offering what you
need?</p>
<p>Cheers,<br>
Daniel<br>
</p>
<div class="gmail-m_440789192180157530moz-cite-prefix">On 24.09.19 10:42, Melek Oktay wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">Hi,
<div><br>
</div>
<div>I am trying to monitor <b>uac </b>channels status
periodically in kamailio config file.</div>
<div>I call
uac.reg_dump rpc command and result will be inside in
$var(uac_channel) variable</div>
<div><br>
</div>
<div> jsonrpc_exec('{"jsonrpc": "2.0", "method":
"uac.reg_dump"}');<br>
</div>
<div> $var(uac_channel) = $jsonrpl(body);<br>
</div>
<div><br>
</div>
<div>it returns me json formatted result like below, it has a
several channels info and their status <b>flags</b></div>
<div><br>
</div>
<div>{"jsonrpc":"2.0", "result":[ </div>
<div>{"l_uuid":"YY","l_username":"YY","l_domain":"YY","r_username":"YY",".,
"<b>flags</b>":16 },<br>
{"l_uuid":"XX","l_username":"XX","l_domain":"XX","r_username":"XX",,...
"<b>flags</b>":1 }}]}<br>
</div>
<div><br>
</div>
<div>I could not parse this result on kamailio.cfg file ! I want
to learn channel that has a 16 value in flag attribute for
example !!</div>
<div><br>
</div>
<div>Would you help me to figure out how I am gonna parse this
json file please ?</div>
<div><br>
</div>
<div><br>
</div>
</div>
<br>
<fieldset class="gmail-m_440789192180157530mimeAttachmentHeader"></fieldset>
<pre class="gmail-m_440789192180157530moz-quote-pre">_______________________________________________
Kamailio (SER) - Users Mailing List
<a class="gmail-m_440789192180157530moz-txt-link-abbreviated" href="mailto:sr-users@lists.kamailio.org" target="_blank">sr-users@lists.kamailio.org</a>
<a class="gmail-m_440789192180157530moz-txt-link-freetext" href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<pre class="gmail-m_440789192180157530moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="gmail-m_440789192180157530moz-txt-link-abbreviated" href="http://www.asipto.com" target="_blank">www.asipto.com</a>
<a class="gmail-m_440789192180157530moz-txt-link-abbreviated" href="http://www.twitter.com/miconda" target="_blank">www.twitter.com/miconda</a> -- <a class="gmail-m_440789192180157530moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda" target="_blank">www.linkedin.com/in/miconda</a>
Kamailio Advanced Training, Oct 21-23, 2019, Berlin, Germany -- <a class="gmail-m_440789192180157530moz-txt-link-freetext" href="https://asipto.com/u/kat" target="_blank">https://asipto.com/u/kat</a></pre>
</div>
</blockquote></div>