Commands › Exchange Online

Remove-VivaModuleFeaturePolicy

Exchange Online ExchangeOnlineManagement Remove-*

2.0 or later. For more information, see About the Exchange Online PowerShell module. Use the Remove-VivaModuleFeaturePolicy cmdlet to delete an access policy for a feature in a Viva module in Viva. Once you delete a policy, the policy is permanently deleted. You can't undo the deletion.

Quick start script

# Remove-VivaModuleFeaturePolicy — 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-VivaModuleFeaturePolicy
$before | Format-List

# 3. Make the change (dry run first)
Remove-VivaModuleFeaturePolicy -FeatureId <String> -ModuleId <String> -PolicyId <String> -WhatIf
Remove-VivaModuleFeaturePolicy -FeatureId <String> -ModuleId <String> -PolicyId <String>

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

Syntax

Remove-VivaModuleFeaturePolicy -FeatureId <String> -ModuleId <String> -PolicyId <String>
 [-Confirm]
 [-ResultSize <Unlimited>]
 [-WhatIf]
 [<CommonParameters>]

Parameters (6)

ParameterTypeRequiredWhat it controls
-FeatureId String yes The FeatureId parameter specifies the feature in the Viva module that you want to remove the policy from.
-ModuleId String yes The ModuleId parameter specifies the Viva module of the feature that you want to remove the policy from.
-PolicyId String yes The PolicyId parameter specifies the policy for the feature in the Viva module that you want to remove.
-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.
-ResultSize Unlimited This parameter is reserved for internal Microsoft use.
-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.