API Reference
Command
Export-ADXMigrationReport
Exports an AD migration execution report to JSON.
Examples
Example 1: Preview a migration and export the execution report.
$result = $plan | Invoke-ADXMigrationPlan
$result | Export-ADXMigrationReport -Path '.\CAB-1234.preview.adxmigration-report.json' -Force
Get-Content '.\CAB-1234.preview.adxmigration-report.json' -Raw | ConvertFrom-Json | Select-Object -ExpandProperty summary
Example 2: Review what still remains after execution.
$reportPath = '.\CAB-1234.apply.adxmigration-report.json'
$result | Export-ADXMigrationReport -Path $reportPath -Force
$report = Get-Content $reportPath -Raw | ConvertFrom-Json
$report.outstandingActions | Format-Table kind, severity, phaseKind, target, message -AutoSize
Example 3: Review rollback instructions for phases that changed state.
$reportPath = '.\CAB-1234.apply.adxmigration-report.json'
$result | Export-ADXMigrationReport -Path $reportPath -Force
$report = Get-Content $reportPath -Raw | ConvertFrom-Json
$report.rollbackActions | Format-Table kind, phaseKind, target, requiresMachineExecutor, instruction -AutoSize
Example 4: Apply a governed migration and export audit evidence.
$result = $plan | Invoke-ADXMigrationPlan -Intent read_write -AllowWrite -Apply -WriteExecutionId mig-2026-001 -WriteActorId pklys -WriteChangeReason CAB-1234 -WriteRollbackPlanId rollback-CAB-1234 -WriteAuditCorrelationId ([guid]::NewGuid().ToString())
$result | Export-ADXMigrationReport -Path '.\CAB-1234.apply.adxmigration-report.json' -Force -PassThru
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
Export-ADXMigrationReport -Path <string> -Result <AdMigrationPlanExecutionResult> [-Force] [-PassThru] [<CommonParameters>]#Parameters
- Path string
- Destination JSON file path.
- Result AdMigrationPlanExecutionResult
- Migration execution result to export.
- Force SwitchParameter
- Overwrites an existing report file.
- PassThru SwitchParameter
- Returns the exported file after writing.
Outputs
System.IO.FileInfo