[Asterisk-Users] ivr key press?

Rich Adamson radamson at routers.com
Sun Dec 21 11:03:34 MST 2003


Steve,

Thank you very much for taking the time to remove the forest. Until
one attempts something like this, one does not have an appreciation
for the real impact of contexts and how they interact.

My initial dialplan was a very simple single-context version that started
from John Todd's basic get-started samples (which were fine), but now
the level of sophistication has grown far beyond that.

I think I now might have enough of an understanding to rewrite the entire
extensions.conf file to something much better. Thanks again.

Rich

------------------------
> On Sun, 2003-12-21 at 10:19, Rich Adamson wrote:
> > > > for the full 3000? (That's that part I'm not seeing; forest and the trees 
> > > > kind of thing).
> > > 
> > > Okay, please step out of the forest.
> > 
> > Okay, some of the forest is beginning to disappear and I can see some trees. ;)
> > I'm getting closer at least. Here's the ivr context as it stands right now,
> > knowing full well that its incomplete. I've having a brain-fart on part of
> > this. In the initial inbound ivr context [inbound-bus2], I press an 8 to
> > goto the [npilist] context where a message is played that says "for Rich,
> > dial extension 3000, etc". When the user enters 3000, what statement needs to
> > follow the exten => s,2,Background(npi-directory) to send the call to the
> > entered extension?  (Note: all of my extensions are defined in elsewhere
> > in [from-sip].)
> 
> In each of your contexts where you wish someone to be able to dial an
> extension directly, you will need to add a include => from-sip. Be
> careful here as you may have included outside dialing functionality in
> that context guessing from the name of the context. 
> 
> > Also, is there a "set verbose" mode or something like that, that would
> > provide some CLI feedback as to return values, etc? (Example, with the
> > menues above, during the message played in [npilist] I'm expecting to
> > enter 3000. However, as soon as I press the "3" I get a "-- Hungup 'Zap/2-1'"
> > which doesn't help me understand what is really going on. Is there
> > another debug mode that would help?
> 
> If you run asterisk with multiple v options you should see a bit. My
> guess is if you had a i extension you might have noticed this earlier. i
> is for invalid, and I believe you can still string together the ${exten}
> and some other stuff to inform the caller what they had pressed that was
> invalid.
> 
> Just to help speed things up and help come out of the forest, here is a
> skeleton that should help you get started.
> Well it started as a skeleton, but I just kept filling in details I
> didn't want to skip on and I nearly filled it all in for you. Hopefully
> this will help.
> 
> [inbound-bus2]
> include => bus2-extensions
> exten => s,1,wait(1)
> exten => s,2,answer
> exten => s,3,digittimeout(5)
> exten => s,4,responsetimeout(10)
> exten => s,5,Background(npi-greeting)
> 
> exten => 1,1,goto(sales,s,1)
> exten => 2,1,goto(custserv,s,1)
> exten => 8,1,goto(npilist,s,1)
> exten => 9,1,voicemailmain2
> 
> exten => i,1,saydigit(${EXTEN})
> exten => i,2,backgroud(invalid)
> 
> [outbound-bus2]
> exten => _9NXXXXXX,1,setaccount(npi) ; if needed this is nice
> exten => _9NXXXXXX,2,Dial(Zap,g2,${EXTEN:1})
> 
> exten => _9NXXNXXXXXX,1,setaccount(npi)
> exten => _9NXXNXXXXXX,2,Dial(Zap,g2,${EXTEN:1})
> 
> exten => _99XXNXXXXXX,1,playback(No-900-service); needs more specific
> 			;match as there are 9XX area codes.
> 
> [sales]
> include => bus2-extensions
> exten => s,1,goto(bus2-extensions,3000,1)
> 
> [custserv]
> include => bus2-extensions
> exten => s,1,goto(bus2-extensions,3002,1)
> 
> [npilist]
> include => bus2-extensions
> exten => s,1,Wait,1
> exten => s,2,background(npi-directory)
> 
> exten => *,1,goto(inbound-bus2,s,1)
> exten => #,1,goto(inbound-bus2,s,1)
> 
> [from-sip]
> include => bus2-extensions
> include => outbound-bus2
> 
> [bus2-extensions]
> exten => 3001,1,Dial(SIP/3001,15,t)
> exten => 3001,2,voicemail2(u3001 at somecontext)
> exten => 3001,3,hangup
> exten => 3001,102,voicemail2(b3001 at somecontext)
> exten => 3001,103,hangup
> 
> exten => 3002,1,Dial(SIP/3002,15,t)
> exten => 3002,2,voicemail2(u3002 at somecontext)
> exten => 3002,3,hangup
> exten => 3002,102,voicemail2(b3002 at somecontext)
> exten => 3002,103,hangup
> 
> -- 
> Steven Critchfield <critch at basesys.com>
> 
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users

---------------End of Original Message-----------------





More information about the asterisk-users mailing list