Public/Get-GCWfmManagementUnit.ps1

<#
.SYNOPSIS
    Retrieves a single workforce management management unit from Genesys Cloud.

.DESCRIPTION
    Queries the Genesys Cloud API to retrieve a specific management unit by its ID.
    API Endpoint: GET /api/v2/workforcemanagement/managementunits/{managementUnitId}

.PARAMETER ManagementUnitId
    The unique identifier of the management unit to retrieve.

.EXAMPLE
    Get-GCWfmManagementUnit -ManagementUnitId 'abc123-def456'
    Retrieves the management unit with the specified ID.

.NOTES
    Genesys Cloud API: GET /api/v2/workforcemanagement/managementunits/{managementUnitId}
#>

function Get-GCWfmManagementUnit {
    [CmdletBinding()]
    param(
        [Parameter(Mandatory = $true)]
        [string]$ManagementUnitId
    )

    $endpoint = "workforcemanagement/managementunits/$ManagementUnitId"
    return Invoke-GCApiRequest -Endpoint $endpoint -Method GET
}