Commands › Exchange Online

New-ManagementScope

Exchange Online ExchangeOnlineManagement New-*

Create a regular or exclusive management scope.

Quick start script

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

# 3. Make the change (dry run first)
New-ManagementScope -Name <String> -DatabaseList <DatabaseIdParameter[]> -DatabaseRestrictionFilter <String> -WhatIf
New-ManagementScope -Name <String> -DatabaseList <DatabaseIdParameter[]> -DatabaseRestrictionFilter <String>

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

Syntax — 5 parameter sets

DatabaseList

New-ManagementScope [-Name] <String> -DatabaseList <DatabaseIdParameter[]>
 [-Confirm]
 [-DomainController <Fqdn>]
 [-Exclusive]
 [-Force]
 [-WhatIf]
 [<CommonParameters>]

DatabaseFilter

New-ManagementScope [-Name] <String> -DatabaseRestrictionFilter <String>
 [-Confirm]
 [-DomainController <Fqdn>]
 [-Exclusive]
 [-Force]
 [-WhatIf]
 [<CommonParameters>]

RecipientFilter

New-ManagementScope [-Name] <String> -RecipientRestrictionFilter <String>
 [-Confirm]
 [-DomainController <Fqdn>]
 [-Exclusive]
 [-Force]
 [-RecipientRoot <OrganizationalUnitIdParameter>]
 [-WhatIf]
 [<CommonParameters>]

ServerList

New-ManagementScope [-Name] <String> -ServerList <ServerIdParameter[]>
 [-Confirm]
 [-DomainController <Fqdn>]
 [-Exclusive]
 [-Force]
 [-WhatIf]
 [<CommonParameters>]

1 more parameter sets — see the parameter table below.

Parameters (12)

ParameterTypeRequiredWhat it controls
-Name String yes The Name parameter specifies the name of the management scope. The name can be up to 64 characters. If the name contains spaces, enclose the name in quotation marks (").
-DatabaseList DatabaseIdParameter[] yes This parameter is available only in on-premises Exchange.
-DatabaseRestrictionFilter String yes This parameter is available only in on-premises Exchange.
-RecipientRestrictionFilter String yes The RecipientRestrictionFilter parameter uses OPATH filter syntax to specify the recipients that are included in the scope. The syntax is `"Property -ComparisonOperator 'Value'"`.
-ServerList ServerIdParameter[] yes This parameter is available only in on-premises Exchange.
-ServerRestrictionFilter String yes This parameter is available only in on-premises Exchange.
-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.
-DomainController Fqdn This parameter is available only in on-premises Exchange.
-Exclusive SwitchParameter The Exclusive switch specifies that the role should be an exclusive scope. You don't need to specify a value with this switch.
-Force SwitchParameter The Force switch hides warning or confirmation messages. You don't need to specify a value with this switch.
-RecipientRoot OrganizationalUnitIdParameter The RecipientRoot parameter specifies the organizational unit (OU) under which the filter specified with the RecipientRestrictionFilter parameter should be applied. Valid input for this parameter is an OU or domain...
-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.