Erwin Bierens

Knowledge is Power

Microsoft Teams - Connect to Powershell

2017-11-06 1 min read Microsoft Teams Powershell Erwin Bierens

Hi Guys,

Microsoft recently(11-2017) released the Powershell Cmdlets (still in beta), which gives you the opportunity to manage Microsoft Teams by Powershell.

Installing

To get started you wil first need to install the Microsoft Teams Powershell module. You can do this by using the following command:

    Install-Module -Name MicrosoftTeams

install-module MicrosoftTeams

Loading module

Once you have installed a module on your system, you will likely want to import the module in order to use it. Importing is the process that loads the module into active memory, so that a user can access that module in their PowerShell session. You can use the following cmdlet te import the MicrosoftTeams module.

    Import-Module MicrosoftTeams

Connecting

After installing the module we need to set up a connection to your Office 365 tenant, using the following command:

    Connect-MicrosoftTeams

Disconnect

When you are finished you can use the following command to shut down the connection:

    Disconnect-MicrosoftTeams

Check module version

Check your Microsoft Teams module version:

    Get-Module MicrosoftTeams | Format-Table Name,Version

Upgrade module

Upgrade your Microsoft Teams module by the following cmdlet:

    Update-Module Microsoft Teams

If this consult in a error message, you can add the -force parameter to install. /

comments powered by Disqus