Not bad to have a backup of your machine assignments. And sometimes really nice to be able to get what Machine Catalog, Delivery Group, and if you may have reserved IPs.

asnp Citrix*

$date            = (Get-Date).ToString("yyyyMMdd")
$reportPath      = "c:\scripts\logs"
$reportName      = "$date-vdiassignments-citrix.csv"
$report          = @()

$vdiAssignments  = (Get-BrokerCatalog -MaxRecordCount 250000 | Where-Object SessionSupport -eq "SingleSession" | Select-Object CatalogName).CatalogName

foreach($vdi in $vdiAssignments){

    
    $gatherAssignments = Get-BrokerDesktop -Filter {CatalogName -eq $vdi} | Select-Object -Property MachineName, CatalogName, DesktopGroupName, AssociatedUserNames, IPAddress

    $report += $gatherAssignments    

}

$report | Export-Csv -Path "$reportPath\$reportName" -NoTypeInformation -Append