DSCResources/cTeamsTeam/cTeamsTeam.schema.psm1

configuration cTeamsTeam {
    param (
        [Parameter()]
        [hashtable[]]
        $Items
)

<#
TeamsTeam [String] #ResourceName
{
    DisplayName = [string]
    [AccessTokens = [string[]]]
    [AllowAddRemoveApps = [bool]]
    [AllowChannelMentions = [bool]]
    [AllowCreateUpdateChannels = [bool]]
    [AllowCreateUpdateRemoveConnectors = [bool]]
    [AllowCreateUpdateRemoveTabs = [bool]]
    [AllowCustomMemes = [bool]]
    [AllowDeleteChannels = [bool]]
    [AllowGiphy = [bool]]
    [AllowGuestCreateUpdateChannels = [bool]]
    [AllowGuestDeleteChannels = [bool]]
    [AllowOwnerDeleteMessages = [bool]]
    [AllowStickersAndMemes = [bool]]
    [AllowTeamMentions = [bool]]
    [AllowUserDeleteMessages = [bool]]
    [AllowUserEditMessages = [bool]]
    [ApplicationId = [string]]
    [CertificateThumbprint = [string]]
    [Credential = [PSCredential]]
    [DependsOn = [string[]]]
    [Description = [string]]
    [Ensure = [string]{ Absent | Present }]
    [GiphyContentRating = [string]{ Moderate | Strict }]
    [GroupID = [string]]
    [MailNickName = [string]]
    [ManagedIdentity = [bool]]
    [Owner = [string[]]]
    [PsDscRunAsCredential = [PSCredential]]
    [ShowInTeamsSearchAndSuggestions = [bool]]
    [TenantId = [string]]
    [Visibility = [string]{ HiddenMembership | Private | Public }]
}
 
#>



    Import-DscResource -ModuleName PSDesiredStateConfiguration
    Import-DscResource -ModuleName Microsoft365DSC

    $dscResourceName = 'TeamsTeam'

    $param = $PSBoundParameters
    $param.Remove("InstanceName")

    $dscParameterKeys = 'DisplayName' -split ', '

        foreach ($item in $Items)
        {
            if (-not $item.ContainsKey('Ensure'))
            {
                $item.Ensure = 'Present'
            }
            $keyValues = foreach ($key in $dscParameterKeys)
        {
            $item.$key
        }
        $executionName = $keyValues -join '_'
        $executionName = $executionName -replace "[\s()\\:*-+/{}```"']", '_'
        (Get-DscSplattedResource -ResourceName $dscResourceName -ExecutionName $executionName -Properties $item -NoInvoke).Invoke($item)
    }
}