Tried the other way as well (without the API) session:execute("curl", "http://myurl.com/test3.php post name=myname") curl_response_code = session:getVariable("curl_response_code") curl_response = session:getVariable("curl_response_data") Getting this error: [ERR] mod_lua.cpp:203 /usr/share/freeswitch/scripts/test.lua:1: attempt to index global 'session' (a nil value) stack traceback: /usr/share/freeswitch/scripts/test.lua:1: in main chunk On Thu, Aug 4, 2016 at 2:51 PM, Don Hawkins <hawkins@hawkinsegroup.com> wrote:
root@debian:/usr/share/freeswitch/scripts# vi test.lua
api = freeswitch.API(); api:execute("curl", "http://myurl.com/test3.php post name1=value1")
Snatched the code straight from the the example shown at the URL below. FS does execute the script but never reaches my URL with the POST request. Did I miss something?
https://freeswitch.org/confluence/display/FREESWITCH/mod_curl
-- Sincerely, Don Hawkins CEO Hawkins Enterprise Group LLC http://hawkinsegroup.com Zello PTT <http://zello.com>: push2don P: 469-214-5044