We have many multi-loc businesses with branch locations. We take an unused area code and assign each device at each branch a DID in that unused area code. Then we simply create a callflow to grab exts not in the account and prepend the number with the DID to route to a resource that loops back into the system. So all you need in each account is a custom callflow and resource. Easy Peasy Been working wonderfully.
Here are the 2 docs as examples assuming the extensions are 6 digits (You can make the length whatever. Just make sure you fill in the DID with whatever to match 10 digits. in this example, i used a 9 as the filler) You can also create failover resources for your multiple zones.
PUT /resources
{
"data": {
"classifiers": {
"unknown": {
"enabled": true,
"prefix": "+16739",
"suffix": ""
}
},
"flags": [],
"gateways": [
{
"progress_timeout": 8,
"privacy_mode": "sip",
"server": "SERVER IP",
"channel_selection": "ascending",
"enabled": true,
"endpoint_type": "sip",
"force_port": false,
"invite_format": "route",
"port": 5060,
"skype_rr": true
},
{
"progress_timeout": 8,
"privacy_mode": "sip",
"server": "SERVER IP",
"channel_selection": "ascending",
"enabled": true,
"endpoint_type": "sip",
"force_port": false,
"invite_format": "route",
"port": 5060,
"skype_rr": true
}
],
"media": {
"audio": {
"codecs": []
},
"video": {
"codecs": []
},
"fax_option": false,
"encryption": {
"enforce_security": false,
"methods": []
}
},
"template_name": "Vinix East",
"name": "Vinix East",
"ignore_flags": false,
"require_flags": false,
"format_from_uri": false,
"notes": "",
"emergency": false,
"enabled": true,
"grace_period": 5,
"rules": [],
"weight_cost": 50
}
}
PUT /callflows
{
"data": {
"flow": {
"data": {
"caller_id_type": "internal",
"ignore_early_media": false,
"outbound_flags": [],
"use_local_resources": true
},
"module": "resources",
"children": {}
},
"numbers": [],
"patterns": [
"^(\\d{6})$"
],
"ui_is_main_number_cf": false,
"name": "INTERNAL MULTI-LOC CF",
"contact_list": {
"exclude": false
}
}
}