| | 1 | | // <auto-generated> |
| | 2 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 3 | | // Licensed under the MIT License. See License.txt in the project root for |
| | 4 | | // license information. |
| | 5 | | // |
| | 6 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 7 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 8 | | // regenerated. |
| | 9 | | // </auto-generated> |
| | 10 | |
|
| | 11 | | namespace Microsoft.Azure.Graph.RBAC.Models |
| | 12 | | { |
| | 13 | | using Newtonsoft.Json; |
| | 14 | | using System.Linq; |
| | 15 | |
|
| | 16 | | /// <summary> |
| | 17 | | /// Represents an OAuth 2.0 delegated permission scope. The specified OAuth |
| | 18 | | /// 2.0 delegated permission scopes may be requested by client applications |
| | 19 | | /// (through the requiredResourceAccess collection on the Application |
| | 20 | | /// object) when calling a resource application. The oauth2Permissions |
| | 21 | | /// property of the ServicePrincipal entity and of the Application entity |
| | 22 | | /// is a collection of OAuth2Permission. |
| | 23 | | /// </summary> |
| | 24 | | public partial class OAuth2Permission |
| | 25 | | { |
| | 26 | | /// <summary> |
| | 27 | | /// Initializes a new instance of the OAuth2Permission class. |
| | 28 | | /// </summary> |
| 476 | 29 | | public OAuth2Permission() |
| | 30 | | { |
| | 31 | | CustomInit(); |
| 476 | 32 | | } |
| | 33 | |
|
| | 34 | | /// <summary> |
| | 35 | | /// Initializes a new instance of the OAuth2Permission class. |
| | 36 | | /// </summary> |
| | 37 | | /// <param name="adminConsentDescription">Permission help text that |
| | 38 | | /// appears in the admin consent and app assignment |
| | 39 | | /// experiences.</param> |
| | 40 | | /// <param name="adminConsentDisplayName">Display name for the |
| | 41 | | /// permission that appears in the admin consent and app assignment |
| | 42 | | /// experiences.</param> |
| | 43 | | /// <param name="id">Unique scope permission identifier inside the |
| | 44 | | /// oauth2Permissions collection.</param> |
| | 45 | | /// <param name="isEnabled">When creating or updating a permission, |
| | 46 | | /// this property must be set to true (which is the default). To delete |
| | 47 | | /// a permission, this property must first be set to false. At that |
| | 48 | | /// point, in a subsequent call, the permission may be removed. |
| | 49 | | /// </param> |
| | 50 | | /// <param name="type">Specifies whether this scope permission can be |
| | 51 | | /// consented to by an end user, or whether it is a tenant-wide |
| | 52 | | /// permission that must be consented to by a Company Administrator. |
| | 53 | | /// Possible values are "User" or "Admin".</param> |
| | 54 | | /// <param name="userConsentDescription">Permission help text that |
| | 55 | | /// appears in the end user consent experience.</param> |
| | 56 | | /// <param name="userConsentDisplayName">Display name for the |
| | 57 | | /// permission that appears in the end user consent experience.</param> |
| | 58 | | /// <param name="value">The value of the scope claim that the resource |
| | 59 | | /// application should expect in the OAuth 2.0 access token.</param> |
| 0 | 60 | | public OAuth2Permission(string adminConsentDescription = default(string), string adminConsentDisplayName = defau |
| | 61 | | { |
| 0 | 62 | | AdminConsentDescription = adminConsentDescription; |
| 0 | 63 | | AdminConsentDisplayName = adminConsentDisplayName; |
| 0 | 64 | | Id = id; |
| 0 | 65 | | IsEnabled = isEnabled; |
| 0 | 66 | | Type = type; |
| 0 | 67 | | UserConsentDescription = userConsentDescription; |
| 0 | 68 | | UserConsentDisplayName = userConsentDisplayName; |
| 0 | 69 | | Value = value; |
| | 70 | | CustomInit(); |
| 0 | 71 | | } |
| | 72 | |
|
| | 73 | | /// <summary> |
| | 74 | | /// An initialization method that performs custom operations like setting defaults |
| | 75 | | /// </summary> |
| | 76 | | partial void CustomInit(); |
| | 77 | |
|
| | 78 | | /// <summary> |
| | 79 | | /// Gets or sets permission help text that appears in the admin consent |
| | 80 | | /// and app assignment experiences. |
| | 81 | | /// </summary> |
| | 82 | | [JsonProperty(PropertyName = "adminConsentDescription")] |
| 0 | 83 | | public string AdminConsentDescription { get; set; } |
| | 84 | |
|
| | 85 | | /// <summary> |
| | 86 | | /// Gets or sets display name for the permission that appears in the |
| | 87 | | /// admin consent and app assignment experiences. |
| | 88 | | /// </summary> |
| | 89 | | [JsonProperty(PropertyName = "adminConsentDisplayName")] |
| 0 | 90 | | public string AdminConsentDisplayName { get; set; } |
| | 91 | |
|
| | 92 | | /// <summary> |
| | 93 | | /// Gets or sets unique scope permission identifier inside the |
| | 94 | | /// oauth2Permissions collection. |
| | 95 | | /// </summary> |
| | 96 | | [JsonProperty(PropertyName = "id")] |
| 0 | 97 | | public string Id { get; set; } |
| | 98 | |
|
| | 99 | | /// <summary> |
| | 100 | | /// Gets or sets when creating or updating a permission, this property |
| | 101 | | /// must be set to true (which is the default). To delete a permission, |
| | 102 | | /// this property must first be set to false. At that point, in a |
| | 103 | | /// subsequent call, the permission may be removed. |
| | 104 | | /// </summary> |
| | 105 | | [JsonProperty(PropertyName = "isEnabled")] |
| 0 | 106 | | public bool? IsEnabled { get; set; } |
| | 107 | |
|
| | 108 | | /// <summary> |
| | 109 | | /// Gets or sets specifies whether this scope permission can be |
| | 110 | | /// consented to by an end user, or whether it is a tenant-wide |
| | 111 | | /// permission that must be consented to by a Company Administrator. |
| | 112 | | /// Possible values are "User" or "Admin". |
| | 113 | | /// </summary> |
| | 114 | | [JsonProperty(PropertyName = "type")] |
| 0 | 115 | | public string Type { get; set; } |
| | 116 | |
|
| | 117 | | /// <summary> |
| | 118 | | /// Gets or sets permission help text that appears in the end user |
| | 119 | | /// consent experience. |
| | 120 | | /// </summary> |
| | 121 | | [JsonProperty(PropertyName = "userConsentDescription")] |
| 0 | 122 | | public string UserConsentDescription { get; set; } |
| | 123 | |
|
| | 124 | | /// <summary> |
| | 125 | | /// Gets or sets display name for the permission that appears in the |
| | 126 | | /// end user consent experience. |
| | 127 | | /// </summary> |
| | 128 | | [JsonProperty(PropertyName = "userConsentDisplayName")] |
| 0 | 129 | | public string UserConsentDisplayName { get; set; } |
| | 130 | |
|
| | 131 | | /// <summary> |
| | 132 | | /// Gets or sets the value of the scope claim that the resource |
| | 133 | | /// application should expect in the OAuth 2.0 access token. |
| | 134 | | /// </summary> |
| | 135 | | [JsonProperty(PropertyName = "value")] |
| 0 | 136 | | public string Value { get; set; } |
| | 137 | |
|
| | 138 | | } |
| | 139 | | } |