{"id":751,"date":"2017-12-14T09:47:41","date_gmt":"2017-12-14T09:47:41","guid":{"rendered":"https:\/\/pandorafms.com\/library\/?p=751"},"modified":"2017-12-14T09:50:14","modified_gmt":"2017-12-14T09:50:14","slug":"freeswitch","status":"publish","type":"post","link":"https:\/\/pandorafms.com\/library\/freeswitch\/","title":{"rendered":"Freeswitch"},"content":{"rendered":"<p class=\"description_pui\">Several modules for freeswitch: Count of gateway, Count of Channels, Count of calls, Count of registrations.<\/p>\n<h2>Module data<\/h2>\n<p># Count of registrations\u00a0<\/p>\n<pre>module_begin\u00a0\r\nmodule_name FSRegnsCount\u00a0\r\nmodule_type generic_data\u00a0\r\nmodule_exec \/usr\/local\/freeswitch\/bin\/fs_cli -x \"show registrations count\" | awk '{if (match($0,\"total\")) { printf(\"%d\",$1);}}'\u00a0\r\nmodule_description FreeSWITCH registrations\u00a0\r\nmodule_end\u00a0<\/pre>\n<p># Count of calls\u00a0<\/p>\n<pre>module_begin\u00a0\r\nmodule_name FSCallsCount\u00a0\r\nmodule_type generic_data\u00a0\r\nmodule_exec \/usr\/local\/freeswitch\/bin\/fs_cli -x \"show calls count\" | awk '{if (match($0,\"total\")) { printf(\"%d\",$1);}}'\u00a0\r\nmodule_description FreeSWITCH calls\u00a0\r\nmodule_end\u00a0<\/pre>\n<p># Count of Channels\u00a0<\/p>\n<pre>module_begin\u00a0\r\nmodule_name FSChansCount\u00a0\r\nmodule_type generic_data\u00a0\r\nmodule_exec \/usr\/local\/freeswitch\/bin\/fs_cli -x \"show channels count\" | awk '{if (match($0,\"total\")) { printf(\"%d\",$1);}}'\u00a0\r\nmodule_description FreeSWITCH channels\u00a0\r\nmodule_end\u00a0<\/pre>\n<p># Count of gateways:\u00a0<\/p>\n<pre>module_begin\u00a0\r\nmodule_name FSGatesCount\u00a0\r\nmodule_type generic_data\u00a0\r\nmodule_exec \/usr\/local\/freeswitch\/bin\/fs_cli -x \"sofia status gateways\" | awk '{if (match($0,\"gateways:\")) { printf(\"%d\",$1);}}'\u00a0\r\nmodule_description FreeSWITCH gateways\u00a0\r\nmodule_end<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Several modules for freeswitch: Count of gateway, Count of Channels, Count of calls, Count of registrations. Module data # Count of registrations\u00a0 module_begin\u00a0 module_name FSRegnsCount\u00a0 module_type generic_data\u00a0 module_exec \/usr\/local\/freeswitch\/bin\/fs_cli -x &#8220;show registrations count&#8221; | awk &#8216;{if (match($0,&#8221;total&#8221;)) { printf(&#8220;%d&#8221;,$1);}}&#8217;\u00a0 module_description FreeSWITCH registrations\u00a0 module_end\u00a0 # Count of calls\u00a0 module_begin\u00a0 module_name FSCallsCount\u00a0 module_type generic_data\u00a0 module_exec \/usr\/local\/freeswitch\/bin\/fs_cli -x [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_et_pb_use_builder":"","_et_pb_old_content":"","_et_gb_content_width":"","footnotes":""},"categories":[7],"tags":[170],"_links":{"self":[{"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/posts\/751"}],"collection":[{"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/comments?post=751"}],"version-history":[{"count":0,"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/posts\/751\/revisions"}],"wp:attachment":[{"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/media?parent=751"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/categories?post=751"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pandorafms.com\/library\/wp-json\/wp\/v2\/tags?post=751"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}