Forum Discussion

solidpro380's avatar
solidpro380
Copper Contributor
Mar 15, 2021
Solved

Teams Voice - sending 3 digit numbers to one SBC and everything else to another...

Hi   We have a very simple setup but I'm not sure how to succeed in what we need to do. We have SBC#1 which is in the cloud and connected to the PSTN using SIP trunks. We have SBC#2 which is on-pre...
  • fowler_23's avatar
    Mar 17, 2021

    Hi solidpro380 

     

    So I'm presuming you have your 2 SBC's already setup as CsOnlinePSTNGateways.

     

    If so, then you just need to use Voice Routes. It sounds like you just have 1 voice route which picks up everything .* and sends to SBC1

     

    You just need to add a new voice route putting it a higher priority than your wildcard, The voice route will look something like this:

     

    New-CsOnlineVoiceRoute -Name "ExtensionCalling" -Priority 0 -OnlinePstnUsages "???" -OnlinePstnGatewayList sbc2.contoso.com -NumberPattern '[2-4][0-9][0-9]$' -Description "Extension routing"

     

    This will match anything being called that starts with 2,3 or 4 and then any digit for the next 3 numbers and send to sbc2.

     

    Ensure the OnlinePSTNUsage used is assigned to users in your onlinevoiceroutingpolicy who you want to be able to call those 3 digit extension numbers.

     

    or this:

     

    New-CsOnlineVoiceRoute -Name "ExtensionCalling" -Priority 0 -OnlinePstnUsages "???" -OnlinePstnGatewayList sbc2.contoso.com -NumberPattern '^(\d{3})$' -Description "3 digit extension calling"

     

    This is simpler and just matches a 3 digit number and sends to sbc2. However, be careful with this as you may not want emergency calls.e.g. 112/999 going to sbc2??

     

    What you will what to do is add a new rule into your dial plan as you may find that by calling a 3 digit extension number from Teams is that Teams will add a normalisation rule to it which would then not match your voice route. e.g 234 could turn into +44234

     

    So just add a dial plan normalization rule via Teams Admin Centre, accepting a 3 digit number and passing it through as is. It would look like this in Advanced View

     

    If Condition

     

    ^([2-4][0-9][0-9])$

     

    Then do this

     

    $1

     

    Doing this will for example accept 234 from Teams, not change it, will look at your Voice Route and then match the ExtensionCalling route and send 234 to SBC2.

     

    Hope this helps.

Resources