Le 09/06/2021 à 16:18, George Joseph a écrit :
Hi Guys,
The change for allowing a dialstring-like destination in MessageSend
(pjsip only) is now committed in the 16, 18 and master branches. You
can now use MessageSend(pjsip:PJSIP/<number>@<provider_endpoint>) and
the request URI will be composed of the endpoint's contact uri with
the number inserted as the user portion of the uri. Please give it a test.
For Asterisk 19 (not an LTS release) what would you guys think of
changing the MessageSend application to accept discrete parameters for
destination uri, endpoint, user, etc.? This would remove about 400
lines of fuzzy parsing code and give you the most flexibility in
constructing a destination.
Hi George,
I've just tested this with the latest version on branch 16.
I have a SIP phone "linphone" performing an inbound registration, and I
try to send a message to it with the following dialplan:
exten = 800,1,Set(MESSAGE(body)=test)
same = n,MessageSend(pjsip:PJSIP/3200@linphone,8000)
The test fails. The SIP MESSAGE is not sent and the following errors are
displayed:
*CLI> channel originate Local/800@default application Hangup
*CLI> -- Executing [800@default:1]
Set("Local/800@default-00000000;2", "MESSAGE(body)=test") in new stack
-- Called 800@default
-- Executing [800@default:2]
MessageSend("Local/800@default-00000000;2",
"pjsip:PJSIP/3200@linphone,8000") in new stack
[2021-06-15 10:42:49.885] WARNING[5163]: res_pjsip_messaging.c:247
insert_user_in_contact_uri: Dest: 'PJSIP/3200@linphone' MSG SEND FAIL:
There's already a username in endpoint linphone's contact URI
'sip:linphone@127.0.0.1:5063;line=068b0910396d2ed'.
[2021-06-15 10:42:49.885] ERROR[5163]: res_pjsip_messaging.c:1240
msg_send: PJSIP MESSAGE - Could not find endpoint 'PJSIP/3200@linphone'
and no default outbound endpoint configured
-- Auto fallthrough, channel 'Local/800@default-00000000;2' status
is 'UNKNOWN'
I can provide logs if you need.
Regards,
Jean
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-dev