< Back

Add-TeamUser

Sat Jan 18, 2020 4:16 pm

NAME Add-TeamUser



SYNOPSIS

The `Add-TeamUser` adds an owner or member to the team, and to the unified group which backs the team.





SYNTAX

Add-TeamUser -GroupId <String> -User <String> [-Role <String>] [<CommonParameters>]





DESCRIPTION

This cmdlet adds an owner or member to the team, and to the unified group which backs the team.



> [!Note] > The command will return immediately, but the Teams application will not reflect the update

immediately. The Teams application may need to be open for up to an hour before changes are reflected.



It doesn't work in the same way that the Teams application. If you add an owner in the application the user is

also added as member to the unified group. Using this cmdlet, it will add the user only as an owner to the unified

group, not as a member. Then you can run the cmdlet again to add the user as member.





PARAMETERS

-GroupId <String>

GroupId of the team.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-User <String>

User's UPN (user principal name - e.g. johndoe@example.com).



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-Role <String>

Member or Owner.



Required? false

Position? named

Default value Member

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

GroupId, User, Role







OUTPUTS



NOTES









-------------------------- Example 1 --------------------------



Add-TeamUser -GroupId 31f1ff6c-d48c-4f8a-b2e1-abca7fd399df -User dmx@example.com



This example adds the user "dmx@example.com" to a group with the id "31f1ff6c-d48c-4f8a-b2e1-abca7fd399df".



RELATED LINKS