Edit

Share via


Add-TeamUser

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

Syntax

Default (Default)

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 change can take between 24 and 48 hours to appear within the Teams client.

Examples

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".

Parameters

-GroupId

GroupId of the team.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-Role

Member or Owner. If Owner is specified then the user is also added as a member to the Team backed by unified group.

Parameter properties

Type:String
Default value:Member
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-User

UPN of a user of the organization (user principal name - e.g. johndoe@example.com).

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

GroupId

User

Role