Public/Get-GCLocation.ps1

<#
.SYNOPSIS
    Retrieves a single location by ID.

.DESCRIPTION
    Returns the details of a specific location from Genesys Cloud.
    Uses the GET /api/v2/locations/{locationId} endpoint.

.PARAMETER LocationId
    The unique identifier of the location to retrieve.

.EXAMPLE
    Get-GCLocation -LocationId 'a1b2c3d4-e5f6-7890-abcd-ef1234567890'

.NOTES
    Genesys Cloud API: GET /api/v2/locations/{locationId}
#>

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

    $endpoint = "locations/$LocationId"
    return Invoke-GCApiRequest -Endpoint $endpoint -Method GET
}