Public/Other/Get-KriticalUtcmAzureBillingAccountsRoleDefinition.ps1

<#
.SYNOPSIS
    Kritical.UTCM wrapper over Microsoft365DSC helper Get-M365DSCAzureBillingAccountsRoleDefinition
    (category: Other, module: M365DSCAzureHelper).

.DESCRIPTION
    Thin delegating passthrough — logic stays in Microsoft365DSC upstream;
    Kritical.UTCM provides the friendly namespace + citation registration.

    Install-Module Microsoft365DSC -Scope CurrentUser BEFORE calling.

.NOTES
    Category: Other
    Module: M365DSCAzureHelper
    Params: 2
#>

function Get-KriticalUtcmAzureBillingAccountsRoleDefinition {
    [CmdletBinding()]
    param(
        [Parameter(Mandatory)] [String] $BillingAccountId,
        [String] $RoleDefinitionId
    )

    if (-not (Get-Command -Name 'Get-M365DSCAzureBillingAccountsRoleDefinition' -ErrorAction SilentlyContinue)) {
        throw '[KriticalUtcm] Get-M365DSCAzureBillingAccountsRoleDefinition not available — Install-Module Microsoft365DSC -Scope CurrentUser then re-run'
    }
    try {
        & 'Get-M365DSCAzureBillingAccountsRoleDefinition' @PSBoundParameters
    } catch {
        Write-Error ('[KriticalUtcm/Get-KriticalUtcmAzureBillingAccountsRoleDefinition] ' + 'Get-M365DSCAzureBillingAccountsRoleDefinition' + ' failed: ' + $_.Exception.Message)
        throw
    }
}