Hi mod_sms helloworld script. *mod_sms must be loaded or this will not work.* -------------------- chatplan <extension name="sms_test"> <condition field="destination_number" expression="^(.*)$"> <action application="lua" data="lua/sms.lua"/> </condition> </extension> -------------------- sms.lua freeswitch.consoleLog("info", "chat console\n") from = 'sip:1002@192.168.1.2'; to = '1001@192.168.1.2'; -- change *"to*" programmatically local event = freeswitch.Event("CUSTOM", "SMS::SEND_MESSAGE"); event:addHeader("proto", "sip"); event:addHeader("dest_proto", "sip"); event:addHeader("from", from); event:addHeader("from_full", from); event:addHeader("to", to); event:addHeader("subject", "sip:1001@192.168.1.2"); event:addHeader("type", "text/html"); event:addHeader("hint", "the hint"); event:addHeader("replying", "true"); event:addBody("Hello World!"); event:fire(); --freeswitch.consoleLog("info",event:serialize()..'\n'); Moradi On Mon, Jul 29, 2013 at 7:12 PM, Raymond Chandler < intralanman@freeswitch.org> wrote:
On 07/26/2013 12:24 PM, thomas lee wrote:
Hi,
Has anyone manage to get chatplan working?
yes
I only manage to get echo back from server and never succeed in sending the message across to other party. Does anyone has a sample working chatplan for me to reference?
assuming that the sending party is sending to the user@domain that the receiving party is registered as... then you should only have to use "send" as the application name.
-Ray
_________________________________________________________________________ Professional FreeSWITCH Consulting Services: consulting@freeswitch.org http://www.freeswitchsolutions.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server http://www.cudatel.com
Official FreeSWITCH Sites http://www.freeswitch.org http://wiki.freeswitch.org http://www.cluecon.com
FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org