<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">You can use an event hook from mod_lua to execute a lua script on unregister event. <br></div><div dir="ltr">Add "<hook event="custom" subclass="sofia::unregister" script="logout_callcenter.lua" />" in lua.conf.xml</div><div dir="ltr"><br></div><div>In the script you can do whatever you want, for example logout from callcenter.<br></div>>>freeswitch.consoleLog("INFO","Executing logout_callcenter.lua\n");<br>>>local username = event:getHeader("username");<br>>>local from_user = event:getHeader("from-user");<br>>>freeswitch.consoleLog("INFO","username: " .. (username or "") .."\n");<br>>>freeswitch.consoleLog("INFO","from-user: " .. (from_user or "") .."\n");<br>>><br>>>if (username ~= nil) then<br>>>    api = freeswitch.API();<br>>>    result = api:execute("callcenter_config", "agent set status "..username.." 'Logged Out'");<br>>>    freeswitch.consoleLog("INFO", "Execute on unregister: ".. result .. "\n")<br>>>end</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Mar 12, 2019 at 8:26 PM mario_fs <<a href="mailto:mario_fs@mgtech.com">mario_fs@mgtech.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 style="overflow-wrap: break-word;">Still no luck on this and I really need to know date/time when a particular extension is unregistering. Anyone else have an idea that does not involve programming? Thanks,<div>Mario G<br><div><br><blockquote type="cite"><div>On Feb 20, 2019, at 9:16 AM, mario_fs <<a href="mailto:mario_fs@mgtech.com" target="_blank">mario_fs@mgtech.com</a>> wrote:</div><br class="gmail-m_2857438639847486835Apple-interchange-newline"><div><div style="overflow-wrap: break-word;">I have been searching the wiki and web and still nothing simple to log de-registrations. I find it hard to believe there is not a simple way to do this, anyone have a good idea?<div>Mario G<br><div><br><blockquote type="cite"><div>On Feb 15, 2019, at 9:46 AM, mario_fs <<a href="mailto:mario_fs@mgtech.com" target="_blank">mario_fs@mgtech.com</a>> wrote:</div><br class="gmail-m_2857438639847486835Apple-interchange-newline"><div><div style="overflow-wrap: break-word;">Hmmmm…. Logging de-registrations would be a useful enhancement to FreeSwitch for debugging issues like this. I know a SIP trace does it but that’s a LOT of data when we're talking days. Thanks.<div>Mario G<br><div><br><blockquote type="cite"><div>On Feb 15, 2019, at 12:05 AM, Avi Marcus <<a href="mailto:avi@avimarcus.net" target="_blank">avi@avimarcus.net</a>> wrote:</div><br class="gmail-m_2857438639847486835Apple-interchange-newline"><div><div dir="ltr"><div dir="ltr">Here's some old nodejs code relying on `esl` lib to monitor for de-registrations and send me an email. I haven't used it in ages.<div><br></div><div><a href="https://gist.github.com/avimar/9645dd3134476d458e68cca077f4ed16" target="_blank">https://gist.github.com/avimar/9645dd3134476d458e68cca077f4ed16</a></div><div><br></div><div><br clear="all"><div><div dir="ltr" class="gmail-m_2857438639847486835m_-6791474544660118792gmail_signature"><div dir="ltr"><div><div dir="ltr">-Avi Marcus<br>BestFone</div></div></div></div></div><br></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Feb 15, 2019 at 12:13 AM mario_fs <<a href="mailto:mario_fs@mgtech.com" target="_blank">mario_fs@mgtech.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>Does anyone know if there is something I can do to log device registrations, and more importantly when devices lose registration, <i>without having a ton of other log data</i>. I know I can turn on a higher level of diagnostics, but it may be several days before I find what I need and don’t want to flood the log.<div><br></div><div>I am working with Counterpath on Bria Push service and need to find when their push server stops registering. Since they don’t send a notification for that and it’s not in the normal FS log, I may not know for days when this happens. It would be nice to be able to scan the log for lost registrations. Thanks!</div><div>Mario G</div></div>_________________________________________________________________________<br>
Professional FreeSWITCH Services<br>
<a href="mailto:sales@freeswitch.com" target="_blank">sales@freeswitch.com</a><br>
<a href="https://freeswitch.com/" rel="noreferrer" target="_blank">https://freeswitch.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="https://freeswitch.com/oss" rel="noreferrer" target="_blank">https://freeswitch.com/oss</a><br>
<a href="https://freeswitch.org/confluence" rel="noreferrer" target="_blank">https://freeswitch.org/confluence</a><br>
<a href="https://cluecon.com/" rel="noreferrer" target="_blank">https://cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="https://freeswitch.com/" rel="noreferrer" target="_blank">https://freeswitch.com</a></blockquote></div>
_________________________________________________________________________<br>Professional FreeSWITCH Services<br><a href="mailto:sales@freeswitch.com" target="_blank">sales@freeswitch.com</a><br><a href="https://freeswitch.com/" target="_blank">https://freeswitch.com</a><br><br>Official FreeSWITCH Sites<br><a href="https://freeswitch.com/oss" target="_blank">https://freeswitch.com/oss</a><br><a href="https://freeswitch.org/confluence" target="_blank">https://freeswitch.org/confluence</a><br><a href="https://cluecon.com" target="_blank">https://cluecon.com</a><br><br>FreeSWITCH-users mailing list<br><a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br><a href="https://freeswitch.com" target="_blank">https://freeswitch.com</a></div></blockquote></div><br></div></div>_________________________________________________________________________<br>Professional FreeSWITCH Services<br><a href="mailto:sales@freeswitch.com" target="_blank">sales@freeswitch.com</a><br><a href="https://freeswitch.com" target="_blank">https://freeswitch.com</a><br><br>Official FreeSWITCH Sites<br><a href="https://freeswitch.com/oss" target="_blank">https://freeswitch.com/oss</a><br><a href="https://freeswitch.org/confluence" target="_blank">https://freeswitch.org/confluence</a><br><a href="https://cluecon.com" target="_blank">https://cluecon.com</a><br><br>FreeSWITCH-users mailing list<br><a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br><a href="https://freeswitch.com" target="_blank">https://freeswitch.com</a></div></blockquote></div><br></div></div>_________________________________________________________________________<br>Professional FreeSWITCH Services<br><a href="mailto:sales@freeswitch.com" target="_blank">sales@freeswitch.com</a><br><a href="https://freeswitch.com" target="_blank">https://freeswitch.com</a><br><br>Official FreeSWITCH Sites<br><a href="https://freeswitch.com/oss" target="_blank">https://freeswitch.com/oss</a><br><a href="https://freeswitch.org/confluence" target="_blank">https://freeswitch.org/confluence</a><br><a href="https://cluecon.com" target="_blank">https://cluecon.com</a><br><br>FreeSWITCH-users mailing list<br><a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br><a href="https://freeswitch.com" target="_blank">https://freeswitch.com</a></div></blockquote></div><br></div></div>_________________________________________________________________________<br>
Professional FreeSWITCH Services<br>
<a href="mailto:sales@freeswitch.com" target="_blank">sales@freeswitch.com</a><br>
<a href="https://freeswitch.com" rel="noreferrer" target="_blank">https://freeswitch.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="https://freeswitch.com/oss" rel="noreferrer" target="_blank">https://freeswitch.com/oss</a><br>
<a href="https://freeswitch.org/confluence" rel="noreferrer" target="_blank">https://freeswitch.org/confluence</a><br>
<a href="https://cluecon.com" rel="noreferrer" target="_blank">https://cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="https://freeswitch.com" rel="noreferrer" target="_blank">https://freeswitch.com</a></blockquote></div>