[Asterisk-Users] How to route incoming calls to different
contexts?
Tele Cost Price Reducer
telecpr at gmail.com
Sun Mar 5 05:36:27 MST 2006
hi Zach,
i would use GOTOIF to forward the DID from within the [incoming] context to
the other context. i would try :
exten => gotoif($[did]=DID1,goto did1|s|1,)
exten => gotoif($[did]=DID2,goto did2|s|1,)
On 3/4/06, Zach A <zeeshan at acabling.com> wrote:
>
> Both DIDs are SIP and from the same provider. Format of registration is
> like this:
>
> sip.conf
> --------
> [general]
> bindaddr=xxx.xxx.xxx.xxx
> port=5060
> context=incoming
> disallow=all
> allow=g726
> allow=ulaw
> allow=alaw
> allow=gsm
> dtmfmode=rfc2833
> canreinvite=no ; required for incoming calls to ring extensions
> insecure=invite ; outgoing call not working without this
> tos=0x18
> nat=yes
>
> register=DID1:1234 at xxx.xxx.xxx.xxx
> register=DID2:1234 at xxx.xxx.xxx.xxx
>
> [DID1]
> username=DID1
> type=peer
> secret=1234
> host=xxx.xxx.xxx.xxx
> fromuser=DID1
>
> [DID2]
> username=DID2
> type=peer
> secret=1234
> host=xxx.xxx.xxx.xxx
> fromuser=DID2
>
> Now both DIDs are sent to context [incoming] which is the default
> context for SIP. If I add context=incoming2 under any DID section, it
> doesn't go to that context and still go to the default context. How can
> I direct DID2 to [incoming2] context?
>
> Zach A
>
>
> -----Original Message-----
> From: Joseph Tanner [mailto:joseph at thetechguide.com]
> Sent: Friday, March 03, 2006 7:18 PM
> To: Asterisk Users Mailing List - Non-Commercial Discussion
> Subject: Re: [Asterisk-Users] How to route incoming calls to
> differentcontexts?
>
> First, tell us if it's sip, iax, or zap. Then tell us what provider
> (most will use the same general config, but some like ipkall are
> special and a bit tricky).
>
> joseph Tanner
>
> On 3/3/06, Zach A <zeeshan at acabling.com> wrote:
> >
> >
> >
> > Hi everybody,
> >
> >
> >
> > It should be a simple thing to do but I don't know how to do it. Now I
> have
> > 2 DIDs and I want one of them go to [context1] and other one to go to
> > [context2]. How can I achieve this.
> >
> >
> >
> > Thanks,
> >
> >
> >
> > Zach A
> > _______________________________________________
> > --Bandwidth and Colocation provided by Easynews.com --
> >
> > Asterisk-Users mailing list
> > To UNSUBSCRIBE or update options visit:
> >
> > http://lists.digium.com/mailman/listinfo/asterisk-users
> >
> >
> >
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
>
> Asterisk-Users mailing list
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users
>
>
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
>
> Asterisk-Users mailing list
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060305/b70f5225/attachment.htm
More information about the asterisk-users
mailing list