Messagesend To SIP Peer In Sip.conf (or Otherwise Authenticated)

Home » Asterisk Users » Messagesend To SIP Peer In Sip.conf (or Otherwise Authenticated)
Asterisk Users No Comments

Hi,

I want to be able to send SIP SIMPLE messages via/to my VOIP provider but in trying to do so with MessageSend() I am getting 401 errors back from them, unsurprisingly. They want such messages from me authenticated with my account just as they would for SIP voice calls.

For voice calls, of course I use Dial(SIP/remote@peer) where remote is the phone number I want to call and peer is my SIP provider’s entry from my sip.conf complete with account and password.

So how do I achieve the same thing with MessageSend()? When I try to use the same kind of recipient string I get an error:

[Oct 1 09:48:40] WARNING[3286][C-000013ab]: message.c:1232 msg_send_exec: No message technology ‘SIP/sms-number@sip-peer’ found.

Using MessageSend() with raw URLs (sip:
sms-number@sip-provider.example.com) is accepted by Asterisk but it provides no authentication to the MESSAGE command sent to sip-
provider.example.com so is rejected.

So how can I, preferably, use my existing sip.conf entries to send SIP
SIMPLE messages, or at least provide some kind of authentication otherwise with MessageSend()?

Cheers, b.