-
Notifications
You must be signed in to change notification settings - Fork 186
/
ISiteCollectionProperties.cs
459 lines (372 loc) · 15 KB
/
ISiteCollectionProperties.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
using PnP.Core.Model.SharePoint;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
namespace PnP.Core.Admin.Model.SharePoint
{
/// <summary>
/// Properties of a site collection
/// </summary>
public interface ISiteCollectionProperties
{
#region Properties
/// <summary>
/// Indicates whether end users can download non-viewable files (e.g. zip)
/// from browser. By default, this would be set to true if setting ConditionalAccessPolicy to AllowLimitedAccess.
/// This can be set to false to block automatic download of files that can't be vieweed in the browser
/// </summary>
bool AllowDownloadingNonWebViewableFiles { get; set; }
/// <summary>
/// Indicates whether WAC files should be open in Edit mode.
/// By default, this would be set to true if setting ConditionalAccessPolicy to AllowLimitedAccess.
/// This can be set to false to enable view only mode in WAC.
/// </summary>
bool AllowEditing { get; set; }
/// <summary>
/// Flag that indicates is a site supports self-service upgrade
/// </summary>
bool AllowSelfServiceUpgrade { get; set; }
/// <summary>
/// Anonymous link expiration in days
/// </summary>
int AnonymousLinkExpirationInDays { get; set; }
/// <summary>
/// Gets or sets the authentication context strength for this site for all the webs
/// </summary>
[Obsolete("Please use the AuthenticationContextName property")]
string AuthContextStrength { get; set; }
/// <summary>
/// Gets or sets the authentication context for this site for all the webs
/// </summary>
string AuthenticationContextName { get; set; }
/// <summary>
/// Specifies the types of files that can be displayed when the block download links feature is being used
/// </summary>
BlockDownloadLinksFileTypes BlockDownloadLinksFileType { get; set; }
/// <summary>
/// Gets or sets the Block download policy flag
/// </summary>
bool BlockDownloadPolicy { get; set; }
/// <summary>
/// Clears the Restricted access control groups
/// </summary>
bool ClearRestrictedAccessControl { get; set; }
/// <summary>
/// Whether comments on site pages are disabled or not
/// </summary>
bool CommentsOnSitePagesDisabled { get; set; }
/// <summary>
/// The compatibility leve of this site
/// </summary>
int CompatibilityLevel { get; }
/// <summary>
/// Flag that controls access from devices that aren't compliant or joined to a domain to have
/// limited access (web-only, without the Download, Print, and Sync commands)
/// </summary>
SPOConditionalAccessPolicyType ConditionalAccessPolicy { get; set; }
/// <summary>
/// The default link permission for this site
/// </summary>
SharingPermissionType DefaultLinkPermission { get; set; }
/// <summary>
/// The default link to existing access for this site
/// </summary>
bool DefaultLinkToExistingAccess { get; set; }
/// <summary>
/// This is to reset default link to existing access for this site. After resetting, the value will be default (false) or respect the higher level value
/// </summary>
bool DefaultLinkToExistingAccessReset { get; set; }
/// <summary>
/// Default share link role
/// </summary>
Role DefaultShareLinkRole { get; set; }
/// <summary>
/// Default share link scope
/// </summary>
SharingScope DefaultShareLinkScope { get; set; }
/// <summary>
/// The default link type for this site
/// </summary>
SharingLinkType DefaultSharingLinkType { get; set; }
/// <summary>
/// Determines whether the site has AddAndCustomizePages denied
/// </summary>
DenyAddAndCustomizePagesStatus DenyAddAndCustomizePages { get; set; }
/// <summary>
/// Site's description
/// </summary>
string Description { get; }
/// <summary>
/// Indicates whether app views are disabled in all the webs of this site
/// </summary>
AppViewsPolicy DisableAppViews { get; set; }
/// <summary>
/// Indicates whether company wide sharing links are disabled in all the webs of this site
/// </summary>
CompanyWideSharingLinksPolicy DisableCompanyWideSharingLinks { get; set; }
/// <summary>
/// Indicates whether flows are disabled in all the webs of this site
/// </summary>
FlowsPolicy DisableFlows { get; set; }
/// <summary>
/// Gets or sets the exclude site owners flag for Block download policy
/// </summary>
bool ExcludeBlockDownloadPolicySiteOwners { get; set; }
/// <summary>
/// External user expiration in days
/// </summary>
int ExternalUserExpirationInDays { get; set; }
/// <summary>
/// The GroupId of the site
/// </summary>
Guid GroupId { get; }
/// <summary>
/// The login name of the group owner
/// </summary>
string GroupOwnerLoginName { get; }
/// <summary>
/// Flag that indicates a site has Holds
/// </summary>
bool HasHolds { get; }
/// <summary>
/// The HubSiteId of the HubSite this site is associated with
/// </summary>
Guid HubSiteId { get; }
/// <summary>
/// get or Set IBMode (Information Barrier Mode)
/// </summary>
string IBMode { get; set; }
/// <summary>
/// Gets or sets the IB (Information Barrier Mode) segment GUIDs
/// </summary>
Guid[] IBSegments { get; set; }
/// <summary>
/// Gets or sets the IB (Information Barrier Mode) segments to add
/// </summary>
Guid[] IBSegmentsToAdd { get; set; }
/// <summary>
/// Gets or sets the IB (Information Barrier Mode) segments to remove
/// </summary>
Guid[] IBSegmentsToRemove { get; set; }
/// <summary>
/// Whether group owner is site admin
/// </summary>
bool IsGroupOwnerSiteAdmin { get; }
/// <summary>
/// Whether or not this site is a HubSite
/// </summary>
bool IsHubSite { get; }
/// <summary>
/// Gets if the site is connected to a team channel in Microsoft Teams.
/// </summary>
bool IsTeamsChannelConnected { get; }
/// <summary>
/// Gets if the site is connected to a team in Microsoft Teams
/// </summary>
bool IsTeamsConnected { get; }
/// <summary>
/// The last time content was modified on the site
/// </summary>
DateTime LastContentModifiedDate { get; }
/// <summary>
/// The Locale ID of the site
/// </summary>
int Lcid { get; set; }
/// <summary>
/// Specifies what files can be viewed when ConditionalAccessPolicy is set to AllowLimitedAccess
/// </summary>
SPOLimitedAccessFileType LimitedAccessFileType { get; set; }
/// <summary>
/// A description of the lock issue
/// </summary>
string LockIssue { get; }
/// <summary>
/// A string representing the lock state of the site. Valid values are
/// - Unlock: the site is not locked, default state
/// - NoAccess: the site is locked for all access
/// - ReadOnly: the site is set to read only status
/// </summary>
string LockState { get; set; }
/// <summary>
/// Gets or sets the media transcription policy
/// </summary>
MediaTranscriptionPolicyType MediaTranscription { get; set; }
/// <summary>
/// Indicates what the state of the browse user info policy in the site
/// </summary>
SiteUserInfoVisibilityPolicyValue OverrideBlockUserInfoVisibility { get; set; }
/// <summary>
/// This site overrides the tenant anonymous link expiration policy
/// </summary>
bool OverrideTenantAnonymousLinkExpirationPolicy { get; set; }
/// <summary>
/// This site overrides the tenant external user expiration policy
/// </summary>
bool OverrideTenantExternalUserExpirationPolicy { get; set; }
/// <summary>
/// The decoded login name of the site owner
/// </summary>
string Owner { get; set; }
/// <summary>
/// The email address of the site owner
/// </summary>
string OwnerEmail { get; }
/// <summary>
/// The encoded login name of the site owner
/// </summary>
string OwnerLoginName { get; }
/// <summary>
/// The site owner name
/// </summary>
string OwnerName { get; }
/// <summary>
/// Determines whether PWA is enabled for the site
/// </summary>
PWAEnabledStatus PWAEnabled { get; set; }
/// <summary>
/// Gets or sets the Read only access for unmanaged devices policy flag
/// </summary>
bool ReadOnlyForUnmanagedDevices { get; set; }
/// <summary>
/// The GroupId of the group this site is associated with
/// </summary>
Guid RelatedGroupId { get; }
/// <summary>
/// Gets or sets request files link enabled
/// </summary>
bool RequestFilesLinkEnabled { get; set; }
/// <summary>
/// Gets or sets request files link expiration days
/// </summary>
int RequestFilesLinkExpirationInDays { get; set; }
/// <summary>
/// Gets or sets the Restricted access control policy flag based on group membership
/// </summary>
bool RestrictedAccessControl { get; set; }
/// <summary>
/// Gets or sets the Restricted Access Control Groups
/// </summary>
IList<Guid> RestrictedAccessControlGroups { get; set; }
/// <summary>
/// Gets or sets the restricted access control groups to be added
/// </summary>
IList<Guid> RestrictedAccessControlGroupsToAdd { get; set; }
/// <summary>
/// Gets or sets the restricted access control groups to be removed
/// </summary>
IList<Guid> RestrictedAccessControlGroupsToRemove { get; set; }
/// <summary>
/// Determines whether the site is resticted to a specific geo location
/// </summary>
RestrictedToRegion RestrictedToRegion { get; set; }
/// <summary>
/// The Guid of an Information Protection label
/// </summary>
Guid SensitivityLabel { get; set; }
/// <summary>
/// The Guid of an Information Protection label
/// </summary>
string SensitivityLabel2 { get; set; }
/// <summary>
/// Whether update secondary admin during setting primary admin
/// </summary>
bool SetOwnerWithoutUpdatingSecondaryAdmin { get; set; }
/// <summary>
/// A list of allowed domain names for this site
/// </summary>
string SharingAllowedDomainList { get; set; }
/// <summary>
/// A list of blocked domain names for this site
/// </summary>
string SharingBlockedDomainList { get; set; }
/// <summary>
/// Specifies what type of external user and guest link sharing is enabled
/// </summary>
SharingCapabilities SharingCapability { get; set; }
/// <summary>
/// Indicates what this site's domain restriction mode is
/// </summary>
SharingDomainRestrictionModes SharingDomainRestrictionMode { get; set; }
/// <summary>
/// Get whether the sharing lock can be cleared
/// </summary>
bool SharingLockDownCanBeCleared { get; }
/// <summary>
/// Gets the SharingLockDownEnabled setting
/// </summary>
bool SharingLockDownEnabled { get; }
/// <summary>
/// Flag that controls allowing members to search guest users in the directory
/// </summary>
bool ShowPeoplePickerSuggestionsForGuestUsers { get; set; }
/// <summary>
/// Specifies what type of external user and guest link sharing is enabled for the site
/// </summary>
SharingCapabilities SiteDefinedSharingCapability { get; }
/// <summary>
/// Whether social bar on site pages is enabled or not
/// </summary>
bool SocialBarOnSitePagesDisabled { get; set; }
/// <summary>
/// The status of the site, possible values are:
/// - Active: default status for a site
/// - Recycled: the site is the tenant's site collection recyclebin
/// </summary>
string Status { get; }
/// <summary>
/// The Storage Quota
/// </summary>
long StorageMaximumLevel { get; set; }
/// <summary>
/// The storage quota type for the site
/// </summary>
string StorageQuotaType { get; }
/// <summary>
/// The current usage of storage for the site
/// </summary>
long StorageUsage { get; }
/// <summary>
/// The warning level for storage usage
/// </summary>
long StorageWarningLevel { get; set; }
/// <summary>
/// When the site is connected to a team channel in Microsoft Teams, gets the type of channel the site is connected to
/// </summary>
TeamsChannelTypeValue TeamsChannelType { get; }
/// <summary>
/// The site's web template name
/// </summary>
string Template { get; set; }
/// <summary>
/// The TimeZone
/// </summary>
TimeZone TimeZoneId { get; set; }
/// <summary>
/// The site's title
/// </summary>
string Title { get; set; }
/// <summary>
/// The Url of the site
/// </summary>
string Url { get; }
/// <summary>
/// The number of webs in the site
/// </summary>
int WebsCount { get; }
#endregion
#region Methods
/// <summary>
/// Updates the properties of this site collection
/// </summary>
/// <param name="vanityUrlOptions">Optionally specify the custom vanity URI's used by this tenant</param>
/// <returns></returns>
Task UpdateAsync(VanityUrlOptions vanityUrlOptions = null);
/// <summary>
/// Updates the properties of this site collection
/// </summary>
/// <param name="vanityUrlOptions">Optionally specify the custom vanity URI's used by this tenant</param>
/// <returns></returns>
void Update(VanityUrlOptions vanityUrlOptions = null);
#endregion
}
}