Public/Remove-GCTeam.ps1

<#
.SYNOPSIS
    Deletes a team.

.DESCRIPTION
    Removes the specified team from Genesys Cloud.
    Uses the DELETE /api/v2/teams/{teamId} endpoint.

.PARAMETER TeamId
    The unique identifier of the team to delete.

.EXAMPLE
    Remove-GCTeam -TeamId 'a1b2c3d4-e5f6-7890-abcd-ef1234567890'

.NOTES
    Genesys Cloud API: DELETE /api/v2/teams/{teamId}
#>

function Remove-GCTeam {
    [CmdletBinding()]
    param(
        [Parameter(Mandatory = $true)]
        [string]$TeamId
    )

    $endpoint = "teams/$TeamId"
    return Invoke-GCApiRequest -Endpoint $endpoint -Method DELETE
}