Freeswitch 报告挂钩
Freeswitch reporting hook
是否可以在每次调用结束时执行 python 脚本,以便它可以访问 billsec
变量并将它们发送到我的 API?有 session.setHangupHook
方法,但如果我尝试在那里获取 billsec
变量,它 returns None
.
billsec
is not available until the handlers have exited and the call is disconnected. Instead, use api_hangup_hook
调用完成后调用
<action application="set" data="session_in_hangup_hook=true"/>
<action application="set" data="api_hangup_hook=python script.py ${uuid}"/>
更多信息:https://freeswitch.org/confluence/display/FREESWITCH/api_hangup_hook
是否可以在每次调用结束时执行 python 脚本,以便它可以访问 billsec
变量并将它们发送到我的 API?有 session.setHangupHook
方法,但如果我尝试在那里获取 billsec
变量,它 returns None
.
billsec
is not available until the handlers have exited and the call is disconnected. Instead, use api_hangup_hook
调用完成后调用
<action application="set" data="session_in_hangup_hook=true"/>
<action application="set" data="api_hangup_hook=python script.py ${uuid}"/>
更多信息:https://freeswitch.org/confluence/display/FREESWITCH/api_hangup_hook