ByPassing dial betwen SIP TRUNKS

Hi all.

I wanna set a bypassing betwen two sip trunks.

I mean:

DIAL 60xx --> TRUNK_A --> TRUNK_B --> DIAL 60xx

[Inbound_A]
exten => _X.,1,Answer
exten => _X.,2,Dial(SIP${EXTEN}@TRUNK_B)

How can I define that dialed number is going to B. If Asterisk doesn’t know what is the dialed number…

thanks in advance

You are missing a “/”, but otherwise I don’t understand the problem. _X. allows you to forward the dialled digits without enumerating every possibility.

Thanks David55 but is not working…

SIP.CONF

[Mitel]
host=192.168.2.1
type=peer
insecure=port,invite
allow=all
auth=md5
context=from-internal

[5802]
type=friend
secret=secret
qualify=yes
port=5060
nat=yes
host=dynamic
dtmfmode=rfc2833
context=from-internal
canreinvite=no
EXTENSIONS.CONF

[from-internal]
exten =>_6xxx,n,Dial(SIP/${EXTEN}@Mitel)      

Why? The Sip Trunk is Working fine, I checked that.

No “priority” 1

are you trying to dial from asterisk through the Mitel and back into asterisk again?

if so… in your Mitel Class of service make sure “public network to public network connection allowed” is enabled

also make sure “allow DPNSS access” I think its called is enabled

these would be enabled in the mitel class of service for ANY and ALL parties that will touch the call… this includes the TRUNKS AND STATIONS…
-Christopher

Thanks cadillackid

Is working fine now!