1
1
---
2
- external help file : Microsoft.Open.MS.GraphBeta.PowerShell.dll-Help.xml
2
+ external help file : Microsoft.Open.MS.GraphBeta.PowerShell.Custom. dll-Help.xml
3
3
Module Name : AzureADPreview
4
- ms.custom : iamfeature=PowerShell
5
- ms.reviewer : rodejo
6
4
online version :
7
5
schema : 2.0.0
8
6
---
@@ -15,10 +13,10 @@ Creates an Azure AD group.
15
13
## SYNTAX
16
14
17
15
```
18
- New-AzureADMSGroup [-Description <String>] -DisplayName <String> -MailEnabled <Boolean> -MailNickname <String>
19
- -SecurityEnabled <Boolean> [-GroupTypes <System.Collections.Generic.List`1[System. String]>]
20
- [-MembershipRule <String>] [-MembershipRuleProcessingState < String>] [-Visibility <String>]
21
- [<CommonParameters>]
16
+ New-AzureADMSGroup [-LabelId <String>] [-Description <String>] -DisplayName <String>
17
+ [-IsAssignableToRole <Boolean>] -MailEnabled <Boolean> -MailNickname < String> -SecurityEnabled <Boolean>
18
+ [-GroupTypes <System.Collections.Generic.List`1[System. String] >] [-MembershipRule <String>]
19
+ [-MembershipRuleProcessingState <String>] [-Visibility <String>] [ <CommonParameters>]
22
20
```
23
21
24
22
## DESCRIPTION
@@ -30,7 +28,7 @@ For information about creating dynamic groups, see Using attributes to create ad
30
28
31
29
### Example 1: Create a dynamic group
32
30
```
33
- PS C:\> New-AzureADMSGroup -DisplayName "Dynamic Group 01" -Description "Dynamic group created from PS" -MailEnabled $False -MailNickName "group" -SecurityEnabled $True -GroupTypes "DynamicMembership" -MembershipRule "(user.department -contains ""Marketing"")" -MembershipRuleProcessingState "On"
31
+ PS C:\> New-AzureADMSGroup -DisplayName "Dynamic Group 01" -Description "Dynamic group created from PS" -MailEnabled $False -MailNickname "group" -SecurityEnabled $True -GroupTypes "DynamicMembership" -MembershipRule "(user.department -contains ""Marketing"")" -MembershipRuleProcessingState "On"
34
32
35
33
Id : 9126185e-25df-4522-a380-7ab697a7241c
36
34
Description : Dynamic group created from PS
@@ -57,6 +55,36 @@ The processing state is On.
57
55
This means that all users in the directory that qualify the rule are added as members to the group.
58
56
Any users that do not qualify are removed from the group.
59
57
58
+ ### Example 2: Create a group assignable to role
59
+ ```
60
+ PS C:\> New-AzureADMSGroup -DisplayName "HelpDesk admin group" -Description "Group assignable to role" -MailEnabled $False -MailNickname "helpDeskAdminGroup" -SecurityEnabled $True -IsAssignableToRole $True -Visibility "Private"
61
+
62
+ Id : 1026185e-25df-4522-a380-7ab697a7241c
63
+ Description : Group assignable to role
64
+ OnPremisesSyncEnabled :
65
+ DisplayName : HelpDesk admin group
66
+ Mail :
67
+ MailEnabled : False
68
+ IsAssignableToRole : True
69
+ MailNickname : helpDeskAdminGroup
70
+ ProxyAddresses : {}
71
+ SecurityEnabled : True
72
+ GroupTypes : {}
73
+ ```
74
+
75
+ ### Example 3: Create a group with label assignment
76
+ ```
77
+ PS C:\> New-AzureADMSGroup -Description "Group associated with a label" -DisplayName "HelpDesk admin group" -GroupTypes "Unified" -LabelId "00000000-0000-0000-0000-000000000000" -MailEnabled $True -MailNickname "helpDeskAdminGroup" -SecurityEnabled $False
78
+
79
+ Id : 11111111-1111-1111-1111-111111111111
80
+ Description : Group associated with a label
81
+ DisplayName : HelpDesk admin group
82
+ GroupTypes : ["Unified"]
83
+ MailEnabled : True
84
+ MailNickname : helpDeskAdminGroup
85
+ SecurityEnabled : False
86
+ ```
87
+
60
88
## PARAMETERS
61
89
62
90
### -Description
@@ -89,42 +117,59 @@ Accept pipeline input: False
89
117
Accept wildcard characters : False
90
118
` ` `
91
119
92
- ### -MailEnabled
93
- Specifies whether this group is mail enabled.
120
+ ### -GroupTypes
121
+ Specifies that the group is a dynamic group.
122
+ To create a dynamic group, specify a value of DynamicMembership.
94
123
95
- Currently, you cannot create mail enabled groups in Azure AD.
124
+ ` ` ` yaml
125
+ Type : System.Collections.Generic.List`1[System.String]
126
+ Parameter Sets : (All)
127
+ Aliases :
128
+
129
+ Required : False
130
+ Position : Named
131
+ Default value : None
132
+ Accept pipeline input : False
133
+ Accept wildcard characters : False
134
+ ` ` `
135
+
136
+ ### -IsAssignableToRole
137
+ Flag indicates whether group can be assigned to a role.
138
+ This property can only be set at the time of group creation and cannot be modified on an existing group.
96
139
97
140
` ` ` yaml
98
141
Type : Boolean
99
142
Parameter Sets : (All)
100
143
Aliases :
101
144
102
- Required : True
145
+ Required : False
103
146
Position : Named
104
147
Default value : None
105
148
Accept pipeline input : False
106
149
Accept wildcard characters : False
107
150
` ` `
108
151
109
- ### -MailNickname
110
- Specifies a mail nickname for the group.
111
- If MailEnabled is $False you must still specify a mail nickname.
152
+ ### -LabelId
153
+ Specifies a comma separated list of label identifiers to assign to the group.
154
+
155
+ Currently, only one label could be assigned to a group.
112
156
113
157
` ` ` yaml
114
158
Type : String
115
159
Parameter Sets : (All)
116
160
Aliases :
117
161
118
- Required : True
162
+ Required : False
119
163
Position : Named
120
164
Default value : None
121
- Accept pipeline input : False
165
+ Accept pipeline input : True (ByPropertyName, ByValue)
122
166
Accept wildcard characters : False
123
167
` ` `
124
168
125
- ### -SecurityEnabled
126
- Specifies whether the group is security enabled.
127
- For security groups, this value must be $True.
169
+ ### -MailEnabled
170
+ Specifies whether this group is mail enabled.
171
+
172
+ Currently, you cannot create mail enabled groups in Azure AD.
128
173
129
174
` ` ` yaml
130
175
Type : Boolean
@@ -138,16 +183,16 @@ Accept pipeline input: False
138
183
Accept wildcard characters : False
139
184
` ` `
140
185
141
- ### -GroupTypes
142
- Specifies that the group is a dynamic group.
143
- To create a dynamic group, specify a value of DynamicMembership .
186
+ ### -MailNickname
187
+ Specifies a mail nickname for the group.
188
+ If MailEnabled is $False you must still specify a mail nickname .
144
189
145
190
` ` ` yaml
146
- Type : System.Collections.Generic.List`1[System. String]
191
+ Type : String
147
192
Parameter Sets : (All)
148
193
Aliases :
149
194
150
- Required : False
195
+ Required : True
151
196
Position : Named
152
197
Default value : None
153
198
Accept pipeline input : False
@@ -192,8 +237,25 @@ Accept pipeline input: False
192
237
Accept wildcard characters : False
193
238
` ` `
194
239
240
+ ### -SecurityEnabled
241
+ Specifies whether the group is security enabled.
242
+ For security groups, this value must be $True.
243
+
244
+ ` ` ` yaml
245
+ Type : Boolean
246
+ Parameter Sets : (All)
247
+ Aliases :
248
+
249
+ Required : True
250
+ Position : Named
251
+ Default value : None
252
+ Accept pipeline input : False
253
+ Accept wildcard characters : False
254
+ ` ` `
255
+
195
256
### -Visibility
196
- This parameter determines the visibility of the group's content and members list. This parameter can take one of the following values:
257
+ This parameter determines the visibility of the group's content and members list.
258
+ This parameter can take one of the following values:
197
259
198
260
* "Public" - Anyone can view the contents of the group
199
261
* "Private" - Only members can view the content of the group
@@ -225,11 +287,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
225
287
## INPUTS
226
288
227
289
### None
228
-
229
290
## OUTPUTS
230
291
231
292
### System.Object
232
-
233
293
## NOTES
234
294
This cmdlet is currently in Public Preview.
235
295
While a cmdlet is in Public Preview, we may make changes to the cmdlet which could have unexpected effects.
0 commit comments