Hello,
I want to make a program, that makes a call to the user and calls my script when it ends.
I run the following script:
dialA = "{origination_caller_id_number="..telephone_from..",ignore_early_media=true}sofia/gateway/iskratel/"..telephone_to
while(legA:ready() and dispoA ~= "ANSWER") do
dispoA = legA:getVariable("endpoint_disposition")
freeswitch.consoleLog("INFO","Leg A disposition is '" .. dispoA .. "'\n")
legA:execute("set", "api_hangup_hook=luarun autoinform_cleanup.lua");
legA:execute("set", "session_in_hangup_hook=true");
legA:execute("playback", "/usr/local/freeswitch/sounds/alert.wav");
legA:execute("hangup");
end