Messages Out Of Calls. Is It Really Possible?
Hi.
I have read in some web sites that ASTERISK can support messages out of calls. What does it exactly means?
1 – Can a dialplan script accept and handle a message from a callee party, even before the call be connected?
2 – Can a ringing callee send SIP MESSAGE to the ASTERISK even before answer the call?
3- Could I use dialplan function MESSAGE() to receive SIP messages from callees, even before the call be connected?
Any hint will be very helpful!
Best regards.
RODRIGO PIMENTA CARVALHO
Inatel Competence Center Software Ph: +55 35 3471 9200 RAMAL 979 (Brasil)
One thought on - Messages Out Of Calls. Is It Really Possible?
Since it is out of call, yes.
SIP MESSAGE requests are handled by the respective channel driver
(chan_sip or the res_pjsip stack) and passed to the dialplan using a
“special” hidden channel, Message. That channel caries the payload and some meta information about the MESSAGE request, which can be accessed using the generic out-of-call messaging functions [1].
Likewise, you can send an out of call SIP MESSAGE request using MessageSend [2].
Note that all of this has been supported since Asterisk 10.
Yes, hence the term “out-of-call”.
It does not receive messages; it accesses data on the message currently being serviced by the executing Message channel.
chan_sip/res_pjsip will receive and dispatch MESSAGE requests at any point in time. They have nothing to do with your “normal” SIP or PJSIP
channels, and hence nothing to do with whatever INVITE request derived channels are currently executing in the dialplan.
[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Function_MESSAGE
and https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Function_MESSAGE_DATA
[2] https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Application_MessageSend