Create a class team using powershell - template EDU_Class

Xrc2319 26 Reputation points
2021-08-27T16:07:28.297+00:00

Hi!
I want to create new Teams classes for all the classes of my school, using EDU_Class template.
I'm trying to use this powershell script to test:

Connect-MicrosoftTeams 
$group = New-Team -MailNickname "TestTeam1" -displayname "Test - Team1" -Visibility "Public" -Template "EDU_Class"

With Template parameter powershell always displays an error, conflicting with Visibility parameter. When I remove -Template "EDU_Class" from the script, it creates the team successfully. However, the new team is not a class team.

Is it possible to create a class team via powershell?
Thanks!

Microsoft Teams Microsoft Teams for business Other
{count} vote

Accepted answer
  1. Sharon Zhao-MSFT 25,756 Reputation points Microsoft External Staff
    2021-08-30T00:36:20.227+00:00

    @Xrc2319 ,

    Is it possible to create a class team via powershell?

    Yes, you can.

    According to the error message, it seems that the Visibility attribute has conflict with EDU_Class team. You could try to remove Visibility parameter from the command and try a again.

    I read an official document which has a guide for creating a class team in Microsoft Teams. From the steps (see the image as below), it has no place to choose the option of visibility. So, I think that user has no permission to specify such an attribute for class team.
    127333-image.png

    Besides, as we are responsible for Microsoft Teams for Business not Teams for Education, it is hard for us to provide more help for you.

    I find an appropriate place to consult question with support engineer of Teams for Education. Here is the right place. Please note it needs to log in with your Teams education account.


    If the response is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.