Open arezvani opened 1 day ago
Based on the log you provide, somehow its dialing the message context
-- Executing [s@dial-extension:3] Dial("Message/ast_msg_queue", "PJSIP/User2,30") in new stack
Looks like main-context includes message context, so call are able to follow it. But the message context only needs to be applied to the extension config.
This may work
[webrtc-phones](!)
context=main-context
message_context=textmessages
transport=transport-wss
allow=!all,opus,ulaw,alaw,vp8,vp9
webrtc=yes
But then take textmessages out of the includes for main-context.
Thank you. With this change error has been changed. First I change extentions.conf to:
[send-text]
exten => s,1,NoOp(SMS receiving dialplan invoked)
exten => s,n,NoOp(To ${MESSAGE(to)})
exten => s,n,Set(TO=${MESSAGE(to)})
exten => s,n,NoOp(From ${MESSAGE(from)})
exten => s,n,NoOp(Body ${MESSAGE(body)})
exten => s,n,Set(ACTUALTO=${CUT(MESSAGE(to),@,1)})
exten => s,n,MessageSend(${ACTUALTO},${MESSAGE(from)})
exten => s,n,NoOp(Send status is ${MESSAGE_SEND_STATUS})
exten => s,n,Hangup()
Now I get this error:
-- Executing [100@textmessages:1] Gosub("Message/ast_msg_queue", "send-text,s,1,(User1)") in new stack
-- Executing [s@send-text:1] NoOp("Message/ast_msg_queue", "SMS receiving dialplan invoked") in new stack
-- Executing [s@send-text:2] NoOp("Message/ast_msg_queue", "To pjsip:100@185.60.136.36") in new stack
-- Executing [s@send-text:3] Set("Message/ast_msg_queue", "TO=pjsip:100@185.60.136.36") in new stack
-- Executing [s@send-text:4] NoOp("Message/ast_msg_queue", "From "User2" <sip:User2@185.60.136.36>") in new stack
-- Executing [s@send-text:5] NoOp("Message/ast_msg_queue", "Body Thjryc") in new stack
-- Executing [s@send-text:6] Set("Message/ast_msg_queue", "ACTUALTO=pjsip:100") in new stack
-- Executing [s@send-text:7] MessageSend("Message/ast_msg_queue", "pjsip:100,"User2" <sip:User2@185.60.136.36>") in new stack
[Dec 3 21:25:58] ERROR[1074603]: res_pjsip_messaging.c:621 msg_send: PJSIP MESSAGE - Could not find endpoint '100' and no default outbound endpoint configured
If I hardcode pjsip:User1 instead ${ACTUALTO}, I get this error:
-- Executing [s@send-text:7] MessageSend("Message/ast_msg_queue", "pjsip:100@185.60.136.36,"User2" <sip:User2@185.60.136.36>") in new stack
[Dec 3 21:20:04] ERROR[1071222]: res_pjsip_messaging.c:621 msg_send: PJSIP MESSAGE - Could not find endpoint '100@185.60.136.36' and no default outbound endpoint configured
Can you help me to solve this problem?
I have this pjsip.conf:
also have this extensions.conf
When I send a message in chat other user don't recieve that and get this error:
what should I do?