You are on page 1of 92

Contents

Reference
teams
Add-TeamChannelUser
Add-TeamUser
Connect-MicrosoftTeams
Disconnect-MicrosoftTeams
Get-CsBatchPolicyAssignmentOperation
Get-CsGroupPolicyAssignment
Get-CsPolicyPackage
Get-CsUserPolicyAssignment
Get-CsUserPolicyPackage
Get-CsUserPolicyPackageRecommendation
Get-Team
Get-TeamChannel
Get-TeamChannelUser
Get-TeamFunSettings
Get-TeamGuestSettings
Get-TeamHelp
Get-TeamMemberSettings
Get-TeamMessagingSettings
Get-TeamsApp
Get-TeamUser
Grant-CsGroupPolicyPackageAssignment
Grant-CsUserPolicyPackage
New-CsBatchPolicyAssignmentOperation
New-CsBatchPolicyPackageAssignmentOperation
New-CsGroupPolicyAssignment
New-Team
New-TeamChannel
New-TeamsApp
Remove-CsGroupPolicyAssignment
Remove-Team
Remove-TeamChannel
Remove-TeamChannelUser
Remove-TeamsApp
Remove-TeamUser
Set-CsGroupPolicyAssignment
Set-Team
Set-TeamChannel
Set-TeamFunSettings
Set-TeamGuestSettings
Set-TeamMemberSettings
Set-TeamMessagingSettings
Set-TeamPicture
Set-TeamsApp
minutes to read • Edit Online

Add-TeamChannelUser
In ths Article

Adds an owner or member to the private channel. Note: the command will return immediately, but the Teams
application will not reflect the update immediately, please refresh the members page to see the update. To turn an
existing Member into an Owner, first Add-TeamChannelUser -User foo to add them to the members list, then Add-
TeamChannelUser -User foo -Role Owner to add them to owner list.

Syntax
Add-TeamChannelUser -GroupId <String> -DisplayName <String> -User <String> [-Role <String>]
[<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

Add-TeamChannelUser -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df -DisplayName "Engineering" -User


dmx@example.com

Add user dmx@example.com to private channel with name "Engineering" under the given group.
Example 2

Add-TeamChannelUser -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df -DisplayName "Engineering" -User


dmx@example.com -Role Owner

Promote user dmx@example.com to an owner of private channel with name "Engineering" under the given group.

Parameters
-DisplayName
Display name of the private channel
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-GroupId
GroupId of the parent team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Role
Owner

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-User
User's UPN (user principal name - e.g. johndoe@example.com)

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId, DisplayName, User, Role
minutes to read • Edit Online

Add-TeamUser
In ths Article

The `Add-TeamUser` adds an owner or member to the team, and to the unified group which backs the team.

Syntax
Add-TeamUser -GroupId <String> -User <String> [-Role <String>] [<CommonParameters>]

Description
This cmdlet adds an owner or member to the team, and to the unified group which backs the team.

NOTE
The command will return immediately, but the Teams application will not reflect the update immediately. The Teams
application may need to be open for up to an hour before changes are reflected.

It doesn't work in the same way that the Teams application. If you add an owner in the application the user is also
added as member to the unified group. Using this cmdlet, it will add the user only as an owner to the unified group,
not as a member. Then you can run the cmdlet again to add the user as member.

Examples
Example 1

Add-TeamUser -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df -User dmx@example.com

This example adds the user "dmx@example.com" to a group with the id "31f1ff6c-d48c-4f8a-b2e1-abca7fd399df".

Parameters
-GroupId
GroupId of the team.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Role
Member or Owner.

Type: String
Required: False
Position: Named
Default value: Member
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-User
User's UPN (user principal name - e.g. johndoe@example.com).

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId, User, Role
minutes to read • Edit Online

Connect-MicrosoftTeams
In ths Article

The Connect-MicrosoftTeams cmdlet connects an authenticated account to use for Microsoft Teams cmdlet
requests. You can use this authenticated account only with Microsoft Teams cmdlets.

Syntax
Connect-MicrosoftTeams [-TenantId <String>] [-Credential <PSCredential>] [-AccountId <String>]
[-LogLevel <LogLevel>] [-LogFilePath <String>] [-TeamsEnvironmentName <String>] [-WhatIf] [-Confirm]
[<CommonParameters>]

Connect-MicrosoftTeams -TenantId <String> -CertificateThumbprint <String> -ApplicationId <String>


[-LogLevel <LogLevel>] [-LogFilePath <String>] [-WhatIf] [-Confirm] [<CommonParameters>]

Connect-MicrosoftTeams [-TenantId <String>] -AadAccessToken <String> [-MsAccessToken <String>]


-AccountId <String> [-LogLevel <LogLevel>] [-LogFilePath <String>] [-WhatIf] [-Confirm] [<CommonParameters>]

Examples
Example 1

PS C:\> Connect-MicrosoftTeams -TeamsEnvironmentName TeamsGCCH

Specifies that the organization being managed is in the Teams GCC High environment, so connect to that
environment.

Parameters
-AadAccessToken
Specifies a Azure Active Directory Graph access token.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AccountId
Specifies the ID of an account. You must specify the UPN of the user when authenticating with a user access token.
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ApplicationId
Specifies the application ID of the service principal.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-CertificateThumbprint
Specifies the certificate thumbprint of a digital public key X.509 certificate of a user account that has permission to
perform this action.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Confirm
Prompts you for confirmation before running the cmdlet.

Type: SwitchParameter
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-Credential
Specifies a PSCredential object. For more information about the PSCredential object, type Get-Help Get-
Credential.
The PSCredential object provides the user ID and password for organizational ID credentials.

Type: PSCredential
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-LogFilePath
The path where the log file for this PowerShell session is written to. Provide a value here if you need to deviate
from the default PowerShell log file location.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-LogLevel
Specifies the log level. The acceptable values for this parameter are:
Info
Error
Warning
None
The default value is Info.

Type: LogLevel
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-MsAccessToken
Specifies a Microsoft Graph access token.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-TeamsEnvironmentName
Use this setting if your organization is in one of the Teams Government Cloud environments.
Specify "TeamsGCCH" if your organization is in the GCC High Environment. Specify "TeamsDOD" if your
organization is in the DoD Environment.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-TenantId
Specifies the ID of a tenant.
If you do not specify this parameter, the account is authenticated with the home tenant.
You must specify the TenantId parameter to authenticate as a service principal or when using Microsoft account.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type: SwitchParameter
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

Notes
Tips for troubleshooting:
1. Confirm SAML 2.0 is being used.
IDP is outputting invalid SAML information. Needs to have SAML 2.0 vs. SAML 1.0 for the module to connect. You
might experience an error if the Identity Provider (IDP ) only allows the use of SAML 1.0 when trying to auth via
basic authentication. Which in turn, isn't expected to work because the cmdlet expects either OAUTH2 (which is
used when doing just connect-microsofteams), or SAML 2.0.
2. Confirm you have the latest version of the cmdlet.
You can find the version by running: `get-module -listavailable` and then looking for the MicrosoftTeams name and
the version to the left of it. For more information and how to download the module, see Teams PowerShell
Overview
minutes to read • Edit Online

Disconnect-MicrosoftTeams
In ths Article

Syntax
Disconnect-MicrosoftTeams [-WhatIf] [-Confirm] [<CommonParameters>]

Examples
Example 1

PS C:\> Disconnect-MicrosoftTeams

Disconnects from the Microsoft Teams environment.

Parameters
-Confirm
Proactively accepts any confirmation prompts.

Type: SwitchParameter
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-WhatIf
Simulates what would happen if the cmdlet is run. The cmdlet is not run.

Type: SwitchParameter
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
minutes to read • Edit Online

Get-CsBatchPolicyAssignmentOperation
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is used to assign retrieve the status of batch policy assignment operations.

Syntax
Get-CsBatchPolicyAssignmentOperation [-OperationId <UniqueIdentifier>]

Description
This cmdlets returns the status of all batch policy assignment operations for the last 30 days. If an operation ID is
specified, the detailed status for that operation is returned including the status for each user in the batch.

Examples
Example 1
In this example, the status of all batch assignment operations is returned.

Get-CsBatchPolicyAssignmentOperation | ft OperationId, CreatedTime, CompletedTime, CompletedCount, ErrorCount

OperationId CreatedTime CompletedTime CompletedCount ErrorCount


----------- ----------- ------------- -------------- ----------
e640a5c9-c74f-4df7-b62e-4b01ae878bdc 7/19/2019 5:21:07 AM 7/19/2019 5:21:15 AM 8 0
01b9b2b7-5dbb-487c-b4ea-887c7c66559c 7/30/2019 7:55:16 PM 7/30/2019 7:55:21 PM 8 0
47bbc636-365d-4441-af34-9e0eceb05ef1 7/30/2019 8:14:22 PM 7/30/2019 8:14:33 PM 8 0
3964004e-caa8-4eb4-b0d2-7dd2c8173c8c 7/30/2019 8:17:37 PM 7/30/2019 8:17:49 PM 8 0
e70ef814-3289-4ee8-9402-5ec7ce1dde49 8/19/2019 8:16:25 PM 8/19/2019 8:16:34 PM 8 0
001141c3-1daa-4da1-88e9-66cc01c511e1 8/19/2019 8:17:41 PM 8/19/2019 8:17:51 PM 8 1
fd269d30-ae75-45b2-ad10-ec678940ef81 8/21/2019 11:28:01 PM 8/21/2019 11:28:07 PM 8 0
7040dcc2-30fa-4d19-a280-09e824c8b7aa 8/21/2019 11:37:00 PM 8/21/2019 11:37:12 PM 8 0

Example 2
In this example, the status of a single batch is returned, including the assignment status for each user. In this
example, one of the users was not found.
Get-CsBatchPolicyAssignmentOperation -OperationId 001141c3-1daa-4da1-88e9-66cc01c511e1 | Select -ExpandProperty
UserState

Id Result State
-- ------ -----
user01@fabrikam.com Success Completed
user02@fabrikam.com Success Completed
user03@fabrikam.com Success Completed
user04@fabrikam.com Success Completed
user05@fabkam.com Error: User not found. Completed
user06@fabrikam.com Success Completed
user07@fabrikam.com Success Completed
user08@fabrikam.com Success Completed

Outputs
OperationId
The ID of the operation that can be used with the Get-CsBatchPolicyAssignmentOperation cmdlet to get the status
of the operation.

Outputs
CompletedCount
The number of users in the batch for which the assignment has been completed (possibly with an error).

Outputs
CompletedTime
The date and time when the operation was completed.

Outputs
CreatedTime
The date and time when the operation was created.

Outputs
ErrorCount
The number of users in the batch for which the assignment failed.

Outputs
InProgressCount
The number of users in the batch for which the assignment is in progress.

Outputs
NotStartedCount
The number of users in the batch for which the assignment has not yet been performed.
Outputs
OperationId
The ID of the operation.

Outputs
OperationName
The name of the operation, if one was specific when the operation was created.

Outputs
OverallStatus
The overall status of the operations: NotStarted, InProgress, Complete

Outputs
UserState
Contains the status for each user in the batch.
Id: The ID of the user as specified when the batch was submitted. Either the user object ID (guid) or
UPN/SIP/email.
result: The result of the assignment operation for the user: Success or an error.
state: The status for the user: NotStarted, InProgress, Completed

Related Links
N ew-CsBatchPolicyAssignmentOperation
minutes to read • Edit Online

Get-CsGroupPolicyAssignment
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is used to return group policy assignments.

Syntax
Get-CsGroupPolicyAssignment [-GroupId <String>] [-PolicyType <String>]

Description
This cmdlets returns group policy assignments. Optional parameters allow the results to be restricted to policies
assigned to a specific group or policies of a specific type.

Examples
Example 1
In this example, all group policy assignments are returned.

Get-CsGroupPolicyAssignment

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
e050ce51-54bc-45b7-b3e6-c00343d31274 Tenant:SalesMessaging TeamsMessagingPolicy 2
e050ce51-54bc-45b7-b3e6-c00343d31274 Host:AllOff TeamsMeetingPolicy 2
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 3

Example 2
In this example, only the policies assigned to a specific group are returned.

Get-CsGroupPolicyAssignment -GroupId e050ce51-54bc-45b7-b3e6-c00343d31274

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
e050ce51-54bc-45b7-b3e6-c00343d31274 Tenant:SalesMessaging TeamsMessagingPolicy 2
e050ce51-54bc-45b7-b3e6-c00343d31274 Host:AllOff TeamsMeetingPolicy 2

Example 3
In this example, only the policies of a specific type are returned.
Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy
GroupId PolicyName PolicyType Priority
------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
e050ce51-54bc-45b7-b3e6-c00343d31274 Host:AllOff TeamsMeetingPolicy 2
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 3

Related Links
N ew-CsGroupPolicyAssignment

Set-CsGroupPolicyAssignment

Remove-CsGroupPolicyAssignment
minutes to read • Edit Online

Get-CsPolicyPackage
In ths Article

This cmdlet supports retrieving all the policy packages available on a tenant.

Syntax
Get-CsPolicyPackage [[-Identity] <String>] [<CommonParameters>]

Description
This cmdlet supports retrieving all the policy packages available on a tenant. Provide the identity of a specific policy
package to retrieve its definition, including details on the policies applied with the package. For more information
on policy packages, please review https://docs.microsoft.com/en-us/MicrosoftTeams/manage-policy-packages

Examples
Example 1

PS C:\> Get-CsPolicyPackage

Returns all policy packages available on the tenant.


Example 2

PS C:\> Get-CsPolicyPackage -Identity Education_PrimaryStudent

Returns the definition of the Education_PrimaryStudent policy package, including the policies applied with the
package.

Parameters
-Identity
The name of a specific policy package. All possible policy package names can be found by running Get-
CsPolicyPackage.

Type: String
Required: False
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Related Links
Get-CsUserPolicyPackageRecommendation
Get-CsUserPolicyPackage
Grant-CsUserPolicyPackage
minutes to read • Edit Online

Get-CsUserPolicyAssignment
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is used to return the policy assignments for a user, both directly assigned and inherited from a group.

Syntax
Get-CsUserPolicyAssignment -Identity <String> [-PolicyType <String>]

Description
This cmdlets returns the effective policies for a user, based on either direct policy assignment or inheritance from a
group policy assignment. For a given policy type, if an effective policy is not returned, this indicates that the
effective policy for the user is either the tenant global default policy (if set) or the system global default policy.
This cmdlet does not currently support returning policies for multiple users.

Examples
Example 1
This examples returns the policies that are either directly assigned to a user or that the user inherited from a group.

Get-CsUserPolicyAssignment -Identity 3b90faad-9056-49ff-8357-0b53b1d45d39

PolicyName PolicyType
---------- ----------
AllowCalling TeamsCallingPolicy
Employees Events TeamsMeetingBroadcastPolicy
Kiosk TeamsMeetingPolicy

Example 2
The PolicySource property can be expanded to show more details for a particular policy type. The PolicySource
property indicates whether a particular policy was directly assigned to the user or inherited from a group.
In this example, the details for the TeamsBroadcastMeetingPolicy are shown. The user was directly assigned the
"Employees Events" policy, which took precedence over the "Vendor Live Events" policy which is assigned to a
group that the user belongs to.
Get-CsUserPolicyAssignment -Identity 3b90faad-9056-49ff-8357-0b53b1d45d39 -PolicyType
TeamsMeetingBroadcastPolicy | select -ExpandProperty PolicySource

AssignmentType PolicyName Reference


-------------- ---------- ---------
Direct Employees Events
Group Vendor Live Events 566b8d39-5c5c-4aaa-bc07-4f36278a1b38

Example 3
In this example, the details for the TeamsMeetingPolicy are shown. The user is a member of two groups, each of
which is assigned a TeamsMeetingPolicy. The user has inherited the "AllOn" policy because the priority of the
assignment is higher than that of the "Kiosk" policy assignment to the other group.

Get-CsUserPolicyAssignment -Identity 3b90faad-9056-49ff-8357-0b53b1d45d39 -PolicyType TeamsMeetingPolicy |


select -ExpandProperty PolicySource

AssignmentType PolicyName Reference


-------------- ---------- ---------
Group AllOn d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17
Group Kiosk 566b8d39-5c5c-4aaa-bc07-4f36278a1b38

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 AllOn TeamsMeetingPolicy 1
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Kiosk TeamsMeetingPolicy 2

Related Links
N ew-CsGroupPolicyAssignment

Set-CsGroupPolicyAssignment

Remove-CsGroupPolicyAssignment
minutes to read • Edit Online

Get-CsUserPolicyPackage
In ths Article

This cmdlet supports retrieving the policy package that's assigned to a user.

Syntax
Get-CsUserPolicyPackage [-Identity] <String> [<CommonParameters>]

Description
This cmdlet supports retrieving the policy package that's assigned to a user. Provide the identity of a user to
retrieve the definition of their assigned policy package. For more information on policy packages, please review
https://docs.microsoft.com/en-us/MicrosoftTeams/manage-policy-packages

Examples
Example 1

PS C:\> Get-CsUserPolicyPackage -Identity johndoe@example.com

Returns the policy package that's assigned to johndoe@example.com.

Parameters
-Identity
The user that will get their assigned policy package.

Type: String
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Related Links
Get-CsPolicyPackage
Get-CsUserPolicyPackageRecommendation
Grant-CsUserPolicyPackage
minutes to read • Edit Online

Get-CsUserPolicyPackageRecommendation
In ths Article

This cmdlet supports retrieving recommendations for which policy packages are best suited for a given user.

Syntax
Get-CsUserPolicyPackageRecommendation [-Identity] <String> [<CommonParameters>]

Description
This cmdlet supports retrieving recommendations for which policy packages are best suited for a given user. This
recommendation is based on tenant and user information such as license types. For more information on policy
packages, please review https://docs.microsoft.com/en-us/MicrosoftTeams/manage-policy-packages

Examples
Example 1

PS C:\> Get-CsUserPolicyPackageRecommendation -Identity johndoe@example.com

Returns recommendations for which policy packages are best suited for johndoe@example.com. The
recommendation value per package can either be none, weak, or strong based on how confident the existing
signals (e.g. license type) imply a user role.

Parameters
-Identity
The user that will receive policy package recommendations.

Type: String
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Related Links
Get-CsPolicyPackage
Get-CsUserPolicyPackage
Grant-CsUserPolicyPackage
minutes to read • Edit Online

Get-Team
In ths Article

This cmdlet supports retrieving teams with particular properties/information, including all teams that a specific
user belongs to, all teams that have been archived, all teams with a specific display name, or all teams in the
organization.

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

Get-Team [-User <String>] [-Archived <Boolean>] [-Visibility <String>] [-DisplayName <String>]


[-MailNickName <String>] [<CommonParameters>]

Description
This cmdlet supports retrieving teams with particular properties/information, including all teams that a specific
user belongs to, all teams that have been archived, all teams with a specific display name, or all teams in the
organization.
Note: depending on the number of teams and O365 Groups in your organization and which filters you are using,
this cmdlet can take upwards of ten minutes to run. Some of the input parameters are guaranteed unique (e.g.
GroupId), and others serve as filters (e.g. -Archived).

Examples
Example 1

PS> Get-Team -User dmx1@example.com

Returns all teams that a user (dmx1@example.com) belongs to


Example 2

PS> Get-Team -Archived $true -Visibility Private

Returns all teams that are private and have been archived.
Example 3

PS> Get-Team -MailNickName "BusinessDevelopment"

Returns the team that matches the specified MailNickName


Parameters
-Archived
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 is a filter rather than an
exact match.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-DisplayName
Filters to return teams with a full match to the provided displayname. As displayname is not unique, this acts as a
filter rather than an exact match.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
Specify the specific GroupId (as a string) of the team to be returned. This is a unique identifier and returns exact
match.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-MailNickName
Specify the mailnickname of the team that is being returned. This is a unique identifier and returns exact match.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-User
User's UPN (user principal name - e.g. johndoe@example.com)
Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Visibility
Filters to return teams with a set "visibility" value. Accepted values are "Public" or "Private". Do not specify any
value to return teams that match filter regardless of visibility. This is a filter rather than an exact match.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Inputs
UPN, UserID

Outputs
Team

Related Links
N ew-Team

Set-Team
minutes to read • Edit Online

Get-TeamChannel
In ths Article

Get all the channels for a team.

Syntax
Get-TeamChannel -GroupId <String> [-MembershipType <String>] [<CommonParameters>]

Examples
Example 1

Get-TeamChannel -GroupId af55e84c-dc67-4e48-9005-86e0b07272f9

Get channels of the group.


Example 2

Get-TeamChannel -GroupId af55e84c-dc67-4e48-9005-86e0b07272f9 -MembershipType Private

Get all private channels of the group.

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-MembershipType
Membership type of the channel to display, Standard or Private (available in private preview )

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
minutes to read • Edit Online

Get-TeamChannelUser
In ths Article

Returns users of a channel.

Syntax
Get-TeamChannelUser -GroupId <String> -DisplayName <String> [-Role <String>] [<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

Get-TeamChannelUser -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf -DisplayName "Engineering" -Role Owner

Get owners of channel with display name as "Engineering"

Parameters
-DisplayName
Display name of the channel

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-GroupId
GroupId of the team
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Role
Filter the results to only users with the given role: Owner or Member.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
minutes to read • Edit Online

Get-TeamFunSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To
retrieve a Team's fun settings, run Get-Team. Gets a team's fun settings.

Syntax
Get-TeamFunSettings -GroupId <String>

Examples
-------------------------- Example 1 --------------------------

Get-TeamFunSettings -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Get-TeamGuestSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To
retrieve a Team's guest settings, run Get-Team. Gets Team guest settings.

Syntax
Get-TeamGuestSettings -GroupId <String>

Examples
-------------------------- Example 1 --------------------------

Get-TeamGuestSettings -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Get-TeamHelp
In ths Article

Gets a list of commands for Microsoft Teams.

Syntax
Get-TeamHelp

Examples
Example 1

PS C:\> Get-TeamHelp

Gets a list of commands available for Microsoft Teams.


minutes to read • Edit Online

Get-TeamMemberSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To
retrieve a Team's member settings, run Get-Team. Gets team member settings.

Syntax
Get-TeamMemberSettings -GroupId <String>

Examples
-------------------------- Example 1 --------------------------

Get-TeamMemberSettings -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Get-TeamMessagingSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To
retrieve a Team's messaging settings, run Get-Team. Gets team messaging settings.

Syntax
Get-TeamMessagingSettings -GroupId <String>

Examples
-------------------------- Example 1 --------------------------

Get-TeamMessagingSettings -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Get-TeamsApp
In ths Article

Returns app information from the Teams tenant app store.

Syntax
Get-TeamsApp [-Id <String>] [-ExternalId <String>] [-DisplayName <String>] [-DistributionMethod <String>]
[<CommonParameters>]

Description
Use any optional parameter to retrieve app information from the Teams tenant app store.

Examples
Example 1

PS C:\> Get-TeamsApp -Id b9cc7986-dd56-4b57-ab7d-9c4e5288b775

Example 2

PS C:\> Get-TeamsApp -ExternalId b00080be-9b31-4927-9e3e-fa8024a7d98a -DisplayName ] [-DistributionMethod ]

Example 3

PS C:\> Get-TeamsApp -DisplayName SampleApp -DistributionMethod organization

Parameters
-DisplayName
Name of the app visible to users

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-DistributionMethod
The type of app in Teams: global or organization. For LOB apps, use "organization"
Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ExternalId
The external ID of the app, provided by the app developer and used by Azure Active Directory

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Id
The app's ID generated by Teams (different from the external ID )

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Inputs
None

Outputs
System.Object
minutes to read • Edit Online

Get-TeamUser
In ths Article

Returns users of a team.

Syntax
Get-TeamUser -GroupId <String> [-Role <String>] [<CommonParameters>]

Examples
Example 1

Get-TeamUser -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf -Role Owner

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Role
Filter the results to only users with the given role: Owner or Member.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
minutes to read • Edit Online

Grant-CsGroupPolicyPackageAssignment
In ths Article

This cmdlet applies a policy package to a group in a tenant.

Syntax
Grant-CsUserPolicyPackage -Identity <String> -PackageName <String> [-Priority <String>] [<CommonParameters>]

Description
This cmdlet applies a policy package to a group in a tenant. Provide a group identity to assign the package with all
the associated policies. The available policy packages and their definitions can be found by running Get-
CsPolicyPackage. Priority can be optionally specified to determine which policies in a package will be applied to the
user in case they belong to two or more groups. If priority is not specified, the group's package assignment will be
ranked last in priority. If a user was directly assigned a package, direct assignment takes precedence over group
assignment. For more information on priority and group policy assignments, please review this section. For more
information on policy packages, please review https://docs.microsoft.com/en-us/MicrosoftTeams/manage-policy-
packages

Examples
Example 1

PS C:\> Grant-CsGroupPolicyPackageAssignment -Identity 1bc0b35f-095a-4a37-a24c-c4b6049816ab -PackageName


Education_PrimaryStudent

Applies the Education_PrimaryStudent policy package to the group in the tenant.


Example 2

PS C:\> Grant-CsGroupPolicyPackageAssignment -Identity 1bc0b35f-095a-4a37-a24c-c4b6049816ab -PackageName


Education_Teacher -Priority 2

Applies the Education_Teacher policy package to the group in the tenant with a priority of 2, which means each
policy in the package will be assigned to the group with a priority of 2.

Parameters
-Identity
A group id in the tenant. It can either be a group's object id or a group's email address.
Type: String
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-PackageName
The name of a specific policy package to apply. All possible policy package names can be found by running Get-
CsPolicyPackage.

Type: String
Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Priority
The priority of the package assignment, relative to other group package assignments that contain one or more of
the same policy types.

Type: String
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Related Links
Get-CsPolicyPackage
New -CsGroupPolicyAssignment
minutes to read • Edit Online

Grant-CsUserPolicyPackage
In ths Article

This cmdlet supports applying a policy package to users in a tenant.

Syntax
Grant-CsUserPolicyPackage [-Identity] <String[]> [-PackageName] <String> [<CommonParameters>]

Description
This cmdlet supports applying a policy package to users in a tenant. Provide one or more user identities to assign
the package with all the associated policies. The available policy packages and their definitions can be found by
running Get-CsPolicyPackage. The recommended policy package for each user can be found by running Get-
CsUserPolicyPackageRecommendation. For more information on policy packages, please review
https://docs.microsoft.com/en-us/MicrosoftTeams/manage-policy-packages

Examples
Example 1

PS C:\> Grant-CsUserPolicyPackage -Identity 1bc0b35f-095a-4a37-a24c-c4b6049816ab,johndoe@example.com -


PackageName Education_PrimaryStudent

Applies the Education_PrimaryStudent policy package to two users in the tenant.

Parameters
-Identity
A list of one or more users in the tenant. Note that we recommend applying a policy package to no more than 15
users at once.

Type: String[]
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-PackageName
The name of a specific policy package to apply. All possible policy package names can be found by running Get-
CsPolicyPackage.
Type: String
Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Related Links
Get-CsPolicyPackage
Get-CsUserPolicyPackageRecommendation
Get-CsUserPolicyPackage
minutes to read • Edit Online

New-CsBatchPolicyAssignmentOperation
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is used to assign a policy to a batch of users.

Syntax
New-CsBatchPolicyAssignmentOperation -PolicyType <String> -PolicyName <String> -Identity <Array> [-
OperationName <String>]

Description
When a policy is assigned to a batch of users, the assignments are performed as an asynchronous operation. The
cmdlet returns the operation ID which can be used to track the progress and status of the assignments.
Users can be specified by their object ID (guid) or by their UPN/SIP/email (user@contoso.com).
A batch may contain up to 20,000 users.
Batch policy assignment is currently limited to the following policy types: CallingLineIdentity,
TeamsAppSetupPolicy, TeamsAppPermissionPolicy, TeamsCallingPolicy, TeamsCallParkPolicy,
TeamsChannelsPolicy, TeamsEducationAssignmentsAppPolicy, TeamsMeetingBroadcastPolicy,
TeamsMeetingPolicy, TeamsMessagingPolicy, TeamsUpdateManagementPolicy, TeamsUpgradePolicy,
TeamsVerticalPackagePolicy, TeamsVideoInteropServicePolicy, TenantDialPlan

Examples
Example 1
In this example, the batch of users is specified as an array of user email addresses.

$users_ids = @("psmith@contoso.com","tsanchez@contoso.com","bharvest@contoso.com")
New-CsBatchPolicyAssignmentOperation -PolicyType TeamsMeetingPolicy -PolicyName Kiosk -Identity $users_ids -
OperationName "Example 1 batch"

Example 2
In this example, the batch of users is read from a text file containing user object IDs (guids).

$user_ids = Get-Content .\users_ids.txt


New-CsBatchPolicyAssignmentOperation -PolicyType TeamsMeetingPolicy -PolicyName Kiosk -Identity $users_ids -
OperationName "Example 1 batch"

Example 3
In this example, the batch of users is obtained by connecting to Azure AD and retrieving a collection of users and
then referencing their user principal names.

Connect-AzureAD
$users = Get-AzureADUser
New-CsBatchPolicyAssignmentOperation -PolicyType TeamsMeetingPolicy -PolicyName Kiosk -Identity
$users.UserPrincipalName -OperationName "Example 1 batch"

Outputs
OperationId
The ID of the operation that can be used with the Get-CsBatchPolicyAssignmentOperation cmdlet to get the status
of the operation.

Related Links
Get-CsBatchPolicyAssignmentOperation
minutes to read • Edit Online

New-CsBatchPolicyPackageAssignmentOperation
In ths Article

This cmdlet submits an operation that applies a policy package to a batch of users in a tenant.

Syntax
New-CsBatchPolicyPackageAssignmentOperation -Identity <String[]> -PackageName <String> [<CommonParameters>]

Description
This cmdlet submits an operation that applies a policy package to a batch of users in a tenant. Provide one or more
user identities to assign the package with all the associated policies. The available policy packages and their
definitions can be found by running Get-CsPolicyPackage. The recommended policy package for each user can be
found by running Get-CsUserPolicyPackageRecommendation. For more information on policy packages, please
review https://docs.microsoft.com/en-us/MicrosoftTeams/manage-policy-packages

Examples
Example 1

PS C:\> New-CsBatchPolicyPackageAssignmentOperation -Identity 1bc0b35f-095a-4a37-a24c-


c4b6049816ab,johndoe@example.com,richardroe@example.com -PackageName Education_PrimaryStudent

Applies the Education_PrimaryStudent policy package to three users in the tenant.

Parameters
-Identity
A list of one or more users in the tenant. A user identity can either be a user's object id or email address.

Type: String[]
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-PackageName
The name of a specific policy package to apply. All policy package names can be found by running Get-
CsPolicyPackage.
Type: String
Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Related Links
Get-CsPolicyPackage
Get-CsUserPolicyPackageRecommendation
minutes to read • Edit Online

New-CsGroupPolicyAssignment
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is used to assign a policy to a group.

Syntax
New-CsGroupPolicyAssignment -GroupId <String> -PolicyType <String> -PolicyName <String> [-Priority <Int>]

Description
This cmdlet will assign a policy to a group. The policy assignment will then be propagated to the members of the
group in accordance with the rules for group policy inheritance. If a user is directly assigned a policy of a specific
type, then they will not inherit a policy of the same type from a group. If a user is a member of two or more groups
that each have a policy of the same type assigned, then the user will inherit the policy based on the group policy
assignment with the highest priority.
The group policy assignment is set at the time a policy is being assigned to a group and is relative to other group
policy assignments of the same policy type. For example, if there are two groups, each assigned a Teams Meeting
policy, then one of the group assignments will be priority 1 while the other will be priority 2.
It’s helpful to think of priority as determining the position of each policy assignment in an ordered list, from highest
priority to lowest priority. In fact, priority can be specified as any number, but these are converted into sequential
values 1, 2, 3, etc. with 1 being the highest priority. When assigning a policy to a group, set the priority to be the
position in the list where you want the new group policy assignment to be. If a priority is not specified, the policy
assignment will be given the lowest priority, corresponding to the end of the list.
Group policy assignment is currently limited to the following policy types: TeamsCallingPolicy,
TeamsCallParkPolicy, TeamsEducationAssignmentsAppPolicy, TeamsMeetingBroadcastPolicy, TeamsMeetingPolicy,
TeamsMessagingPolicy, TeamsUpdateManagementPolicy

Examples
Example 1
In this example, a policy is assigned to a group specified by object id.

New-CsGroupPolicyAssignment -GroupId d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 -PolicyType TeamsMeetingPolicy -


PolicyName AllOn -Priority 1

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
Example 2
In this example, a policy is assigned to a group specified by email/SIP address. The priority is not specified so it will
be set to the lowest priority for the given policy type.

New-CsGroupPolicyAssignment -GroupId salesdepartment@contoso.com -PolicyType TeamsMeetingPolicy -PolicyName


Kiosk

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 2

Example 3
In this example, the policy assignment priority is set to 2. The current priority 2 policy assignment of the same type
will be updated to priority 3.

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 2

New-CsGroupPolicyAssignment -GroupId e050ce51-54bc-45b7-b3e6-c00343d31274 -PolicyType TeamsMeetingpolicy -


PolicyName AllOff -Priority 2

Get-CsGroupPolicyAssignment

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
e050ce51-54bc-45b7-b3e6-c00343d31274 Host:AllOff TeamsMeetingPolicy 2
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 3

Related Links
Get-CsGroupPolicyAssignment

Set-CsGroupPolicyAssignment

Remove-CsGroupPolicyAssignment
minutes to read • Edit Online

New-Team
In ths Article

This cmdlet lets you provision a new Team for use in Microsoft Teams and will create an O365 Unified Group to
back the team. Groups created through teams cmdlets, APIs, or clients will not show up in Outlook by default. If
you want these groups to appear in Outlook clients, you can use the Set-UnifiedGroup
(https://docs.microsoft.com/en-us/powershell/module/exchange/users-and-groups/set-unifiedgroup?
view=exchange-ps) cmdlet in the Exchange Powershell Module to set the parameter HiddenFromExchangeClients
to $false. Note: The Teams application may need to be open by an Owner for up to two hours before changes are
reflected.

Syntax
New-Team -DisplayName <String> [-Description <String>] [-MailNickName <String>] [-Classification <String>]
[-Visibility <String>] [-Template <String>] [-Owner <String>] [-AllowGiphy <Boolean>]
[-GiphyContentRating <String>] [-AllowStickersAndMemes <Boolean>] [-AllowCustomMemes <Boolean>]
[-AllowGuestCreateUpdateChannels <Boolean>] [-AllowGuestDeleteChannels <Boolean>]
[-AllowCreateUpdateChannels <Boolean>] [-AllowDeleteChannels <Boolean>] [-AllowAddRemoveApps <Boolean>]
[-AllowCreateUpdateRemoveTabs <Boolean>] [-AllowCreateUpdateRemoveConnectors <Boolean>]
[-AllowUserEditMessages <Boolean>] [-AllowUserDeleteMessages <Boolean>] [-AllowOwnerDeleteMessages <Boolean>]
[-AllowTeamMentions <Boolean>] [-AllowChannelMentions <Boolean>][-ShowInTeamsSearchAndSuggestions <Boolean>]
[<CommonParameters>]

New-Team -GroupId <String> [-Owner <String>] [-AllowGiphy <Boolean>] [-GiphyContentRating <String>]


[-AllowStickersAndMemes <Boolean>] [-AllowCustomMemes <Boolean>] [-AllowGuestCreateUpdateChannels <Boolean>]
[-AllowGuestDeleteChannels <Boolean>] [-AllowCreateUpdateChannels <Boolean>] [-AllowDeleteChannels <Boolean>]
[-AllowAddRemoveApps <Boolean>] [-AllowCreateUpdateRemoveTabs <Boolean>]
[-AllowCreateUpdateRemoveConnectors <Boolean>] [-AllowUserEditMessages <Boolean>]
[-AllowUserDeleteMessages <Boolean>] [-AllowOwnerDeleteMessages <Boolean>] [-AllowTeamMentions <Boolean>]
[-AllowChannelMentions <Boolean>][-ShowInTeamsSearchAndSuggestions <Boolean>] [<CommonParameters>]

Description
Creates a new team with user specified settings, and returns a Group object with a GroupID property. Note that
Templates are not yet supported in our 1.0 PowerShell release.

Examples
Example 1

New-Team -DisplayName "Tech Reads"

Example 2

New-Team -DisplayName "Tech Reads" -Description "Team to post technical articles and blogs" -Visibility Public
Example 3

Connect-MicrosoftTeams -AccountId myaccount@example.com


$group = New-Team -MailNickname "TestTeam" -displayname "Test Teams" -Visibility "private"
Add-TeamUser -GroupId $group.GroupId -User "fred@example.com"
Add-TeamUser -GroupId $group.GroupId -User "john@example.com"
Add-TeamUser -GroupId $group.GroupId -User "wilma@example.com"
New-TeamChannel -GroupId $group.GroupId -DisplayName "Q4 planning"
New-TeamChannel -GroupId $group.GroupId -DisplayName "Exec status"
New-TeamChannel -GroupId $group.GroupId -DisplayName "Contracts"

Parameters
-AllowAddRemoveApps
Boolean value that determines whether or not members (not only owners) are allowed to add apps to the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowChannelMentions
Boolean value that determines whether or not channels in the team can be @ mentioned so that all users who
follow the channel are notified.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateChannels
Setting that determines whether or not members (and not just owners) are allowed to create channels.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateRemoveConnectors
Setting that determines whether or not members (and not only owners) can manage connectors in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-AllowCreateUpdateRemoveTabs
Setting that determines whether or not members (and not only owners) can manage tabs in channels.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCustomMemes
Setting that determines whether or not members can use the custom memes functionality in teams.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowDeleteChannels
Setting that determines whether or not members (and not only owners) can delete channels in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGiphy
Setting that determines whether or not giphy can be used in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGuestCreateUpdateChannels
Setting that determines whether or not guests can create channels in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGuestDeleteChannels
Setting that determines whether or not guests can delete in the team.
Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowOwnerDeleteMessages
Setting that determines whether or not owners can delete messages that they or other members of the team have
posted.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowStickersAndMemes
Setting that determines whether stickers and memes usage is allowed in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowTeamMentions
Setting that determines whether the entire team can be @ mentioned (which means that all users will be notified)

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowUserDeleteMessages
Setting that determines whether or not members can delete messages that they have posted.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowUserEditMessages
Setting that determines whether or not users can edit messages that they have posted.
Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Classification
This parameter is reserved for internal Microsoft use.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Description
Team description. Team Description Characters Limit - 1024.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-DisplayName
Team display name. Team Name Characters Limit - 256.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-GiphyContentRating
Setting that determines the level of sensitivity of giphy usage that is allowed in the team. Accepted values are
"Strict" or "Moderate"

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
Specify a GroupId to convert to a Team. If specified, you cannot provide the other values that are already specified
by the existing group, namely: Visibility, Alias, Description, or DisplayName.
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-MailNickName
The MailNickName parameter specifies the alias for the associated Office 365 Group. This value will be used for
the mail enabled object and will be used as PrimarySmtpAddress for this Office 365 Group. The value of the
MailNickName parameter has to be unique across your tenant.
For more details about the naming conventions see here: New -UnifiedGroup, Parameter: -Alias
(https://docs.microsoft.com/en-us/powershell/module/exchange/users-and-groups/new -unifiedgroup?
view=exchange-ps#optional-parameters).

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Owner
An admin who is allowed to create on behalf of another user should use this flag to specify the desired owner of
the group. This user will be added as both a member and an owner of the group. If not specified, the user who
creates the team will be added as both a member and an owner.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-ShowInTeamsSearchAndSuggestions
Setting that determines whether or not private teams should be searchable from Teams clients for users who do
not belong to that team. Set to $false to make those teams not discoverable from Teams clients.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Template
Note: this parameter is not supported in our 1.0 PowerShell release, only in Preview.
If you have an EDU license, you can use this parameter to specify which template you'd like to use for creating your
group. Do not use this parameter when converting an existing group.
Valid values are: "EDU_Class" or "EDU_PLC"
Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Visibility
Set to Public to allow all users in your organization to join the group by default. Set to Private to require that an
owner approve the join request.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Outputs
GroupId

Related Links
Remove-Team
Get-Team
Set-Team
minutes to read • Edit Online

New-TeamChannel
In ths Article

Add a new channel to a team.

Syntax
New-TeamChannel -GroupId <String> -DisplayName <String> [-Description <String>] [-MembershipType <String>] [-
Owner <String>] [<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

New-TeamChannel -GroupId 126b90a5-e65a-4fef-98e3-d9b49f4acf12 -DisplayName "Architecture"

Create a standard channel with display name as "Architecture"


Example 2

New-TeamChannel -GroupId 126b90a5-e65a-4fef-98e3-d9b49f4acf12 -DisplayName "Engineering" -MembershipType


Private

Create a private channel with display name as "Engineering"

Parameters
-Description
Channel description. Channel description can be up to 1024 characters.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
-DisplayName
Channel display name. Names must be 50 characters or less, and can't contain the characters # % & * { } / \ : < > ?
+|'"

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-MembershipType (available in private preview)


Channel membership type, Standard or Private.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Owner (available in private preview)


UPN of owner that can be specified while creating a private channel.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId, DisplayName, Description, MembershipType, Owner

Outputs
Id
minutes to read • Edit Online

New-TeamsApp
In ths Article

Creates a new app in the Teams tenant app store.

Syntax
New-TeamsApp -DistributionMethod <String> -Path <String> [<CommonParameters>]

Description
Use a Teams app manifest zip file to upload an app to the tenant app store. DistributionMethod specifies that the
app should be added to the organization.

Examples
Example 1

PS C:\> New-TeamsApp -DistributionMethod organization -Path c:\Path\SampleApp.zip

Parameters
-DistributionMethod
The type of app in Teams: global or organization. For LOB apps, use "organization"

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Path
The local path of the app manifest zip file, for use in New and Set

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Inputs
None

Outputs
System.Object
minutes to read • Edit Online

Remove-CsGroupPolicyAssignment
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is used to remove a group policy assignment.

Syntax
Remove-CsGroupPolicyAssignment -GroupId <String> -PolicyType <String>

Description
This cmdlet removes the policy of a specific type from a group. A group can only be assigned one policy of a given
type, so the name of the pokicy tobe removed does not need to be specified.
When a policy assignment is removed from a group, any other group policy assignments of the same type that
have lower priority will be updated. For example, if the policy assignment with priority 2 is removed, then the
priority 3 and 4 policy assignments will be updated to priority 2 and 3 respectively.

Examples
Example 1
In this example, the policy assignment with priority 2 is removed. As a result, the policy assignment with priority 3
is updated to priority 2.

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
e050ce51-54bc-45b7-b3e6-c00343d31274 Host:AllOff TeamsMeetingPolicy 2
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 3

Remove-CsGroupPolicyAssignment -GroupId e050ce51-54bc-45b7-b3e6-c00343d31274 -PolicyType TeamsMeetingPolicy

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 2

Related Links
Get-CsGroupPolicyAssignment

N ew-CsGroupPolicyAssignment

Set-CsGroupPolicyAssignment
minutes to read • Edit Online

Remove-Team
In ths Article

This cmdlet deletes a specified Team from Microsoft Teams. NOTE: The associated Office 365 Unified Group will
also be removed.

Syntax
Remove-Team -GroupId <String> [<CommonParameters>]

Description
Removes a specified team via GroupID and all its associated components, like O365 Unified Group...

Examples
Example 1

Remove-Team -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Related Links
N ew-Team
minutes to read • Edit Online

Remove-TeamChannel
In ths Article

Delete a channel. This will not delete content in associated tabs. Note: The channel will be "soft deleted", meaning
the contents are not permanently deleted for a time. So a subsequent call to Add-TeamChannel using the same
channel name will fail if enough time has not passed.

Syntax
Remove-TeamChannel -GroupId <String> -DisplayName <String> [<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

Remove-TeamChannel -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf -DisplayName "Tech Reads"

Parameters
-DisplayName
Channel name to be deleted

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-GroupId
GroupId of the team
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Remove-TeamChannelUser
In ths Article

Note: the command will return immediately, but the Teams application will not reflect the update immediately,
please refresh the members page to see the update. To turn an existing Owner into an Member, specify role
parameter as Owner. Note: last owner cannot be removed from the private channel.

Syntax
Remove-TeamChannelUser -GroupId <String> -DisplayName <String> -User <String> [-Role <String>]
[<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

Remove-TeamChannelUser -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df -DisplayName "Engineering" -User


dmx@example.com

Parameters
-DisplayName
Display name of the private channel

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-GroupId
GroupId of the team
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Role
Use this to demote a user from owner to member of the team

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-User
User's UPN (user principal name - e.g. johndoe@example.com)

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Remove-TeamsApp
In ths Article

Removes an app in the Teams tenant app store.

Syntax
Remove-TeamsApp -Id <String> [<CommonParameters>]

Description
Removes an app in the Teams tenant app store.

Examples
Example 1

PS C:\> Remove-TeamsApp -Id b9cc7986-dd56-4b57-ab7d-9c4e5288b775

Parameters
-Id
The app's ID generated by Teams (different from the external ID )

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Inputs
None

Outputs
System.Object
minutes to read • Edit Online

Remove-TeamUser
In ths Article

Remove an owner or member from a team, and from the unified group which backs the team. Note: the command
will return immediately, but the Teams application will not reflect the update immediately. The Teams application
may need to be open for up to an hour before changes are reflected. Note: last owner cannot be removed from the
team.

Syntax
Remove-TeamUser -GroupId <String> -User <String> [-Role <String>] [<CommonParameters>]

Examples
Example 1

Remove-TeamUser -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df -User dmx@example.com -Role Owner

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Role
Specify the role of the user you are removing from the team.

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-User
User's UPN (user principal name - e.g. johndoe@example.com)
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
minutes to read • Edit Online

Set-CsGroupPolicyAssignment
In ths Article

NOTE: This cmdlet is currently only available in limited preview in the pre-release Teams PowerShell module. This
cmdlet is update a group policy assignment.

Syntax
Set-CsGroupPolicyAssignment -GroupId <String> -PolicyType <String> [-PolicyName <String>] [-Priority <Int>]

Description
This cmdlet will update the policy assignment for a group for a given policy type. The policy instance and/or policy
priority can be updated. Refer to for more details about priority.
N ew-CsGroupPolicyAssignment

Examples
Example 1
In this example, a new policy of the same type is set without changing the priority.

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOn TeamsMeetingPolicy 1
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 2

Set-CsGroupPolicyAssignment -GroupId d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 -PolicyType TeamsMeetingPolicy -


PolicyName AllOff

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOff TeamsMeetingPolicy 1
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 2

Example 2
In this example, the priority of the policy assignment is updated.
Set-CsGroupPolicyAssignment -GroupId d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 -PolicyType TeamsMeetingPolicy -
Priority 2

Get-CsGroupPolicyAssignment -PolicyType TeamsMeetingPolicy

GroupId PolicyName PolicyType Priority


------- ---------- ---------- --------
566b8d39-5c5c-4aaa-bc07-4f36278a1b38 Host:Kiosk TeamsMeetingPolicy 1
d8ebfa45-0f28-4d2d-9bcc-b158a49e2d17 Host:AllOff TeamsMeetingPolicy 2

Related Links
Get-CsGroupPolicyAssignment

Set-CsGroupPolicyAssignment

Remove-CsGroupPolicyAssignment
minutes to read • Edit Online

Set-Team
In ths Article

This cmdlet allows you to update properties of a team, including its displayname, description, and team-specific
settings.

Syntax
Set-Team -GroupId <String> [-DisplayName <String>] [-Description <String>] [-MailNickName <String>]
[-Classification <String>] [-Visibility <String>] [-AllowGiphy <Boolean>] [-GiphyContentRating <String>]
[-AllowStickersAndMemes <Boolean>] [-AllowCustomMemes <Boolean>] [-AllowGuestCreateUpdateChannels <Boolean>]
[-AllowGuestDeleteChannels <Boolean>] [-AllowCreateUpdateChannels <Boolean>] [-AllowDeleteChannels <Boolean>]
[-AllowAddRemoveApps <Boolean>] [-AllowCreateUpdateRemoveTabs <Boolean>]
[-AllowCreateUpdateRemoveConnectors <Boolean>] [-AllowUserEditMessages <Boolean>]
[-AllowUserDeleteMessages <Boolean>] [-AllowOwnerDeleteMessages <Boolean>] [-AllowTeamMentions <Boolean>]
[-AllowChannelMentions <Boolean>] [-ShowInTeamsSearchAndSuggestions <Boolean>] [<CommonParameters>]

Description
This cmdlet allows you to update properties of a team, including its displayname, description, and team-specific
settings. This cmdlet includes all settings that used to be set using the Set-TeamFunSettings, Set-
TeamGuestSettings, etc. cmdlets

Examples
Example 1

Set-Team -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf -DisplayName "Updated TeamName" -Visibility Public

Parameters
-AllowAddRemoveApps
Boolean value that determines whether or not members (not only owners) are allowed to add apps to the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowChannelMentions
Boolean value that determines whether or not channels in the team can be @ mentioned so that all users who
follow the channel are notified.
Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateChannels
Setting that determines whether or not members (and not just owners) are allowed to create channels.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateRemoveConnectors
Setting that determines whether or not members (and not only owners) can manage connectors in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateRemoveTabs
Setting that determines whether or not members (and not only owners) can manage tabs in channels.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCustomMemes
Setting that determines whether or not members can use the custom memes functionality in teams.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowDeleteChannels
Setting that determines whether or not members (and not only owners) can delete channels in the team.
Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGiphy
Setting that determines whether or not giphy can be used in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGuestCreateUpdateChannels
Setting that determines whether or not guests can create channels in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGuestDeleteChannels
Setting that determines whether or not guests can delete in the team.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowOwnerDeleteMessages
Setting that determines whether or not owners can delete messages that they or other members of the team have
posted.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowStickersAndMemes
Setting that determines whether stickers and memes usage is allowed in the team.
Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowTeamMentions
Setting that determines whether the entire team can be @ mentioned (which means that all users will be notified)

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowUserDeleteMessages
Setting that determines whether or not members can delete messages that they have posted.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowUserEditMessages
Setting that determines whether or not users can edit messages that they have posted.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Classification
This parameter is reserved for internal Microsoft use.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Description
Team description. Team Description Characters Limit - 1024.
Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-DisplayName
Team display name. Team Name Characters Limit - 256.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GiphyContentRating
Setting that determines the level of sensitivity of giphy usage that is allowed in the team. Accepted values are
"Strict" or "Moderate"

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-MailNickName
The MailNickName parameter specifies the alias for the associated Office 365 Group. This value will be used for
the mail enabled object and will be used as PrimarySmtpAddress for this Office 365 Group. The value of the
MailNickName parameter has to be unique across your tenant.

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ShowInTeamsSearchAndSuggestions
Setting that determines whether or not private teams should be searchable from Teams clients for users who do
not belong to that team. Set to $false to make those teams not discoverable from Teams clients.

Type: Boolean
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Visibility
Team visibility. Valid values are "Private" and "Public"

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Related Links
Get-Team

N ew-Team
minutes to read • Edit Online

Set-TeamChannel
In ths Article

Update Team channels settings.

Syntax
Set-TeamChannel -GroupId <String> -CurrentDisplayName <String> [-NewDisplayName <String>]
[-Description <String>] [<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

Set-TeamChannel -GroupId c58566a6-4bb4-4221-98d4-47677dbdbef6 -CurrentDisplayName TechReads -NewDisplayName


"Technical Reads"

Parameters
-CurrentDisplayName
Current channel name

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Description
Updated Channel description. Channel Description Characters Limit - 1024.
Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-NewDisplayName
New Channel display name. Names must be 50 characters or less, and can't contain the characters # % & * { } / \ : <
>?
|'"

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
minutes to read • Edit Online

Set-TeamFunSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To set a
Team's settings, run Set-Team. Update Giphy, Stickers and Memes settings.

Syntax
Set-TeamFunSettings -GroupId <String> [-AllowGiphy <String>] [-GiphyContentRating <String>]
[-AllowStickersAndMemes <String>] [-AllowCustomMemes <String>]

Examples
-------------------------- Example 1 --------------------------

Set-TeamFunSettings -GroupId 0ebb500c-f5f3-44dd-b155-cc8c4f383e2d -AllowGiphy true -GiphyContentRating Strict

Parameters
-AllowCustomMemes
Allow custom memes to be uploaded

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowGiphy
Setting to enable giphy for team

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowStickersAndMemes
Enable Stickers and memes
Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GiphyContentRating
Settings to set content rating for giphy. Can be "Strict" or "Moderate"

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId, AllowGiphy, GiphyContentRating, AllowStickersAndMemes, AllowCustomMemes
minutes to read • Edit Online

Set-TeamGuestSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To set a
Team's settings, run Set-Team. Updates team guest settings.

Syntax
Set-TeamGuestSettings -GroupId <String> [-AllowCreateUpdateChannels <String>] [-AllowDeleteChannels <String>]

Examples
-------------------------- Example 1 --------------------------

Set-TeamGuestSettings -GroupId a61f5a96-a0cf-43db-a7c8-cec05f8a8fc4 -AllowCreateUpdateChannels true

Parameters
-AllowCreateUpdateChannels
Settings to create and update channels

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowDeleteChannels
Settings to Delete channels

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
GroupId of the team
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId

Inputs
AllowCreateUpdateChannels

Inputs
AllowDeleteChannels
minutes to read • Edit Online

Set-TeamMemberSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To set a
Team's settings, run Set-Team. Updates team member settings.

Syntax
Set-TeamMemberSettings -GroupId <String> [-AllowCreateUpdateChannels <String>] [-AllowDeleteChannels <String>]
[-AllowAddRemoveApps <String>] [-AllowCreateUpdateRemoveTabs <String>]
[-AllowCreateUpdateRemoveConnectors <String>]

Examples
-------------------------- Example 1 --------------------------

Set-TeamMemberSettings -GroupId 4ba546e6-e28d-4645-8cc1-d3575ef9d266 -AllowCreateUpdateChannels false

-------------------------- Example 2 --------------------------

Set-TeamMemberSettings -GroupId 4ba546e6-e28d-4645-8cc1-d3575ef9d266 -AllowDeleteChannels true -


AllowAddRemoveApps false

Parameters
-AllowAddRemoveApps
Setting to add and remove apps to teams

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateChannels
Setting to create and update channels

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-AllowCreateUpdateRemoveConnectors
Setting to create, update and remove connectors

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowCreateUpdateRemoveTabs
Setting to create, update and remove tabs

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowDeleteChannels
Setting to Delete channels

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId

Inputs
AllowCreateUpdateChannels

Inputs
AllowDeleteChannels
Inputs
AllowAddRemoveApps

Inputs
AllowCreateUpdateRemoveTabs

Inputs
AllowCreateUpdateRemoveConnectors
minutes to read • Edit Online

Set-TeamMessagingSettings
In ths Article

Note: This cmdlet is deprecated as of our 1.0 PowerShell release, and is not supported in our 1.0 release. To set a
Team's settings, run Set-Team. Updates team messaging settings.

Syntax
Set-TeamMessagingSettings -GroupId <String> [-AllowUserEditMessages <String>]
[-AllowUserDeleteMessages <String>] [-AllowOwnerDeleteMessages <String>] [-AllowTeamMentions <String>]
[-AllowChannelMentions <String>]

Examples
-------------------------- Example 1 --------------------------

Set-TeamMessagingSettings -GroupId 4ba546e6-e28d-4645-8cc1-d3575ef9d266 -AllowUserEditMessages true

-------------------------- Example 2 --------------------------

Set-TeamMessagingSettings -GroupId 4ba546e6-e28d-4645-8cc1-d3575ef9d266 -AllowUserDeleteMessages false -


AllowChannelMentions true

Parameters
-AllowChannelMentions
Allow @channel or @[channel name] mentions. This wil notify members who've favorited that channel

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowOwnerDeleteMessages
Setting to allow owner to Delete messages

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-AllowTeamMentions
Allow @team or @[team name] mentions. This will notify everyone in the team

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowUserDeleteMessages
Setting to allow user to delete messages

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-AllowUserEditMessages
Setting to allow user to edit messages

Type: String
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

Inputs
GroupId

Inputs
AllowUserEditMessages

Inputs
AllowUserDeleteMessages
Inputs
AllowOwnerDeleteMessages

Inputs
AllowTeamMentions

Inputs
AllowChannelMentions
minutes to read • Edit Online

Set-TeamPicture
In ths Article

Update the team picture. Note: the command will return immediately, but the Teams application will not reflect the
update immediately. The Teams application may need to be open for up to an hour before changes are reflected.
Note: this cmdlet is not support in special government environments (TeamsGCCH and TeamsDoD ) and is
currently only supported in our beta release.

Syntax
Set-TeamPicture -GroupId <String> -ImagePath <String> [<CommonParameters>]

Description
IMPORTANT
Modules in the PS INT gallery for Microsoft Teams run on the /beta version in Microsoft Graph and are subject to change. Int
modules can be install from here https://www.poshtestgallery.com/packages/MicrosoftTeams.

Examples
Example 1

Set-TeamPicture -GroupId 2f162b0e-36d2-4e15-8ba3-ba229cecdccf -ImagePath c:\Image\TeamPictire.png

Parameters
-GroupId
GroupId of the team

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-ImagePath
File path and image ( .png, .gif, .jpg, or .jpeg)
Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
minutes to read • Edit Online

Set-TeamsApp
In ths Article

Updates an app in the Teams tenant app store.

Syntax
Set-TeamsApp -Id <String> -Path <String> [<CommonParameters>]

Description
Use a Teams app manifest zip file to upload an app to the tenant app store.

Examples
Example 1

PS C:\> Set-TeamsApp -Id b9cc7986-dd56-4b57-ab7d-9c4e5288b775 -Path c:\Path\SampleApp.zip

Parameters
-Id
The app's ID generated by Teams (different from the external ID )

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Path
The local path of the app manifest zip file, for use in New and Set

Type: String
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

Inputs
None
Outputs
System.Object

You might also like