Commands › Microsoft Teams

New-CsTeamTemplate

Microsoft Teams MicrosoftTeams New-*

This cmdlet lets you provision a new team template for use in Microsoft Teams.

Quick start script

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

# 2. Capture the current state first — you cannot roll back what you never recorded
$before = Get-CsTeamTemplate
$before | Format-List

# 3. Make the change (dry run first)
New-CsTeamTemplate -Body <ITeamTemplate> -DisplayName <String> -InputObject <IConfigApiBasedCmdletsIdentity> -WhatIf
New-CsTeamTemplate -Body <ITeamTemplate> -DisplayName <String> -InputObject <IConfigApiBasedCmdletsIdentity>

# 4. Verify and diff
$after = Get-CsTeamTemplate
Compare-Object ($before | Out-String) ($after | Out-String)

Syntax — 4 parameter sets

NewExpanded (Default)

New-CsTeamTemplate -Locale <String> -DisplayName <String> -ShortDescription <String>
 [-App <ITeamsAppTemplate[]>] [-Category <String[]>] [-Channel <IChannelTemplate[]>]
 [-Classification <String>] [-Description <String>] [-DiscoverySetting <ITeamDiscoverySettings>]
 [-FunSetting <ITeamFunSettings>] [-GuestSetting <ITeamGuestSettings>] [-Icon <String>]
 [-IsMembershipLimitedToOwner] [-MemberSetting <ITeamMemberSettings>]
 [-MessagingSetting <ITeamMessagingSettings>] [-OwnerUserObjectId <String>] [-PublishedBy <String>]
 [-Specialization <String>] [-TemplateId <String>] [-Uri <String>] [-Visibility <String>] [-Break]
 [-HttpPipelineAppend <SendAsyncStep[]>] [-HttpPipelinePrepend <SendAsyncStep[]>] [-Proxy <Uri>]
 [-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [-WhatIf] [-Confirm] [<CommonParameters>]

New

New-CsTeamTemplate -Locale <String> -Body <ITeamTemplate> [-Break]
 [-HttpPipelineAppend <SendAsyncStep[]>] [-HttpPipelinePrepend <SendAsyncStep[]>] [-Proxy <Uri>]
 [-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [-WhatIf] [-Confirm] [<CommonParameters>]

NewViaIdentity

New-CsTeamTemplate -InputObject <IConfigApiBasedCmdletsIdentity> -Body <ITeamTemplate> [-Break]
 [-HttpPipelineAppend <SendAsyncStep[]>] [-HttpPipelinePrepend <SendAsyncStep[]>] [-Proxy <Uri>]
 [-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [-WhatIf] [-Confirm] [<CommonParameters>]

NewViaIdentityExpanded

New-CsTeamTemplate -InputObject <IConfigApiBasedCmdletsIdentity> -DisplayName <String>
 -ShortDescription <String> [-App <ITeamsAppTemplate[]>] [-Category <String[]>]
 [-Channel <IChannelTemplate[]>] [-Classification <String>] [-Description <String>]
 [-DiscoverySetting <ITeamDiscoverySettings>] [-FunSetting <ITeamFunSettings>]
 [-GuestSetting <ITeamGuestSettings>] [-Icon <String>] [-IsMembershipLimitedToOwner]
 [-MemberSetting <ITeamMemberSettings>] [-MessagingSetting <ITeamMessagingSettings>]
 [-OwnerUserObjectId <String>] [-PublishedBy <String>] [-Specialization <String>] [-TemplateId <String>]
 [-Uri <String>] [-Visibility <String>] [-Break]
 [-HttpPipelineAppend <SendAsyncStep[]>] [-HttpPipelinePrepend <SendAsyncStep[]>] [-Proxy <Uri>]
 [-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [-WhatIf] [-Confirm] [<CommonParameters>]

Parameters (31)

ParameterTypeRequiredWhat it controls
-App ITeamsAppTemplate[] Gets or sets the set of applications that should be installed in teams created based on the template.The app catalog is the main directory for information about each app; this set is intended only as a reference. To...
-Body ITeamTemplate yes The client input for a request to create a template. Only admins from Config Api can perform this request. To construct, see NOTES section for BODY properties and create a hash table.
-Break SwitchParameter Wait for .NET debugger to attach
-Category String[] Gets or sets list of categories.
-Channel IChannelTemplate[] Gets or sets the set of channel templates included in the team template. To construct, see NOTES section for CHANNEL properties and create a hash table.
-Classification String Gets or sets the team's classification.Tenant admins configure Microsoft Entra ID with the set of possible values.
-Confirm SwitchParameter Prompts you for confirmation before running the cmdlet.
-Description String Gets or sets the team's Description.
-DiscoverySetting ITeamDiscoverySettings Governs discoverability of a team. To construct, see NOTES section for DISCOVERYSETTING properties and create a hash table.
-DisplayName String yes Gets or sets the team's DisplayName.
-FunSetting ITeamFunSettings Governs use of fun media like giphy and stickers in the team. To construct, see NOTES section for FUNSETTING properties and create a hash table.
-GuestSetting ITeamGuestSettings Guest role settings for the team. To construct, see NOTES section for GUESTSETTING properties and create a hash table.
-HttpPipelineAppend SendAsyncStep[] SendAsync Pipeline Steps to be appended to the front of the pipeline
-HttpPipelinePrepend SendAsyncStep[] SendAsync Pipeline Steps to be prepended to the front of the pipeline
-Icon String Gets or sets template icon.
-InputObject IConfigApiBasedCmdletsIdentity yes Identity Parameter To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
-IsMembershipLimitedToOwner SwitchParameter Gets or sets whether to limit the membership of the team to owners in the Microsoft Entra group until an owner "activates" the team.
-Locale String yes {{ Fill Locale Description }}
-MemberSetting ITeamMemberSettings Member role settings for the team. To construct, see NOTES section for MEMBERSETTING properties and create a hash table.
-MessagingSetting ITeamMessagingSettings Governs use of messaging features within the teamThese are settings the team owner should be able to modify from UI after team creation. To construct, see NOTES section for MESSAGINGSETTING properties and create a hash table.
-OwnerUserObjectId String Gets or sets the Microsoft Entra user object id of the user who should be set as the owner of the new team.Only to be used when an application or administrative user is making the request on behalf of the specified user.
-Proxy Uri The URI for the proxy server to use
-ProxyCredential PSCredential Credentials for a proxy server to use for the remote call
-ProxyUseDefaultCredentials SwitchParameter Use the default credentials for the proxy
-PublishedBy String Gets or sets published name.
-ShortDescription String yes Gets or sets template short description.
-Specialization String The specialization or use case describing the team.Used for telemetry/BI, part of the team context exposed to app developers, and for legacy implementations of differentiated features for education.
-TemplateId String Gets or sets the id of the base template for the team.Either a Microsoft base template or a custom template.
-Uri String Gets or sets uri to be used for GetTemplate api call.
-Visibility String Used to control the scope of users who can view a group/team and its members, and ability to join.
-WhatIf SwitchParameter Shows what would happen if the cmdlet runs. The cmdlet is not run.

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