Commands › Exchange Online
New-ReportSubmissionRule
Create the report submission rule in your cloud-based organization. The report submission rule identifies the reporting mailbox where user reported messages are delivered. **Note**: If the rule already exists (the Get-ReportSubmissionRule cmdlet returns output), you can't use this cmdlet. To delete the existing rule and start over, use the Remove-ReportSubmissionRule cmdlet first.
Quick start script
# New-ReportSubmissionRule — 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-ReportSubmissionRule
$before | Format-List
# 3. Make the change (dry run first)
New-ReportSubmissionRule -Name <String> -ReportSubmissionPolicy <ReportSubmissionPolicyIdParameter> -WhatIf
New-ReportSubmissionRule -Name <String> -ReportSubmissionPolicy <ReportSubmissionPolicyIdParameter>
# 4. Verify and diff
$after = Get-ReportSubmissionRule
Compare-Object ($before | Out-String) ($after | Out-String)
Syntax
New-ReportSubmissionRule [-Name] <String> -ReportSubmissionPolicy <ReportSubmissionPolicyIdParameter>
[-Comments <String>]
[-Confirm]
[-Enabled <Boolean>]
[-SentTo <RecipientIdParameter[]>]
[-WhatIf]
[<CommonParameters>]
Parameters (7)
Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.