<div dir="ltr">Greetings list, <div><br></div><div>I am trying to get profile size with jsonrpc-s module. Below is jsonrpc-s configuration and a curl command to get the profile  size. </div><div><br></div><div><span style="font-size:12.8px">listen=tcp:</span><a href="http://0.0.0.0:5060/" rel="noreferrer" target="_blank" style="font-size:12.8px">0.0.0.0:5060</a><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">loadmodule "xhttp"</span><br style="font-size:12.8px"><span style="font-size:12.8px">loadmodule "jsonrpc-s"</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">modparam("xhttp", "url_match", "^/rpc_path/")</span><br style="font-size:12.8px"><span style="font-size:12.8px">modparam("jsonrpc-s", "pretty_format", 1)</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">event_route[xhttp:request] {</span><br style="font-size:12.8px"><span style="font-size:12.8px">   if($hu =~ "^/rpc_path")</span><br style="font-size:12.8px"><span style="font-size:12.8px">      jsonrpc_dispatch();</span><br style="font-size:12.8px"><span style="font-size:12.8px">   else</span><br style="font-size:12.8px"><span style="font-size:12.8px">      xhttp_reply("404", "Not Found", "text/html", "");</span><br style="font-size:12.8px"><span style="font-size:12.8px">}</span><br></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">curl -v -H 'Content-Type: application/json' -H 'Call-ID: abc12' -d '{"jsonrpc": "2.0", "method": "dlg.profile_get_size","params":{"accountno": "1234567"}, "id": "0deadb33f"}' <a href="http://127.0.0.1:5060/rpc_path/">http://127.0.0.1:5060/rpc_path/</a></span><br></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">I am getting this in respose.</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px"> * Hostname was NOT found in DNS cache</span></div><div><span style="font-size:12.8px">*   Trying 127.0.0.1...</span></div><div><span style="font-size:12.8px">* Connected to 127.0.0.1 (127.0.0.1) port 5060 (#0)</span></div><div><span style="font-size:12.8px">> POST /rpc_path/ HTTP/1.1</span></div><div><span style="font-size:12.8px">> User-Agent: curl/7.38.0</span></div><div><span style="font-size:12.8px">> Host: <a href="http://127.0.0.1:5060">127.0.0.1:5060</a></span></div><div><span style="font-size:12.8px">> Accept: */*</span></div><div><span style="font-size:12.8px">> Content-Type: application/json</span></div><div><span style="font-size:12.8px">> Call-ID: abc12</span></div><div><span style="font-size:12.8px">> Content-Length: 106</span></div><div><span style="font-size:12.8px">></span></div><div><span style="font-size:12.8px">* upload completely sent off: 106 out of 106 bytes</span></div><div><span style="font-size:12.8px"><b>< HTTP/1.1 404 Profile not found: 1234567</b></span></div><div><span style="font-size:12.8px">< Sia: SIP/2.0/TCP <a href="http://127.0.0.1:49374">127.0.0.1:49374</a></span></div><div><span style="font-size:12.8px">< Call-ID: abc12</span></div><div><span style="font-size:12.8px">< Content-Type: application/json</span></div><div><span style="font-size:12.8px">* Server kamailio (4.4.1 (x86_64/linux)) is not blacklisted</span></div><div><span style="font-size:12.8px">< Server: kamailio (4.4.1 (x86_64/linux))</span></div><div><span style="font-size:12.8px">< Content-Length: 106</span></div><div><span style="font-size:12.8px"><</span></div><div><span style="font-size:12.8px">{</span></div><div><span style="font-size:12.8px">        "jsonrpc":      "2.0",</span></div><div><span style="font-size:12.8px">        "error":        {</span></div><div><span style="font-size:12.8px">                "code": -32000,</span></div><div><span style="font-size:12.8px">                "message":      "Execution Error"</span></div><div><span style="font-size:12.8px">        },</span></div><div><span style="font-size:12.8px">        "id":   "0deadb33f"</span></div><div><span style="font-size:12.8px">* Connection #0 to host 127.0.0.1 left intact</span></div><div><br></div><div>Whereas fifo command gives me this. <br></div><div><div>root@debian:/usr/local/kamailio/sbin# ./kamctl fifo profile_get_size accountno 1234567</div><div>profile::  name=accountno value=1234567 count=2</div></div><div><br></div><div><br></div><div>Why jsonrpc-s is search for profile 1234567 whereas profile should be accountno. <br><br>Anyhelp what i am doing wrong here is much appreciated. </div><div><br></div><div>Best Regards. </div></div>