I’m very new to freepbx but have past experience with Asterisk.
In the past I’ve used a dial plan entry to answer a call and play a ringing tone to the caller while allowing the caller to press the “" key to break-out to a DISA entry. If the caller didn’t press the "” key then after 20 seconds (typically 2 rings) the call was routed to a regular extension as normal.
This way I could break-out to a DISA entry without having to use an IVR. Is there any way to code this with freepbx?
What I’m wondering is how to do this dialplan code this in freepbx?
Go to How to change incoming CallerID and skip the first few paragraphs, but start where it says “(Original page starts here:)” - this will show you the principle of inserting “shim code” between the incoming trunk and the inbound route.
For the [from-trunk-custom] context, instead of any of the examples shown in that article you could perhaps do something like this:
Then you create two inbound routes in FreePBX - one for the regular DID number associated with the trunk (the 1888301XXXX in your example) and send that to whatever voicemail box you like. You create a second inbound route for 9999999999 (or whatever other “dummy” DID you may care to use) and if the caller has pressed the * then it should go there. Make the destination of that inbound route your DISA.
The above suggestion is UNTESTED by me, and I’m not even saying it’s the most efficient way to do it. But, it should work, or be close enough that you can tweak it to work.