Commands › Exchange Online

Update-PublicFolderMailbox

Exchange Online ExchangeOnlineManagement Update-*

Update the hierarchy for public folders.

Quick start script

# Update-PublicFolderMailbox — 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-PublicFolderMailbox
$before | Format-List

# 3. Make the change (dry run first)
Update-PublicFolderMailbox -Identity <MailboxIdParameter> -FolderId <PublicFolderIdParameter> -InvokeSynchronizer <SwitchParameter> -WhatIf
Update-PublicFolderMailbox -Identity <MailboxIdParameter> -FolderId <PublicFolderIdParameter> -InvokeSynchronizer <SwitchParameter>

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

Syntax — 2 parameter sets

InvokeSynchronizer

Update-PublicFolderMailbox [-Identity] <MailboxIdParameter>
 [-ForceOnlineSync]
 [-FullSync]
 [-Confirm]
 [-DomainController <Fqdn>]
 [-InvokeSynchronizer]
 [-ReconcileFolders]
 [-SuppressStatus]
 [-WhatIf]
 [<CommonParameters>]

InvokeSingleFolderSynchronizer

Update-PublicFolderMailbox [-Identity] <MailboxIdParameter> -FolderId <PublicFolderIdParameter> -InvokeSynchronizer
 [-CreateAssociatedDumpster]
 [-Confirm]
 [-DomainController <Fqdn>]
 [-WhatIf]
 [<CommonParameters>]

Parameters (11)

ParameterTypeRequiredWhat it controls
-Identity MailboxIdParameter yes The Identity parameter specifies the public folder mailbox that you want to update. You can use any value that uniquely identifies the mailbox. For example:
-FolderId PublicFolderIdParameter yes The FolderId parameter specifies the GUID or name of the public folder that you want to synchronize. You can also include the path using the format \\TopLevelPublicFolder\\PublicFolder.
-InvokeSynchronizer SwitchParameter yes The InvokeSynchronizer switch can only be used on secondary hierarchy public folder mailboxes and triggers hierarchy synchronization from the primary public folder mailbox to the specified secondary public folder...
-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.
-CreateAssociatedDumpster SwitchParameter The CreateAssociatedDumpster switch specifies whether to create the associated dumpster before synchronizing the folder. You don't need to specify a value with this switch.
-DomainController Fqdn This parameter is available only in on-premises Exchange.
-ForceOnlineSync SwitchParameter The ForceOnlineSync switch specifies whether to force the secondary public folder mailbox to synchronize with the primary public folder mailbox. You don't need to specify a value with this switch.
-FullSync SwitchParameter The FullSync switch specifies that you want to perform a full synchronization of the public folder mailbox. You don't need to specify a value with this switch.
-ReconcileFolders SwitchParameter The ReconcileFolders switch specifies whether to look closely for differences in the folder hierarchy between the primary public folder mailbox and the secondary public folder mailbox. Folders that exist in the...
-SuppressStatus SwitchParameter The SuppressStatus switch specifies that the output of this cmdlet is suppressed and that the command runs asynchronously in the background from the Exchange Management Shell. You don't need to specify a value with...
-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.