FOOD FOR THOUGHT Asterisk Dialplan Help

Prits

Active Member
Joined
May 28, 2013
Messages
163
Reaction score
30
Hello,

I am wondering if anyone is able to help with the following outbound route dialplan I need please:

I have an outbound currently formatted to dial 8 before any long distance number ie. 1NXXNXXXXXX but what I need is this long-distance format to EXCLUDE area codes 602, 623 and 480 as I have another outbound route to process these 3 area codes exclusively.

Thank you
Prits
 

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
Put the other outbound route above the one with the 8 prefix.
 

Prits

Active Member
Joined
May 28, 2013
Messages
163
Reaction score
30
Rossiv,

Thank you for the suggestion...

I already have:

9+480NXXXXXX
9+602NXXXXXX
9+623NXXXXXX

Before the '8' prefix route of:

8+1NXXNXXXXXX

But, 9 uses a different trunk than 8 even though the trunk assigned to '8' outbound route can still terminate these calls...

so, I need to prevent uses from dialing:

8+1480NXXXXXX
8+1602NXXXXXX
8+1623NXXXXXX

I think this gives you a better picture of what I have and want to do...

Thank you
 

rossiv

Guru
Joined
Oct 26, 2008
Messages
2,624
Reaction score
139
Ok, that helps.
So I think you'll need a total of three from what I see.
Top: 9+480..., 9+602..., 9+623....
Next: 8+1480..., 8+1602..., 7+1623...
Bottom: 8+1NXX......

This will give the 9s first priority, then pick up the 8+areacodes before the rest of the 8s and can route them accordingly (hangup or wherever). If I'm understanding, I think that should work.
 

geopeterwc

Guru
Joined
Aug 17, 2010
Messages
385
Reaction score
131
Given the programing options of PIAF and FreePBX, it's really not necessary to require your users to remember to dial 8+ or 9+ before making their call ... just be creative with your dial plan and make use of available dial plan masks. By masking the 256 active area codes in the NANP, you're able to eliminate the 8+ or 9+ scheme for outbound calls from your PBX. For what it's worth, give this a shot:

The dial plan for "general" trunk route #1 (all except A/C 480, 602, 623) will include:
Code:
[2-4]XXNXXXXXX
4[1-7]XNXXXXXX (or should it be 4[0-7]XNXXXXXX ?)
4[9-0]XNXXXXXX (or should it be 49XNXXXXXX for AC's 49x?)
5XXNXXXXXX
601NXXXXXX
60[2-9]XNXXXXXX
61XNXXXXXX
62[12]NXXXXXX (or should it be 62[02]NXXXXXX ?)
62[4-9]NXXXXXX (or should it be 62[4-0]NXXXXXX ?)
[7-9]XXNXXXXXX

And the dial plan for your local Phoenix Area trunk route #2 (480, 602, 623) will include:
Code:
480NXXXXXX
602NXXXXXX
623NXXXXXX

Or, maybe this would work for Phoenix AC's:
Code:
6[02][23]NXXXXXX

It would be necessary to duplicate this scheme to accommodate 1+number if that is a local requirement (or a service provider requirement). More information is here: http://pbxinaflash.com/community/index.php?threads/dial-plan-explanation.2081/

You would likely want to put your local Phoenix AC route first (for your preferred trunk for local calls) and the general dial plan for the remaining area codes to follow. I admit that I haven't actually tried this scheme, but I wouldn't want to create 256 separate dial plan entries for each of the area code in existence in FreePBX, though an ongoing maintenance would be required to accommodate new area codes!

Anyway! Or, maybe this idea is full of holes. Fire away!

/Pete./
 

Members online

No members online now.

Forum statistics

Threads
25,810
Messages
167,755
Members
19,240
Latest member
nikko
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top