Share:
Setting Up PowerShell
Set up PowerShell on Windows
By default, PowerShell comes pre-installed with the latest Windows OS versions. If you are already using PowerShell to manage different aspects of Azure or Office 365 subscriptions, most probably you are all set. To start:
- Start PowerShell CLE as administrator (you can do that by hitting the Windows keyboard button on your machine, entering PowerShell, and by selecting Run as an administrator)
- Install Teams PowerShell. Enter the command Install-Module MicrosoftTeams and hit enter
- Test connection if you can start the session successfully:
$credential = Get-Credential
Import-Module MicrosoftTeams
$sfboSession = New-CsOnlineSession -Credential $credential
Import-PSSession $sfboSession - Connect to Microsoft Teams:
Connect-MicrosoftTeams -Credential $credential
If you have trouble logging in, it might be due to Multi-Factor Authenticator.
To log in with MFA enabled, please start and run PowerShell ISE and use the following command:
$acctName=”[email protected]” $orgName=”company.domain” Import-Module MicrosoftTeams Connect-MicrosoftTeams
Please have the device on which you confirm your login, e.g mobile phone with Microsoft Authenticator App