<div dir="ltr"><div><div><div>Hi,<br><br></div>I&#39;m using Linphone to test mod_sms on smart phones, the chat messages aren&#39;t being forwarded to the second user.<br></div>I&#39;ve two registered users 3333 and 4444. when i use action &quot;send&quot; the message is forwarded, but when i use my script with event fire it&#39;s not...what am i missing?  <br><br></div><b><u>public.xml:</u></b><br><br>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;<br>&lt;include&gt;<br>    &lt;context name=&quot;public&quot;&gt;<br>        &lt;extension name=&quot;public&quot;&gt;<br>            &lt;condition field=&quot;to&quot; expression=&quot;^(.*)$&quot;&gt;<br>                &lt;action application=&quot;lua&quot; data=&quot;handle_chat.lua&quot;/&gt;<br>                &lt;action application=&quot;reply&quot; data=&quot;Hello, you said: ${_body}&quot;/&gt;<br>                &lt;!--action application=&quot;send&quot;/--&gt;<br>            &lt;/condition&gt;<br>        &lt;/extension&gt;<br>    &lt;/context&gt;<br>&lt;/include&gt;<br><br><br><b><u>handle_chat.lua</u></b><br><br><div><div>local body = message:getBody();<br>local from = message:getHeader(&quot;from&quot;);<br>local to = message:getHeader(&quot;to&quot;);<br>freeswitch.consoleLog(&quot;info&quot;, message:getHeader(&quot;from&quot;));<br>freeswitch.consoleLog(&quot;info&quot;, message:getHeader(&quot;to&quot;));<br>freeswitch.consoleLog(&quot;info&quot;, message:serialize());<br>freeswitch.consoleLog(&quot;info&quot;, message:getBody() .. &quot;\n&quot;);<br>local event = freeswitch.Event(&quot;CUSTOM&quot;, &quot;SMS::SEND_MESSAGE&quot;);<br>event:addHeader(&quot;proto&quot;, &quot;sip&quot;);<br>event:addHeader(&quot;dest_proto&quot;, &quot;sip&quot;);<br>event:addHeader(&quot;from&quot;, &quot;sip:&quot; .. from);<br>event:addHeader(&quot;from_full&quot;, &quot;sip:&quot; .. from);<br>event:addHeader(&quot;to&quot;, to);<br>event:addHeader(&quot;type&quot;, &quot;text/html&quot;);<br>event:addHeader(&quot;replying&quot;, &quot;true&quot;);<br>event:addBody(&quot;Hello from Seven Du! Have funnnnnnn!&quot;);<br>freeswitch.consoleLog(&quot;info&quot;, event:serialize());<br>event:fire();<br><br><br><div><div><div><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks,<br></div><div class="gmail_extra">Snabel<br></div></div></div></div></div></div></div>