Commands › Microsoft Teams

Get-Team

Microsoft Teams MicrosoftTeams Get-*

Get Team information based on particular properties.

Quick start script

# Get-Team — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-MicrosoftTeams -CertificateThumbprint $thumb -ApplicationId $appId -TenantId $tenantId

# 2. Run and inspect
Get-Team -GroupId <String> | Format-List

# 3. Export for evidence / drift tracking
Get-Team | Export-Clixml .\Team-$(Get-Date -Format yyyyMMdd).xml

Syntax — 2 parameter sets

Identity

Get-Team -GroupId <String> [-User <String>] [-Archived <Boolean>] [-Visibility <String>]
 [-DisplayName <String>] [-MailNickName <String>] [<CommonParameters>] [-NumberOfThreads <Int32>]

Filters

Get-Team [-User <String>] [-Archived <Boolean>] [-Visibility <String>] [-DisplayName <String>]
 [-MailNickName <String>] [<CommonParameters>] [-NumberOfThreads <Int32>]

Parameters (7)

ParameterTypeRequiredWhat it controls
-Archived Boolean If $true, filters to return teams that have been archived. If $false, filters to return teams that have not been archived. Do not specify any value to return teams that match filter regardless of archived state. This...
-DisplayName String Specify this parameter to return teams with the provided display name as a filter. As the display name is not unique, multiple values can be returned. Note that this filter value is case-sensitive.
-GroupId String yes Specify the specific GroupId (as a string) of the team to be returned. This is a unique identifier and returns exact match.
-MailNickName String Specify the mailnickname of the team that is being returned. This acts as a filter instead of being an exact match.
-NumberOfThreads Int32 Specifies the number of threads to use. If you have sufficient network bandwidth and want to decrease the time required to retrieve the list of teams, use the -NumberOfThreads parameter, which supports a value from 1...
-User String User's UPN (user principal name - e.g. johndoe@example.com)
-Visibility String Filters to return teams with a set "visibility" value. Accepted values are "Public", "Private" or "HiddenMembership". Do not specify any value to return teams that match filter regardless of visibility. This is a...

Message Center changes mentioning this command

Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.