blob: b78eeef942e3db3bf1c6fb1b2b7b49eac504e2b5 [file] [log] [blame]
John Asmuth614db982014-04-24 15:46:26 -04001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="drive_v2.html">Drive API</a> . <a href="drive_v2.files.html">files</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070078 <code><a href="#close">close()</a></code></p>
79<p class="firstline">Close httplib2 connections.</p>
80<p class="toc_element">
81 <code><a href="#copy">copy(fileId, body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, ocr=None, ocrLanguage=None, pinned=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, visibility=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -070082<p class="firstline">Creates a copy of the specified file. Folders cannot be copied.</p>
John Asmuth614db982014-04-24 15:46:26 -040083<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070084 <code><a href="#delete">delete(fileId, enforceSingleParent=None, supportsAllDrives=None, supportsTeamDrives=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070085<p class="firstline">Permanently deletes a file by ID. Skips the trash. The currently authenticated user must own the file or be an organizer on the parent for shared drive files.</p>
John Asmuth614db982014-04-24 15:46:26 -040086<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070087 <code><a href="#emptyTrash">emptyTrash(enforceSingleParent=None)</a></code></p>
Craig Citro065b5302014-08-14 00:47:23 -070088<p class="firstline">Permanently deletes all of the user's trashed files.</p>
89<p class="toc_element">
Sai Cheemalapatidf613972016-10-21 13:59:49 -070090 <code><a href="#export">export(fileId, mimeType)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070091<p class="firstline">Exports a Google Doc to the requested MIME type and returns the exported content. Please note that the exported content is limited to 10MB.</p>
Sai Cheemalapatidf613972016-10-21 13:59:49 -070092<p class="toc_element">
93 <code><a href="#export_media">export_media(fileId, mimeType)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070094<p class="firstline">Exports a Google Doc to the requested MIME type and returns the exported content. Please note that the exported content is limited to 10MB.</p>
Sai Cheemalapatidf613972016-10-21 13:59:49 -070095<p class="toc_element">
yoshi-code-botc2cd3262021-05-16 02:16:04 -070096 <code><a href="#generateIds">generateIds(maxResults=None, space=None, type=None)</a></code></p>
Dan O'Mearadd494642020-05-01 07:42:23 -070097<p class="firstline">Generates a set of file IDs which can be provided in insert or copy requests.</p>
Takashi Matsuo06694102015-09-11 13:55:40 -070098<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070099 <code><a href="#get">get(fileId, acknowledgeAbuse=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</a></code></p>
yoshi-code-bot3dd15272021-04-21 15:07:48 -0700100<p class="firstline">Gets a file's metadata or content by ID.</p>
Craig Citroe633be12015-03-02 13:40:36 -0800101<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700102 <code><a href="#get_media">get_media(fileId, acknowledgeAbuse=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</a></code></p>
yoshi-code-bot3dd15272021-04-21 15:07:48 -0700103<p class="firstline">Gets a file's metadata or content by ID.</p>
John Asmuth614db982014-04-24 15:46:26 -0400104<p class="toc_element">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800105 <code><a href="#insert">insert(body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, media_body=None, media_mime_type=None, ocr=None, ocrLanguage=None, pinned=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, useContentAsIndexableText=None, visibility=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -0400106<p class="firstline">Insert a new file.</p>
107<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700108 <code><a href="#list">list(corpora=None, corpus=None, driveId=None, includeItemsFromAllDrives=None, includePermissionsForView=None, includeTeamDriveItems=None, maxResults=None, orderBy=None, pageToken=None, projection=None, q=None, spaces=None, supportsAllDrives=None, supportsTeamDrives=None, teamDriveId=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -0400109<p class="firstline">Lists the user's files.</p>
110<p class="toc_element">
111 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
112<p class="firstline">Retrieves the next page of results.</p>
113<p class="toc_element">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800114 <code><a href="#patch">patch(fileId, addParents=None, body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, modifiedDateBehavior=None, newRevision=None, ocr=None, ocrLanguage=None, pinned=None, removeParents=None, setModifiedDate=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, updateViewedDate=None, useContentAsIndexableText=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -0400115<p class="firstline">Updates file metadata and/or content. This method supports patch semantics.</p>
116<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700117 <code><a href="#touch">touch(fileId, includePermissionsForView=None, supportsAllDrives=None, supportsTeamDrives=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -0400118<p class="firstline">Set the file's updated time to the current server time.</p>
119<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700120 <code><a href="#trash">trash(fileId, includePermissionsForView=None, supportsAllDrives=None, supportsTeamDrives=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700121<p class="firstline">Moves a file to the trash. The currently authenticated user must own the file or be at least a fileOrganizer on the parent for shared drive files. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.</p>
John Asmuth614db982014-04-24 15:46:26 -0400122<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700123 <code><a href="#untrash">untrash(fileId, includePermissionsForView=None, supportsAllDrives=None, supportsTeamDrives=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700124<p class="firstline">Restores a file from the trash. The currently authenticated user must own the file or be at least a fileOrganizer on the parent for shared drive files. Only the owner may untrash a file.</p>
John Asmuth614db982014-04-24 15:46:26 -0400125<p class="toc_element">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800126 <code><a href="#update">update(fileId, addParents=None, body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, media_body=None, media_mime_type=None, modifiedDateBehavior=None, newRevision=None, ocr=None, ocrLanguage=None, pinned=None, removeParents=None, setModifiedDate=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, updateViewedDate=None, useContentAsIndexableText=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -0400127<p class="firstline">Updates file metadata and/or content.</p>
128<p class="toc_element">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800129 <code><a href="#watch">watch(fileId, acknowledgeAbuse=None, body=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</a></code></p>
Craig Citroe633be12015-03-02 13:40:36 -0800130<p class="firstline">Subscribe to changes on a file</p>
131<p class="toc_element">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800132 <code><a href="#watch_media">watch_media(fileId, acknowledgeAbuse=None, body=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</a></code></p>
John Asmuth614db982014-04-24 15:46:26 -0400133<p class="firstline">Subscribe to changes on a file</p>
134<h3>Method Details</h3>
135<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700136 <code class="details" id="close">close()</code>
137 <pre>Close httplib2 connections.</pre>
138</div>
139
140<div class="method">
141 <code class="details" id="copy">copy(fileId, body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, ocr=None, ocrLanguage=None, pinned=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, visibility=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700142 <pre>Creates a copy of the specified file. Folders cannot be copied.
John Asmuth614db982014-04-24 15:46:26 -0400143
144Args:
145 fileId: string, The ID of the file to copy. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700146 body: object, The request body.
John Asmuth614db982014-04-24 15:46:26 -0400147 The object takes the form of:
148
149{ # The metadata for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700150 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
151 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
152 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
153 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
154 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
155 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700156 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -0700157 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
158 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
159 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
160 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
161 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
162 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
163 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
164 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
165 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
166 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
167 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700168 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700169 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
170 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700171 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
Bu Sun Kim65020912020-05-20 12:08:20 -0700172 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
173 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
174 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
175 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700176 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700177 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
178 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
179 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
180 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
181 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
182 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
183 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
184 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
185 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
186 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
187 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
188 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
John Asmuth614db982014-04-24 15:46:26 -0400189 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700190 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
191 { # A restriction for accessing the content of the file.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700192 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700193 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
194 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
195 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
196 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
197 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
198 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
199 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
200 &quot;picture&quot;: { # The user&#x27;s profile picture.
201 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
202 },
203 },
204 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
205 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
206 },
207 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700208 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
209 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
210 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
211 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
212 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700213 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -0700214 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
215 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
216 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
217 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
218 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700219 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
Bu Sun Kim65020912020-05-20 12:08:20 -0700220 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
John Asmuth614db982014-04-24 15:46:26 -0400221 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700222 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
223 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -0700224 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700225 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -0700226 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
227 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700228 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -0700229 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
230 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
231 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
232 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
233 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
234 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
235 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
236 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
237 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
238 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
239 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
240 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
241 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
242 &quot;height&quot;: 42, # The height of the image in pixels.
243 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
244 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
245 &quot;location&quot;: { # Geographic location information stored in the image.
246 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
247 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
248 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
249 },
250 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
251 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
252 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
253 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
254 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
255 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
256 &quot;width&quot;: 42, # The width of the image in pixels.
257 },
258 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
259 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
260 },
261 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
262 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
263 &quot;labels&quot;: { # A group of labels for the file.
264 &quot;hidden&quot;: True or False, # Deprecated.
265 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
266 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
267 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700268 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700269 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
270 },
271 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
272 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
273 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
274 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
275 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
276 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
277 &quot;picture&quot;: { # The user&#x27;s profile picture.
278 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
279 },
280 },
281 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
282 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
283 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700284 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -0700285 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
286 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
287 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
288 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
289 &quot;a_key&quot;: &quot;A String&quot;,
290 },
291 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
292 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
293 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
294 &quot;A String&quot;,
295 ],
296 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700297 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -0700298 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
299 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
300 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
301 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
302 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
303 &quot;picture&quot;: { # The user&#x27;s profile picture.
304 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -0400305 },
John Asmuth614db982014-04-24 15:46:26 -0400306 },
307 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700308 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
309 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
310 { # A reference to a file&#x27;s parent.
311 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
312 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
313 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
314 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
315 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
John Asmuth614db982014-04-24 15:46:26 -0400316 },
317 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700318 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
319 &quot;A String&quot;,
320 ],
321 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
322 { # A permission for a file.
323 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
324 &quot;A String&quot;,
325 ],
326 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
327 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
328 &quot;domain&quot;: &quot;A String&quot;, # 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.
329 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
330 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
331 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
332 # - They cannot be set on shared drive items
333 # - They can only be set on user and group permissions
334 # - The date must be in the future
335 # - The date cannot be more than a year in the future
336 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
337 &quot;id&quot;: &quot;A String&quot;, # 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.
338 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
339 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
340 &quot;permissionDetails&quot;: [ # 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.
341 {
342 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
343 &quot;A String&quot;,
344 ],
345 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
346 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
347 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
348 # - file
349 # - member
350 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
351 # - organizer
352 # - fileOrganizer
353 # - writer
354 # - reader
355 },
356 ],
357 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
358 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
359 # - owner
360 # - organizer
361 # - fileOrganizer
362 # - writer
363 # - reader
364 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
365 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
366 {
367 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
368 &quot;A String&quot;,
369 ],
370 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
371 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
372 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
373 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
374 },
375 ],
376 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
377 # - user
378 # - group
379 # - domain
380 # - anyone
381 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700382 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -0700383 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -0400384 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700385 ],
386 &quot;properties&quot;: [ # The list of properties.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000387 { # A key-value pair attached to a file that is either public or private to an application.
388 # The following limits apply to file properties:
389 # - Maximum of 100 properties total per file
390 # - Maximum of 30 private properties per app
391 # - Maximum of 30 public properties
392 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
Bu Sun Kim65020912020-05-20 12:08:20 -0700393 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
394 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
395 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
396 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
397 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -0800398 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
John Asmuth614db982014-04-24 15:46:26 -0400399 },
400 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700401 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
402 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
403 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
404 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
405 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
406 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
407 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
408 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
409 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
410 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
411 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
412 &quot;picture&quot;: { # The user&#x27;s profile picture.
413 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
414 },
Takashi Matsuo06694102015-09-11 13:55:40 -0700415 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700416 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
417 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
418 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
419 },
420 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
421 &quot;A String&quot;,
422 ],
423 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
424 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
425 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
426 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
427 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700428 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
Bu Sun Kim65020912020-05-20 12:08:20 -0700429 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
430 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
431 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
432 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
433 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
434 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
435 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
436 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
437 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
438 &quot;picture&quot;: { # The user&#x27;s profile picture.
439 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
440 },
441 },
442 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
443 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
444 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400445 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700446 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
447 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
448 &quot;domain&quot;: &quot;A String&quot;, # 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.
449 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
450 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
451 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -0700452 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400453 # - They can only be set on user and group permissions
454 # - The date must be in the future
455 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700456 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -0700457 &quot;id&quot;: &quot;A String&quot;, # 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.
458 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
459 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
460 &quot;permissionDetails&quot;: [ # 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.
461 {
462 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
463 &quot;A String&quot;,
464 ],
465 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
466 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
467 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
468 # - file
469 # - member
470 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
471 # - organizer
472 # - fileOrganizer
473 # - writer
474 # - reader
475 },
476 ],
477 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
478 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -0400479 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700480 # - organizer
481 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -0400482 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700483 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -0700484 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
485 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
486 {
487 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
488 &quot;A String&quot;,
489 ],
490 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
491 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
492 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
493 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
494 },
495 ],
496 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -0400497 # - user
498 # - group
499 # - domain
500 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -0700501 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700502 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -0700503 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -0400504 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700505 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
506 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
507 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
508 &quot;height&quot;: 42, # The height of the video in pixels.
509 &quot;width&quot;: 42, # The width of the video in pixels.
510 },
511 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
512 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
513 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
John Asmuth614db982014-04-24 15:46:26 -0400514}
515
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700516 convert: boolean, Whether to convert this file to the corresponding Docs Editors format.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800517 enforceSingleParent: boolean, Deprecated. Copying files into multiple folders is no longer supported. Use shortcuts instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700518 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700519 ocr: boolean, Whether to attempt OCR on .jpg, .png, .gif, or .pdf uploads.
Bu Sun Kim65020912020-05-20 12:08:20 -0700520 ocrLanguage: string, If ocr is true, hints at the language to use. Valid values are BCP 47 codes.
521 pinned: boolean, Whether to pin the head revision of the new copy. A file can have a maximum of 200 pinned revisions.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700522 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -0700523 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
524 timedTextLanguage: string, The language of the timed text.
525 timedTextTrackName: string, The timed text track name.
John Asmuth614db982014-04-24 15:46:26 -0400526 visibility: string, The visibility of the new file. This parameter is only relevant when the source is not a native Google Doc and convert=false.
527 Allowed values
Bu Sun Kim65020912020-05-20 12:08:20 -0700528 DEFAULT - The visibility of the new file is determined by the user&#x27;s default visibility/sharing policies.
John Asmuth614db982014-04-24 15:46:26 -0400529 PRIVATE - The new file will be visible to only the owner.
John Asmuth614db982014-04-24 15:46:26 -0400530
531Returns:
532 An object of the form:
533
534 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800535 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
536 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
537 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
538 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
539 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
540 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
541 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
542 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
543 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
544 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
545 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
546 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
547 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
548 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
549 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
550 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
551 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
552 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
553 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
554 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
555 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
556 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
557 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
558 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
559 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
560 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
561 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
562 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
563 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
564 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
565 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
566 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
567 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
568 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
569 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
570 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
571 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
572 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
573 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
574 },
575 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
576 { # A restriction for accessing the content of the file.
577 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
578 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
579 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -0700580 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
581 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
582 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
583 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
584 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
585 &quot;picture&quot;: { # The user&#x27;s profile picture.
586 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -0400587 },
John Asmuth614db982014-04-24 15:46:26 -0400588 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800589 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
590 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
591 },
592 ],
593 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
594 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
595 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
596 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
597 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
598 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
599 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
600 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
601 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
602 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
603 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
604 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
605 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
606 },
607 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
608 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
609 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
610 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
611 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
612 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
613 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
614 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
615 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
616 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
617 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
618 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
619 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
620 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
621 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
622 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
623 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
624 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
625 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
626 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
627 &quot;height&quot;: 42, # The height of the image in pixels.
628 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
629 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
630 &quot;location&quot;: { # Geographic location information stored in the image.
631 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
632 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
633 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
634 },
635 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
636 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
637 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
638 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
639 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
640 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
641 &quot;width&quot;: 42, # The width of the image in pixels.
642 },
643 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
644 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
645 },
646 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
647 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
648 &quot;labels&quot;: { # A group of labels for the file.
649 &quot;hidden&quot;: True or False, # Deprecated.
650 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
651 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
652 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
653 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
654 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
655 },
656 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
657 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
658 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
659 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
660 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
661 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
662 &quot;picture&quot;: { # The user&#x27;s profile picture.
663 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
664 },
665 },
666 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
667 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
668 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
669 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
670 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
671 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
672 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
673 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
674 &quot;a_key&quot;: &quot;A String&quot;,
675 },
676 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
677 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
678 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
679 &quot;A String&quot;,
680 ],
681 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
682 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -0700683 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
684 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
685 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
686 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
687 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
688 &quot;picture&quot;: { # The user&#x27;s profile picture.
689 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
690 },
Takashi Matsuo06694102015-09-11 13:55:40 -0700691 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800692 ],
693 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
694 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
695 { # A reference to a file&#x27;s parent.
696 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
697 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
698 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
699 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
700 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -0700701 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800702 ],
703 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
704 &quot;A String&quot;,
705 ],
706 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
707 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700708 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
709 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400710 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700711 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
712 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
713 &quot;domain&quot;: &quot;A String&quot;, # 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.
714 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
715 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
716 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -0700717 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400718 # - They can only be set on user and group permissions
719 # - The date must be in the future
720 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700721 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -0700722 &quot;id&quot;: &quot;A String&quot;, # 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.
723 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
724 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
725 &quot;permissionDetails&quot;: [ # 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.
726 {
727 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
728 &quot;A String&quot;,
729 ],
730 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
731 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
732 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
733 # - file
734 # - member
735 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
736 # - organizer
737 # - fileOrganizer
738 # - writer
739 # - reader
740 },
741 ],
742 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
743 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -0400744 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700745 # - organizer
746 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -0400747 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700748 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -0700749 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
750 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
751 {
752 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
753 &quot;A String&quot;,
754 ],
755 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
756 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
757 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
758 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
759 },
760 ],
761 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -0400762 # - user
763 # - group
764 # - domain
765 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -0700766 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700767 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -0700768 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -0400769 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800770 ],
771 &quot;properties&quot;: [ # The list of properties.
772 { # A key-value pair attached to a file that is either public or private to an application.
773 # The following limits apply to file properties:
774 # - Maximum of 100 properties total per file
775 # - Maximum of 30 private properties per app
776 # - Maximum of 30 public properties
777 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
778 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
779 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
780 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
781 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
782 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -0800783 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -0700784 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800785 ],
786 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
787 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
788 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
789 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
790 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
791 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
792 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
793 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
794 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
795 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
796 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
797 &quot;picture&quot;: { # The user&#x27;s profile picture.
798 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
799 },
800 },
801 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
802 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
803 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
804 },
805 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
806 &quot;A String&quot;,
807 ],
808 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
809 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
810 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
811 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
812 },
813 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
814 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
815 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
816 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
817 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
818 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
819 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
820 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
821 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
822 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
823 &quot;picture&quot;: { # The user&#x27;s profile picture.
824 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
825 },
826 },
827 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
828 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
829 &quot;A String&quot;,
830 ],
831 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
832 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
833 &quot;domain&quot;: &quot;A String&quot;, # 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.
834 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
835 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
836 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
837 # - They cannot be set on shared drive items
838 # - They can only be set on user and group permissions
839 # - The date must be in the future
840 # - The date cannot be more than a year in the future
841 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
842 &quot;id&quot;: &quot;A String&quot;, # 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.
843 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
844 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
845 &quot;permissionDetails&quot;: [ # 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.
846 {
847 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
848 &quot;A String&quot;,
849 ],
850 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
851 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
852 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
853 # - file
854 # - member
855 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
856 # - organizer
857 # - fileOrganizer
858 # - writer
859 # - reader
860 },
861 ],
862 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
863 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
864 # - owner
865 # - organizer
866 # - fileOrganizer
867 # - writer
868 # - reader
869 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
870 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
871 {
872 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
873 &quot;A String&quot;,
874 ],
875 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
876 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
877 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
878 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
879 },
880 ],
881 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
882 # - user
883 # - group
884 # - domain
885 # - anyone
886 &quot;value&quot;: &quot;A String&quot;, # 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.
887 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
888 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
889 },
890 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
891 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
892 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
893 &quot;height&quot;: 42, # The height of the video in pixels.
894 &quot;width&quot;: 42, # The width of the video in pixels.
895 },
896 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
897 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
898 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
899}</pre>
John Asmuth614db982014-04-24 15:46:26 -0400900</div>
901
902<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700903 <code class="details" id="delete">delete(fileId, enforceSingleParent=None, supportsAllDrives=None, supportsTeamDrives=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700904 <pre>Permanently deletes a file by ID. Skips the trash. The currently authenticated user must own the file or be an organizer on the parent for shared drive files.
John Asmuth614db982014-04-24 15:46:26 -0400905
906Args:
907 fileId: string, The ID of the file to delete. (required)
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800908 enforceSingleParent: boolean, Deprecated. If an item is not in a shared drive and its last parent is deleted but the item itself is not, the item will be placed under its owner&#x27;s root.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700909 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -0700910 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
John Asmuth614db982014-04-24 15:46:26 -0400911</pre>
912</div>
913
914<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700915 <code class="details" id="emptyTrash">emptyTrash(enforceSingleParent=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -0700916 <pre>Permanently deletes all of the user&#x27;s trashed files.
Craig Citro065b5302014-08-14 00:47:23 -0700917
918Args:
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800919 enforceSingleParent: boolean, Deprecated. If an item is not in a shared drive and its last parent is deleted but the item itself is not, the item will be placed under its owner&#x27;s root.
Craig Citro065b5302014-08-14 00:47:23 -0700920</pre>
921</div>
922
923<div class="method">
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700924 <code class="details" id="export">export(fileId, mimeType)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700925 <pre>Exports a Google Doc to the requested MIME type and returns the exported content. Please note that the exported content is limited to 10MB.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700926
927Args:
928 fileId: string, The ID of the file. (required)
929 mimeType: string, The MIME type of the format requested for this export. (required)
930</pre>
931</div>
932
933<div class="method">
934 <code class="details" id="export_media">export_media(fileId, mimeType)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700935 <pre>Exports a Google Doc to the requested MIME type and returns the exported content. Please note that the exported content is limited to 10MB.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700936
937Args:
938 fileId: string, The ID of the file. (required)
939 mimeType: string, The MIME type of the format requested for this export. (required)
940</pre>
941</div>
942
943<div class="method">
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700944 <code class="details" id="generateIds">generateIds(maxResults=None, space=None, type=None)</code>
Dan O'Mearadd494642020-05-01 07:42:23 -0700945 <pre>Generates a set of file IDs which can be provided in insert or copy requests.
Takashi Matsuo06694102015-09-11 13:55:40 -0700946
947Args:
Takashi Matsuo06694102015-09-11 13:55:40 -0700948 maxResults: integer, Maximum number of IDs to return.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700949 space: string, The space in which the IDs can be used to create new files. Supported values are &#x27;drive&#x27; and &#x27;appDataFolder&#x27;. (Default: &#x27;drive&#x27;)
950 type: string, The type of items which the IDs can be used for. Supported values are &#x27;files&#x27; and &#x27;shortcuts&#x27;. Note that &#x27;shortcuts&#x27; are only supported in the drive &#x27;space&#x27;. (Default: &#x27;files&#x27;)
Takashi Matsuo06694102015-09-11 13:55:40 -0700951
952Returns:
953 An object of the form:
954
955 { # A list of generated IDs which can be provided in insert requests
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800956 &quot;ids&quot;: [ # The IDs generated for the requesting user in the specified space.
957 &quot;A String&quot;,
958 ],
959 &quot;kind&quot;: &quot;drive#generatedIds&quot;, # This is always drive#generatedIds
960 &quot;space&quot;: &quot;A String&quot;, # The type of file that can be created with these IDs.
961}</pre>
Takashi Matsuo06694102015-09-11 13:55:40 -0700962</div>
963
964<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700965 <code class="details" id="get">get(fileId, acknowledgeAbuse=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</code>
yoshi-code-bot3dd15272021-04-21 15:07:48 -0700966 <pre>Gets a file&#x27;s metadata or content by ID.
John Asmuth614db982014-04-24 15:46:26 -0400967
968Args:
969 fileId: string, The ID for the file in question. (required)
Bu Sun Kim65020912020-05-20 12:08:20 -0700970 acknowledgeAbuse: boolean, Whether the user is acknowledging the risk of downloading known malware or other abusive files.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700971 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
John Asmuth614db982014-04-24 15:46:26 -0400972 projection: string, This parameter is deprecated and has no function.
973 Allowed values
974 BASIC - Deprecated
975 FULL - Deprecated
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000976 revisionId: string, Specifies the Revision ID that should be downloaded. Ignored unless alt=media is specified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700977 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -0700978 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700979 updateViewedDate: boolean, Deprecated: Use files.update with modifiedDateBehavior=noChange, updateViewedDate=true and an empty request body.
John Asmuth614db982014-04-24 15:46:26 -0400980
981Returns:
982 An object of the form:
983
984 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800985 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
986 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
987 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
988 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
989 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
990 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
991 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
992 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
993 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
994 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
995 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
996 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
997 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
998 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
999 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
1000 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
1001 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
1002 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
1003 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
1004 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
1005 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
1006 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
1007 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
1008 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
1009 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
1010 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
1011 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
1012 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
1013 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
1014 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
1015 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
1016 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
1017 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
1018 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
1019 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
1020 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
1021 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
1022 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
1023 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
1024 },
1025 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
1026 { # A restriction for accessing the content of the file.
1027 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
1028 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
1029 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001030 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1031 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1032 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1033 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1034 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1035 &quot;picture&quot;: { # The user&#x27;s profile picture.
1036 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04001037 },
John Asmuth614db982014-04-24 15:46:26 -04001038 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001039 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
1040 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
1041 },
1042 ],
1043 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
1044 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
1045 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
1046 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
1047 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
1048 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1049 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
1050 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
1051 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
1052 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
1053 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
1054 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
1055 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
1056 },
1057 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1058 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
1059 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
1060 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1061 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
1062 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
1063 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1064 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
1065 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
1066 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
1067 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
1068 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
1069 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
1070 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
1071 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
1072 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
1073 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
1074 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
1075 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
1076 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
1077 &quot;height&quot;: 42, # The height of the image in pixels.
1078 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
1079 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
1080 &quot;location&quot;: { # Geographic location information stored in the image.
1081 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
1082 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
1083 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
1084 },
1085 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
1086 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
1087 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
1088 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
1089 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
1090 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
1091 &quot;width&quot;: 42, # The width of the image in pixels.
1092 },
1093 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
1094 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
1095 },
1096 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
1097 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
1098 &quot;labels&quot;: { # A group of labels for the file.
1099 &quot;hidden&quot;: True or False, # Deprecated.
1100 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
1101 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
1102 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
1103 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
1104 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
1105 },
1106 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
1107 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1108 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1109 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1110 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1111 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1112 &quot;picture&quot;: { # The user&#x27;s profile picture.
1113 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1114 },
1115 },
1116 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
1117 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
1118 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
1119 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1120 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
1121 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
1122 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
1123 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
1124 &quot;a_key&quot;: &quot;A String&quot;,
1125 },
1126 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
1127 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
1128 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
1129 &quot;A String&quot;,
1130 ],
1131 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
1132 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07001133 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1134 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1135 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1136 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1137 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1138 &quot;picture&quot;: { # The user&#x27;s profile picture.
1139 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1140 },
Takashi Matsuo06694102015-09-11 13:55:40 -07001141 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001142 ],
1143 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
1144 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
1145 { # A reference to a file&#x27;s parent.
1146 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
1147 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
1148 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
1149 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
1150 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07001151 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001152 ],
1153 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
1154 &quot;A String&quot;,
1155 ],
1156 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
1157 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001158 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
1159 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001160 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001161 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
1162 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
1163 &quot;domain&quot;: &quot;A String&quot;, # 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.
1164 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
1165 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
1166 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07001167 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001168 # - They can only be set on user and group permissions
1169 # - The date must be in the future
1170 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001171 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07001172 &quot;id&quot;: &quot;A String&quot;, # 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.
1173 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
1174 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
1175 &quot;permissionDetails&quot;: [ # 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.
1176 {
1177 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
1178 &quot;A String&quot;,
1179 ],
1180 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
1181 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
1182 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
1183 # - file
1184 # - member
1185 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
1186 # - organizer
1187 # - fileOrganizer
1188 # - writer
1189 # - reader
1190 },
1191 ],
1192 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
1193 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04001194 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001195 # - organizer
1196 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04001197 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001198 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07001199 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
1200 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
1201 {
1202 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
1203 &quot;A String&quot;,
1204 ],
1205 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
1206 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
1207 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
1208 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
1209 },
1210 ],
1211 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04001212 # - user
1213 # - group
1214 # - domain
1215 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07001216 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001217 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07001218 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04001219 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001220 ],
1221 &quot;properties&quot;: [ # The list of properties.
1222 { # A key-value pair attached to a file that is either public or private to an application.
1223 # The following limits apply to file properties:
1224 # - Maximum of 100 properties total per file
1225 # - Maximum of 30 private properties per app
1226 # - Maximum of 30 public properties
1227 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
1228 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
1229 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
1230 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
1231 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
1232 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08001233 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07001234 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001235 ],
1236 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
1237 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
1238 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
1239 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
1240 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
1241 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
1242 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1243 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1244 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1245 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1246 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1247 &quot;picture&quot;: { # The user&#x27;s profile picture.
1248 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1249 },
1250 },
1251 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
1252 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
1253 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
1254 },
1255 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
1256 &quot;A String&quot;,
1257 ],
1258 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
1259 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
1260 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
1261 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
1262 },
1263 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
1264 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
1265 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
1266 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
1267 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
1268 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1269 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1270 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1271 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1272 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1273 &quot;picture&quot;: { # The user&#x27;s profile picture.
1274 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1275 },
1276 },
1277 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
1278 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
1279 &quot;A String&quot;,
1280 ],
1281 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
1282 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
1283 &quot;domain&quot;: &quot;A String&quot;, # 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.
1284 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
1285 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
1286 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
1287 # - They cannot be set on shared drive items
1288 # - They can only be set on user and group permissions
1289 # - The date must be in the future
1290 # - The date cannot be more than a year in the future
1291 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
1292 &quot;id&quot;: &quot;A String&quot;, # 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.
1293 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
1294 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
1295 &quot;permissionDetails&quot;: [ # 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.
1296 {
1297 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
1298 &quot;A String&quot;,
1299 ],
1300 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
1301 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
1302 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
1303 # - file
1304 # - member
1305 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
1306 # - organizer
1307 # - fileOrganizer
1308 # - writer
1309 # - reader
1310 },
1311 ],
1312 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
1313 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
1314 # - owner
1315 # - organizer
1316 # - fileOrganizer
1317 # - writer
1318 # - reader
1319 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
1320 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
1321 {
1322 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
1323 &quot;A String&quot;,
1324 ],
1325 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
1326 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
1327 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
1328 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
1329 },
1330 ],
1331 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
1332 # - user
1333 # - group
1334 # - domain
1335 # - anyone
1336 &quot;value&quot;: &quot;A String&quot;, # 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.
1337 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
1338 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
1339 },
1340 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
1341 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
1342 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
1343 &quot;height&quot;: 42, # The height of the video in pixels.
1344 &quot;width&quot;: 42, # The width of the video in pixels.
1345 },
1346 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
1347 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
1348 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
1349}</pre>
John Asmuth614db982014-04-24 15:46:26 -04001350</div>
1351
1352<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001353 <code class="details" id="get_media">get_media(fileId, acknowledgeAbuse=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</code>
yoshi-code-bot3dd15272021-04-21 15:07:48 -07001354 <pre>Gets a file&#x27;s metadata or content by ID.
Craig Citroe633be12015-03-02 13:40:36 -08001355
1356Args:
1357 fileId: string, The ID for the file in question. (required)
Bu Sun Kim65020912020-05-20 12:08:20 -07001358 acknowledgeAbuse: boolean, Whether the user is acknowledging the risk of downloading known malware or other abusive files.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001359 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Craig Citroe633be12015-03-02 13:40:36 -08001360 projection: string, This parameter is deprecated and has no function.
1361 Allowed values
1362 BASIC - Deprecated
1363 FULL - Deprecated
Nathaniel Manista4f877e52015-06-15 16:44:50 +00001364 revisionId: string, Specifies the Revision ID that should be downloaded. Ignored unless alt=media is specified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001365 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07001366 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
Sai Cheemalapatidf613972016-10-21 13:59:49 -07001367 updateViewedDate: boolean, Deprecated: Use files.update with modifiedDateBehavior=noChange, updateViewedDate=true and an empty request body.
Craig Citroe633be12015-03-02 13:40:36 -08001368
1369Returns:
1370 The media object as a string.
1371
1372 </pre>
1373</div>
1374
1375<div class="method">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001376 <code class="details" id="insert">insert(body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, media_body=None, media_mime_type=None, ocr=None, ocrLanguage=None, pinned=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, useContentAsIndexableText=None, visibility=None)</code>
John Asmuth614db982014-04-24 15:46:26 -04001377 <pre>Insert a new file.
1378
1379Args:
1380 body: object, The request body.
1381 The object takes the form of:
1382
1383{ # The metadata for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001384 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
1385 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
1386 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
1387 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
1388 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
1389 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001390 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07001391 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
1392 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
1393 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
1394 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
1395 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
1396 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
1397 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
1398 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
1399 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
1400 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
1401 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001402 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001403 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
1404 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001405 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
Bu Sun Kim65020912020-05-20 12:08:20 -07001406 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
1407 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
1408 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
1409 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001410 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
Bu Sun Kim65020912020-05-20 12:08:20 -07001411 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
1412 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
1413 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
1414 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
1415 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
1416 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
1417 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
1418 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
1419 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
1420 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
1421 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
1422 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
John Asmuth614db982014-04-24 15:46:26 -04001423 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001424 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
1425 { # A restriction for accessing the content of the file.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001426 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001427 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
1428 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
1429 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1430 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1431 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1432 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1433 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1434 &quot;picture&quot;: { # The user&#x27;s profile picture.
1435 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1436 },
1437 },
1438 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
1439 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
1440 },
1441 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001442 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
1443 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
1444 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
1445 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
1446 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001447 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07001448 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
1449 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
1450 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
1451 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
1452 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001453 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
Bu Sun Kim65020912020-05-20 12:08:20 -07001454 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
John Asmuth614db982014-04-24 15:46:26 -04001455 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001456 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1457 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07001458 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001459 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07001460 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
1461 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001462 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07001463 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
1464 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
1465 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
1466 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
1467 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
1468 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
1469 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
1470 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
1471 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
1472 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
1473 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
1474 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
1475 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
1476 &quot;height&quot;: 42, # The height of the image in pixels.
1477 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
1478 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
1479 &quot;location&quot;: { # Geographic location information stored in the image.
1480 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
1481 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
1482 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
1483 },
1484 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
1485 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
1486 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
1487 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
1488 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
1489 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
1490 &quot;width&quot;: 42, # The width of the image in pixels.
1491 },
1492 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
1493 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
1494 },
1495 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
1496 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
1497 &quot;labels&quot;: { # A group of labels for the file.
1498 &quot;hidden&quot;: True or False, # Deprecated.
1499 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
1500 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
1501 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001502 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001503 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
1504 },
1505 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
1506 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1507 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1508 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1509 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1510 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1511 &quot;picture&quot;: { # The user&#x27;s profile picture.
1512 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1513 },
1514 },
1515 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
1516 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
1517 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001518 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07001519 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
1520 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
1521 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
1522 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
1523 &quot;a_key&quot;: &quot;A String&quot;,
1524 },
1525 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
1526 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
1527 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
1528 &quot;A String&quot;,
1529 ],
1530 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
Sai Cheemalapatidf613972016-10-21 13:59:49 -07001531 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07001532 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1533 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1534 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1535 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1536 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1537 &quot;picture&quot;: { # The user&#x27;s profile picture.
1538 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04001539 },
John Asmuth614db982014-04-24 15:46:26 -04001540 },
1541 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001542 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
1543 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
1544 { # A reference to a file&#x27;s parent.
1545 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
1546 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
1547 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
1548 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
1549 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
John Asmuth614db982014-04-24 15:46:26 -04001550 },
1551 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001552 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
1553 &quot;A String&quot;,
1554 ],
1555 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
1556 { # A permission for a file.
1557 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
1558 &quot;A String&quot;,
1559 ],
1560 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
1561 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
1562 &quot;domain&quot;: &quot;A String&quot;, # 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.
1563 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
1564 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
1565 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
1566 # - They cannot be set on shared drive items
1567 # - They can only be set on user and group permissions
1568 # - The date must be in the future
1569 # - The date cannot be more than a year in the future
1570 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
1571 &quot;id&quot;: &quot;A String&quot;, # 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.
1572 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
1573 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
1574 &quot;permissionDetails&quot;: [ # 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.
1575 {
1576 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
1577 &quot;A String&quot;,
1578 ],
1579 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
1580 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
1581 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
1582 # - file
1583 # - member
1584 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
1585 # - organizer
1586 # - fileOrganizer
1587 # - writer
1588 # - reader
1589 },
1590 ],
1591 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
1592 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
1593 # - owner
1594 # - organizer
1595 # - fileOrganizer
1596 # - writer
1597 # - reader
1598 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
1599 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
1600 {
1601 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
1602 &quot;A String&quot;,
1603 ],
1604 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
1605 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
1606 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
1607 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
1608 },
1609 ],
1610 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
1611 # - user
1612 # - group
1613 # - domain
1614 # - anyone
1615 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001616 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07001617 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04001618 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001619 ],
1620 &quot;properties&quot;: [ # The list of properties.
Nathaniel Manista4f877e52015-06-15 16:44:50 +00001621 { # A key-value pair attached to a file that is either public or private to an application.
1622 # The following limits apply to file properties:
1623 # - Maximum of 100 properties total per file
1624 # - Maximum of 30 private properties per app
1625 # - Maximum of 30 public properties
1626 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
Bu Sun Kim65020912020-05-20 12:08:20 -07001627 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
1628 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
1629 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
1630 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
1631 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08001632 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
John Asmuth614db982014-04-24 15:46:26 -04001633 },
1634 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001635 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
1636 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
1637 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
1638 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
1639 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
1640 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
1641 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1642 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1643 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1644 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1645 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1646 &quot;picture&quot;: { # The user&#x27;s profile picture.
1647 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1648 },
Takashi Matsuo06694102015-09-11 13:55:40 -07001649 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001650 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
1651 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
1652 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
1653 },
1654 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
1655 &quot;A String&quot;,
1656 ],
1657 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
1658 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
1659 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
1660 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
1661 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001662 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
Bu Sun Kim65020912020-05-20 12:08:20 -07001663 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
1664 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
1665 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
1666 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
1667 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1668 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1669 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1670 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1671 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1672 &quot;picture&quot;: { # The user&#x27;s profile picture.
1673 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1674 },
1675 },
1676 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
1677 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
1678 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001679 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001680 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
1681 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
1682 &quot;domain&quot;: &quot;A String&quot;, # 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.
1683 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
1684 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
1685 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07001686 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001687 # - They can only be set on user and group permissions
1688 # - The date must be in the future
1689 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001690 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07001691 &quot;id&quot;: &quot;A String&quot;, # 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.
1692 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
1693 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
1694 &quot;permissionDetails&quot;: [ # 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.
1695 {
1696 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
1697 &quot;A String&quot;,
1698 ],
1699 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
1700 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
1701 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
1702 # - file
1703 # - member
1704 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
1705 # - organizer
1706 # - fileOrganizer
1707 # - writer
1708 # - reader
1709 },
1710 ],
1711 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
1712 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04001713 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001714 # - organizer
1715 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04001716 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001717 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07001718 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
1719 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
1720 {
1721 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
1722 &quot;A String&quot;,
1723 ],
1724 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
1725 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
1726 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
1727 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
1728 },
1729 ],
1730 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04001731 # - user
1732 # - group
1733 # - domain
1734 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07001735 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001736 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07001737 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04001738 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001739 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
1740 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
1741 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
1742 &quot;height&quot;: 42, # The height of the video in pixels.
1743 &quot;width&quot;: 42, # The width of the video in pixels.
1744 },
1745 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
1746 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
1747 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
John Asmuth614db982014-04-24 15:46:26 -04001748}
1749
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001750 convert: boolean, Whether to convert this file to the corresponding Docs Editors format.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001751 enforceSingleParent: boolean, Deprecated. Creating files in multiple folders is no longer supported.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001752 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001753 media_body: string, The filename of the media request body, or an instance of a MediaUpload object.
1754 media_mime_type: string, The MIME type of the media request body, or an instance of a MediaUpload object.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001755 ocr: boolean, Whether to attempt OCR on .jpg, .png, .gif, or .pdf uploads.
Bu Sun Kim65020912020-05-20 12:08:20 -07001756 ocrLanguage: string, If ocr is true, hints at the language to use. Valid values are BCP 47 codes.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001757 pinned: boolean, Whether to pin the head revision of the uploaded file. A file can have a maximum of 200 pinned revisions.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001758 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07001759 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
1760 timedTextLanguage: string, The language of the timed text.
1761 timedTextTrackName: string, The timed text track name.
1762 useContentAsIndexableText: boolean, Whether to use the content as indexable text.
John Asmuth614db982014-04-24 15:46:26 -04001763 visibility: string, The visibility of the new file. This parameter is only relevant when convert=false.
1764 Allowed values
Bu Sun Kim65020912020-05-20 12:08:20 -07001765 DEFAULT - The visibility of the new file is determined by the user&#x27;s default visibility/sharing policies.
John Asmuth614db982014-04-24 15:46:26 -04001766 PRIVATE - The new file will be visible to only the owner.
John Asmuth614db982014-04-24 15:46:26 -04001767
1768Returns:
1769 An object of the form:
1770
1771 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001772 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
1773 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
1774 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
1775 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
1776 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
1777 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
1778 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
1779 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
1780 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
1781 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
1782 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
1783 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
1784 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
1785 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
1786 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
1787 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
1788 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
1789 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
1790 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
1791 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
1792 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
1793 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
1794 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
1795 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
1796 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
1797 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
1798 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
1799 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
1800 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
1801 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
1802 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
1803 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
1804 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
1805 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
1806 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
1807 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
1808 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
1809 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
1810 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
1811 },
1812 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
1813 { # A restriction for accessing the content of the file.
1814 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
1815 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
1816 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07001817 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1818 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1819 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1820 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1821 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1822 &quot;picture&quot;: { # The user&#x27;s profile picture.
1823 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04001824 },
John Asmuth614db982014-04-24 15:46:26 -04001825 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001826 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
1827 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
1828 },
1829 ],
1830 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
1831 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
1832 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
1833 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
1834 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
1835 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1836 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
1837 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
1838 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
1839 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
1840 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
1841 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
1842 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
1843 },
1844 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1845 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
1846 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
1847 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1848 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
1849 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
1850 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1851 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
1852 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
1853 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
1854 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
1855 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
1856 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
1857 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
1858 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
1859 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
1860 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
1861 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
1862 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
1863 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
1864 &quot;height&quot;: 42, # The height of the image in pixels.
1865 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
1866 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
1867 &quot;location&quot;: { # Geographic location information stored in the image.
1868 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
1869 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
1870 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
1871 },
1872 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
1873 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
1874 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
1875 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
1876 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
1877 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
1878 &quot;width&quot;: 42, # The width of the image in pixels.
1879 },
1880 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
1881 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
1882 },
1883 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
1884 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
1885 &quot;labels&quot;: { # A group of labels for the file.
1886 &quot;hidden&quot;: True or False, # Deprecated.
1887 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
1888 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
1889 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
1890 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
1891 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
1892 },
1893 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
1894 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1895 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1896 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1897 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1898 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1899 &quot;picture&quot;: { # The user&#x27;s profile picture.
1900 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1901 },
1902 },
1903 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
1904 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
1905 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
1906 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
1907 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
1908 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
1909 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
1910 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
1911 &quot;a_key&quot;: &quot;A String&quot;,
1912 },
1913 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
1914 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
1915 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
1916 &quot;A String&quot;,
1917 ],
1918 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
1919 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07001920 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
1921 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
1922 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
1923 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
1924 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
1925 &quot;picture&quot;: { # The user&#x27;s profile picture.
1926 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
1927 },
Takashi Matsuo06694102015-09-11 13:55:40 -07001928 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001929 ],
1930 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
1931 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
1932 { # A reference to a file&#x27;s parent.
1933 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
1934 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
1935 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
1936 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
1937 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07001938 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08001939 ],
1940 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
1941 &quot;A String&quot;,
1942 ],
1943 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
1944 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001945 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
1946 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001947 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001948 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
1949 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
1950 &quot;domain&quot;: &quot;A String&quot;, # 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.
1951 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
1952 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
1953 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07001954 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001955 # - They can only be set on user and group permissions
1956 # - The date must be in the future
1957 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001958 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07001959 &quot;id&quot;: &quot;A String&quot;, # 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.
1960 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
1961 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
1962 &quot;permissionDetails&quot;: [ # 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.
1963 {
1964 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
1965 &quot;A String&quot;,
1966 ],
1967 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
1968 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
1969 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
1970 # - file
1971 # - member
1972 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
1973 # - organizer
1974 # - fileOrganizer
1975 # - writer
1976 # - reader
1977 },
1978 ],
1979 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
1980 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04001981 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001982 # - organizer
1983 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04001984 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001985 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07001986 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
1987 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
1988 {
1989 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
1990 &quot;A String&quot;,
1991 ],
1992 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
1993 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
1994 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
1995 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
1996 },
1997 ],
1998 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04001999 # - user
2000 # - group
2001 # - domain
2002 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07002003 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002004 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07002005 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04002006 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002007 ],
2008 &quot;properties&quot;: [ # The list of properties.
2009 { # A key-value pair attached to a file that is either public or private to an application.
2010 # The following limits apply to file properties:
2011 # - Maximum of 100 properties total per file
2012 # - Maximum of 30 private properties per app
2013 # - Maximum of 30 public properties
2014 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
2015 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
2016 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
2017 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
2018 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
2019 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08002020 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07002021 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002022 ],
2023 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
2024 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
2025 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
2026 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
2027 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
2028 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
2029 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2030 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2031 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2032 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2033 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2034 &quot;picture&quot;: { # The user&#x27;s profile picture.
2035 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2036 },
2037 },
2038 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
2039 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
2040 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
2041 },
2042 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
2043 &quot;A String&quot;,
2044 ],
2045 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
2046 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
2047 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
2048 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
2049 },
2050 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
2051 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
2052 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
2053 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
2054 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
2055 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2056 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2057 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2058 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2059 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2060 &quot;picture&quot;: { # The user&#x27;s profile picture.
2061 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2062 },
2063 },
2064 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
2065 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
2066 &quot;A String&quot;,
2067 ],
2068 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
2069 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
2070 &quot;domain&quot;: &quot;A String&quot;, # 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.
2071 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
2072 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
2073 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
2074 # - They cannot be set on shared drive items
2075 # - They can only be set on user and group permissions
2076 # - The date must be in the future
2077 # - The date cannot be more than a year in the future
2078 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
2079 &quot;id&quot;: &quot;A String&quot;, # 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.
2080 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
2081 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
2082 &quot;permissionDetails&quot;: [ # 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.
2083 {
2084 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
2085 &quot;A String&quot;,
2086 ],
2087 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
2088 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
2089 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
2090 # - file
2091 # - member
2092 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
2093 # - organizer
2094 # - fileOrganizer
2095 # - writer
2096 # - reader
2097 },
2098 ],
2099 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
2100 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
2101 # - owner
2102 # - organizer
2103 # - fileOrganizer
2104 # - writer
2105 # - reader
2106 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
2107 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
2108 {
2109 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
2110 &quot;A String&quot;,
2111 ],
2112 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
2113 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
2114 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
2115 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
2116 },
2117 ],
2118 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
2119 # - user
2120 # - group
2121 # - domain
2122 # - anyone
2123 &quot;value&quot;: &quot;A String&quot;, # 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.
2124 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
2125 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
2126 },
2127 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
2128 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
2129 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
2130 &quot;height&quot;: 42, # The height of the video in pixels.
2131 &quot;width&quot;: 42, # The width of the video in pixels.
2132 },
2133 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
2134 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
2135 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
2136}</pre>
John Asmuth614db982014-04-24 15:46:26 -04002137</div>
2138
2139<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002140 <code class="details" id="list">list(corpora=None, corpus=None, driveId=None, includeItemsFromAllDrives=None, includePermissionsForView=None, includeTeamDriveItems=None, maxResults=None, orderBy=None, pageToken=None, projection=None, q=None, spaces=None, supportsAllDrives=None, supportsTeamDrives=None, teamDriveId=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -07002141 <pre>Lists the user&#x27;s files.
John Asmuth614db982014-04-24 15:46:26 -04002142
2143Args:
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002144 corpora: string, Groupings of files to which the query applies. Supported groupings are: &#x27;user&#x27; (files created by, opened by, or shared directly with the user), &#x27;drive&#x27; (files in the specified shared drive as indicated by the &#x27;driveId&#x27;), &#x27;domain&#x27; (files shared to the user&#x27;s domain), and &#x27;allDrives&#x27; (A combination of &#x27;user&#x27; and &#x27;drive&#x27; for all drives where the user is a member). When able, use &#x27;user&#x27; or &#x27;drive&#x27;, instead of &#x27;allDrives&#x27;, for efficiency.
Bu Sun Kim65020912020-05-20 12:08:20 -07002145 corpus: string, The body of items (files/documents) to which the query applies. Deprecated: use &#x27;corpora&#x27; instead.
2146 Allowed values
2147 DEFAULT - The items that the user has accessed.
2148 DOMAIN - Items shared to the user&#x27;s domain.
2149 driveId: string, ID of the shared drive to search.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002150 includeItemsFromAllDrives: boolean, Whether both My Drive and shared drive items should be included in results.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002151 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Bu Sun Kim65020912020-05-20 12:08:20 -07002152 includeTeamDriveItems: boolean, Deprecated use includeItemsFromAllDrives instead.
2153 maxResults: integer, The maximum number of files to return per page. Partial or empty result pages are possible even before the end of the files list has been reached.
2154 orderBy: string, A comma-separated list of sort keys. Valid keys are &#x27;createdDate&#x27;, &#x27;folder&#x27;, &#x27;lastViewedByMeDate&#x27;, &#x27;modifiedByMeDate&#x27;, &#x27;modifiedDate&#x27;, &#x27;quotaBytesUsed&#x27;, &#x27;recency&#x27;, &#x27;sharedWithMeDate&#x27;, &#x27;starred&#x27;, &#x27;title&#x27;, and &#x27;title_natural&#x27;. Each key sorts ascending by default, but may be reversed with the &#x27;desc&#x27; modifier. Example usage: ?orderBy=folder,modifiedDate desc,title. Please note that there is a current limitation for users with approximately one million files in which the requested sort order is ignored.
2155 pageToken: string, Page token for files.
John Asmuth614db982014-04-24 15:46:26 -04002156 projection: string, This parameter is deprecated and has no function.
2157 Allowed values
2158 BASIC - Deprecated
2159 FULL - Deprecated
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002160 q: string, Query string for searching files.
Bu Sun Kim65020912020-05-20 12:08:20 -07002161 spaces: string, A comma-separated list of spaces to query. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002162 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07002163 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
2164 teamDriveId: string, Deprecated use driveId instead.
John Asmuth614db982014-04-24 15:46:26 -04002165
2166Returns:
2167 An object of the form:
2168
2169 { # A list of files.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002170 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the list.
2171 &quot;incompleteSearch&quot;: True or False, # Whether the search process was incomplete. If true, then some search results may be missing, since all documents were not searched. This may occur when searching multiple drives with the &quot;allDrives&quot; corpora, but all corpora could not be searched. When this happens, it is suggested that clients narrow their query by choosing a different corpus such as &quot;default&quot; or &quot;drive&quot;.
2172 &quot;items&quot;: [ # The list of files. If nextPageToken is populated, then this list may be incomplete and an additional page of results should be fetched.
2173 { # The metadata for a file.
2174 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
2175 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
2176 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
2177 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
2178 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
2179 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
2180 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2181 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
2182 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
2183 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
2184 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
2185 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
2186 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
2187 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2188 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
2189 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
2190 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
2191 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
2192 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
2193 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
2194 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
2195 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
2196 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
2197 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
2198 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
2199 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
2200 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
2201 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
2202 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
2203 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
2204 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
2205 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
2206 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
2207 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
2208 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
2209 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
2210 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
2211 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2212 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
2213 },
2214 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
2215 { # A restriction for accessing the content of the file.
2216 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
2217 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
2218 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07002219 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2220 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2221 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2222 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2223 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2224 &quot;picture&quot;: { # The user&#x27;s profile picture.
2225 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04002226 },
John Asmuth614db982014-04-24 15:46:26 -04002227 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002228 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
2229 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
2230 },
2231 ],
2232 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
2233 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
2234 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
2235 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
2236 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
2237 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
2238 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
2239 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
2240 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
2241 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
2242 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
2243 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
2244 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
2245 },
2246 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
2247 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
2248 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
2249 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
2250 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
2251 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
2252 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
2253 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
2254 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
2255 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
2256 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
2257 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
2258 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
2259 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
2260 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
2261 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
2262 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
2263 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
2264 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
2265 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
2266 &quot;height&quot;: 42, # The height of the image in pixels.
2267 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
2268 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
2269 &quot;location&quot;: { # Geographic location information stored in the image.
2270 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
2271 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
2272 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
2273 },
2274 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
2275 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
2276 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
2277 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
2278 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
2279 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
2280 &quot;width&quot;: 42, # The width of the image in pixels.
2281 },
2282 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
2283 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
2284 },
2285 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
2286 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
2287 &quot;labels&quot;: { # A group of labels for the file.
2288 &quot;hidden&quot;: True or False, # Deprecated.
2289 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
2290 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
2291 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
2292 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
2293 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
2294 },
2295 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
2296 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2297 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2298 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2299 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2300 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2301 &quot;picture&quot;: { # The user&#x27;s profile picture.
2302 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2303 },
2304 },
2305 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
2306 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
2307 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
2308 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
2309 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
2310 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
2311 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
2312 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
2313 &quot;a_key&quot;: &quot;A String&quot;,
2314 },
2315 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
2316 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
2317 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
2318 &quot;A String&quot;,
2319 ],
2320 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
2321 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07002322 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2323 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2324 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2325 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2326 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2327 &quot;picture&quot;: { # The user&#x27;s profile picture.
2328 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2329 },
Takashi Matsuo06694102015-09-11 13:55:40 -07002330 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002331 ],
2332 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
2333 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
2334 { # A reference to a file&#x27;s parent.
2335 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
2336 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
2337 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
2338 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
2339 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07002340 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002341 ],
2342 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
2343 &quot;A String&quot;,
2344 ],
2345 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
2346 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07002347 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
2348 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04002349 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002350 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
2351 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
2352 &quot;domain&quot;: &quot;A String&quot;, # 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.
2353 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
2354 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
2355 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07002356 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04002357 # - They can only be set on user and group permissions
2358 # - The date must be in the future
2359 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002360 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07002361 &quot;id&quot;: &quot;A String&quot;, # 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.
2362 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
2363 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
2364 &quot;permissionDetails&quot;: [ # 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.
2365 {
2366 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
2367 &quot;A String&quot;,
2368 ],
2369 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
2370 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
2371 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
2372 # - file
2373 # - member
2374 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
2375 # - organizer
2376 # - fileOrganizer
2377 # - writer
2378 # - reader
2379 },
2380 ],
2381 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
2382 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04002383 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002384 # - organizer
2385 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04002386 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002387 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07002388 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
2389 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
2390 {
2391 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
2392 &quot;A String&quot;,
2393 ],
2394 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
2395 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
2396 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
2397 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
2398 },
2399 ],
2400 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04002401 # - user
2402 # - group
2403 # - domain
2404 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07002405 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002406 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07002407 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04002408 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002409 ],
2410 &quot;properties&quot;: [ # The list of properties.
2411 { # A key-value pair attached to a file that is either public or private to an application.
2412 # The following limits apply to file properties:
2413 # - Maximum of 100 properties total per file
2414 # - Maximum of 30 private properties per app
2415 # - Maximum of 30 public properties
2416 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
2417 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
2418 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
2419 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
2420 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
2421 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08002422 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07002423 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002424 ],
2425 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
2426 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
2427 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
2428 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
2429 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
2430 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
2431 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2432 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2433 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2434 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2435 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2436 &quot;picture&quot;: { # The user&#x27;s profile picture.
2437 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2438 },
John Asmuth614db982014-04-24 15:46:26 -04002439 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002440 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
2441 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
2442 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
2443 },
2444 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
2445 &quot;A String&quot;,
2446 ],
2447 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
2448 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
2449 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
2450 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
2451 },
2452 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
2453 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
2454 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
2455 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
2456 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
2457 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2458 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2459 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2460 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2461 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2462 &quot;picture&quot;: { # The user&#x27;s profile picture.
2463 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2464 },
2465 },
2466 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
2467 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
2468 &quot;A String&quot;,
2469 ],
2470 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
2471 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
2472 &quot;domain&quot;: &quot;A String&quot;, # 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.
2473 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
2474 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
2475 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
2476 # - They cannot be set on shared drive items
2477 # - They can only be set on user and group permissions
2478 # - The date must be in the future
2479 # - The date cannot be more than a year in the future
2480 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
2481 &quot;id&quot;: &quot;A String&quot;, # 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.
2482 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
2483 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
2484 &quot;permissionDetails&quot;: [ # 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.
2485 {
2486 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
2487 &quot;A String&quot;,
2488 ],
2489 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
2490 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
2491 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
2492 # - file
2493 # - member
2494 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
2495 # - organizer
2496 # - fileOrganizer
2497 # - writer
2498 # - reader
2499 },
2500 ],
2501 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
2502 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
2503 # - owner
2504 # - organizer
2505 # - fileOrganizer
2506 # - writer
2507 # - reader
2508 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
2509 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
2510 {
2511 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
2512 &quot;A String&quot;,
2513 ],
2514 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
2515 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
2516 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
2517 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
2518 },
2519 ],
2520 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
2521 # - user
2522 # - group
2523 # - domain
2524 # - anyone
2525 &quot;value&quot;: &quot;A String&quot;, # 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.
2526 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
2527 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
2528 },
2529 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
2530 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
2531 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
2532 &quot;height&quot;: 42, # The height of the video in pixels.
2533 &quot;width&quot;: 42, # The width of the video in pixels.
2534 },
2535 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
2536 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
2537 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
2538 },
2539 ],
2540 &quot;kind&quot;: &quot;drive#fileList&quot;, # This is always drive#fileList.
2541 &quot;nextLink&quot;: &quot;A String&quot;, # A link to the next page of files.
2542 &quot;nextPageToken&quot;: &quot;A String&quot;, # The page token for the next page of files. This will be absent if the end of the files list has been reached. If the token is rejected for any reason, it should be discarded, and pagination should be restarted from the first page of results.
2543 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this list.
2544}</pre>
John Asmuth614db982014-04-24 15:46:26 -04002545</div>
2546
2547<div class="method">
2548 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
2549 <pre>Retrieves the next page of results.
2550
2551Args:
2552 previous_request: The request for the previous page. (required)
2553 previous_response: The response from the request for the previous page. (required)
2554
2555Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -07002556 A request object that you can call &#x27;execute()&#x27; on to request the next
John Asmuth614db982014-04-24 15:46:26 -04002557 page. Returns None if there are no more items in the collection.
2558 </pre>
2559</div>
2560
2561<div class="method">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002562 <code class="details" id="patch">patch(fileId, addParents=None, body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, modifiedDateBehavior=None, newRevision=None, ocr=None, ocrLanguage=None, pinned=None, removeParents=None, setModifiedDate=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, updateViewedDate=None, useContentAsIndexableText=None)</code>
John Asmuth614db982014-04-24 15:46:26 -04002563 <pre>Updates file metadata and/or content. This method supports patch semantics.
2564
2565Args:
2566 fileId: string, The ID of the file to update. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002567 body: object, The request body.
John Asmuth614db982014-04-24 15:46:26 -04002568 The object takes the form of:
2569
2570{ # The metadata for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07002571 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
2572 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
2573 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
2574 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
2575 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
2576 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002577 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07002578 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
2579 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
2580 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
2581 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
2582 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
2583 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
2584 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2585 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
2586 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
2587 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
2588 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002589 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
Bu Sun Kim65020912020-05-20 12:08:20 -07002590 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
2591 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002592 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
Bu Sun Kim65020912020-05-20 12:08:20 -07002593 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
2594 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
2595 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
2596 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002597 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
Bu Sun Kim65020912020-05-20 12:08:20 -07002598 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
2599 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
2600 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
2601 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
2602 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
2603 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
2604 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
2605 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
2606 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
2607 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
2608 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2609 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
John Asmuth614db982014-04-24 15:46:26 -04002610 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002611 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
2612 { # A restriction for accessing the content of the file.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002613 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002614 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
2615 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
2616 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2617 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2618 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2619 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2620 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2621 &quot;picture&quot;: { # The user&#x27;s profile picture.
2622 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2623 },
2624 },
2625 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
2626 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
2627 },
2628 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002629 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
2630 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
2631 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
2632 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
2633 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002634 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07002635 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
2636 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
2637 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
2638 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
2639 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002640 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
Bu Sun Kim65020912020-05-20 12:08:20 -07002641 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
John Asmuth614db982014-04-24 15:46:26 -04002642 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002643 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
2644 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07002645 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002646 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07002647 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
2648 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002649 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07002650 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
2651 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
2652 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
2653 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
2654 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
2655 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
2656 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
2657 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
2658 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
2659 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
2660 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
2661 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
2662 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
2663 &quot;height&quot;: 42, # The height of the image in pixels.
2664 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
2665 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
2666 &quot;location&quot;: { # Geographic location information stored in the image.
2667 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
2668 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
2669 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
2670 },
2671 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
2672 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
2673 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
2674 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
2675 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
2676 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
2677 &quot;width&quot;: 42, # The width of the image in pixels.
2678 },
2679 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
2680 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
2681 },
2682 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
2683 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
2684 &quot;labels&quot;: { # A group of labels for the file.
2685 &quot;hidden&quot;: True or False, # Deprecated.
2686 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
2687 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
2688 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002689 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
Bu Sun Kim65020912020-05-20 12:08:20 -07002690 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
2691 },
2692 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
2693 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2694 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2695 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2696 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2697 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2698 &quot;picture&quot;: { # The user&#x27;s profile picture.
2699 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2700 },
2701 },
2702 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
2703 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
2704 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002705 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07002706 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
2707 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
2708 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
2709 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
2710 &quot;a_key&quot;: &quot;A String&quot;,
2711 },
2712 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
2713 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
2714 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
2715 &quot;A String&quot;,
2716 ],
2717 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
Sai Cheemalapatidf613972016-10-21 13:59:49 -07002718 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07002719 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2720 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2721 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2722 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2723 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2724 &quot;picture&quot;: { # The user&#x27;s profile picture.
2725 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04002726 },
John Asmuth614db982014-04-24 15:46:26 -04002727 },
2728 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002729 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
2730 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
2731 { # A reference to a file&#x27;s parent.
2732 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
2733 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
2734 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
2735 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
2736 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
John Asmuth614db982014-04-24 15:46:26 -04002737 },
2738 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002739 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
2740 &quot;A String&quot;,
2741 ],
2742 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
2743 { # A permission for a file.
2744 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
2745 &quot;A String&quot;,
2746 ],
2747 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
2748 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
2749 &quot;domain&quot;: &quot;A String&quot;, # 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.
2750 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
2751 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
2752 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
2753 # - They cannot be set on shared drive items
2754 # - They can only be set on user and group permissions
2755 # - The date must be in the future
2756 # - The date cannot be more than a year in the future
2757 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
2758 &quot;id&quot;: &quot;A String&quot;, # 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.
2759 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
2760 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
2761 &quot;permissionDetails&quot;: [ # 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.
2762 {
2763 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
2764 &quot;A String&quot;,
2765 ],
2766 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
2767 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
2768 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
2769 # - file
2770 # - member
2771 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
2772 # - organizer
2773 # - fileOrganizer
2774 # - writer
2775 # - reader
2776 },
2777 ],
2778 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
2779 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
2780 # - owner
2781 # - organizer
2782 # - fileOrganizer
2783 # - writer
2784 # - reader
2785 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
2786 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
2787 {
2788 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
2789 &quot;A String&quot;,
2790 ],
2791 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
2792 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
2793 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
2794 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
2795 },
2796 ],
2797 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
2798 # - user
2799 # - group
2800 # - domain
2801 # - anyone
2802 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002803 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07002804 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04002805 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002806 ],
2807 &quot;properties&quot;: [ # The list of properties.
Nathaniel Manista4f877e52015-06-15 16:44:50 +00002808 { # A key-value pair attached to a file that is either public or private to an application.
2809 # The following limits apply to file properties:
2810 # - Maximum of 100 properties total per file
2811 # - Maximum of 30 private properties per app
2812 # - Maximum of 30 public properties
2813 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
Bu Sun Kim65020912020-05-20 12:08:20 -07002814 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
2815 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
2816 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
2817 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
2818 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08002819 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
John Asmuth614db982014-04-24 15:46:26 -04002820 },
2821 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002822 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
2823 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
2824 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
2825 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
2826 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
2827 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
2828 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2829 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2830 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2831 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2832 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2833 &quot;picture&quot;: { # The user&#x27;s profile picture.
2834 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2835 },
Takashi Matsuo06694102015-09-11 13:55:40 -07002836 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002837 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
2838 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
2839 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
2840 },
2841 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
2842 &quot;A String&quot;,
2843 ],
2844 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
2845 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
2846 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
2847 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
2848 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07002849 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
Bu Sun Kim65020912020-05-20 12:08:20 -07002850 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
2851 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
2852 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
2853 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
2854 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
2855 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
2856 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
2857 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
2858 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
2859 &quot;picture&quot;: { # The user&#x27;s profile picture.
2860 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
2861 },
2862 },
2863 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
2864 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
2865 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04002866 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002867 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
2868 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
2869 &quot;domain&quot;: &quot;A String&quot;, # 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.
2870 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
2871 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
2872 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07002873 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04002874 # - They can only be set on user and group permissions
2875 # - The date must be in the future
2876 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002877 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07002878 &quot;id&quot;: &quot;A String&quot;, # 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.
2879 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
2880 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
2881 &quot;permissionDetails&quot;: [ # 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.
2882 {
2883 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
2884 &quot;A String&quot;,
2885 ],
2886 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
2887 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
2888 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
2889 # - file
2890 # - member
2891 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
2892 # - organizer
2893 # - fileOrganizer
2894 # - writer
2895 # - reader
2896 },
2897 ],
2898 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
2899 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04002900 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002901 # - organizer
2902 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04002903 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002904 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07002905 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
2906 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
2907 {
2908 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
2909 &quot;A String&quot;,
2910 ],
2911 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
2912 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
2913 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
2914 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
2915 },
2916 ],
2917 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04002918 # - user
2919 # - group
2920 # - domain
2921 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07002922 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002923 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07002924 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04002925 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002926 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
2927 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
2928 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
2929 &quot;height&quot;: 42, # The height of the video in pixels.
2930 &quot;width&quot;: 42, # The width of the video in pixels.
2931 },
2932 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
2933 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
2934 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
John Asmuth614db982014-04-24 15:46:26 -04002935}
2936
Bu Sun Kim65020912020-05-20 12:08:20 -07002937 addParents: string, Comma-separated list of parent IDs to add.
2938 convert: boolean, This parameter is deprecated and has no function.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08002939 enforceSingleParent: boolean, Deprecated. Adding files to multiple folders is no longer supported. Use shortcuts instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002940 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Takashi Matsuo06694102015-09-11 13:55:40 -07002941 modifiedDateBehavior: string, Determines the behavior in which modifiedDate is updated. This overrides setModifiedDate.
2942 Allowed values
2943 fromBody - Set modifiedDate to the value provided in the body of the request. No change if no value was provided.
2944 fromBodyIfNeeded - Set modifiedDate to the value provided in the body of the request depending on other contents of the update.
2945 fromBodyOrNow - Set modifiedDate to the value provided in the body of the request, or to the current time if no value was provided.
2946 noChange - Maintain the previous value of modifiedDate.
2947 now - Set modifiedDate to the current time.
2948 nowIfNeeded - Set modifiedDate to the current time depending on contents of the update.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002949 newRevision: boolean, Whether a blob upload should create a new revision. If false, the blob data in the current head revision is replaced. If true or not set, a new blob is created as head revision, and previous unpinned revisions are preserved for a short period of time. Pinned revisions are stored indefinitely, using additional storage quota, up to a maximum of 200 revisions. For details on how revisions are retained, see the Drive Help Center. Note that this field is ignored if there is no payload in the request.
Bu Sun Kim65020912020-05-20 12:08:20 -07002950 ocr: boolean, Whether to attempt OCR on .jpg, .png, .gif, or .pdf uploads.
Nathaniel Manista4f877e52015-06-15 16:44:50 +00002951 ocrLanguage: string, If ocr is true, hints at the language to use. Valid values are BCP 47 codes.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002952 pinned: boolean, Whether to pin the new revision. A file can have a maximum of 200 pinned revisions. Note that this field is ignored if there is no payload in the request.
Craig Citro065b5302014-08-14 00:47:23 -07002953 removeParents: string, Comma-separated list of parent IDs to remove.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002954 setModifiedDate: boolean, Whether to set the modified date using the value supplied in the request body. Setting this field to true is equivalent to modifiedDateBehavior=fromBodyOrNow, and false is equivalent to modifiedDateBehavior=now. To prevent any changes to the modified date set modifiedDateBehavior=noChange.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002955 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07002956 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
John Asmuth614db982014-04-24 15:46:26 -04002957 timedTextLanguage: string, The language of the timed text.
Bu Sun Kim65020912020-05-20 12:08:20 -07002958 timedTextTrackName: string, The timed text track name.
2959 updateViewedDate: boolean, Whether to update the view date after successfully updating the file.
2960 useContentAsIndexableText: boolean, Whether to use the content as indexable text.
John Asmuth614db982014-04-24 15:46:26 -04002961
2962Returns:
2963 An object of the form:
2964
2965 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08002966 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
2967 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
2968 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
2969 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
2970 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
2971 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
2972 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2973 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
2974 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
2975 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
2976 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
2977 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
2978 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
2979 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
2980 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
2981 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
2982 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
2983 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
2984 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
2985 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
2986 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
2987 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
2988 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
2989 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
2990 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
2991 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
2992 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
2993 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
2994 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
2995 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
2996 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
2997 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
2998 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
2999 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
3000 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
3001 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
3002 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
3003 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3004 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
3005 },
3006 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
3007 { # A restriction for accessing the content of the file.
3008 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
3009 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
3010 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07003011 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3012 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3013 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3014 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3015 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3016 &quot;picture&quot;: { # The user&#x27;s profile picture.
3017 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04003018 },
John Asmuth614db982014-04-24 15:46:26 -04003019 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003020 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
3021 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
3022 },
3023 ],
3024 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
3025 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
3026 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
3027 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
3028 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
3029 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3030 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
3031 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
3032 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
3033 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
3034 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
3035 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
3036 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
3037 },
3038 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3039 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
3040 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
3041 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3042 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
3043 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
3044 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3045 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
3046 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
3047 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
3048 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
3049 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
3050 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
3051 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
3052 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
3053 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
3054 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
3055 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
3056 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
3057 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
3058 &quot;height&quot;: 42, # The height of the image in pixels.
3059 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
3060 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
3061 &quot;location&quot;: { # Geographic location information stored in the image.
3062 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
3063 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
3064 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
3065 },
3066 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
3067 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
3068 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
3069 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
3070 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
3071 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
3072 &quot;width&quot;: 42, # The width of the image in pixels.
3073 },
3074 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
3075 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
3076 },
3077 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
3078 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
3079 &quot;labels&quot;: { # A group of labels for the file.
3080 &quot;hidden&quot;: True or False, # Deprecated.
3081 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
3082 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
3083 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
3084 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
3085 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
3086 },
3087 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
3088 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3089 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3090 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3091 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3092 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3093 &quot;picture&quot;: { # The user&#x27;s profile picture.
3094 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3095 },
3096 },
3097 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
3098 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
3099 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
3100 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3101 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
3102 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
3103 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
3104 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
3105 &quot;a_key&quot;: &quot;A String&quot;,
3106 },
3107 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
3108 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
3109 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
3110 &quot;A String&quot;,
3111 ],
3112 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
3113 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07003114 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3115 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3116 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3117 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3118 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3119 &quot;picture&quot;: { # The user&#x27;s profile picture.
3120 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3121 },
Takashi Matsuo06694102015-09-11 13:55:40 -07003122 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003123 ],
3124 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
3125 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
3126 { # A reference to a file&#x27;s parent.
3127 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
3128 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
3129 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
3130 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
3131 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07003132 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003133 ],
3134 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
3135 &quot;A String&quot;,
3136 ],
3137 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
3138 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07003139 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
3140 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04003141 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07003142 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
3143 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
3144 &quot;domain&quot;: &quot;A String&quot;, # 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.
3145 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
3146 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
3147 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07003148 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04003149 # - They can only be set on user and group permissions
3150 # - The date must be in the future
3151 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003152 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07003153 &quot;id&quot;: &quot;A String&quot;, # 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.
3154 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
3155 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
3156 &quot;permissionDetails&quot;: [ # 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.
3157 {
3158 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
3159 &quot;A String&quot;,
3160 ],
3161 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
3162 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
3163 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
3164 # - file
3165 # - member
3166 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
3167 # - organizer
3168 # - fileOrganizer
3169 # - writer
3170 # - reader
3171 },
3172 ],
3173 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
3174 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04003175 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003176 # - organizer
3177 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04003178 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003179 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07003180 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
3181 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
3182 {
3183 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
3184 &quot;A String&quot;,
3185 ],
3186 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
3187 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
3188 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
3189 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
3190 },
3191 ],
3192 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04003193 # - user
3194 # - group
3195 # - domain
3196 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07003197 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003198 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07003199 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04003200 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003201 ],
3202 &quot;properties&quot;: [ # The list of properties.
3203 { # A key-value pair attached to a file that is either public or private to an application.
3204 # The following limits apply to file properties:
3205 # - Maximum of 100 properties total per file
3206 # - Maximum of 30 private properties per app
3207 # - Maximum of 30 public properties
3208 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
3209 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
3210 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
3211 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
3212 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
3213 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08003214 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07003215 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003216 ],
3217 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
3218 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
3219 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
3220 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
3221 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
3222 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
3223 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3224 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3225 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3226 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3227 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3228 &quot;picture&quot;: { # The user&#x27;s profile picture.
3229 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3230 },
3231 },
3232 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
3233 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
3234 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
3235 },
3236 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
3237 &quot;A String&quot;,
3238 ],
3239 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
3240 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
3241 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
3242 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
3243 },
3244 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
3245 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
3246 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
3247 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
3248 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
3249 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3250 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3251 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3252 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3253 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3254 &quot;picture&quot;: { # The user&#x27;s profile picture.
3255 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3256 },
3257 },
3258 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
3259 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
3260 &quot;A String&quot;,
3261 ],
3262 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
3263 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
3264 &quot;domain&quot;: &quot;A String&quot;, # 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.
3265 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
3266 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
3267 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
3268 # - They cannot be set on shared drive items
3269 # - They can only be set on user and group permissions
3270 # - The date must be in the future
3271 # - The date cannot be more than a year in the future
3272 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
3273 &quot;id&quot;: &quot;A String&quot;, # 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.
3274 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
3275 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
3276 &quot;permissionDetails&quot;: [ # 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.
3277 {
3278 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
3279 &quot;A String&quot;,
3280 ],
3281 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
3282 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
3283 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
3284 # - file
3285 # - member
3286 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
3287 # - organizer
3288 # - fileOrganizer
3289 # - writer
3290 # - reader
3291 },
3292 ],
3293 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
3294 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
3295 # - owner
3296 # - organizer
3297 # - fileOrganizer
3298 # - writer
3299 # - reader
3300 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
3301 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
3302 {
3303 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
3304 &quot;A String&quot;,
3305 ],
3306 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
3307 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
3308 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
3309 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
3310 },
3311 ],
3312 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
3313 # - user
3314 # - group
3315 # - domain
3316 # - anyone
3317 &quot;value&quot;: &quot;A String&quot;, # 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.
3318 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
3319 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
3320 },
3321 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
3322 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
3323 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
3324 &quot;height&quot;: 42, # The height of the video in pixels.
3325 &quot;width&quot;: 42, # The width of the video in pixels.
3326 },
3327 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
3328 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
3329 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
3330}</pre>
John Asmuth614db982014-04-24 15:46:26 -04003331</div>
3332
3333<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003334 <code class="details" id="touch">touch(fileId, includePermissionsForView=None, supportsAllDrives=None, supportsTeamDrives=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -07003335 <pre>Set the file&#x27;s updated time to the current server time.
John Asmuth614db982014-04-24 15:46:26 -04003336
3337Args:
3338 fileId: string, The ID of the file to update. (required)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003339 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003340 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07003341 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
John Asmuth614db982014-04-24 15:46:26 -04003342
3343Returns:
3344 An object of the form:
3345
3346 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003347 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
3348 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
3349 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
3350 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
3351 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
3352 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
3353 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3354 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
3355 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
3356 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
3357 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
3358 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
3359 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
3360 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3361 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
3362 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
3363 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
3364 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
3365 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
3366 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
3367 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
3368 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
3369 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
3370 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
3371 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
3372 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
3373 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
3374 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
3375 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
3376 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
3377 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
3378 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
3379 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
3380 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
3381 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
3382 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
3383 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
3384 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3385 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
3386 },
3387 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
3388 { # A restriction for accessing the content of the file.
3389 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
3390 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
3391 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07003392 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3393 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3394 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3395 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3396 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3397 &quot;picture&quot;: { # The user&#x27;s profile picture.
3398 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04003399 },
John Asmuth614db982014-04-24 15:46:26 -04003400 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003401 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
3402 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
3403 },
3404 ],
3405 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
3406 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
3407 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
3408 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
3409 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
3410 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3411 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
3412 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
3413 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
3414 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
3415 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
3416 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
3417 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
3418 },
3419 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3420 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
3421 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
3422 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3423 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
3424 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
3425 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3426 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
3427 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
3428 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
3429 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
3430 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
3431 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
3432 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
3433 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
3434 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
3435 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
3436 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
3437 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
3438 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
3439 &quot;height&quot;: 42, # The height of the image in pixels.
3440 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
3441 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
3442 &quot;location&quot;: { # Geographic location information stored in the image.
3443 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
3444 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
3445 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
3446 },
3447 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
3448 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
3449 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
3450 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
3451 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
3452 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
3453 &quot;width&quot;: 42, # The width of the image in pixels.
3454 },
3455 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
3456 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
3457 },
3458 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
3459 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
3460 &quot;labels&quot;: { # A group of labels for the file.
3461 &quot;hidden&quot;: True or False, # Deprecated.
3462 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
3463 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
3464 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
3465 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
3466 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
3467 },
3468 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
3469 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3470 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3471 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3472 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3473 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3474 &quot;picture&quot;: { # The user&#x27;s profile picture.
3475 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3476 },
3477 },
3478 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
3479 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
3480 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
3481 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3482 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
3483 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
3484 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
3485 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
3486 &quot;a_key&quot;: &quot;A String&quot;,
3487 },
3488 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
3489 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
3490 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
3491 &quot;A String&quot;,
3492 ],
3493 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
3494 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07003495 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3496 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3497 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3498 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3499 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3500 &quot;picture&quot;: { # The user&#x27;s profile picture.
3501 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3502 },
Takashi Matsuo06694102015-09-11 13:55:40 -07003503 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003504 ],
3505 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
3506 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
3507 { # A reference to a file&#x27;s parent.
3508 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
3509 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
3510 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
3511 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
3512 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07003513 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003514 ],
3515 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
3516 &quot;A String&quot;,
3517 ],
3518 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
3519 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07003520 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
3521 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04003522 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07003523 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
3524 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
3525 &quot;domain&quot;: &quot;A String&quot;, # 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.
3526 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
3527 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
3528 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07003529 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04003530 # - They can only be set on user and group permissions
3531 # - The date must be in the future
3532 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003533 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07003534 &quot;id&quot;: &quot;A String&quot;, # 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.
3535 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
3536 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
3537 &quot;permissionDetails&quot;: [ # 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.
3538 {
3539 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
3540 &quot;A String&quot;,
3541 ],
3542 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
3543 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
3544 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
3545 # - file
3546 # - member
3547 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
3548 # - organizer
3549 # - fileOrganizer
3550 # - writer
3551 # - reader
3552 },
3553 ],
3554 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
3555 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04003556 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003557 # - organizer
3558 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04003559 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003560 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07003561 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
3562 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
3563 {
3564 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
3565 &quot;A String&quot;,
3566 ],
3567 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
3568 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
3569 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
3570 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
3571 },
3572 ],
3573 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04003574 # - user
3575 # - group
3576 # - domain
3577 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07003578 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003579 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07003580 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04003581 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003582 ],
3583 &quot;properties&quot;: [ # The list of properties.
3584 { # A key-value pair attached to a file that is either public or private to an application.
3585 # The following limits apply to file properties:
3586 # - Maximum of 100 properties total per file
3587 # - Maximum of 30 private properties per app
3588 # - Maximum of 30 public properties
3589 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
3590 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
3591 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
3592 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
3593 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
3594 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08003595 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07003596 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003597 ],
3598 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
3599 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
3600 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
3601 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
3602 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
3603 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
3604 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3605 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3606 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3607 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3608 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3609 &quot;picture&quot;: { # The user&#x27;s profile picture.
3610 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3611 },
3612 },
3613 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
3614 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
3615 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
3616 },
3617 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
3618 &quot;A String&quot;,
3619 ],
3620 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
3621 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
3622 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
3623 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
3624 },
3625 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
3626 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
3627 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
3628 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
3629 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
3630 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3631 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3632 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3633 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3634 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3635 &quot;picture&quot;: { # The user&#x27;s profile picture.
3636 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3637 },
3638 },
3639 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
3640 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
3641 &quot;A String&quot;,
3642 ],
3643 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
3644 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
3645 &quot;domain&quot;: &quot;A String&quot;, # 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.
3646 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
3647 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
3648 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
3649 # - They cannot be set on shared drive items
3650 # - They can only be set on user and group permissions
3651 # - The date must be in the future
3652 # - The date cannot be more than a year in the future
3653 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
3654 &quot;id&quot;: &quot;A String&quot;, # 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.
3655 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
3656 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
3657 &quot;permissionDetails&quot;: [ # 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.
3658 {
3659 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
3660 &quot;A String&quot;,
3661 ],
3662 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
3663 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
3664 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
3665 # - file
3666 # - member
3667 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
3668 # - organizer
3669 # - fileOrganizer
3670 # - writer
3671 # - reader
3672 },
3673 ],
3674 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
3675 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
3676 # - owner
3677 # - organizer
3678 # - fileOrganizer
3679 # - writer
3680 # - reader
3681 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
3682 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
3683 {
3684 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
3685 &quot;A String&quot;,
3686 ],
3687 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
3688 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
3689 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
3690 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
3691 },
3692 ],
3693 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
3694 # - user
3695 # - group
3696 # - domain
3697 # - anyone
3698 &quot;value&quot;: &quot;A String&quot;, # 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.
3699 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
3700 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
3701 },
3702 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
3703 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
3704 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
3705 &quot;height&quot;: 42, # The height of the video in pixels.
3706 &quot;width&quot;: 42, # The width of the video in pixels.
3707 },
3708 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
3709 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
3710 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
3711}</pre>
John Asmuth614db982014-04-24 15:46:26 -04003712</div>
3713
3714<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003715 <code class="details" id="trash">trash(fileId, includePermissionsForView=None, supportsAllDrives=None, supportsTeamDrives=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003716 <pre>Moves a file to the trash. The currently authenticated user must own the file or be at least a fileOrganizer on the parent for shared drive files. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
John Asmuth614db982014-04-24 15:46:26 -04003717
3718Args:
3719 fileId: string, The ID of the file to trash. (required)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003720 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003721 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07003722 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
John Asmuth614db982014-04-24 15:46:26 -04003723
3724Returns:
3725 An object of the form:
3726
3727 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003728 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
3729 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
3730 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
3731 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
3732 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
3733 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
3734 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3735 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
3736 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
3737 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
3738 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
3739 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
3740 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
3741 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3742 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
3743 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
3744 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
3745 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
3746 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
3747 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
3748 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
3749 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
3750 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
3751 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
3752 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
3753 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
3754 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
3755 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
3756 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
3757 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
3758 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
3759 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
3760 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
3761 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
3762 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
3763 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
3764 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
3765 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
3766 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
3767 },
3768 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
3769 { # A restriction for accessing the content of the file.
3770 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
3771 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
3772 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07003773 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3774 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3775 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3776 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3777 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3778 &quot;picture&quot;: { # The user&#x27;s profile picture.
3779 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04003780 },
John Asmuth614db982014-04-24 15:46:26 -04003781 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003782 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
3783 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
3784 },
3785 ],
3786 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
3787 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
3788 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
3789 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
3790 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
3791 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3792 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
3793 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
3794 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
3795 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
3796 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
3797 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
3798 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
3799 },
3800 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3801 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
3802 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
3803 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3804 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
3805 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
3806 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3807 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
3808 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
3809 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
3810 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
3811 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
3812 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
3813 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
3814 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
3815 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
3816 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
3817 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
3818 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
3819 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
3820 &quot;height&quot;: 42, # The height of the image in pixels.
3821 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
3822 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
3823 &quot;location&quot;: { # Geographic location information stored in the image.
3824 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
3825 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
3826 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
3827 },
3828 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
3829 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
3830 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
3831 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
3832 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
3833 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
3834 &quot;width&quot;: 42, # The width of the image in pixels.
3835 },
3836 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
3837 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
3838 },
3839 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
3840 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
3841 &quot;labels&quot;: { # A group of labels for the file.
3842 &quot;hidden&quot;: True or False, # Deprecated.
3843 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
3844 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
3845 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
3846 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
3847 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
3848 },
3849 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
3850 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3851 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3852 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3853 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3854 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3855 &quot;picture&quot;: { # The user&#x27;s profile picture.
3856 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3857 },
3858 },
3859 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
3860 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
3861 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
3862 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
3863 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
3864 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
3865 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
3866 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
3867 &quot;a_key&quot;: &quot;A String&quot;,
3868 },
3869 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
3870 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
3871 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
3872 &quot;A String&quot;,
3873 ],
3874 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
3875 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07003876 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3877 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3878 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3879 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3880 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3881 &quot;picture&quot;: { # The user&#x27;s profile picture.
3882 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3883 },
Takashi Matsuo06694102015-09-11 13:55:40 -07003884 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003885 ],
3886 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
3887 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
3888 { # A reference to a file&#x27;s parent.
3889 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
3890 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
3891 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
3892 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
3893 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07003894 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003895 ],
3896 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
3897 &quot;A String&quot;,
3898 ],
3899 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
3900 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07003901 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
3902 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04003903 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07003904 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
3905 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
3906 &quot;domain&quot;: &quot;A String&quot;, # 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.
3907 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
3908 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
3909 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07003910 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04003911 # - They can only be set on user and group permissions
3912 # - The date must be in the future
3913 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003914 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07003915 &quot;id&quot;: &quot;A String&quot;, # 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.
3916 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
3917 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
3918 &quot;permissionDetails&quot;: [ # 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.
3919 {
3920 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
3921 &quot;A String&quot;,
3922 ],
3923 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
3924 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
3925 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
3926 # - file
3927 # - member
3928 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
3929 # - organizer
3930 # - fileOrganizer
3931 # - writer
3932 # - reader
3933 },
3934 ],
3935 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
3936 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04003937 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003938 # - organizer
3939 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04003940 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003941 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07003942 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
3943 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
3944 {
3945 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
3946 &quot;A String&quot;,
3947 ],
3948 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
3949 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
3950 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
3951 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
3952 },
3953 ],
3954 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04003955 # - user
3956 # - group
3957 # - domain
3958 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07003959 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07003960 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07003961 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04003962 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003963 ],
3964 &quot;properties&quot;: [ # The list of properties.
3965 { # A key-value pair attached to a file that is either public or private to an application.
3966 # The following limits apply to file properties:
3967 # - Maximum of 100 properties total per file
3968 # - Maximum of 30 private properties per app
3969 # - Maximum of 30 public properties
3970 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
3971 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
3972 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
3973 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
3974 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
3975 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08003976 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07003977 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08003978 ],
3979 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
3980 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
3981 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
3982 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
3983 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
3984 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
3985 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
3986 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
3987 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
3988 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
3989 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
3990 &quot;picture&quot;: { # The user&#x27;s profile picture.
3991 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
3992 },
3993 },
3994 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
3995 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
3996 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
3997 },
3998 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
3999 &quot;A String&quot;,
4000 ],
4001 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
4002 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
4003 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
4004 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
4005 },
4006 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
4007 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
4008 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
4009 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
4010 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
4011 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4012 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4013 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4014 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4015 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4016 &quot;picture&quot;: { # The user&#x27;s profile picture.
4017 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4018 },
4019 },
4020 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
4021 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
4022 &quot;A String&quot;,
4023 ],
4024 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
4025 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
4026 &quot;domain&quot;: &quot;A String&quot;, # 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.
4027 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
4028 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
4029 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
4030 # - They cannot be set on shared drive items
4031 # - They can only be set on user and group permissions
4032 # - The date must be in the future
4033 # - The date cannot be more than a year in the future
4034 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
4035 &quot;id&quot;: &quot;A String&quot;, # 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.
4036 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
4037 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
4038 &quot;permissionDetails&quot;: [ # 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.
4039 {
4040 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
4041 &quot;A String&quot;,
4042 ],
4043 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
4044 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
4045 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
4046 # - file
4047 # - member
4048 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
4049 # - organizer
4050 # - fileOrganizer
4051 # - writer
4052 # - reader
4053 },
4054 ],
4055 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
4056 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
4057 # - owner
4058 # - organizer
4059 # - fileOrganizer
4060 # - writer
4061 # - reader
4062 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
4063 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
4064 {
4065 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
4066 &quot;A String&quot;,
4067 ],
4068 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
4069 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
4070 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
4071 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
4072 },
4073 ],
4074 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
4075 # - user
4076 # - group
4077 # - domain
4078 # - anyone
4079 &quot;value&quot;: &quot;A String&quot;, # 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.
4080 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
4081 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
4082 },
4083 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
4084 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
4085 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
4086 &quot;height&quot;: 42, # The height of the video in pixels.
4087 &quot;width&quot;: 42, # The width of the video in pixels.
4088 },
4089 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
4090 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
4091 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
4092}</pre>
John Asmuth614db982014-04-24 15:46:26 -04004093</div>
4094
4095<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004096 <code class="details" id="untrash">untrash(fileId, includePermissionsForView=None, supportsAllDrives=None, supportsTeamDrives=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004097 <pre>Restores a file from the trash. The currently authenticated user must own the file or be at least a fileOrganizer on the parent for shared drive files. Only the owner may untrash a file.
John Asmuth614db982014-04-24 15:46:26 -04004098
4099Args:
4100 fileId: string, The ID of the file to untrash. (required)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004101 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004102 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07004103 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
John Asmuth614db982014-04-24 15:46:26 -04004104
4105Returns:
4106 An object of the form:
4107
4108 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004109 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
4110 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
4111 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
4112 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
4113 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
4114 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
4115 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4116 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
4117 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
4118 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
4119 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
4120 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
4121 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
4122 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4123 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
4124 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
4125 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
4126 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
4127 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
4128 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
4129 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
4130 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
4131 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
4132 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
4133 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
4134 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
4135 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
4136 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
4137 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
4138 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
4139 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
4140 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
4141 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
4142 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
4143 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
4144 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
4145 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
4146 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4147 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
4148 },
4149 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
4150 { # A restriction for accessing the content of the file.
4151 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
4152 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
4153 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07004154 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4155 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4156 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4157 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4158 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4159 &quot;picture&quot;: { # The user&#x27;s profile picture.
4160 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04004161 },
John Asmuth614db982014-04-24 15:46:26 -04004162 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004163 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
4164 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
4165 },
4166 ],
4167 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
4168 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
4169 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
4170 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
4171 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
4172 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4173 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
4174 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
4175 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
4176 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
4177 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
4178 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
4179 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
4180 },
4181 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4182 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
4183 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
4184 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4185 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
4186 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
4187 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4188 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
4189 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
4190 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
4191 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
4192 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
4193 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
4194 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
4195 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
4196 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
4197 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
4198 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
4199 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
4200 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
4201 &quot;height&quot;: 42, # The height of the image in pixels.
4202 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
4203 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
4204 &quot;location&quot;: { # Geographic location information stored in the image.
4205 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
4206 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
4207 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
4208 },
4209 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
4210 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
4211 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
4212 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
4213 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
4214 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
4215 &quot;width&quot;: 42, # The width of the image in pixels.
4216 },
4217 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
4218 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
4219 },
4220 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
4221 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
4222 &quot;labels&quot;: { # A group of labels for the file.
4223 &quot;hidden&quot;: True or False, # Deprecated.
4224 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
4225 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
4226 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
4227 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
4228 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
4229 },
4230 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
4231 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4232 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4233 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4234 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4235 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4236 &quot;picture&quot;: { # The user&#x27;s profile picture.
4237 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4238 },
4239 },
4240 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
4241 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
4242 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
4243 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4244 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
4245 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
4246 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
4247 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
4248 &quot;a_key&quot;: &quot;A String&quot;,
4249 },
4250 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
4251 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
4252 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
4253 &quot;A String&quot;,
4254 ],
4255 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
4256 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07004257 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4258 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4259 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4260 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4261 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4262 &quot;picture&quot;: { # The user&#x27;s profile picture.
4263 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4264 },
Takashi Matsuo06694102015-09-11 13:55:40 -07004265 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004266 ],
4267 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
4268 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
4269 { # A reference to a file&#x27;s parent.
4270 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
4271 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
4272 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
4273 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
4274 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07004275 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004276 ],
4277 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
4278 &quot;A String&quot;,
4279 ],
4280 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
4281 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07004282 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
4283 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04004284 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004285 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
4286 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
4287 &quot;domain&quot;: &quot;A String&quot;, # 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.
4288 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
4289 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
4290 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07004291 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04004292 # - They can only be set on user and group permissions
4293 # - The date must be in the future
4294 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004295 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07004296 &quot;id&quot;: &quot;A String&quot;, # 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.
4297 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
4298 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
4299 &quot;permissionDetails&quot;: [ # 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.
4300 {
4301 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
4302 &quot;A String&quot;,
4303 ],
4304 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
4305 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
4306 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
4307 # - file
4308 # - member
4309 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
4310 # - organizer
4311 # - fileOrganizer
4312 # - writer
4313 # - reader
4314 },
4315 ],
4316 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
4317 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04004318 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004319 # - organizer
4320 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04004321 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004322 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07004323 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
4324 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
4325 {
4326 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
4327 &quot;A String&quot;,
4328 ],
4329 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
4330 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
4331 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
4332 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
4333 },
4334 ],
4335 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04004336 # - user
4337 # - group
4338 # - domain
4339 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07004340 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004341 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07004342 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04004343 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004344 ],
4345 &quot;properties&quot;: [ # The list of properties.
4346 { # A key-value pair attached to a file that is either public or private to an application.
4347 # The following limits apply to file properties:
4348 # - Maximum of 100 properties total per file
4349 # - Maximum of 30 private properties per app
4350 # - Maximum of 30 public properties
4351 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
4352 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
4353 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
4354 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
4355 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
4356 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08004357 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07004358 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004359 ],
4360 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
4361 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
4362 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
4363 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
4364 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
4365 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
4366 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4367 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4368 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4369 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4370 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4371 &quot;picture&quot;: { # The user&#x27;s profile picture.
4372 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4373 },
4374 },
4375 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
4376 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
4377 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
4378 },
4379 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
4380 &quot;A String&quot;,
4381 ],
4382 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
4383 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
4384 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
4385 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
4386 },
4387 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
4388 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
4389 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
4390 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
4391 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
4392 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4393 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4394 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4395 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4396 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4397 &quot;picture&quot;: { # The user&#x27;s profile picture.
4398 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4399 },
4400 },
4401 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
4402 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
4403 &quot;A String&quot;,
4404 ],
4405 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
4406 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
4407 &quot;domain&quot;: &quot;A String&quot;, # 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.
4408 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
4409 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
4410 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
4411 # - They cannot be set on shared drive items
4412 # - They can only be set on user and group permissions
4413 # - The date must be in the future
4414 # - The date cannot be more than a year in the future
4415 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
4416 &quot;id&quot;: &quot;A String&quot;, # 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.
4417 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
4418 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
4419 &quot;permissionDetails&quot;: [ # 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.
4420 {
4421 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
4422 &quot;A String&quot;,
4423 ],
4424 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
4425 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
4426 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
4427 # - file
4428 # - member
4429 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
4430 # - organizer
4431 # - fileOrganizer
4432 # - writer
4433 # - reader
4434 },
4435 ],
4436 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
4437 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
4438 # - owner
4439 # - organizer
4440 # - fileOrganizer
4441 # - writer
4442 # - reader
4443 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
4444 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
4445 {
4446 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
4447 &quot;A String&quot;,
4448 ],
4449 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
4450 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
4451 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
4452 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
4453 },
4454 ],
4455 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
4456 # - user
4457 # - group
4458 # - domain
4459 # - anyone
4460 &quot;value&quot;: &quot;A String&quot;, # 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.
4461 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
4462 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
4463 },
4464 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
4465 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
4466 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
4467 &quot;height&quot;: 42, # The height of the video in pixels.
4468 &quot;width&quot;: 42, # The width of the video in pixels.
4469 },
4470 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
4471 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
4472 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
4473}</pre>
John Asmuth614db982014-04-24 15:46:26 -04004474</div>
4475
4476<div class="method">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004477 <code class="details" id="update">update(fileId, addParents=None, body=None, convert=None, enforceSingleParent=None, includePermissionsForView=None, media_body=None, media_mime_type=None, modifiedDateBehavior=None, newRevision=None, ocr=None, ocrLanguage=None, pinned=None, removeParents=None, setModifiedDate=None, supportsAllDrives=None, supportsTeamDrives=None, timedTextLanguage=None, timedTextTrackName=None, updateViewedDate=None, useContentAsIndexableText=None)</code>
John Asmuth614db982014-04-24 15:46:26 -04004478 <pre>Updates file metadata and/or content.
4479
4480Args:
4481 fileId: string, The ID of the file to update. (required)
4482 body: object, The request body.
4483 The object takes the form of:
4484
4485{ # The metadata for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07004486 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
4487 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
4488 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
4489 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
4490 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
4491 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004492 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07004493 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
4494 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
4495 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
4496 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
4497 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
4498 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
4499 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4500 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
4501 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
4502 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
4503 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004504 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
Bu Sun Kim65020912020-05-20 12:08:20 -07004505 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
4506 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004507 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
Bu Sun Kim65020912020-05-20 12:08:20 -07004508 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
4509 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
4510 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
4511 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004512 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
Bu Sun Kim65020912020-05-20 12:08:20 -07004513 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
4514 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
4515 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
4516 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
4517 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
4518 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
4519 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
4520 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
4521 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
4522 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
4523 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4524 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
John Asmuth614db982014-04-24 15:46:26 -04004525 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004526 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
4527 { # A restriction for accessing the content of the file.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004528 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004529 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
4530 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
4531 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4532 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4533 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4534 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4535 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4536 &quot;picture&quot;: { # The user&#x27;s profile picture.
4537 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4538 },
4539 },
4540 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
4541 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
4542 },
4543 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004544 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
4545 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
4546 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
4547 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
4548 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004549 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07004550 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
4551 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
4552 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
4553 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
4554 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004555 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
Bu Sun Kim65020912020-05-20 12:08:20 -07004556 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
John Asmuth614db982014-04-24 15:46:26 -04004557 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004558 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4559 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07004560 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004561 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07004562 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
4563 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004564 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07004565 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
4566 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
4567 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
4568 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
4569 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
4570 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
4571 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
4572 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
4573 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
4574 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
4575 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
4576 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
4577 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
4578 &quot;height&quot;: 42, # The height of the image in pixels.
4579 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
4580 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
4581 &quot;location&quot;: { # Geographic location information stored in the image.
4582 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
4583 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
4584 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
4585 },
4586 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
4587 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
4588 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
4589 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
4590 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
4591 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
4592 &quot;width&quot;: 42, # The width of the image in pixels.
4593 },
4594 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
4595 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
4596 },
4597 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
4598 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
4599 &quot;labels&quot;: { # A group of labels for the file.
4600 &quot;hidden&quot;: True or False, # Deprecated.
4601 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
4602 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
4603 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004604 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
Bu Sun Kim65020912020-05-20 12:08:20 -07004605 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
4606 },
4607 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
4608 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4609 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4610 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4611 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4612 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4613 &quot;picture&quot;: { # The user&#x27;s profile picture.
4614 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4615 },
4616 },
4617 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
4618 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
4619 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004620 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
Bu Sun Kim65020912020-05-20 12:08:20 -07004621 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
4622 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
4623 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
4624 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
4625 &quot;a_key&quot;: &quot;A String&quot;,
4626 },
4627 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
4628 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
4629 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
4630 &quot;A String&quot;,
4631 ],
4632 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
Sai Cheemalapatidf613972016-10-21 13:59:49 -07004633 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07004634 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4635 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4636 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4637 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4638 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4639 &quot;picture&quot;: { # The user&#x27;s profile picture.
4640 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04004641 },
John Asmuth614db982014-04-24 15:46:26 -04004642 },
4643 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004644 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
4645 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
4646 { # A reference to a file&#x27;s parent.
4647 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
4648 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
4649 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
4650 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
4651 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
John Asmuth614db982014-04-24 15:46:26 -04004652 },
4653 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004654 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
4655 &quot;A String&quot;,
4656 ],
4657 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
4658 { # A permission for a file.
4659 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
4660 &quot;A String&quot;,
4661 ],
4662 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
4663 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
4664 &quot;domain&quot;: &quot;A String&quot;, # 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.
4665 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
4666 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
4667 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
4668 # - They cannot be set on shared drive items
4669 # - They can only be set on user and group permissions
4670 # - The date must be in the future
4671 # - The date cannot be more than a year in the future
4672 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
4673 &quot;id&quot;: &quot;A String&quot;, # 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.
4674 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
4675 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
4676 &quot;permissionDetails&quot;: [ # 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.
4677 {
4678 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
4679 &quot;A String&quot;,
4680 ],
4681 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
4682 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
4683 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
4684 # - file
4685 # - member
4686 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
4687 # - organizer
4688 # - fileOrganizer
4689 # - writer
4690 # - reader
4691 },
4692 ],
4693 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
4694 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
4695 # - owner
4696 # - organizer
4697 # - fileOrganizer
4698 # - writer
4699 # - reader
4700 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
4701 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
4702 {
4703 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
4704 &quot;A String&quot;,
4705 ],
4706 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
4707 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
4708 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
4709 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
4710 },
4711 ],
4712 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
4713 # - user
4714 # - group
4715 # - domain
4716 # - anyone
4717 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004718 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07004719 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04004720 },
Bu Sun Kim65020912020-05-20 12:08:20 -07004721 ],
4722 &quot;properties&quot;: [ # The list of properties.
Nathaniel Manista4f877e52015-06-15 16:44:50 +00004723 { # A key-value pair attached to a file that is either public or private to an application.
4724 # The following limits apply to file properties:
4725 # - Maximum of 100 properties total per file
4726 # - Maximum of 30 private properties per app
4727 # - Maximum of 30 public properties
4728 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
Bu Sun Kim65020912020-05-20 12:08:20 -07004729 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
4730 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
4731 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
4732 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
4733 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08004734 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
John Asmuth614db982014-04-24 15:46:26 -04004735 },
4736 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004737 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
4738 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
4739 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
4740 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
4741 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
4742 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
4743 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4744 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4745 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4746 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4747 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4748 &quot;picture&quot;: { # The user&#x27;s profile picture.
4749 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4750 },
Takashi Matsuo06694102015-09-11 13:55:40 -07004751 },
Bu Sun Kim65020912020-05-20 12:08:20 -07004752 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
4753 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
4754 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
4755 },
4756 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
4757 &quot;A String&quot;,
4758 ],
4759 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
4760 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
4761 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
4762 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
4763 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07004764 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
Bu Sun Kim65020912020-05-20 12:08:20 -07004765 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
4766 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
4767 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
4768 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
4769 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4770 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4771 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4772 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4773 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4774 &quot;picture&quot;: { # The user&#x27;s profile picture.
4775 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
4776 },
4777 },
4778 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
4779 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
4780 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04004781 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004782 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
4783 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
4784 &quot;domain&quot;: &quot;A String&quot;, # 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.
4785 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
4786 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
4787 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07004788 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04004789 # - They can only be set on user and group permissions
4790 # - The date must be in the future
4791 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004792 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07004793 &quot;id&quot;: &quot;A String&quot;, # 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.
4794 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
4795 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
4796 &quot;permissionDetails&quot;: [ # 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.
4797 {
4798 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
4799 &quot;A String&quot;,
4800 ],
4801 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
4802 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
4803 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
4804 # - file
4805 # - member
4806 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
4807 # - organizer
4808 # - fileOrganizer
4809 # - writer
4810 # - reader
4811 },
4812 ],
4813 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
4814 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04004815 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004816 # - organizer
4817 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04004818 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004819 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07004820 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
4821 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
4822 {
4823 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
4824 &quot;A String&quot;,
4825 ],
4826 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
4827 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
4828 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
4829 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
4830 },
4831 ],
4832 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04004833 # - user
4834 # - group
4835 # - domain
4836 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07004837 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004838 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07004839 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04004840 },
Bu Sun Kim65020912020-05-20 12:08:20 -07004841 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
4842 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
4843 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
4844 &quot;height&quot;: 42, # The height of the video in pixels.
4845 &quot;width&quot;: 42, # The width of the video in pixels.
4846 },
4847 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
4848 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
4849 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
John Asmuth614db982014-04-24 15:46:26 -04004850}
4851
Bu Sun Kim65020912020-05-20 12:08:20 -07004852 addParents: string, Comma-separated list of parent IDs to add.
4853 convert: boolean, This parameter is deprecated and has no function.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08004854 enforceSingleParent: boolean, Deprecated. Adding files to multiple folders is no longer supported. Use shortcuts instead.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07004855 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004856 media_body: string, The filename of the media request body, or an instance of a MediaUpload object.
4857 media_mime_type: string, The MIME type of the media request body, or an instance of a MediaUpload object.
Takashi Matsuo06694102015-09-11 13:55:40 -07004858 modifiedDateBehavior: string, Determines the behavior in which modifiedDate is updated. This overrides setModifiedDate.
4859 Allowed values
4860 fromBody - Set modifiedDate to the value provided in the body of the request. No change if no value was provided.
4861 fromBodyIfNeeded - Set modifiedDate to the value provided in the body of the request depending on other contents of the update.
4862 fromBodyOrNow - Set modifiedDate to the value provided in the body of the request, or to the current time if no value was provided.
4863 noChange - Maintain the previous value of modifiedDate.
4864 now - Set modifiedDate to the current time.
4865 nowIfNeeded - Set modifiedDate to the current time depending on contents of the update.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004866 newRevision: boolean, Whether a blob upload should create a new revision. If false, the blob data in the current head revision is replaced. If true or not set, a new blob is created as head revision, and previous unpinned revisions are preserved for a short period of time. Pinned revisions are stored indefinitely, using additional storage quota, up to a maximum of 200 revisions. For details on how revisions are retained, see the Drive Help Center. Note that this field is ignored if there is no payload in the request.
Bu Sun Kim65020912020-05-20 12:08:20 -07004867 ocr: boolean, Whether to attempt OCR on .jpg, .png, .gif, or .pdf uploads.
Nathaniel Manista4f877e52015-06-15 16:44:50 +00004868 ocrLanguage: string, If ocr is true, hints at the language to use. Valid values are BCP 47 codes.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004869 pinned: boolean, Whether to pin the new revision. A file can have a maximum of 200 pinned revisions. Note that this field is ignored if there is no payload in the request.
Craig Citro065b5302014-08-14 00:47:23 -07004870 removeParents: string, Comma-separated list of parent IDs to remove.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004871 setModifiedDate: boolean, Whether to set the modified date using the value supplied in the request body. Setting this field to true is equivalent to modifiedDateBehavior=fromBodyOrNow, and false is equivalent to modifiedDateBehavior=now. To prevent any changes to the modified date set modifiedDateBehavior=noChange.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004872 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07004873 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
John Asmuth614db982014-04-24 15:46:26 -04004874 timedTextLanguage: string, The language of the timed text.
Bu Sun Kim65020912020-05-20 12:08:20 -07004875 timedTextTrackName: string, The timed text track name.
4876 updateViewedDate: boolean, Whether to update the view date after successfully updating the file.
4877 useContentAsIndexableText: boolean, Whether to use the content as indexable text.
John Asmuth614db982014-04-24 15:46:26 -04004878
4879Returns:
4880 An object of the form:
4881
4882 { # The metadata for a file.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004883 &quot;alternateLink&quot;: &quot;A String&quot;, # A link for opening the file in a relevant Google editor or viewer.
4884 &quot;appDataContents&quot;: True or False, # Whether this file is in the Application Data folder.
4885 &quot;canComment&quot;: True or False, # Deprecated: use capabilities/canComment.
4886 &quot;canReadRevisions&quot;: True or False, # Deprecated: use capabilities/canReadRevisions.
4887 &quot;capabilities&quot;: { # Capabilities the current user has on this file. Each capability corresponds to a fine-grained action that a user may take.
4888 &quot;canAddChildren&quot;: True or False, # Whether the current user can add children to this folder. This is always false when the item is not a folder.
4889 &quot;canAddFolderFromAnotherDrive&quot;: True or False, # Whether the current user can add a folder from another drive (different shared drive or My Drive) to this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4890 &quot;canAddMyDriveParent&quot;: True or False, # Whether the current user can add a parent for the item without removing an existing parent in the same request. Not populated for shared drive files.
4891 &quot;canChangeCopyRequiresWriterPermission&quot;: True or False, # Whether the current user can change the copyRequiresWriterPermission restriction of this file.
4892 &quot;canChangeRestrictedDownload&quot;: True or False, # Deprecated
4893 &quot;canComment&quot;: True or False, # Whether the current user can comment on this file.
4894 &quot;canCopy&quot;: True or False, # Whether the current user can copy this file. For an item in a shared drive, whether the current user can copy non-folder descendants of this item, or this item itself if it is not a folder.
4895 &quot;canDelete&quot;: True or False, # Whether the current user can delete this file.
4896 &quot;canDeleteChildren&quot;: True or False, # Whether the current user can delete children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4897 &quot;canDownload&quot;: True or False, # Whether the current user can download this file.
4898 &quot;canEdit&quot;: True or False, # Whether the current user can edit this file. Other factors may limit the type of changes a user can make to a file. For example, see canChangeCopyRequiresWriterPermission or canModifyContent.
4899 &quot;canListChildren&quot;: True or False, # Whether the current user can list the children of this folder. This is always false when the item is not a folder.
4900 &quot;canModifyContent&quot;: True or False, # Whether the current user can modify the content of this file.
4901 &quot;canModifyContentRestriction&quot;: True or False, # Whether the current user can modify restrictions on content of this file.
4902 &quot;canMoveChildrenOutOfDrive&quot;: True or False, # Whether the current user can move children of this folder outside of the shared drive. This is false when the item is not a folder. Only populated for items in shared drives.
4903 &quot;canMoveChildrenOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenOutOfDrive instead.
4904 &quot;canMoveChildrenWithinDrive&quot;: True or False, # Whether the current user can move children of this folder within this drive. This is false when the item is not a folder. Note that a request to move the child may still fail depending on the current user&#x27;s access to the child and to the destination folder.
4905 &quot;canMoveChildrenWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveChildrenWithinDrive instead.
4906 &quot;canMoveItemIntoTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
4907 &quot;canMoveItemOutOfDrive&quot;: True or False, # Whether the current user can move this item outside of this drive by changing its parent. Note that a request to change the parent of the item may still fail depending on the new parent that is being added.
4908 &quot;canMoveItemOutOfTeamDrive&quot;: True or False, # Deprecated - use canMoveItemOutOfDrive instead.
4909 &quot;canMoveItemWithinDrive&quot;: True or False, # Whether the current user can move this item within this drive. Note that a request to change the parent of the item may still fail depending on the new parent that is being added and the parent that is being removed.
4910 &quot;canMoveItemWithinTeamDrive&quot;: True or False, # Deprecated - use canMoveItemWithinDrive instead.
4911 &quot;canMoveTeamDriveItem&quot;: True or False, # Deprecated - use canMoveItemWithinDrive or canMoveItemOutOfDrive instead.
4912 &quot;canReadDrive&quot;: True or False, # Whether the current user can read the shared drive to which this file belongs. Only populated for items in shared drives.
4913 &quot;canReadRevisions&quot;: True or False, # Whether the current user can read the revisions resource of this file. For a shared drive item, whether revisions of non-folder descendants of this item, or this item itself if it is not a folder, can be read.
4914 &quot;canReadTeamDrive&quot;: True or False, # Deprecated - use canReadDrive instead.
4915 &quot;canRemoveChildren&quot;: True or False, # Whether the current user can remove children from this folder. This is always false when the item is not a folder. For a folder in a shared drive, use canDeleteChildren or canTrashChildren instead.
4916 &quot;canRemoveMyDriveParent&quot;: True or False, # Whether the current user can remove a parent from the item without adding another parent in the same request. Not populated for shared drive files.
4917 &quot;canRename&quot;: True or False, # Whether the current user can rename this file.
4918 &quot;canShare&quot;: True or False, # Whether the current user can modify the sharing settings for this file.
4919 &quot;canTrash&quot;: True or False, # Whether the current user can move this file to trash.
4920 &quot;canTrashChildren&quot;: True or False, # Whether the current user can trash children of this folder. This is false when the item is not a folder. Only populated for items in shared drives.
4921 &quot;canUntrash&quot;: True or False, # Whether the current user can restore this file from trash.
4922 },
4923 &quot;contentRestrictions&quot;: [ # Restrictions for accessing the content of the file. Only populated if such a restriction exists.
4924 { # A restriction for accessing the content of the file.
4925 &quot;readOnly&quot;: True or False, # Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified.
4926 &quot;reason&quot;: &quot;A String&quot;, # Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true.
4927 &quot;restrictingUser&quot;: { # Information about a Drive user. # The user who set the content restriction. Only populated if readOnly is true.
Bu Sun Kim65020912020-05-20 12:08:20 -07004928 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
4929 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
4930 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
4931 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
4932 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
4933 &quot;picture&quot;: { # The user&#x27;s profile picture.
4934 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
John Asmuth614db982014-04-24 15:46:26 -04004935 },
John Asmuth614db982014-04-24 15:46:26 -04004936 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08004937 &quot;restrictionDate&quot;: &quot;A String&quot;, # The time at which the content restriction was set (formatted RFC 3339 timestamp). Only populated if readOnly is true.
4938 &quot;type&quot;: &quot;A String&quot;, # The type of the content restriction. Currently the only possible value is globalContentRestriction.
4939 },
4940 ],
4941 &quot;copyRequiresWriterPermission&quot;: True or False, # Whether the options to copy, print, or download this file, should be disabled for readers and commenters.
4942 &quot;copyable&quot;: True or False, # Deprecated: use capabilities/canCopy.
4943 &quot;createdDate&quot;: &quot;A String&quot;, # Create time for this file (formatted RFC 3339 timestamp).
4944 &quot;defaultOpenWithLink&quot;: &quot;A String&quot;, # A link to open this file with the user&#x27;s default app for this file. Only populated when the drive.apps.readonly scope is used.
4945 &quot;description&quot;: &quot;A String&quot;, # A short description of the file.
4946 &quot;downloadUrl&quot;: &quot;A String&quot;, # Short lived download URL for the file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4947 &quot;driveId&quot;: &quot;A String&quot;, # ID of the shared drive the file resides in. Only populated for items in shared drives.
4948 &quot;editable&quot;: True or False, # Deprecated: use capabilities/canEdit.
4949 &quot;embedLink&quot;: &quot;A String&quot;, # A link for embedding the file.
4950 &quot;etag&quot;: &quot;A String&quot;, # ETag of the file.
4951 &quot;explicitlyTrashed&quot;: True or False, # Whether this file has been explicitly trashed, as opposed to recursively trashed.
4952 &quot;exportLinks&quot;: { # Links for exporting Docs Editors files to specific formats.
4953 &quot;a_key&quot;: &quot;A String&quot;, # A mapping from export format to URL
4954 },
4955 &quot;fileExtension&quot;: &quot;A String&quot;, # The final component of fullFileExtension with trailing text that does not appear to be part of the extension removed. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4956 &quot;fileSize&quot;: &quot;A String&quot;, # The size of the file in bytes. This field is populated for files with content stored in Google Drive and for files in Docs Editors; it is not populated for shortcut files.
4957 &quot;folderColorRgb&quot;: &quot;A String&quot;, # Folder color as an RGB hex string if the file is a folder. The list of supported colors is available in the folderColorPalette field of the About resource. If an unsupported color is specified, it will be changed to the closest color in the palette. Not populated for items in shared drives.
4958 &quot;fullFileExtension&quot;: &quot;A String&quot;, # The full file extension; extracted from the title. May contain multiple concatenated extensions, such as &quot;tar.gz&quot;. Removing an extension from the title does not clear this field; however, changing the extension on the title does update this field. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4959 &quot;hasAugmentedPermissions&quot;: True or False, # Whether there are permissions directly on this file. This field is only populated for items in shared drives.
4960 &quot;hasThumbnail&quot;: True or False, # Whether this file has a thumbnail. This does not indicate whether the requesting app has access to the thumbnail. To check access, look for the presence of the thumbnailLink field.
4961 &quot;headRevisionId&quot;: &quot;A String&quot;, # The ID of the file&#x27;s head revision. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
4962 &quot;iconLink&quot;: &quot;A String&quot;, # A link to the file&#x27;s icon.
4963 &quot;id&quot;: &quot;A String&quot;, # The ID of the file.
4964 &quot;imageMediaMetadata&quot;: { # Metadata about image media. This will only be present for image types, and its contents will depend on what can be parsed from the image content.
4965 &quot;aperture&quot;: 3.14, # The aperture used to create the photo (f-number).
4966 &quot;cameraMake&quot;: &quot;A String&quot;, # The make of the camera used to create the photo.
4967 &quot;cameraModel&quot;: &quot;A String&quot;, # The model of the camera used to create the photo.
4968 &quot;colorSpace&quot;: &quot;A String&quot;, # The color space of the photo.
4969 &quot;date&quot;: &quot;A String&quot;, # The date and time the photo was taken (EXIF format timestamp).
4970 &quot;exposureBias&quot;: 3.14, # The exposure bias of the photo (APEX value).
4971 &quot;exposureMode&quot;: &quot;A String&quot;, # The exposure mode used to create the photo.
4972 &quot;exposureTime&quot;: 3.14, # The length of the exposure, in seconds.
4973 &quot;flashUsed&quot;: True or False, # Whether a flash was used to create the photo.
4974 &quot;focalLength&quot;: 3.14, # The focal length used to create the photo, in millimeters.
4975 &quot;height&quot;: 42, # The height of the image in pixels.
4976 &quot;isoSpeed&quot;: 42, # The ISO speed used to create the photo.
4977 &quot;lens&quot;: &quot;A String&quot;, # The lens used to create the photo.
4978 &quot;location&quot;: { # Geographic location information stored in the image.
4979 &quot;altitude&quot;: 3.14, # The altitude stored in the image.
4980 &quot;latitude&quot;: 3.14, # The latitude stored in the image.
4981 &quot;longitude&quot;: 3.14, # The longitude stored in the image.
4982 },
4983 &quot;maxApertureValue&quot;: 3.14, # The smallest f-number of the lens at the focal length used to create the photo (APEX value).
4984 &quot;meteringMode&quot;: &quot;A String&quot;, # The metering mode used to create the photo.
4985 &quot;rotation&quot;: 42, # The number of clockwise 90 degree rotations applied from the image&#x27;s original orientation.
4986 &quot;sensor&quot;: &quot;A String&quot;, # The type of sensor used to create the photo.
4987 &quot;subjectDistance&quot;: 42, # The distance to the subject of the photo, in meters.
4988 &quot;whiteBalance&quot;: &quot;A String&quot;, # The white balance mode used to create the photo.
4989 &quot;width&quot;: 42, # The width of the image in pixels.
4990 },
4991 &quot;indexableText&quot;: { # Indexable text attributes for the file (can only be written)
4992 &quot;text&quot;: &quot;A String&quot;, # The text to be indexed for this file.
4993 },
4994 &quot;isAppAuthorized&quot;: True or False, # Whether the file was created or opened by the requesting app.
4995 &quot;kind&quot;: &quot;drive#file&quot;, # The type of file. This is always drive#file.
4996 &quot;labels&quot;: { # A group of labels for the file.
4997 &quot;hidden&quot;: True or False, # Deprecated.
4998 &quot;modified&quot;: True or False, # Whether the file has been modified by this user.
4999 &quot;restricted&quot;: True or False, # Deprecated - use copyRequiresWriterPermission instead.
5000 &quot;starred&quot;: True or False, # Whether this file is starred by the user.
5001 &quot;trashed&quot;: True or False, # Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file.
5002 &quot;viewed&quot;: True or False, # Whether this file has been viewed by this user.
5003 },
5004 &quot;lastModifyingUser&quot;: { # Information about a Drive user. # The last user to modify this file.
5005 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
5006 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
5007 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
5008 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
5009 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
5010 &quot;picture&quot;: { # The user&#x27;s profile picture.
5011 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
5012 },
5013 },
5014 &quot;lastModifyingUserName&quot;: &quot;A String&quot;, # Name of the last user to modify this file.
5015 &quot;lastViewedByMeDate&quot;: &quot;A String&quot;, # Last time this file was viewed by the user (formatted RFC 3339 timestamp).
5016 &quot;markedViewedByMeDate&quot;: &quot;A String&quot;, # Deprecated.
5017 &quot;md5Checksum&quot;: &quot;A String&quot;, # An MD5 checksum for the content of this file. This field is only populated for files with content stored in Google Drive; it is not populated for Docs Editors or shortcut files.
5018 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the file. This is only mutable on update when uploading new content. This field can be left blank, and the mimetype will be determined from the uploaded content&#x27;s MIME type.
5019 &quot;modifiedByMeDate&quot;: &quot;A String&quot;, # Last time this file was modified by the user (formatted RFC 3339 timestamp). Note that setting modifiedDate will also update the modifiedByMe date for the user which set the date.
5020 &quot;modifiedDate&quot;: &quot;A String&quot;, # Last time this file was modified by anyone (formatted RFC 3339 timestamp). This is only mutable on update when the setModifiedDate parameter is set.
5021 &quot;openWithLinks&quot;: { # A map of the id of each of the user&#x27;s apps to a link to open this file with that app. Only populated when the drive.apps.readonly scope is used.
5022 &quot;a_key&quot;: &quot;A String&quot;,
5023 },
5024 &quot;originalFilename&quot;: &quot;A String&quot;, # The original filename of the uploaded content if available, or else the original value of the title field. This is only available for files with binary content in Google Drive.
5025 &quot;ownedByMe&quot;: True or False, # Whether the file is owned by the current user. Not populated for items in shared drives.
5026 &quot;ownerNames&quot;: [ # Name(s) of the owner(s) of this file. Not populated for items in shared drives.
5027 &quot;A String&quot;,
5028 ],
5029 &quot;owners&quot;: [ # The owner(s) of this file. Not populated for items in shared drives.
5030 { # Information about a Drive user.
Bu Sun Kim65020912020-05-20 12:08:20 -07005031 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
5032 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
5033 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
5034 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
5035 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
5036 &quot;picture&quot;: { # The user&#x27;s profile picture.
5037 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
5038 },
Takashi Matsuo06694102015-09-11 13:55:40 -07005039 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005040 ],
5041 &quot;parents&quot;: [ # Collection of parent folders which contain this file.
5042 # If not specified as part of an insert request, the file will be placed directly in the user&#x27;s My Drive folder. If not specified as part of a copy request, the file will inherit any discoverable parents of the source file. Update requests can also use the addParents and removeParents parameters to modify the parents list.
5043 { # A reference to a file&#x27;s parent.
5044 &quot;id&quot;: &quot;A String&quot;, # The ID of the parent.
5045 &quot;isRoot&quot;: True or False, # Whether or not the parent is the root folder.
5046 &quot;kind&quot;: &quot;drive#parentReference&quot;, # This is always drive#parentReference.
5047 &quot;parentLink&quot;: &quot;A String&quot;, # A link to the parent.
5048 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this reference.
Bu Sun Kim65020912020-05-20 12:08:20 -07005049 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005050 ],
5051 &quot;permissionIds&quot;: [ # List of permission IDs for users with access to this file.
5052 &quot;A String&quot;,
5053 ],
5054 &quot;permissions&quot;: [ # The list of permissions for users with access to this file. Not populated for items in shared drives.
5055 { # A permission for a file.
Bu Sun Kim65020912020-05-20 12:08:20 -07005056 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
5057 &quot;A String&quot;,
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04005058 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07005059 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
5060 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
5061 &quot;domain&quot;: &quot;A String&quot;, # 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.
5062 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
5063 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
5064 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
Dan O'Mearadd494642020-05-01 07:42:23 -07005065 # - They cannot be set on shared drive items
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04005066 # - They can only be set on user and group permissions
5067 # - The date must be in the future
5068 # - The date cannot be more than a year in the future
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07005069 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
Bu Sun Kim65020912020-05-20 12:08:20 -07005070 &quot;id&quot;: &quot;A String&quot;, # 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.
5071 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
5072 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
5073 &quot;permissionDetails&quot;: [ # 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.
5074 {
5075 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
5076 &quot;A String&quot;,
5077 ],
5078 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
5079 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
5080 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
5081 # - file
5082 # - member
5083 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
5084 # - organizer
5085 # - fileOrganizer
5086 # - writer
5087 # - reader
5088 },
5089 ],
5090 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
5091 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
John Asmuth614db982014-04-24 15:46:26 -04005092 # - owner
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07005093 # - organizer
5094 # - fileOrganizer
John Asmuth614db982014-04-24 15:46:26 -04005095 # - writer
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07005096 # - reader
Bu Sun Kim65020912020-05-20 12:08:20 -07005097 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
5098 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
5099 {
5100 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
5101 &quot;A String&quot;,
5102 ],
5103 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
5104 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
5105 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
5106 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
5107 },
5108 ],
5109 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
John Asmuth614db982014-04-24 15:46:26 -04005110 # - user
5111 # - group
5112 # - domain
5113 # - anyone
Bu Sun Kim65020912020-05-20 12:08:20 -07005114 &quot;value&quot;: &quot;A String&quot;, # 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.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07005115 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
Bu Sun Kim65020912020-05-20 12:08:20 -07005116 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
John Asmuth614db982014-04-24 15:46:26 -04005117 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005118 ],
5119 &quot;properties&quot;: [ # The list of properties.
5120 { # A key-value pair attached to a file that is either public or private to an application.
5121 # The following limits apply to file properties:
5122 # - Maximum of 100 properties total per file
5123 # - Maximum of 30 private properties per app
5124 # - Maximum of 30 public properties
5125 # - Maximum of 124 bytes size limit on (key + value) string in UTF-8 encoding for a single property.
5126 &quot;etag&quot;: &quot;A String&quot;, # ETag of the property.
5127 &quot;key&quot;: &quot;A String&quot;, # The key of this property.
5128 &quot;kind&quot;: &quot;drive#property&quot;, # This is always drive#property.
5129 &quot;selfLink&quot;: &quot;A String&quot;, # The link back to this property.
5130 &quot;value&quot;: &quot;A String&quot;, # The value of this property.
yoshi-code-bot69706592021-03-03 03:54:02 -08005131 &quot;visibility&quot;: &quot;A String&quot;, # The visibility of this property. Allowed values are PRIVATE and PUBLIC. (Default: PRIVATE). Private properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties.
Bu Sun Kim65020912020-05-20 12:08:20 -07005132 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005133 ],
5134 &quot;quotaBytesUsed&quot;: &quot;A String&quot;, # The number of quota bytes used by this file.
5135 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this file.
5136 &quot;shareable&quot;: True or False, # Deprecated: use capabilities/canShare.
5137 &quot;shared&quot;: True or False, # Whether the file has been shared. Not populated for items in shared drives.
5138 &quot;sharedWithMeDate&quot;: &quot;A String&quot;, # Time at which this file was shared with the user (formatted RFC 3339 timestamp).
5139 &quot;sharingUser&quot;: { # Information about a Drive user. # User that shared the item with the current user, if available.
5140 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
5141 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
5142 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
5143 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
5144 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
5145 &quot;picture&quot;: { # The user&#x27;s profile picture.
5146 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
5147 },
5148 },
5149 &quot;shortcutDetails&quot;: { # Shortcut file details. Only populated for shortcut files, which have the mimeType field set to application/vnd.google-apps.shortcut.
5150 &quot;targetId&quot;: &quot;A String&quot;, # The ID of the file that this shortcut points to.
5151 &quot;targetMimeType&quot;: &quot;A String&quot;, # The MIME type of the file that this shortcut points to. The value of this field is a snapshot of the target&#x27;s MIME type, captured when the shortcut is created.
5152 },
5153 &quot;spaces&quot;: [ # The list of spaces which contain the file. Supported values are &#x27;drive&#x27;, &#x27;appDataFolder&#x27; and &#x27;photos&#x27;.
5154 &quot;A String&quot;,
5155 ],
5156 &quot;teamDriveId&quot;: &quot;A String&quot;, # Deprecated - use driveId instead.
5157 &quot;thumbnail&quot;: { # A thumbnail for the file. This will only be used if a standard thumbnail cannot be generated.
5158 &quot;image&quot;: &quot;A String&quot;, # The URL-safe Base64 encoded bytes of the thumbnail image. It should conform to RFC 4648 section 5.
5159 &quot;mimeType&quot;: &quot;A String&quot;, # The MIME type of the thumbnail.
5160 },
5161 &quot;thumbnailLink&quot;: &quot;A String&quot;, # A short-lived link to the file&#x27;s thumbnail. Typically lasts on the order of hours. Only populated when the requesting app can access the file&#x27;s content. If the file isn&#x27;t shared publicly, the URL returned in Files.thumbnailLink must be fetched using a credentialed request.
5162 &quot;thumbnailVersion&quot;: &quot;A String&quot;, # The thumbnail version for use in thumbnail cache invalidation.
5163 &quot;title&quot;: &quot;A String&quot;, # The title of this file. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the title is constant.
5164 &quot;trashedDate&quot;: &quot;A String&quot;, # The time that the item was trashed (formatted RFC 3339 timestamp). Only populated for items in shared drives.
5165 &quot;trashingUser&quot;: { # Information about a Drive user. # If the file has been explicitly trashed, the user who trashed it. Only populated for items in shared drives.
5166 &quot;displayName&quot;: &quot;A String&quot;, # A plain text displayable name for this user.
5167 &quot;emailAddress&quot;: &quot;A String&quot;, # The email address of the user.
5168 &quot;isAuthenticatedUser&quot;: True or False, # Whether this user is the same as the authenticated user for whom the request was made.
5169 &quot;kind&quot;: &quot;drive#user&quot;, # This is always drive#user.
5170 &quot;permissionId&quot;: &quot;A String&quot;, # The user&#x27;s ID as visible in the permissions collection.
5171 &quot;picture&quot;: { # The user&#x27;s profile picture.
5172 &quot;url&quot;: &quot;A String&quot;, # A URL that points to a profile picture of this user.
5173 },
5174 },
5175 &quot;userPermission&quot;: { # A permission for a file. # The permissions for the authenticated user on this file.
5176 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently allowed, though more may be supported in the future.
5177 &quot;A String&quot;,
5178 ],
5179 &quot;authKey&quot;: &quot;A String&quot;, # Deprecated.
5180 &quot;deleted&quot;: True or False, # Whether the account associated with this permission has been deleted. This field only pertains to user and group permissions.
5181 &quot;domain&quot;: &quot;A String&quot;, # 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.
5182 &quot;emailAddress&quot;: &quot;A String&quot;, # 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.
5183 &quot;etag&quot;: &quot;A String&quot;, # The ETag of the permission.
5184 &quot;expirationDate&quot;: &quot;A String&quot;, # The time at which this permission will expire (RFC 3339 date-time). Expiration dates have the following restrictions:
5185 # - They cannot be set on shared drive items
5186 # - They can only be set on user and group permissions
5187 # - The date must be in the future
5188 # - The date cannot be more than a year in the future
5189 # - The date can only be set on drive.permissions.update or drive.permissions.patch requests
5190 &quot;id&quot;: &quot;A String&quot;, # 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.
5191 &quot;kind&quot;: &quot;drive#permission&quot;, # This is always drive#permission.
5192 &quot;name&quot;: &quot;A String&quot;, # The name for this permission.
5193 &quot;permissionDetails&quot;: [ # 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.
5194 {
5195 &quot;additionalRoles&quot;: [ # Additional roles for this user. Only commenter is currently possible, though more may be supported in the future.
5196 &quot;A String&quot;,
5197 ],
5198 &quot;inherited&quot;: True or False, # Whether this permission is inherited. This field is always populated. This is an output-only field.
5199 &quot;inheritedFrom&quot;: &quot;A String&quot;, # The ID of the item from which this permission is inherited. This is an output-only field.
5200 &quot;permissionType&quot;: &quot;A String&quot;, # The permission type for this user. While new values may be added in future, the following are currently possible:
5201 # - file
5202 # - member
5203 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be added in the future, the following are currently possible:
5204 # - organizer
5205 # - fileOrganizer
5206 # - writer
5207 # - reader
5208 },
5209 ],
5210 &quot;photoLink&quot;: &quot;A String&quot;, # A link to the profile photo, if available.
5211 &quot;role&quot;: &quot;A String&quot;, # The primary role for this user. While new values may be supported in the future, the following are currently allowed:
5212 # - owner
5213 # - organizer
5214 # - fileOrganizer
5215 # - writer
5216 # - reader
5217 &quot;selfLink&quot;: &quot;A String&quot;, # A link back to this permission.
5218 &quot;teamDrivePermissionDetails&quot;: [ # Deprecated - use permissionDetails instead.
5219 {
5220 &quot;additionalRoles&quot;: [ # Deprecated - use permissionDetails/additionalRoles instead.
5221 &quot;A String&quot;,
5222 ],
5223 &quot;inherited&quot;: True or False, # Deprecated - use permissionDetails/inherited instead.
5224 &quot;inheritedFrom&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/inheritedFrom instead.
5225 &quot;role&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/role instead.
5226 &quot;teamDrivePermissionType&quot;: &quot;A String&quot;, # Deprecated - use permissionDetails/permissionType instead.
5227 },
5228 ],
5229 &quot;type&quot;: &quot;A String&quot;, # The account type. Allowed values are:
5230 # - user
5231 # - group
5232 # - domain
5233 # - anyone
5234 &quot;value&quot;: &quot;A String&quot;, # 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.
5235 &quot;view&quot;: &quot;A String&quot;, # Indicates the view for this permission. Only populated for permissions that belong to a view. published is the only supported value.
5236 &quot;withLink&quot;: True or False, # Whether the link is required for this permission.
5237 },
5238 &quot;version&quot;: &quot;A String&quot;, # A monotonically increasing version number for the file. This reflects every change made to the file on the server, even those not visible to the requesting user.
5239 &quot;videoMediaMetadata&quot;: { # Metadata about video media. This will only be present for video types.
5240 &quot;durationMillis&quot;: &quot;A String&quot;, # The duration of the video in milliseconds.
5241 &quot;height&quot;: 42, # The height of the video in pixels.
5242 &quot;width&quot;: 42, # The width of the video in pixels.
5243 },
5244 &quot;webContentLink&quot;: &quot;A String&quot;, # A link for downloading the content of the file in a browser using cookie based authentication. In cases where the content is shared publicly, the content can be downloaded without any credentials.
5245 &quot;webViewLink&quot;: &quot;A String&quot;, # A link only available on public folders for viewing their static web assets (HTML, CSS, JS, etc) via Google Drive&#x27;s Website Hosting.
5246 &quot;writersCanShare&quot;: True or False, # Whether writers can share the document with other users. Not populated for items in shared drives.
5247}</pre>
John Asmuth614db982014-04-24 15:46:26 -04005248</div>
5249
5250<div class="method">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005251 <code class="details" id="watch">watch(fileId, acknowledgeAbuse=None, body=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</code>
John Asmuth614db982014-04-24 15:46:26 -04005252 <pre>Subscribe to changes on a file
5253
5254Args:
5255 fileId: string, The ID for the file in question. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07005256 body: object, The request body.
John Asmuth614db982014-04-24 15:46:26 -04005257 The object takes the form of:
5258
5259{ # An notification channel used to watch for resource changes.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005260 &quot;address&quot;: &quot;A String&quot;, # The address where notifications are delivered for this channel.
5261 &quot;expiration&quot;: &quot;A String&quot;, # Date and time of notification channel expiration, expressed as a Unix timestamp, in milliseconds. Optional.
5262 &quot;id&quot;: &quot;A String&quot;, # A UUID or similar unique string that identifies this channel.
5263 &quot;kind&quot;: &quot;api#channel&quot;, # Identifies this as a notification channel used to watch for changes to a resource, which is &quot;api#channel&quot;.
5264 &quot;params&quot;: { # Additional parameters controlling delivery channel behavior. Optional.
5265 &quot;a_key&quot;: &quot;A String&quot;, # Declares a new parameter by name.
5266 },
5267 &quot;payload&quot;: True or False, # A Boolean value to indicate whether payload is wanted. Optional.
5268 &quot;resourceId&quot;: &quot;A String&quot;, # An opaque ID that identifies the resource being watched on this channel. Stable across different API versions.
5269 &quot;resourceUri&quot;: &quot;A String&quot;, # A version-specific identifier for the watched resource.
5270 &quot;token&quot;: &quot;A String&quot;, # An arbitrary string delivered to the target address with each notification delivered over this channel. Optional.
yoshi-code-bota8b35b92021-03-31 13:33:30 -07005271 &quot;type&quot;: &quot;A String&quot;, # The type of delivery mechanism used for this channel. Valid values are &quot;web_hook&quot; (or &quot;webhook&quot;). Both values refer to a channel where Http requests are used to deliver messages.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005272}
John Asmuth614db982014-04-24 15:46:26 -04005273
Bu Sun Kim65020912020-05-20 12:08:20 -07005274 acknowledgeAbuse: boolean, Whether the user is acknowledging the risk of downloading known malware or other abusive files.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07005275 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
John Asmuth614db982014-04-24 15:46:26 -04005276 projection: string, This parameter is deprecated and has no function.
5277 Allowed values
5278 BASIC - Deprecated
5279 FULL - Deprecated
Nathaniel Manista4f877e52015-06-15 16:44:50 +00005280 revisionId: string, Specifies the Revision ID that should be downloaded. Ignored unless alt=media is specified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005281 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07005282 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
Sai Cheemalapatidf613972016-10-21 13:59:49 -07005283 updateViewedDate: boolean, Deprecated: Use files.update with modifiedDateBehavior=noChange, updateViewedDate=true and an empty request body.
John Asmuth614db982014-04-24 15:46:26 -04005284
5285Returns:
5286 An object of the form:
5287
5288 { # An notification channel used to watch for resource changes.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005289 &quot;address&quot;: &quot;A String&quot;, # The address where notifications are delivered for this channel.
5290 &quot;expiration&quot;: &quot;A String&quot;, # Date and time of notification channel expiration, expressed as a Unix timestamp, in milliseconds. Optional.
5291 &quot;id&quot;: &quot;A String&quot;, # A UUID or similar unique string that identifies this channel.
5292 &quot;kind&quot;: &quot;api#channel&quot;, # Identifies this as a notification channel used to watch for changes to a resource, which is &quot;api#channel&quot;.
5293 &quot;params&quot;: { # Additional parameters controlling delivery channel behavior. Optional.
5294 &quot;a_key&quot;: &quot;A String&quot;, # Declares a new parameter by name.
5295 },
5296 &quot;payload&quot;: True or False, # A Boolean value to indicate whether payload is wanted. Optional.
5297 &quot;resourceId&quot;: &quot;A String&quot;, # An opaque ID that identifies the resource being watched on this channel. Stable across different API versions.
5298 &quot;resourceUri&quot;: &quot;A String&quot;, # A version-specific identifier for the watched resource.
5299 &quot;token&quot;: &quot;A String&quot;, # An arbitrary string delivered to the target address with each notification delivered over this channel. Optional.
yoshi-code-bota8b35b92021-03-31 13:33:30 -07005300 &quot;type&quot;: &quot;A String&quot;, # The type of delivery mechanism used for this channel. Valid values are &quot;web_hook&quot; (or &quot;webhook&quot;). Both values refer to a channel where Http requests are used to deliver messages.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005301}</pre>
John Asmuth614db982014-04-24 15:46:26 -04005302</div>
5303
Craig Citroe633be12015-03-02 13:40:36 -08005304<div class="method">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005305 <code class="details" id="watch_media">watch_media(fileId, acknowledgeAbuse=None, body=None, includePermissionsForView=None, projection=None, revisionId=None, supportsAllDrives=None, supportsTeamDrives=None, updateViewedDate=None)</code>
Craig Citroe633be12015-03-02 13:40:36 -08005306 <pre>Subscribe to changes on a file
5307
5308Args:
5309 fileId: string, The ID for the file in question. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07005310 body: object, The request body.
Craig Citroe633be12015-03-02 13:40:36 -08005311 The object takes the form of:
5312
5313{ # An notification channel used to watch for resource changes.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005314 &quot;address&quot;: &quot;A String&quot;, # The address where notifications are delivered for this channel.
5315 &quot;expiration&quot;: &quot;A String&quot;, # Date and time of notification channel expiration, expressed as a Unix timestamp, in milliseconds. Optional.
5316 &quot;id&quot;: &quot;A String&quot;, # A UUID or similar unique string that identifies this channel.
5317 &quot;kind&quot;: &quot;api#channel&quot;, # Identifies this as a notification channel used to watch for changes to a resource, which is &quot;api#channel&quot;.
5318 &quot;params&quot;: { # Additional parameters controlling delivery channel behavior. Optional.
5319 &quot;a_key&quot;: &quot;A String&quot;, # Declares a new parameter by name.
5320 },
5321 &quot;payload&quot;: True or False, # A Boolean value to indicate whether payload is wanted. Optional.
5322 &quot;resourceId&quot;: &quot;A String&quot;, # An opaque ID that identifies the resource being watched on this channel. Stable across different API versions.
5323 &quot;resourceUri&quot;: &quot;A String&quot;, # A version-specific identifier for the watched resource.
5324 &quot;token&quot;: &quot;A String&quot;, # An arbitrary string delivered to the target address with each notification delivered over this channel. Optional.
yoshi-code-bota8b35b92021-03-31 13:33:30 -07005325 &quot;type&quot;: &quot;A String&quot;, # The type of delivery mechanism used for this channel. Valid values are &quot;web_hook&quot; (or &quot;webhook&quot;). Both values refer to a channel where Http requests are used to deliver messages.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -08005326}
Craig Citroe633be12015-03-02 13:40:36 -08005327
Bu Sun Kim65020912020-05-20 12:08:20 -07005328 acknowledgeAbuse: boolean, Whether the user is acknowledging the risk of downloading known malware or other abusive files.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07005329 includePermissionsForView: string, Specifies which additional view&#x27;s permissions to include in the response. Only &#x27;published&#x27; is supported.
Craig Citroe633be12015-03-02 13:40:36 -08005330 projection: string, This parameter is deprecated and has no function.
5331 Allowed values
5332 BASIC - Deprecated
5333 FULL - Deprecated
Nathaniel Manista4f877e52015-06-15 16:44:50 +00005334 revisionId: string, Specifies the Revision ID that should be downloaded. Ignored unless alt=media is specified.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005335 supportsAllDrives: boolean, Whether the requesting application supports both My Drives and shared drives.
Bu Sun Kim65020912020-05-20 12:08:20 -07005336 supportsTeamDrives: boolean, Deprecated use supportsAllDrives instead.
Sai Cheemalapatidf613972016-10-21 13:59:49 -07005337 updateViewedDate: boolean, Deprecated: Use files.update with modifiedDateBehavior=noChange, updateViewedDate=true and an empty request body.
Craig Citroe633be12015-03-02 13:40:36 -08005338
5339Returns:
5340 The media object as a string.
5341
5342 </pre>
5343</div>
5344
John Asmuth614db982014-04-24 15:46:26 -04005345</body></html>