Bypassing incoming context

hello i have setup my dial smoothly
where caller from pstn will be drive by custom ivr thru different context=department and into internal context will local number normally reside

let me picture it out as the script is too long and i anticipate its boring to read.

is there a way or a replacement for DISA function so caller wont type anything just to have full access in dial plan?

i can see “include => internal” to be place in incoming context but i dont know if it is effective or it will cause roaming around.

Let me guess. You want someone to dial this number, and have full access to a context without typing in any more digit. Is this correct? Then there’s no need to bypass DISA. Just set nopassword in DISA, and no voice menu before that.

[incoming] exten => s,1,Answer() exten => s,n,DISA(nopassword,mycontext)

yah that is correct but the caller is still have the right to press local number anytime within the incoming context.

we have a PSTN number = XXX-XX-XX
and when outside caller dial XXX-XX-XX he/she reach the incoming and hear the “Background” saying please enter “1” for departmentA enter “2” for departmentB or if you know the party extensions dial it now

let us say

with that script when the caller could type directly the party extensions
if DISA is before Background it will work i guess but how about if the background is being played. how the caller could press party number within background playing time

Perhaps I misunderstood your question. What is wrong with the [incoming] context you displayed? It does exactly what you want, it appears to me.

i mean a replacement for DISA, its like this the caller can dial the internal number anytime during background playing time…

beacause its not a good idea to put all local to the incoming context, like this

with this threres no need for DISA() as caller could Dial 5001,5004,5006,5007 in order to connect to the inside
but what if i have 30 user and more my incoming context will get longer
so id like to avoid this with smarter idea.

again, i dont want to use include => internal and put it in incoming it as im affraid to make the caller roam around
any help

Yes, it’s a good idea to group destinations according to intentions. So I see that you are not using pattern matching. Any particular reason? For example, if 5000-5099 are internals, try

exten = s,1,Answer()
exten = s,2,Background(please enter one of the ff to connect but if you
know the party extensions dial it now)
exten = 1,1,GoTo(departmentA,1,1)
exten = 2,2,GoTo(departmentB,1,1)
exten = _50XX,1,GoTo(internal,${EXTEN},1)
exten = i,1,Playback(invalid)
exten = i,2,Hangup()
exten = t,1,Playback(timeout)
exten = t,2,Hangup()

exten => _50XX,1,Dial(SIP/${EXTEN})
exten => _50XX,2,Hangup

You can fine tune matching.

that is exactly what i want to have
thanks really, honestly, up to now im not explore the tecnic of this asterisk scripting promise.