Asterisk map DID to extension in a dialplan

0

I run FreePBX 14 (Asterisk 16.3.0) and would like to make use of the SMS feature. They provide a basic setup at https://wiki.voip.ms/article/SIP/SMS_with_FreePBX

However, this set of instructions only works when the extension number and the DID number are set to the same. My internal extension numbers are not related to the outside DIDs, but instead are 3-digits, like 201, 202, etc. The instructions work if I hard-code the extension number (for inbound) and callerID (for outbound), but then it doesn't work for multiple users.

I do have the "Outbound CallerID" extension setting filled in for the extensions that I want to do SMS activity with, so somewhere the system has a map of CallerID data with the extension data.

I'm not too familiar with Asterisk dialplans, but is there any way to "look up" a callerID number extracted from the X-SMS-To SIP header, and return the extension (context?) within the [sms-in] context, and likewise to look up the extension and return the outbound callerID within the [sms-out] context?

jose_can_u_c

Posted 2019-08-19T19:06:30.777

Reputation: 101

No answers