[Freeswitch-dev] Cannot update a Channel Variable inside the api_hangup_hook lua script

varun pratapsingh varunps2003 at gmail.com
Mon Sep 26 06:06:56 UTC 2022


Hi Freeswitch Experts,

I am using session_in_hangup_hook = true and api_hangup_hook to call my lua
script where I want to change the value of my channel variable through
session:setVariable("custom_channel_variable", "new_value"). But I can see
that I cannot do that. It is not getting changed. I am able to access the
channel variables through session:getVariable("custom_channel_variable")
but I cannot set them after the call is hung up.

How can I do that? If I cannot do that then what is the reason? I do not
see any reason yet in the Freeswitch documentation.

Can anyone enlighten me over this?

Thanks and Regards
Varun Singh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-dev/attachments/20220926/e3701ae7/attachment.html>


More information about the FreeSWITCH-dev mailing list