Class Permission
A permission for a file.
Inheritance
Implements
Inherited Members
Namespace: Google.Apis.Drive.v2.Data
Assembly: Google.Apis.Drive.v2.dll
Syntax
public class Permission : IDirectResponseSchema
Properties
AdditionalRoles
Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
Declaration
[JsonProperty("additionalRoles")]
public virtual IList<string> AdditionalRoles { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IList<T><string> |
AuthKey
Deprecated.
Declaration
[JsonProperty("authKey")]
public virtual string AuthKey { get; set; }
Property Value
Type | Description |
---|---|
string |
Deleted
Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
Declaration
[JsonProperty("deleted")]
public virtual bool? Deleted { get; set; }
Property Value
Type | Description |
---|---|
bool? |
Domain
The domain name of the entity this permission refers to. This is an output-only field which is present when the permission type is user, group or domain.
Declaration
[JsonProperty("domain")]
public virtual string Domain { get; set; }
Property Value
Type | Description |
---|---|
string |
EmailAddress
The email address of the user or group this permission refers to. This is an output-only field which is present when the permission type is user or group.
Declaration
[JsonProperty("emailAddress")]
public virtual string EmailAddress { get; set; }
Property Value
Type | Description |
---|---|
string |
ETag
The ETag of the permission.
Declaration
[JsonProperty("etag")]
public virtual string ETag { get; set; }
Property Value
Type | Description |
---|---|
string |
ExpirationDate
System.DateTime representation of ExpirationDateRaw.
Declaration
[JsonIgnore]
public virtual DateTime? ExpirationDate { get; set; }
Property Value
Type | Description |
---|---|
DateTime? |
ExpirationDateRaw
The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions: - They cannot be set on shared drive items - They can only be set on user and group permissions - The date must be in the future - The date cannot be more than a year in the future
Declaration
[JsonProperty("expirationDate")]
public virtual string ExpirationDateRaw { get; set; }
Property Value
Type | Description |
---|---|
string |
Id
The ID of the user this permission refers to, and identical to the permissionId in the About and Files resources. When making a drive.permissions.insert request, exactly one of the id or value fields must be specified unless the permission type is anyone, in which case both id and value are ignored.
Declaration
[JsonProperty("id")]
public virtual string Id { get; set; }
Property Value
Type | Description |
---|---|
string |
Kind
This is always drive#permission.
Declaration
[JsonProperty("kind")]
public virtual string Kind { get; set; }
Property Value
Type | Description |
---|---|
string |
Name
The name for this permission.
Declaration
[JsonProperty("name")]
public virtual string Name { get; set; }
Property Value
Type | Description |
---|---|
string |
PendingOwner
Whether the account associated with this permission is a pending owner. Only populated for user type permissions for files that are not in a shared drive.
Declaration
[JsonProperty("pendingOwner")]
public virtual bool? PendingOwner { get; set; }
Property Value
Type | Description |
---|---|
bool? |
PermissionDetails
Details of whether the permissions on this shared drive item are inherited or directly on this item. This is an output-only field which is present only for shared drive items.
Declaration
[JsonProperty("permissionDetails")]
public virtual IList<Permission.PermissionDetailsData> PermissionDetails { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IList<T><Permission.PermissionDetailsData> |
PhotoLink
A link to the profile photo, if available.
Declaration
[JsonProperty("photoLink")]
public virtual string PhotoLink { get; set; }
Property Value
Type | Description |
---|---|
string |
Role
The primary role for this user. While new values may be supported in the future, the following are currently allowed: - owner - organizer - fileOrganizer - writer - reader
Declaration
[JsonProperty("role")]
public virtual string Role { get; set; }
Property Value
Type | Description |
---|---|
string |
SelfLink
A link back to this permission.
Declaration
[JsonProperty("selfLink")]
public virtual string SelfLink { get; set; }
Property Value
Type | Description |
---|---|
string |
TeamDrivePermissionDetails
Deprecated - use permissionDetails instead.
Declaration
[JsonProperty("teamDrivePermissionDetails")]
public virtual IList<Permission.TeamDrivePermissionDetailsData> TeamDrivePermissionDetails { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IList<T><Permission.TeamDrivePermissionDetailsData> |
Type
The account type. Allowed values are: - user - group - domain - anyone
Declaration
[JsonProperty("type")]
public virtual string Type { get; set; }
Property Value
Type | Description |
---|---|
string |
Value
The email address or domain name for the entity. This is used during inserts and is not populated in responses. When making a drive.permissions.insert request, exactly one of the id or value fields must be specified unless the permission type is anyone, in which case both id and value are ignored.
Declaration
[JsonProperty("value")]
public virtual string Value { get; set; }
Property Value
Type | Description |
---|---|
string |
View
Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Declaration
[JsonProperty("view")]
public virtual string View { get; set; }
Property Value
Type | Description |
---|---|
string |
WithLink
Whether the link is required for this permission.
Declaration
[JsonProperty("withLink")]
public virtual bool? WithLink { get; set; }
Property Value
Type | Description |
---|---|
bool? |