Commands › Microsoft Teams

New-CsCustomPolicyPackage

Microsoft Teams MicrosoftTeams New-*

This cmdlet creates a custom policy package.

Quick start script

# New-CsCustomPolicyPackage — 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-CsCustomPolicyPackage
$before | Format-List

# 3. Make the change
New-CsCustomPolicyPackage -Identity <String> -PolicyList <String[]>

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

Syntax

New-CsCustomPolicyPackage -Identity <String> -PolicyList <String[]> [-Description <String>] [<CommonParameters>]

Parameters (3)

ParameterTypeRequiredWhat it controls
-Description String The description of the custom package.
-Identity String yes The name of the custom package.
-PolicyList String[] yes A list of one or more policies to be added in the package. To specify the policy list, follow this format: "\<PolicyType\>, \<PolicyName\>". Delimiters of ' ', '.', ':', '\t' are also acceptable. Supported policy...

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