Microsoft Teams Direct Routing

Setting up Microsoft Teams Direct Routing

peoplefone GmbH

Heiko Hochländer

Heiko Hochländer

Support

Content Blocks

Set up a domain / Step 1

!!!IMPORTANT!!! If you have the new domains «[CustomerNumber].sbc01.uctrunk.com» and «CustomerNumber].sbc02.uctrunk.com», you must BOTH be added as a domain.



During the onboarding process, peoplefone will assign you a specific domain that must be configured in your O365 account. To configure it, go to your O365 portal, select Setup → Domain from the left menu, and then Add Domain.



Enter the domain you receive from peoplefone (in this example 136007.sbc01uctrunk.com).

Select “More options” and then “Add a TXT record to the domain’s DNS records.”

Select “More options” and then “Add a TXT record to the domain’s DNS records.”

Set up a domain / Step 2

Once you receive confirmation from peoplefone that TXT verification is ready, you will need to return to this configured domain and start the verification process.

In the next step, you can select "Skip." No additional services are required.

!!!IMPORTANT!!!

!!!IMPORTANT!!!

Please inform us as soon as the domain verification is complete, as we will need to remove the TXT records again, otherwise they will interfere with the IP resolution, which will result in outgoing calls not working.



Direct routing configuration

Once the domain setup is complete, you need to activate it in the next step.



This requires a user who has the Teams Admin role and a license with Teams as a product.





If you don't have such an administrator, you can add a "dummy" user to that particular domain. Once setup is complete, you can delete this "dummy" user.



IMPORTANT:





This user must have the Teams Admin role assigned or be a Global Administrator and have a Teams license.





The exact specifications for the administrator can be found in the Microsoft Teams documentation.



 https://learn.microsoft.com/en-us/microsoftteams/using-admin-roles 





Example creation of «dummy» user.

Administrator

Select Teams Administrator or Global Administrator.





Danger:

Please note that it may take up to 72 hours for the rules you configure on Microsoft sites to be activated.

This guide describes how to set up a simple solution where only Teams is enabled as the communications solution in your O365 account. If you have or are planning a hybrid solution with Teams and Skype for Business online or Skype on-premises, you'll need to select additional parameters.

Voice routing policies



Set up Direct Routing, voice routing policies, and users in the Teams admin dashboard



For this setup, you need to log in to your Teams admin dashboard



 https://admin.teams.microsoft.com 





DDI assignment

Powershell:



 Set-CsPhoneNumberAssignment -Identity [user@domain] -PhoneNumber +[ddi] -PhoneNumberType DirectRouting 





Assign DDI to each user using the following instructions.

  1. Go to Users -> Manage Users.

  1. Select a user.

  1. Under Account -> Assigned Phone Number, click Edit.

  1. On the Assign Phone Number tab, in the Phone Number Type drop-down menu, select Direct Routing.

  1. Under Assigned phone number, enter the desired number in E.164 format (e.g. 41445522000).

  1. Click Apply.

Create the PSTN usage entry



Powershell:



 Set-CsOnlinePstnUsage -Identity Global -Usage @{Add="Peoplefone"} 



  1. Go to VoIP -> Direct Routing and then in the top right corner click on Manage PSTN Usage Entries

  1. Click Add and enter a name, then click Apply.

Setting up the Voice Route



New method; only with xxxxxx.sbc01.uctrunk.com and xxxxxx.sbc02.uctrunk.com domain



Powershell:





 New-CsOnlineVoiceRoute -Identity "[Name]" -NumberPattern ".*" -OnlinePstnGatewayList @{add="[CustomerID].sbc01.uctrunk.com","[CustomerID].sbc02.uctrunk.com"} -Priority 1 -OnlinePstnUsages "Peoplefone" 





Compare the setup with the screenshots below to be sure

  1. Go to VoIP -> Direct Routing and click on the VoIP Routes tab.

  1. Click Add

  1. Give the policy a name.

  1. Set the priority to 1 and then enter «.*» for Dialed number pattern.

  1. Under «Registered SBCs», click «Add SBCs»

  1. Enter both domains completely in «Add SBC as derived trunk» (see screenshot below)

  1. Click on «Apply»

  1. For PSTN usage entries, click Add PSTN usage entries, select the PSTN usage entry, and click Apply.

  1. Click Save.

With the new method, you can now proceed directly to the step “Create the VoIP routing policies”.



The steps «Setting up the SBC» and «Creating the VoIP route» are both covered by the method above.



Setting up the SBC



old method; only with xxxxxx.uctrunk.com domain



Powershell:



 New-CsOnlinePSTNGateway -Fqdn [sbc_domain] -SipSignalingPort [sbc_port] -ForwardCallHistory $true -Enabled $true -ForwardPai $true -MaxConcurrentSessions [sbc_nb_channels] 



  1. Go to VoIP -> Direct Routing and click on the SBCs tab.

  1. Click Add

  1. Enter your «xxxxx.uctrunk.com» FQDN for the SBC.

  1. Configure the following settings for the SBC, Port->6000, Call Forwarding History->On,

  1. Forward P-Asserted-Identity (PAI) header->On

    

    For details on each of these settings, see the Microsoft documentation: https://learn.microsoft.com/en-us/microsoftteams/direct-routing-connect-the-sbc#sbc-settings

  1. Set the capacity for simultaneous calls according to the channels you have ordered

  1. Click Save.

Create the VoIP routing policies



Powershell:



 New-CsOnlineVoiceRoutingPolicy "Peoplefone" -OnlinePstnUsages "Peoplefone" 



 Grant-CsOnlineVoiceRoutingPolicy -Identity "<user>" -PolicyName "Peoplefone" 



  1. Go to VoIP -> VoIP Routing Policies.

  1. Click Add .

  1. Give the policy a name.

  1. Under PSTN usage entries, click Add, select the PSTN entry and click Apply.

  1. Click Save.

  1. After you create the policy, assign it to users so they can make outgoing calls.

Setting up resource accounts

  1. Go to VoIP > Resource Accounts and click Add.

  1. Give the resource account a name and select whether it should be used as an auto attendant or call queue.

  1. Select the account and then click Assign/Unassign.

  1. Select Direct Routing as the phone number type and then enter the number below in the same format as the user.

  1. You can now add the resource account to your call queues or auto attendants to route incoming calls to it.

IMPORTANT:



If this auto attendant or call queue is to forward to external numbers, then the resource account must be assigned the voice routing policy, just like a regular user.





Comments