Public/Remove-GCOutboundContactList.ps1

<#
.SYNOPSIS
    Deletes an outbound contact list from Genesys Cloud.

.DESCRIPTION
    Deletes an outbound contact list by its unique identifier using the Genesys Cloud API.
    API Endpoint: DELETE /api/v2/outbound/contactlists/{contactListId}

.PARAMETER ContactListId
    The unique identifier of the contact list to delete.

.EXAMPLE
    Remove-GCOutboundContactList -ContactListId 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee'
    Deletes the contact list with the specified ID.

.NOTES
    Genesys Cloud API: DELETE /api/v2/outbound/contactlists/{contactListId}
#>

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

    $endpoint = "outbound/contactlists/$ContactListId"
    return Invoke-GCApiRequest -Endpoint $endpoint -Method DELETE
}