Hi all,
I’m new to the AMI feature, but long time user of asterisk. I have an issue where messages sent using the below Examples results in the recipient unable to reply as the sender (From:) shows up unknown. Is there any way to spoof the From variable or will AMI Messages always show as unknown?
I have a php script that receives sms via an http gateway and feeds it into the AMI. It works well , and I can also send messages out via dial plan and CURL if I hand enter the recipient in a new message. I Just can’t reply due to the ‘Unknown’ sender issue.
Example1:
Action: MessageSend
To: sip:201
From: 407-380-0667
Body: This is a test message
Example2:
Action: MessageSend
To: sip:201
From: sip:203
Body: This is a test message
Note: Currently using Asterisk 16.3.0 and each example replies as:
“Response: Success
Message: Message successfully sent”
Update -
With some help from the freepbx forum, I was nudged to try this with pjsip and it works flawlessly.
So, leaves me wondering if this needs to be reported as a bug with MessageSend using chan sip or if there’s a way to pass the right variables when using MessageSend with sip.
For now, I’ll plan to use pjsip and hope there’s no future regrets looming in other aspects.