CmdID / PowerShell / Cmdlets / Set
Set-CsTeamsExternalAccessConfiguration
From the Microsoft Teams PowerShell reference 5 parameters Its page in the reference
Parameters
-BlockedUsersYou can specify blocked users using a List object that contains either the user email or the MRI from the external user you want to block.-BlockExternalAccessUserAccessDesignates whether BlockedUsers list is taking effect or not.-ForceBypass confirmation-IdentityThe only option is Global-WhatIf, -wiShows what would happen if the cmdlet runs.