Skip to content

Commit a22e854

Browse files
feat(drive): update the API
#### drive:v2 The following keys were added: - schemas.User.properties.displayName.readOnly - schemas.User.properties.emailAddress.readOnly - schemas.User.properties.isAuthenticatedUser.readOnly - schemas.User.properties.kind.readOnly - schemas.User.properties.permissionId.readOnly - schemas.User.properties.picture.properties.url.readOnly - schemas.User.properties.picture.readOnly The following keys were changed: - documentationLink - resources.drives.methods.list.description - resources.files.methods.get.description - resources.files.methods.insert.description - resources.files.methods.list.description - resources.files.methods.update.description - schemas.Comment.properties.anchor.description - schemas.User.properties.emailAddress.description - schemas.User.properties.kind.description - schemas.User.properties.permissionId.description - schemas.User.properties.picture.properties.url.description #### drive:v3 The following keys were added: - schemas.User.properties.displayName.readOnly - schemas.User.properties.emailAddress.readOnly - schemas.User.properties.kind.readOnly - schemas.User.properties.me.readOnly - schemas.User.properties.permissionId.readOnly - schemas.User.properties.photoLink.readOnly The following keys were changed: - documentationLink - resources.about.methods.get.description - resources.apps.methods.get.description - resources.apps.methods.list.description - resources.changes.methods.getStartPageToken.description - resources.changes.methods.list.description - resources.changes.methods.watch.description - resources.channels.methods.stop.description - resources.comments.methods.create.description - resources.comments.methods.delete.description - resources.comments.methods.get.description - resources.comments.methods.list.description - resources.comments.methods.update.description - resources.drives.methods.list.description - resources.files.methods.create.description - resources.files.methods.get.description - resources.files.methods.list.description - resources.files.methods.update.description - schemas.Comment.properties.anchor.description - schemas.Permission.description - schemas.User.properties.kind.description
1 parent 5c9ffdb commit a22e854

File tree

4 files changed

+76
-63
lines changed

4 files changed

+76
-63
lines changed

‎discovery/drive-v2.json

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
"batchPath": "batch/drive/v2",
4141
"description": "The Google Drive API allows clients to access resources from Google Drive.",
4242
"discoveryVersion": "v1",
43-
"documentationLink": "https://developers.google.com/drive/",
43+
"documentationLink": "https://developers.google.com/workspace/drive/",
4444
"icons": {
4545
"x16": "http://www.google.com/images/icons/product/search-16.gif",
4646
"x32": "http://www.google.com/images/icons/product/search-32.gif"
@@ -1134,7 +1134,7 @@
11341134
]
11351135
},
11361136
"list": {
1137-
"description": " Lists the user's shared drives. This method accepts the `q` parameter, which is a search query combining one or more search terms. For more information, see the [Search for shared drives](/drive/api/guides/search-shareddrives) guide.",
1137+
"description": " Lists the user's shared drives. This method accepts the `q` parameter, which is a search query combining one or more search terms. For more information, see the [Search for shared drives](/workspace/drive/api/guides/search-shareddrives) guide.",
11381138
"flatPath": "drives",
11391139
"httpMethod": "GET",
11401140
"id": "drive.drives.list",
@@ -1485,7 +1485,7 @@
14851485
]
14861486
},
14871487
"get": {
1488-
"description": " Gets a file's metadata or content by ID. If you provide the URL parameter `alt=media`, then the response includes the file contents in the response body. Downloading content with `alt=media` only works if the file is stored in Drive. To download Google Docs, Sheets, and Slides use [`files.export`](/drive/api/reference/rest/v2/files/export) instead. For more information, see [Download & export files](/drive/api/guides/manage-downloads).",
1488+
"description": " Gets a file's metadata or content by ID. If you provide the URL parameter `alt=media`, then the response includes the file contents in the response body. Downloading content with `alt=media` only works if the file is stored in Drive. To download Google Docs, Sheets, and Slides use [`files.export`](/workspace/drive/api/reference/rest/v2/files/export) instead. For more information, see [Download & export files](/workspace/drive/api/guides/manage-downloads).",
14891489
"flatPath": "files/{fileId}",
14901490
"httpMethod": "GET",
14911491
"id": "drive.files.get",
@@ -1574,7 +1574,7 @@
15741574
"useMediaDownloadService": true
15751575
},
15761576
"insert": {
1577-
"description": " Inserts a new file. This method supports an */upload* URI and accepts uploaded media with the following characteristics: - *Maximum file size:* 5,120 GB - *Accepted Media MIME types:*`*/*` Note: Specify a valid MIME type, rather than the literal `*/*` value. The literal `*/*` is only used to indicate that any valid MIME type can be uploaded. For more information on uploading files, see [Upload file data](/drive/api/guides/manage-uploads). Apps creating shortcuts with `files.insert` must specify the MIME type `application/vnd.google-apps.shortcut`. Apps should specify a file extension in the `title` property when inserting files with the API. For example, an operation to insert a JPEG file should specify something like `\"title\": \"cat.jpg\"` in the metadata. Subsequent `GET` requests include the read-only `fileExtension` property populated with the extension originally specified in the `title` property. When a Google Drive user requests to download a file, or when the file is downloaded through the sync client, Drive builds a full filename (with extension) based on the title. In cases where the extension is missing, Drive attempts to determine the extension based on the file's MIME type.",
1577+
"description": " Inserts a new file. This method supports an */upload* URI and accepts uploaded media with the following characteristics: - *Maximum file size:* 5,120 GB - *Accepted Media MIME types:*`*/*` Note: Specify a valid MIME type, rather than the literal `*/*` value. The literal `*/*` is only used to indicate that any valid MIME type can be uploaded. For more information on uploading files, see [Upload file data](/workspace/drive/api/guides/manage-uploads). Apps creating shortcuts with `files.insert` must specify the MIME type `application/vnd.google-apps.shortcut`. Apps should specify a file extension in the `title` property when inserting files with the API. For example, an operation to insert a JPEG file should specify something like `\"title\": \"cat.jpg\"` in the metadata. Subsequent `GET` requests include the read-only `fileExtension` property populated with the extension originally specified in the `title` property. When a Google Drive user requests to download a file, or when the file is downloaded through the sync client, Drive builds a full filename (with extension) based on the title. In cases where the extension is missing, Drive attempts to determine the extension based on the file's MIME type.",
15781578
"flatPath": "files",
15791579
"httpMethod": "POST",
15801580
"id": "drive.files.insert",
@@ -1696,7 +1696,7 @@
16961696
"supportsMediaUpload": true
16971697
},
16981698
"list": {
1699-
"description": " Lists the user's files. This method accepts the `q` parameter, which is a search query combining one or more search terms. For more information, see the [Search for files & folders](/drive/api/guides/search-files) guide. *Note:* This method returns *all* files by default, including trashed files. If you don't want trashed files to appear in the list, use the `trashed=false` query parameter to remove trashed files from the results.",
1699+
"description": " Lists the user's files. This method accepts the `q` parameter, which is a search query combining one or more search terms. For more information, see the [Search for files & folders](/workspace/drive/api/guides/search-files) guide. *Note:* This method returns *all* files by default, including trashed files. If you don't want trashed files to appear in the list, use the `trashed=false` query parameter to remove trashed files from the results.",
17001700
"flatPath": "files",
17011701
"httpMethod": "GET",
17021702
"id": "drive.files.list",
@@ -2202,7 +2202,7 @@
22022202
]
22032203
},
22042204
"update": {
2205-
"description": " Updates a file's metadata and/or content. When calling this method, only populate fields in the request that you want to modify. When updating fields, some fields might be changed automatically, such as `modifiedDate`. This method supports patch semantics. This method supports an */upload* URI and accepts uploaded media with the following characteristics: - *Maximum file size:* 5,120 GB - *Accepted Media MIME types:*`*/*` Note: Specify a valid MIME type, rather than the literal `*/*` value. The literal `*/*` is only used to indicate that any valid MIME type can be uploaded. For more information on uploading files, see [Upload file data](/drive/api/guides/manage-uploads).",
2205+
"description": " Updates a file's metadata and/or content. When calling this method, only populate fields in the request that you want to modify. When updating fields, some fields might be changed automatically, such as `modifiedDate`. This method supports patch semantics. This method supports an */upload* URI and accepts uploaded media with the following characteristics: - *Maximum file size:* 5,120 GB - *Accepted Media MIME types:*`*/*` Note: Specify a valid MIME type, rather than the literal `*/*` value. The literal `*/*` is only used to indicate that any valid MIME type can be uploaded. For more information on uploading files, see [Upload file data](/workspace/drive/api/guides/manage-uploads).",
22062206
"flatPath": "files/{fileId}",
22072207
"httpMethod": "PUT",
22082208
"id": "drive.files.update",
@@ -3887,7 +3887,7 @@
38873887
}
38883888
}
38893889
},
3890-
"revision": "20250216",
3890+
"revision": "20250427",
38913891
"rootUrl": "https://www.googleapis.com/",
38923892
"schemas": {
38933893
"About": {
@@ -4559,7 +4559,7 @@
45594559
"id": "Comment",
45604560
"properties": {
45614561
"anchor": {
4562-
"description": "A region of the document represented as a JSON string. For details on defining anchor properties, refer to [Add comments and replies](https://developers.google.com/drive/api/v2/manage-comments).",
4562+
"description": "A region of the document represented as a JSON string. For details on defining anchor properties, refer to [Add comments and replies](https://developers.google.com/workspace/drive/api/v2/manage-comments).",
45634563
"type": "string"
45644564
},
45654565
"author": {
@@ -6743,33 +6743,40 @@
67436743
"properties": {
67446744
"displayName": {
67456745
"description": "Output only. A plain text displayable name for this user.",
6746+
"readOnly": true,
67466747
"type": "string"
67476748
},
67486749
"emailAddress": {
6749-
"description": "Output only. The email address of the user.",
6750+
"description": "Output only. The email address of the user. This may not be present in certain contexts if the user has not made their email address visible to the requester.",
6751+
"readOnly": true,
67506752
"type": "string"
67516753
},
67526754
"isAuthenticatedUser": {
67536755
"description": "Output only. Whether this user is the same as the authenticated user for whom the request was made.",
6756+
"readOnly": true,
67546757
"type": "boolean"
67556758
},
67566759
"kind": {
67576760
"default": "drive#user",
6758-
"description": "Output only. This is always `drive#user`.",
6761+
"description": "Output only. Identifies what kind of resource this is. Value: the fixed string `drive#user`.",
6762+
"readOnly": true,
67596763
"type": "string"
67606764
},
67616765
"permissionId": {
6762-
"description": "Output only. The user's ID as visible in the permissions collection.",
6766+
"description": "Output only. The user's ID as visible in Permission resources.",
6767+
"readOnly": true,
67636768
"type": "string"
67646769
},
67656770
"picture": {
67666771
"description": "Output only. The user's profile picture.",
67676772
"properties": {
67686773
"url": {
6769-
"description": "Output Only. A URL that points to a profile picture of this user.",
6774+
"description": "Output only. A URL that points to a profile picture of this user.",
6775+
"readOnly": true,
67706776
"type": "string"
67716777
}
67726778
},
6779+
"readOnly": true,
67736780
"type": "object"
67746781
}
67756782
},

0 commit comments

Comments
 (0)