Hi everyone, i have a trouble to configure instant messaging using freepbx 14 and asterisk 13 , i want that two sip clients can send and receive messages using their soft phones on smartphone and desktop , can anyone help me !
Welcome to the community Ranoo!
I know that is possible, but I’m not sure that someone already achieved this. Maybe @mrchiao or @Stll0 can help.
As suggestion, I would choose ejabberd or Mattermost as chat instead of using the SIP protocol.
Thank you for your reply
I am a graduate student of my freepbx project over the VoIP phone system … I have to send text messages using SIP over the PDA, so I can’t use ejabberd or Mattermost because I can’t guide you.
I will use Softphone …
x.lit on the computer
zoiper on iphone
They communicate with each other
…
sip SIMPLE message Configuration for Asterisk 13 and freepbx 14
SIP general settings in sip.conf in Web GUI and add inside “Other SIP Settings”
accept_outofcall_message=yes
outofcall_message_context=astsms
extensions_custom.conf
[astsms]
exten => _.,1,NoOp(SMS receiving dialplan invoked)
exten => _.,n,NoOp(To {MESSAGE(to)})
exten => _.,n,NoOp(From {MESSAGE(from)})
exten => _.,n,NoOp(Body {MESSAGE(body)})
exten => _.,n,Set(ACTUALTO={CUT(MESSAGE(to),@,1)})
exten => _.,n,MessageSend({ACTUALTO},{MESSAGE(from)})
exten => _.,n,NoOp(Send status is {MESSAGE_SEND_STATUS})
exten => _.,n,GotoIf(["{MESSAGE_SEND_STATUS}" != "SUCCESS"]?sendfailedmsg)
exten => _.,n,Hangup()
;
; Handle failed messaging
exten => _.,n(sendfailedmsg),Set(MESSAGE(body)="[{STRFTIME({EPOCH},,%d%m%Y-%H:%M:%S)}] Your message to {EXTEN} has failed. Retry later.")
exten => _.,n,Set(ME_1={CUT(MESSAGE(from),<,2)})
exten => _.,n,Set(ACTUALFROM={CUT(ME_1,@,1)})
exten => _.,n,MessageSend(${ACTUALFROM},ServiceCenter)
exten => _.,n,Hangup()
exten => _.,n,Hangup()