Skip to main content

teams channel add

Adds a channel to the specified Microsoft Teams team

Usage

m365 teams channel add [options]

Options

-i, --teamId [teamId]

The ID of the team to add the channel to. Specify either teamId or teamName but not both

--teamName [teamName]

The display name of the team to add the channel to. Specify either teamId or teamName but not both

-n, --name <name>

The name of the channel to add

-d, --description [description]

The description of the channel to add

--type [type]

Type of channel to create: standard, private, shared. Default standard.

--owner [owner]

User with this ID or UPN will be added as owner of the channel. This option is required when type is private or shared.

-h, --help [help]

Output usage information. Optionally, specify which section of command's help you want to see. Allowed values are options, examples, remarks, response, full. Default is options.

--query [query]

JMESPath query string. See http://jmespath.org/ for more information and examples.

-o, --output [output]

Output type. json, text, csv, md, none. Default json.

--verbose

Runs command with verbose logging.

--debug

Runs command with debug logging.

Remarks

You can only add a channel to the Microsoft Teams team you are a member of.

Examples

Add channel to the specified Microsoft Teams team with id 6703ac8a-c49b-4fd4-8223-28f0ac3a6402

m365 teams channel add --teamId 6703ac8a-c49b-4fd4-8223-28f0ac3a6402 --name climicrosoft365 --description development

Add channel to the specified Microsoft Teams team with name Team Name

m365 teams channel add --teamName "Team Name" --name climicrosoft365 --description development

Add private channel to the specified Microsoft Teams team with owner UPN

m365 teams channel add --teamName "Team Name" --name climicrosoft365 --type private --owner john.doe@contoso.com

Add shared channel to the specified Microsoft Teams team with owner ID

m365 teams channel add --teamId 6703ac8a-c49b-4fd4-8223-28f0ac3a6402 --name climicrosoft365 --type shared --owner cc693a7d-4833-4911-a89a-f0fe6e49bf69

Response

{
"id": "19:591922f67c4341eeb15e49c791822bfe@thread.tacv2",
"createdDateTime": "2022-11-05T10:02:44.3930065Z",
"displayName": "climicrosoft365",
"description": null,
"isFavoriteByDefault": false,
"email": "",
"webUrl": "https://teams.microsoft.com/l/channel/19%3a591922f67c4341eeb15e49c791822bfe%40thread.tacv2/climicrosoft365?groupId=6703ac8a-c49b-4fd4-8223-28f0ac3a6402&tenantId=446355e4-e7e3-43d5-82f8-d7ad8272d55b",
"membershipType": "standard"
}
CTRL + M