Microsoft Teams Implementation Guide v1.0

Microsoft Teams Implementation Guide v1.0

 









Microsoft Teams Implementation Guide





Overview


This implementation guide describes how service providers can configure an interconnection between the Microsoft Phone System Direct Routing Interface and 46 Labs' Peeredge Orchestrator. Microsoft documentation describes many configuration requirements specific to the Microsoft Teams environment. This implementation guide includes references to that Microsoft Teams documentation where appropriate.

The Service Provider Peeredge Orchestrator is an appliance that can be deployed on the customer premise, hosted in the 46 Labs Cloud, or deployed as a virtual machine on customer-provided bare metal or a VMware ESXi host. The Orchestrator contains the Peeredge SBC application.

Throughout this guide, we use the name Peeredge SBC when referring to the 46 Labs software application running in the Peeredge Orchestrator. This naming convention helps readers distinguish our product from other Microsoft-approved SBCs supported by Direct Routing. The Peeredge SBC offers several features typically not found in traditional SBCs.

Earlier versions of our documentation referred to the 46 Labs SBC application as the Peeredge Switch. The Customer’s Peeredge Portal User Interface uses terminology such as Switch Location or Switch IP. These are references to the Peeredge SBC Location and IP Addresses.

Revision History

Version

Description of Changes

Date Revised

1.0

Initial version

8/24/2022













Table of Contents


About Microsoft Teams Direct Routing

Microsoft Teams Direct Routing allows the Peeredge SBC to connect to the Microsoft Phone System. After completing the instructions detailed in this document, Direct Routing enables you to:

  • Use virtually any PSTN Provider with Microsoft Phone System (including 46 Labs' ECO Carrier Platform).

  • Configure interoperability between customer-owned telephony equipment, such as a third-party private branch exchange (PBX), analog devices, and the Microsoft Phone System.

Note Additional information on the Microsoft 365 site can be found here.

Prerequisites

Before starting the implementation, make sure you have access to an active instance of the Peeredge SBC. The 46 Labs team can deploy the Peeredge SBC to the client's preferred environment (i.e. 46 Labs data center, on-premise, or in a third-party data center) after the client purchases a Peeredge SBC license.

Microsoft 365 Tenant Requirements

Direct Routing requires a custom domain for each Office 365 tenant. For more information, click here.

Licensing Requirements

Direct Routing users must be assigned the following licenses in their Office 365 tenant:

  • Skype for Business Online (Plan 2)

  • Microsoft Phone System

These licenses are in an Office 365 E5. The Office 365 E3 license includes the Skype for Business Online (Plan 2) license, but a Microsoft Phone System add-on license must be assigned to each user with an Office 365 E3 license.

  • For more information about Microsoft licensing requirements, click here.

Domain Name Server (DNS) Requirements

DNS records for domains that resolve to your SBC must be created by your DNS Administrator. The following information will be necessary for any SBC you want to pair:

  • Public IP Address

  • Fully Qualified Domain Name (FQDN)

  • Public DNS entry

SBC Domain Names

The domain names for SBCs must be in the list of domain names registered in the "Domains" section under Settings of the Microsoft 365 admin center menu. The domain of a tenant must be activated and have a Healthy status. Go to the admin dashboard to add domains not already created and verified.

  • For more information about Microsoft SBC domain names, click here.

 

 

Domain Name

Usable for SBC FQDN?

FQDN Example Names

46ldev.com

Yes

Valid

  • dal-sbc1.46ldev.com

voice46.com

Yes

Valid

  • sbc1.voice46.com, loc1.voice46.com, asia.voice46.com

Non-valid

  • sbc1.asia.voice46.org

asia.voice46.com

Yes

Valid

  • sbc1.asia.voice46.org

*.onmicrosoft.com

No

*.onmicrosoft.com is not supported

  • Table note The IPs and domain names in this document are examples.

Public Trusted Certificate for the Peeredge SBC

The Peeredge SBC must have a public trust certificate when establishing a TLS connection between the Microsoft Teams SIP Proxy and the SBC. The certificate needs to have the SBC's FQDN in the subject, common name, or subject alternate name fields.

By design, the SBC Provisioning Portal does not include Certificate Management Functions. If the SBCs are deployed in the 46 Labs cloud, 46 Labs sets up and manages a Let's Encrypt certificate. If the Peeredge SBC is deployed outside the 46 Labs cloud or the client wants the SBC Certificate to be signed by a specific root Certificate Authority (CA), contact 46 Labs and request a Certificate Signing Request (CSR).

Once you have the CSR, submit the certificate to a Microsoft-approved root certificate authority. Return the signed certificate and any CA intermediate certificates to 46 Labs.

Configuring Microsoft 365 Tenant for Direct Routing

To configure the Microsoft 365 Tenant for a Peeredge SBC-Direct Routing connection, complete five high-level steps:

  1. Connect the SBC with the Phone System and validate the connection.

  2. Enable users for Direct Routing, voice, and voicemail.

  3. Configure call routing.

  4. Translate number to an alternate format (optional).

  5. Add a Dial Plan and assign it to a user.


Admins can complete some of these steps via the Microsoft Teams admin center. Admins can complete all configuration steps via PowerShell. This document provides examples of both methods. To use the PowerShell commands, you must install the Microsoft Teams PowerShell Module from the Windows PowerShell prompt and then sign in with your Azure credentials using the Connect-MicrosoftTeams command.

Note The Microsoft Teams PowerShell Module is not supported by PowerShell Core.

1. Connect the SBC with phone system and validate connection

Using the Microsoft Teams admin center

To add the Peeredge SBC to Direct Routing:

  1. Locate Voice in the Microsoft Teams Admin Center.

  2. Go to the Direct Routing page.

  3. Click Add under the SBC tab.

The SBC FQDN entered in the Add an FQDN for the SBC field must be an exact match with the SBC Certificate's Common Name (CN) or be included in the Subject Alternative Name (SAN). We recommend using 5061 as the SIP signaling port and enabling the Send SIP options, Forward call history, and Ring phone while trying to find the user. You may need to enable other settings based on your specific business requirements. If you plan to enable location-based routing or Bypass mode, we recommend that you fully test the SBC integration with these features disabled first.

Note The TLS connectivity status is Inactive and the SIP Options status is Warning until you configure the Peeredge SBC Origination Customer SIP Trunk Group. If you are want to see the status of these columns change to Active, jump ahead and complete Step 1 and Step 3 in the Peeredge SBC configuration section.


Using Windows PowerShell

To add a new Direct Routing SBC, use the New-CsOnlinePSTNGateway command. If you fail to include a mandatory parameter, the cmdlet prompts you to provide it, as in the example below.

 

  • To view the configuration of the existing SBCs, use the Get-CsOnlinePSTNGateway command.

 

  • To change the configuration of an existing SBC, use the Set-CsOnlinePSTNGateway command.

 

  • To delete an existing SBC, use the Remove-CsOnlinePSTNGateway command.

2. Enable users for Direct Routing, voice, and voicemail

To enable a Direct Routing user, the admin must:

  • make sure the user exists in your Microsoft 365 Tenant, and

  • assign the Skype for Business Online (Plan 2) and Microsoft Phone System licenses.

There are two options for adding a new user to Microsoft 365:


Must be configured for Teams Only mode

This requirement applies to Tenants that are still using Skype for Business. Direct Routing requires that the user's Coexistence mode be set to Teams Only. This setting ensures incoming calls land in the Teams client. See Upgrade strategies if this situation applies to your organization.

Must be homed online, enabled for enterprise voice, and assigned a phone number

Using the Microsoft Teams admin center:

  1. Go to Users -> Manage users.

  2. Select a user.

  3. Under Account General information, select Edit.

  4. Under Assign phone number, click the Phone number type drop-down menu and select Direct Routing.

  5. Enter an assigned phone number and a phone number extension, if applicable.

  6. Click Apply.

Using Windows PowerShell

If you are managing the user's phone number on-premises, make sure the user is Enterprise Voice enabled online by entering the following command:

  • Set-CsPhoneNumberAssignment -Identity "<User name>" -EnterpriseVoiceEnabled $true


If you are managing the user's phone number online, assign the phone number to the user by entering the following command in Teams PowerShell. The user is automatically Enterprise Voice enabled by the command:

  • Set-CsPhoneNumberAssignment -Identity "<User name>" -PhoneNumber <phone number> -PhoneNumberType DirectRouting


Before phone number assignment

After phone number assignment

3. Configure call routing

Call routing has the following elements:

Call routing policy

Also called a Voice Routing policy. A container for PSTN usages, which can be assigned to a user or to multiple users. Sample Call routing policy names include:

  • US Only

  • US Global

  • Germany Only

  • Germany Global

  • Internal

PSTN usages

A container for voice routes and PSTN usages, which can be shared in different voice routing policies. Sample PSTN usage names include:

  • US-Emergency

  • US-LD

  • US-INTL

  • Company-Internal

Voice routes

A number pattern and set of online PSTN gateways for calls where the calling number matches the pattern. In the examples below, the Internal voice routes represent routes to company-managed third-party PBXs used by employees that have not yet migrated to MS Teams. Sample Voice route names and their associated dialed number pattern include:

  • US Emergency ^933$

  • US LD e164 ^+1[2-9]\d{2}[2-9]\d{6}$

  • US INTL e164 ^+[2-9]\d+$

  • Reston Internal ^+170355512\d{2}$

  • Chicago Internal ^+13125556[43]\d{2}$

Online PSTN gateway

This is a pointer to the Peeredge SBC that also stores the configuration which is applied when a call is placed through the SBC, such as forward P-Asserted-Identity (PAI) or Preferred Codecs. The pointer can be added to voice routes.

Two examples (from Microsoft) of voice routing policies in a call flow.

 

Create the PTSN usages

In the following example, we create four PSTN usage records. We suggest admins use easy-to-understand names representing the types of calls a user is allowed to dial. Using the Microsoft Teams admin center:

  1. Go to Voice -> Direct Routing.

  2. Select Manage PSTN usage records in the top right corner of the page.

  3. Click + Add and enter the name of the PSTN usage record.

  4. Repeat step 3 to add more records.

  5. Click Apply to finish.

Using Windows PowerShell

Use the following command to create a PSTN Usage:

  • Set-CsOnlinePstnUsage -Identity Global -Usage @{Add="US and Canada"}


Use the Get-CSOnlinePSTNUsage command to view the PSTN Usages.

Create the voice routes

In the following example, we create four voice routes. The dial number patterns are in the form of a regular expression (regex). You can validate your regex patterns.
Using the Microsoft Teams admin center:

  1. Go to Voice -> Direct Routing.

  2. Click the Voice routes button.

  3. Click the Add button.

  4. Add the name Non-Emergency Test in the voice route in the Add a name for your voice route field.

  5. Make sure the Priority is 1.

  6. Make sure the Dialed number pattern is ^933$.

  7. Click the Add SBCs button and select your Peeredge SBCs and then click Apply.

  8. Click the ADD PSTN usage button and select the US-Emergency PSTN Usage and then click Apply.

  9. Click Save.

  10. Repeat steps 3 – 9 for any other voice routes using an appropriate priority and PSTN Usage. When overlapping dialed number patterns exist, give the more specific pattern higher priority.



Using Windows PowerShell

New-CsOnlineVoiceRoute -Identity "voice route name" -NumberPattern "regex pattern" -OnlinePstnGatewayList sbc1-fqdn, sbc2-fqdn -Priority 1 -OnlinePstnUsages "PSTN Usage."

Note Priorities start at 0 in PowerShell and start at 1 in the admin center.

To edit an existing voice route, use the Set-CsOnlineVoiceRoute command:

  • Set-CsOnlineVoiceRoute -id "voice route name" -NumberPattern "regex pattern" -OnlinePstnGatewayList sbc1-fqdn

To remove an existing voice route, use the Remove- CsOnlineVoiceRoute command:

  • Remove- CsOnlineVoiceRoute -Identity "voice route name"


To view the existing voice routes, use the Get-CsOnlineVoiceRoute command.

Create the voice routing policy

Using the Microsoft Teams admin center:

  1. Go to Voice -> Voice routing policies.

  2. Click the + Add button.

  3. Add the policy name in the Add a name for your voice routing policy field.

  4. Add an appropriate description.

  5. Add one or more PSTN usages.

  6. Click Save.

  7. Repeat steps 2 – 6 for each voice routing policy.

Using Windows PowerShell

To create a new voice routing policy, use the New-CsOnlineVoiceRoutingPolicy command.

  • New-CsOnlineVoiceRoutingPolicy "policy name" -OnlinePstnUsages "PSTN Usage"


To edit an existing voice routing policy, use the Set-CsOnlineVoiceRoutingPolicy command:

  • Set-CsOnlineVoiceRoutingPolicy -Identity "policy name" -OnlinePstnUsages @{Add|Remove="PSTN Usage"}

To delete an existing voice route policy, use the Remove-CsOnlineVoiceRoutingPolicy "policy name" command.

Note A voice route policy cannot be removed if it is assigned to users.


To view a list of existing voice routing policies, use the Get-CsOnlineVoiceRoutingPolicy command.

Assign the voice routing policy to a user

Using the Microsoft Teams admin center:

  1. Go to Voice -> Voice routing policies.

  2. Highlight the voice policy you want to assign.

  3. Click the Assign button.

  4. In the Manage user search box, search for the user and click add when found.

  5. Click Apply.


Using Windows PowerShell

To assign a voice routing policy to a user, use the Grant-CsOnlineVoiceRoutingPolicy command:

  • Grant-CsOnlineVoiceRoutingPolicy -Identity "User's UPN or SIP Address" -PolicyName "policy name"


To remove a voice routing policy for a user, use the Remove-CsOnlineVoiceRoutingPolicy command:

  • Remove-CsOnlineVoiceRoutingPolicy -Identity "User's UPN or SIP Address" -PolicyName "policy name"

4. Translate number to an alternate format

Based on your unique business requirements, you may want to change the number for outbound and/or inbound calls based on the patterns they created to ensure interoperability with Session Border Controllers (SBCs).

You can use the Number Translation Rules policy to translate numbers for the following:

Inbound calls

  • Calls from a PSTN endpoint (caller) to a Teams client (callee).

Outbound calls

  • Calls from a Teams client (caller) to a PSTN endpoint (callee).

These policies are applied at the SBC level. You can assign multiple translation rules to an SBC, which are applied in the order they appear in your PowerShell list. You can also change the order of the rules in the policy. There is no specific requirement to configure Number Translation Rules to interoperate with the Peeredge SBC. Consult Microsoft online documentation if your business requires the use of Number Translation Rules.

5. Add a dial plan and assign to a user

A dial plan is a named set of normalization rules that translate dialed phone numbers by an individual user into an alternate format (typically E.164) for purposes of call authorization and voice routing.

The normalization rules define how phone numbers are expressed in various formats and translated to an alternate format. The same dial string may be interpreted and translated differently in different dial plans. Depending on which dial plan is assigned to a given user, the same dialed number may be translated and routed differently.

The example below shows how to add a typical US dial plan.

Using the Microsoft Teams admin center:

  1. Go to Voice -> Dial plans.

  2. Click the +Add button to add a Tenant dial plan.

  3. Add the dial plan name (US DP) in the Add a name for your dial plan field.

  4. Add an appropriate description (Tenant User Dial plan for US-based users).

  5. Add an External dialing prefix (8). Legacy PBX was often configured with 8 or 9 as an external dialing prefix to route the call to an external line.

  6. Set Optimized device dialing to ON if you configured an External dialing prefix.

  7. Click the Add button under Normalization rules to open the Add new rule pane.

  8. Enter a rule name (Non-Emergency Test Call) in the Name field.

  9. Add an appropriate description.

  10. Select an appropriate Rule creation mode (Advanced).

  11. Enter a dial pattern to match (^(911)$) in the If condition.

  12. Enter the translation/number manipulation ($1) in the Then do this field.

  13. Optionally, enter a number in the test this rule field to validate the rule. A validated test results in, "The translated number is an E.164 phone number."

  14. Click Save.

  15. Repeat steps 7 – 14 to add Normalization rules.

  16. Click Save.

Assign the Dial plan to a user

  1. Go to Voice -> Dial plans.

  2. Highlight the Dial plan you want to assign.

  3. Click Assign.

  4. Search for the user.

  5. Click the Add button.

  6. Click Apply.


Related PowerShell commands

To view the Tenant Dial plans, use the Get-CsTenantDialPlan command.

To view a specific Normalization Rule in the Tenant Dial plan, use the (Get-CsTenantDialPlan "dial plan name").NormalizationRules[X] command (where X is the rule number).


To view a User's Effective (the service-scoped and the tenant-scoped) Dial plan, use the Get-CsEffectiveTenantDialPlan command.

Note The US service-scoped dial plan includes a translation of 988 to the national US Suicide Provention Hotline +18002738255.


Peeredge SBC Terminology

A Relationship is a top-level container used to group related items. Related items include Trunk Groups, Capacity Groups, Rate decks, Route plans, Balances, Invoices, Agents, Triggers, and E911-related configurations. There is typically one Relationship for each Customer and one Relationship for each Vendor.

A SIP Trunk is a connection between a specific Peeredge SBC and a single SIP-enabled device. This device can be a PBX, an SBC, or any SIP-enabled gateway.

A Trunk Group is a group of one or more SIP Trunks with shared attributes and used for the same purpose. For example, a Termination Vendor SIP Trunk would be used to route outbound PSTN calls to several different SBCs belonging to the same vendor. Peeredge SBC Trunk Groups are unidirectional. Each Trunk Group has a Direction attribute and a Relationship attribute. The direction can be either Termination or Origination, and the Relationship can be either Customer or Vendor. This means there are four (4) possible Trunk Group types.