Commands › Exchange Online

New-MessageClassification

Exchange Online ExchangeOnlineManagement New-*

Create a message classification instance in your organization.

Quick start script

# New-MessageClassification — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-ExchangeOnline -CertificateThumbprint $thumb -AppId $appId -Organization $org

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

# 3. Make the change (dry run first)
New-MessageClassification -Name <String> -DisplayName <String> -Locale <CultureInfo> -WhatIf
New-MessageClassification -Name <String> -DisplayName <String> -Locale <CultureInfo>

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

Syntax — 2 parameter sets

Localized

New-MessageClassification [-Name] <String> -DisplayName <String> -Locale <CultureInfo> -SenderDescription <String>
 [-Confirm]
 [-DomainController <Fqdn>]
 [-RecipientDescription <String>]
 [-WhatIf]
 [<CommonParameters>]

Identity

New-MessageClassification [-Name] <String> -DisplayName <String> -SenderDescription <String>
 [-ClassificationID <Guid>]
 [-Confirm]
 [-DisplayPrecedence <ClassificationDisplayPrecedenceLevel>]
 [-DomainController <Fqdn>]
 [-PermissionMenuVisible <Boolean>]
 [-RecipientDescription <String>]
 [-RetainClassificationEnabled <Boolean>]
 [-WhatIf]
 [<CommonParameters>]

Parameters (12)

ParameterTypeRequiredWhat it controls
-Name String yes The Name parameter specifies the unique name for the message classification. The maximum length is 64 characters. If the value contains spaces, enclose the value in quotation marks (").
-DisplayName String yes The DisplayName parameter specifies the title of the message classification that's displayed in Outlook and selected by users. The maximum length is 256 characters. If the value contains spaces, enclose the value in...
-Locale CultureInfo yes This parameter is functional on in on-premises Exchange.
-SenderDescription String yes The SenderDescription parameter specifies the detailed text that's shown to Outlook senders when they select a message classification to apply to a message before they send the message. The maximum length is 1024...
-ClassificationID Guid The ClassificationID parameter specifies the classification ID (GUID) of an existing message classification that you want to import and use in your Exchange organization. Use this parameter if you're configuring...
-Confirm SwitchParameter The Confirm switch specifies whether to show or hide the confirmation prompt. How this switch affects the cmdlet depends on whether the cmdlet requires confirmation before proceeding.
-DisplayPrecedence ClassificationDisplayPrecedenceLevel The DisplayPrecedence parameter specifies the relative precedence of the message classification to other message classifications that might be applied to a specified message. Valid values are:
-DomainController Fqdn This parameter is available only in on-premises Exchange.
-PermissionMenuVisible Boolean The PermissionMenuVisible parameter specifies whether the values that you entered for the DisplayName and RecipientDescription parameters are displayed in Outlook as the user composes a message. Valid values are:
-RecipientDescription String The RecipientDescription parameter specifies the detailed text that's shown to Outlook recipient when they receive a message that has the message classification applied. The maximum length is 1024 characters. If the...
-RetainClassificationEnabled Boolean The RetainClassificationEnabled parameter specifies whether the message classification should persist with the message if the message is forwarded or replied to.
-WhatIf SwitchParameter The WhatIf switch shows what the command does without making any changes. You don't need to specify a value with this switch.

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