# Teams Voice Services Configuration

<span class="TextRun SCXW136270634 BCX8" data-contrast="auto" lang="PL-PL" xml:lang="PL-PL"><span class="NormalTextRun SCXW136270634 BCX8" data-ccp-parastyle="Body Text"><video controls="controls" height="399" style="width: 798px; height: 399px;" width="798"> <source src="https://wpm.uc.t-mobile.pl/attachments/Konfiguracja_uslug_glosowych.mp4" type="video/mp4"></source></video></span></span>

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">The configuration will be performed in **Windows PowerShell**.</span>

You should have the **.NET Framework** add-on version **4.7.2** or later installed on your computer. If you don't have it, click the following link and install it: <span style="color: rgb(226, 0, 116);">**https://docs.microsoft.com/en-us/dotnet/framework/install/**</span>

##### **Starting PowerShell**

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">In the Start menu, search for the **PowerShell**, right-click the icon, and select **Run as administrator**.</span>

[![image.png](https://bookstack.uc.t-mobile.pl/uploads/images/gallery/2023-11/scaled-1680-/nJVimage.png)](https://bookstack.uc.t-mobile.pl/uploads/images/gallery/2023-11/nJVimage.png)



#### **Checking the version of PowerShell**

To make sure that you will be able to execute the commands described in the following sections, check the version of the **PowerShell.** <span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">Open **PowerShell** and enter the following command:</span>

<p class="callout info">**<span class="TextRun SCXW171973274 BCX8" data-contrast="none" lang="PL-PL" style="color: rgb(226, 68, 116);" xml:lang="PL-PL"><span class="NormalTextRun SCXW171973274 BCX8">$</span><span class="NormalTextRun SpellingErrorV2Themed SCXW171973274 BCX8">PSVersionTable.PSVersion</span></span><span class="EOP SCXW171973274 BCX8" data-ccp-props="{"134245417":false,"335559685":3018}"> </span>**</p>

<span class="WACImageGroupContainer SCXW171973274 BCX8"><span class="WACImageContainer NoPadding AttachedToBeginning DragDrop SCXW171973274 BCX8" role="presentation">![](https://bookstack.uc.t-mobile.pl/uploads/images/gallery/2023-11/embedded-image-vvksqjuz.png)</span></span>

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">The **PowerShell** application should have version **5.1 (Major:** **5,** **Minor: 1**) or **higher.** If it is lower, update **PowerShell** according to the instructions on the following page:</span>

[<span class="TextRun Underlined SCXW171973274 BCX8" data-contrast="none" lang="PL-PL" xml:lang="PL-PL"><span class="NormalTextRun SCXW171973274 BCX8" data-ccp-charstyle="Hyperlink">https://docs.microsoft.com/en-us/powershell/scripting/windows-powershell/install/installing-windows-powershell#upgrading-existing-windows-powershell</span></span>](https://docs.microsoft.com/en-us/powershell/scripting/windows-powershell/install/installing-windows-powershell#upgrading-existing-windows-powershell)<span class="TextRun SCXW171973274 BCX8" data-contrast="auto" lang="PL-PL" xml:lang="PL-PL"><span class="NormalTextRun SCXW171973274 BCX8"> </span></span><span class="EOP SCXW171973274 BCX8" data-ccp-props="{"134245417":false,"335559685":3018}"> </span>

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">If the version information does not appear after issuing the **$PSVersionTable.PSVersion** command, use the following command:</span>

<p class="callout info">**<span class="TextRun SCXW171973274 BCX8" data-contrast="none" lang="PL-PL" xml:lang="PL-PL"><span class="NormalTextRun SCXW171973274 BCX8" style="color: rgb(226, 68, 116);">$</span><span class="NormalTextRun SpellingErrorV2Themed SCXW171973274 BCX8"><span style="color: rgb(226, 68, 116);">host.Version</span>.</span></span>**</p>

#### **Installing required modules**

Install the required **modules** to properly configure the service. Individually copy the following commands highlighted in blue, paste them into **PowerShell** and execute by pressing **Enter.**

<p class="callout info"><span style="color: rgb(226, 68, 116);">**<span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-US" xml:lang="EN-US"><span class="NormalTextRun SCXW30550165 BCX8">\[</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">Net.ServicePointManager</span><span class="NormalTextRun ContextualSpellingAndGrammarErrorV2Themed SCXW30550165 BCX8">\]::</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">SecurityProtocol</span> <span class="NormalTextRun SCXW30550165 BCX8">= \[</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">Net.SecurityProtocolType</span><span class="NormalTextRun ContextualSpellingAndGrammarErrorV2Themed SCXW30550165 BCX8">\]::</span><span class="NormalTextRun SCXW30550165 BCX8">Tls12</span></span>**<span class="EOP SCXW30550165 BCX8" data-ccp-props="{"134245417":false,"335559685":3018}"> </span></span></p>

<p class="callout info"><span style="color: rgb(226, 68, 116);">**<span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW30550165 BCX8">Register-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">PSRepository</span><span class="NormalTextRun SCXW30550165 BCX8"> -Default</span></span>**<span class="EOP SCXW30550165 BCX8" data-ccp-props="{"134245417":false,"335559685":3018}"> </span></span></p>

<p class="callout info"><span style="color: rgb(226, 68, 116);">**<span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW30550165 BCX8">Install-Module -Name </span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">PowerShellGet</span><span class="NormalTextRun SCXW30550165 BCX8"> -Force -</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">AllowClobber</span></span>** </span></p>

<p class="callout info"><span style="color: rgb(226, 68, 116);">**<span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW30550165 BCX8">Install-Module -Name </span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">MicrosoftTeams</span><span class="NormalTextRun SCXW30550165 BCX8"> -Force -</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">AllowClobber</span></span>**<span class="EOP SCXW30550165 BCX8" data-ccp-props="{"134245417":false,"335559685":3018}"> </span></span></p>

<p class="callout info"><span style="color: rgb(226, 68, 116);">**<span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-US" xml:lang="EN-US"><span class="NormalTextRun SCXW30550165 BCX8">Update-Module </span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">MicrosoftTeams</span></span>**</span></p>

<p class="callout info">**<span style="color: rgb(226, 68, 116);"><span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW30550165 BCX8">Set-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">ExecutionPolicy</span> <span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">RemoteSigned</span></span></span>**</p>

<p class="callout info">**<span style="color: rgb(226, 68, 116);"><span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="EN-US" xml:lang="EN-US"><span class="NormalTextRun SCXW30550165 BCX8">Import-Module -Name </span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">MicrosoftTeams</span></span></span>**</p>

<p class="callout info">**<span style="color: rgb(226, 68, 116);"><span class="TextRun SCXW30550165 BCX8" data-contrast="none" lang="PL-PL" xml:lang="PL-PL"><span class="NormalTextRun SCXW30550165 BCX8">Set-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">ExecutionPolicy</span> <span class="NormalTextRun SpellingErrorV2Themed SCXW30550165 BCX8">Restricted</span></span></span>**</p>

#### **Logging in to the tenant in the MS Teams organization**

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">Copy the following command, paste it into the **PowerShell** and execute by pressing **Enter.**</span>

<p class="callout info">**<span style="color: rgb(226, 68, 116);"><span class="TextRun SCXW17773935 BCX8" data-contrast="none" lang="PL-PL" xml:lang="PL-PL"><span class="NormalTextRun SCXW17773935 BCX8">Connect-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW17773935 BCX8">MicrosoftTeams</span></span></span>**</p>

[![image.png](https://bookstack.uc.t-mobile.pl/uploads/images/gallery/2023-11/scaled-1680-/aYVimage.png)](https://bookstack.uc.t-mobile.pl/uploads/images/gallery/2023-11/aYVimage.png)

Log in with a user account with **administrator privileges** in the tenant. The account with administrator privileges is the one used to create the new domain in the **Adding a New Domain to the Microsoft 365 Administration Center** instructions.

#### **Configuring routing for phone calls**

Individually copy the following commands highlighted in blue, paste them into **PowerShell** and execute by pressing **Enter.**

<p class="callout info"><span style="color: rgb(226, 68, 116);">**<span class="TextRun SCXW49396621 BCX8" data-contrast="none" lang="EN-US" xml:lang="EN-US"><span class="NormalTextRun SCXW49396621 BCX8">Set-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">CsOnlinePstnUsage</span><span class="NormalTextRun SCXW49396621 BCX8"> -Identity Global -Usage @{Add="TMobileRouting"}</span></span>** </span></p>

<p class="callout info">**<span style="color: rgb(226, 68, 116);"><span class="TextRun SCXW49396621 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW49396621 BCX8">Set-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">CsOnlineVoiceRoutingPolicy</span><span class="NormalTextRun SCXW49396621 BCX8"> -Identity Global -</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">OnlinePSTNUsages</span><span class="NormalTextRun SCXW49396621 BCX8"> "</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">TMobileRouting</span><span class="NormalTextRun SCXW49396621 BCX8">"</span></span></span>**</p>

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">In the last command, the domain <span style="color: rgb(226, 0, 116);">**<span style="background-color: rgb(241, 196, 15);">T10012345.teams.t-mobile.pl</span>**</span> should be replaced with the one that was assigned by T-Mobile.</span>

<p class="callout info">**<span style="color: rgb(226, 68, 116);"><span class="TextRun SCXW49396621 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW49396621 BCX8">New-</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">CsOnlineVoiceRoute</span><span class="NormalTextRun SCXW49396621 BCX8"> -Identity "</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">TMobileRouting</span><span class="NormalTextRun SCXW49396621 BCX8">“</span><span class="NormalTextRun SCXW49396621 BCX8"> -</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">NumberPattern</span> <span class="NormalTextRun ContextualSpellingAndGrammarErrorV2Themed SCXW49396621 BCX8">".\*</span><span class="NormalTextRun SCXW49396621 BCX8">" -</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">OnlinePstnGatewayList</span> </span><span class="TextRun Highlight SCXW49396621 BCX8" data-contrast="none" lang="EN-GB" style="background-color: rgb(241, 196, 15);" xml:lang="EN-GB"><span class="NormalTextRun SCXW49396621 BCX8">T10012345</span><span class="NormalTextRun SCXW49396621 BCX8">.</span><span class="NormalTextRun SCXW49396621 BCX8">teams</span><span class="NormalTextRun SCXW49396621 BCX8">.t-mobile.</span><span class="NormalTextRun SCXW49396621 BCX8">pl</span></span><span class="TextRun SCXW49396621 BCX8" data-contrast="none" lang="EN-GB" xml:lang="EN-GB"><span class="NormalTextRun SCXW49396621 BCX8"> -Priority 1 -</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">OnlinePstnUsages</span><span class="NormalTextRun SCXW49396621 BCX8"> "</span><span class="NormalTextRun SpellingErrorV2Themed SCXW49396621 BCX8">TMobileRouting</span><span class="NormalTextRun SCXW49396621 BCX8">"</span></span></span>**</p>

<p class="callout warning">**Do not close PowerShell it will be needed in the next instruction.**</p>

<span class="ui-provider a b c d e f g h i j k l m n o p q r s t u v w x y z ab ac ae af ag ah ai aj ak" dir="ltr">After successfully executing this command, you can proceed to the next instruction.</span>