google-api-client 0.9.pre3 → 0.9.pre4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (307) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +1 -0
  3. data/CHANGELOG.md +14 -2
  4. data/Gemfile +4 -0
  5. data/MIGRATING.md +1 -1
  6. data/README.md +17 -3
  7. data/api_names.yaml +127 -14
  8. data/api_names_out.yaml +5442 -710
  9. data/bin/generate-api +16 -14
  10. data/generated/google/apis/adexchangebuyer_v1_3.rb +1 -1
  11. data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +213 -2
  12. data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +71 -0
  13. data/generated/google/apis/adexchangebuyer_v1_3/service.rb +21 -42
  14. data/generated/google/apis/adexchangeseller_v2_0.rb +1 -1
  15. data/generated/google/apis/adexchangeseller_v2_0/service.rb +15 -29
  16. data/generated/google/apis/admin_datatransfer_v1.rb +37 -0
  17. data/generated/google/apis/admin_datatransfer_v1/classes.rb +267 -0
  18. data/generated/google/apis/admin_datatransfer_v1/representations.rb +118 -0
  19. data/generated/google/apis/admin_datatransfer_v1/service.rb +262 -0
  20. data/generated/google/apis/admin_directory_v1.rb +25 -1
  21. data/generated/google/apis/admin_directory_v1/classes.rb +718 -0
  22. data/generated/google/apis/admin_directory_v1/representations.rb +244 -0
  23. data/generated/google/apis/admin_directory_v1/service.rb +1522 -509
  24. data/generated/google/apis/admin_reports_v1.rb +1 -1
  25. data/generated/google/apis/admin_reports_v1/service.rb +5 -10
  26. data/generated/google/apis/adsense_v1_4.rb +1 -1
  27. data/generated/google/apis/adsense_v1_4/classes.rb +6 -0
  28. data/generated/google/apis/adsense_v1_4/representations.rb +1 -0
  29. data/generated/google/apis/adsense_v1_4/service.rb +40 -78
  30. data/generated/google/apis/adsensehost_v4_1.rb +1 -1
  31. data/generated/google/apis/adsensehost_v4_1/service.rb +26 -52
  32. data/generated/google/apis/analytics_v3.rb +1 -1
  33. data/generated/google/apis/analytics_v3/classes.rb +11 -13
  34. data/generated/google/apis/analytics_v3/service.rb +84 -158
  35. data/generated/google/apis/androidenterprise_v1.rb +2 -2
  36. data/generated/google/apis/androidenterprise_v1/classes.rb +276 -8
  37. data/generated/google/apis/androidenterprise_v1/representations.rb +106 -0
  38. data/generated/google/apis/androidenterprise_v1/service.rb +715 -97
  39. data/generated/google/apis/androidpublisher_v2.rb +1 -1
  40. data/generated/google/apis/androidpublisher_v2/classes.rb +2 -2
  41. data/generated/google/apis/androidpublisher_v2/service.rb +55 -107
  42. data/generated/google/apis/appengine_v1beta4.rb +35 -0
  43. data/generated/google/apis/appengine_v1beta4/classes.rb +1532 -0
  44. data/generated/google/apis/appengine_v1beta4/representations.rb +526 -0
  45. data/generated/google/apis/appengine_v1beta4/service.rb +476 -0
  46. data/generated/google/apis/appsactivity_v1.rb +1 -1
  47. data/generated/google/apis/appsactivity_v1/service.rb +1 -2
  48. data/generated/google/apis/appstate_v1.rb +1 -1
  49. data/generated/google/apis/appstate_v1/service.rb +6 -11
  50. data/generated/google/apis/autoscaler_v1beta2/service.rb +10 -20
  51. data/generated/google/apis/bigquery_v2.rb +4 -1
  52. data/generated/google/apis/bigquery_v2/classes.rb +231 -16
  53. data/generated/google/apis/bigquery_v2/representations.rb +62 -0
  54. data/generated/google/apis/bigquery_v2/service.rb +24 -45
  55. data/generated/google/apis/blogger_v3/service.rb +33 -66
  56. data/generated/google/apis/books_v1.rb +1 -1
  57. data/generated/google/apis/books_v1/classes.rb +441 -0
  58. data/generated/google/apis/books_v1/representations.rb +177 -0
  59. data/generated/google/apis/books_v1/service.rb +210 -90
  60. data/generated/google/apis/calendar_v3.rb +1 -1
  61. data/generated/google/apis/calendar_v3/classes.rb +34 -18
  62. data/generated/google/apis/calendar_v3/service.rb +118 -103
  63. data/generated/google/apis/civicinfo_v2.rb +1 -1
  64. data/generated/google/apis/civicinfo_v2/classes.rb +12 -3
  65. data/generated/google/apis/civicinfo_v2/representations.rb +1 -0
  66. data/generated/google/apis/civicinfo_v2/service.rb +5 -10
  67. data/generated/google/apis/classroom_v1.rb +49 -0
  68. data/generated/google/apis/classroom_v1/classes.rb +512 -0
  69. data/generated/google/apis/classroom_v1/representations.rb +217 -0
  70. data/generated/google/apis/classroom_v1/service.rb +970 -0
  71. data/generated/google/apis/cloudbilling_v1.rb +35 -0
  72. data/generated/google/apis/cloudbilling_v1/classes.rb +169 -0
  73. data/generated/google/apis/cloudbilling_v1/representations.rb +79 -0
  74. data/generated/google/apis/cloudbilling_v1/service.rb +258 -0
  75. data/generated/google/apis/clouddebugger_v2.rb +41 -0
  76. data/generated/google/apis/clouddebugger_v2/classes.rb +1004 -0
  77. data/generated/google/apis/clouddebugger_v2/representations.rb +410 -0
  78. data/generated/google/apis/clouddebugger_v2/service.rb +370 -0
  79. data/generated/google/apis/cloudmonitoring_v2beta2.rb +1 -1
  80. data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +6 -12
  81. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +5 -2
  82. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +173 -249
  83. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +36 -68
  84. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +293 -80
  85. data/generated/google/apis/cloudtrace_v1.rb +35 -0
  86. data/generated/google/apis/cloudtrace_v1/classes.rb +188 -0
  87. data/generated/google/apis/cloudtrace_v1/representations.rb +92 -0
  88. data/generated/google/apis/cloudtrace_v1/service.rb +190 -0
  89. data/generated/google/apis/clouduseraccounts_beta.rb +43 -0
  90. data/generated/google/apis/clouduseraccounts_beta/classes.rb +823 -0
  91. data/generated/google/apis/clouduseraccounts_beta/representations.rb +313 -0
  92. data/generated/google/apis/clouduseraccounts_beta/service.rb +854 -0
  93. data/generated/google/apis/compute_beta.rb +49 -0
  94. data/generated/google/apis/compute_beta/classes.rb +9128 -0
  95. data/generated/google/apis/compute_beta/representations.rb +3048 -0
  96. data/generated/google/apis/compute_beta/service.rb +10154 -0
  97. data/generated/google/apis/compute_v1.rb +1 -1
  98. data/generated/google/apis/compute_v1/classes.rb +1305 -520
  99. data/generated/google/apis/compute_v1/representations.rb +122 -15
  100. data/generated/google/apis/compute_v1/service.rb +2202 -1085
  101. data/generated/google/apis/container_v1.rb +1 -1
  102. data/generated/google/apis/container_v1/classes.rb +56 -31
  103. data/generated/google/apis/container_v1/representations.rb +12 -0
  104. data/generated/google/apis/container_v1/service.rb +62 -41
  105. data/generated/google/apis/content_v2.rb +2 -2
  106. data/generated/google/apis/content_v2/classes.rb +2252 -56
  107. data/generated/google/apis/content_v2/representations.rb +917 -87
  108. data/generated/google/apis/content_v2/service.rb +680 -85
  109. data/generated/google/apis/coordinate_v1.rb +1 -1
  110. data/generated/google/apis/coordinate_v1/service.rb +16 -25
  111. data/generated/google/apis/customsearch_v1/service.rb +1 -2
  112. data/generated/google/apis/datastore_v1beta2.rb +1 -1
  113. data/generated/google/apis/datastore_v1beta2/service.rb +12 -18
  114. data/generated/google/apis/deploymentmanager_v2.rb +44 -0
  115. data/generated/google/apis/deploymentmanager_v2/classes.rb +1089 -0
  116. data/generated/google/apis/deploymentmanager_v2/representations.rb +422 -0
  117. data/generated/google/apis/deploymentmanager_v2/service.rb +857 -0
  118. data/generated/google/apis/deploymentmanager_v2beta2.rb +5 -2
  119. data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +22 -3
  120. data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +3 -0
  121. data/generated/google/apis/deploymentmanager_v2beta2/service.rb +14 -27
  122. data/generated/google/apis/dfareporting_v2_1.rb +1 -1
  123. data/generated/google/apis/dfareporting_v2_1/classes.rb +29 -14
  124. data/generated/google/apis/dfareporting_v2_1/service.rb +196 -389
  125. data/generated/google/apis/discovery_v1/classes.rb +7 -0
  126. data/generated/google/apis/discovery_v1/representations.rb +1 -0
  127. data/generated/google/apis/discovery_v1/service.rb +2 -4
  128. data/generated/google/apis/dns_v1.rb +4 -1
  129. data/generated/google/apis/dns_v1/service.rb +9 -18
  130. data/generated/google/apis/doubleclickbidmanager_v1.rb +1 -1
  131. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +9 -2
  132. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +1 -0
  133. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +8 -16
  134. data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
  135. data/generated/google/apis/doubleclicksearch_v2/classes.rb +15 -6
  136. data/generated/google/apis/doubleclicksearch_v2/representations.rb +1 -0
  137. data/generated/google/apis/doubleclicksearch_v2/service.rb +13 -23
  138. data/generated/google/apis/drive_v2.rb +1 -1
  139. data/generated/google/apis/drive_v2/classes.rb +73 -30
  140. data/generated/google/apis/drive_v2/representations.rb +14 -0
  141. data/generated/google/apis/drive_v2/service.rb +139 -135
  142. data/generated/google/apis/drive_v3.rb +55 -0
  143. data/generated/google/apis/drive_v3/classes.rb +1534 -0
  144. data/generated/google/apis/drive_v3/representations.rb +497 -0
  145. data/generated/google/apis/drive_v3/service.rb +1541 -0
  146. data/generated/google/apis/fitness_v1.rb +1 -1
  147. data/generated/google/apis/fitness_v1/service.rb +14 -27
  148. data/generated/google/apis/fusiontables_v2/service.rb +40 -73
  149. data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
  150. data/generated/google/apis/games_configuration_v1configuration/service.rb +14 -27
  151. data/generated/google/apis/games_management_v1management.rb +37 -0
  152. data/generated/google/apis/games_management_v1management/classes.rb +524 -0
  153. data/generated/google/apis/games_management_v1management/representations.rb +231 -0
  154. data/generated/google/apis/games_management_v1management/service.rb +994 -0
  155. data/generated/google/apis/games_v1.rb +1 -1
  156. data/generated/google/apis/games_v1/classes.rb +39 -0
  157. data/generated/google/apis/games_v1/representations.rb +14 -0
  158. data/generated/google/apis/games_v1/service.rb +93 -109
  159. data/generated/google/apis/gan_v1beta1/service.rb +10 -20
  160. data/generated/google/apis/genomics_v1.rb +5 -3
  161. data/generated/google/apis/genomics_v1/classes.rb +519 -200
  162. data/generated/google/apis/genomics_v1/representations.rb +126 -13
  163. data/generated/google/apis/genomics_v1/service.rb +392 -236
  164. data/generated/google/apis/gmail_v1.rb +4 -1
  165. data/generated/google/apis/gmail_v1/service.rb +39 -71
  166. data/generated/google/apis/groupsmigration_v1/service.rb +2 -3
  167. data/generated/google/apis/groupssettings_v1/service.rb +3 -6
  168. data/generated/google/apis/identitytoolkit_v3.rb +1 -1
  169. data/generated/google/apis/identitytoolkit_v3/classes.rb +125 -0
  170. data/generated/google/apis/identitytoolkit_v3/representations.rb +37 -0
  171. data/generated/google/apis/identitytoolkit_v3/service.rb +44 -24
  172. data/generated/google/apis/kgsearch_v1.rb +32 -0
  173. data/generated/google/apis/kgsearch_v1/classes.rb +59 -0
  174. data/generated/google/apis/kgsearch_v1/representations.rb +39 -0
  175. data/generated/google/apis/kgsearch_v1/service.rb +111 -0
  176. data/generated/google/apis/licensing_v1.rb +1 -1
  177. data/generated/google/apis/licensing_v1/service.rb +7 -14
  178. data/generated/google/apis/logging_v1beta3.rb +16 -4
  179. data/generated/google/apis/logging_v1beta3/classes.rb +620 -46
  180. data/generated/google/apis/logging_v1beta3/representations.rb +144 -0
  181. data/generated/google/apis/logging_v1beta3/service.rb +435 -104
  182. data/generated/google/apis/manager_v1beta2.rb +3 -0
  183. data/generated/google/apis/manager_v1beta2/service.rb +8 -16
  184. data/generated/google/apis/mapsengine_v1.rb +1 -1
  185. data/generated/google/apis/mapsengine_v1/service.rb +85 -162
  186. data/generated/google/apis/mirror_v1.rb +1 -1
  187. data/generated/google/apis/mirror_v1/service.rb +28 -52
  188. data/generated/google/apis/oauth2_v2.rb +1 -1
  189. data/generated/google/apis/oauth2_v2/service.rb +4 -8
  190. data/generated/google/apis/pagespeedonline_v2/service.rb +1 -2
  191. data/generated/google/apis/partners_v2.rb +32 -0
  192. data/generated/google/apis/partners_v2/classes.rb +942 -0
  193. data/generated/google/apis/partners_v2/representations.rb +402 -0
  194. data/generated/google/apis/partners_v2/service.rb +400 -0
  195. data/generated/google/apis/plus_domains_v1.rb +1 -1
  196. data/generated/google/apis/plus_domains_v1/classes.rb +207 -0
  197. data/generated/google/apis/plus_domains_v1/representations.rb +114 -0
  198. data/generated/google/apis/plus_domains_v1/service.rb +21 -41
  199. data/generated/google/apis/plus_v1.rb +1 -1
  200. data/generated/google/apis/plus_v1/classes.rb +207 -0
  201. data/generated/google/apis/plus_v1/representations.rb +114 -0
  202. data/generated/google/apis/plus_v1/service.rb +11 -56
  203. data/generated/google/apis/prediction_v1_6.rb +1 -1
  204. data/generated/google/apis/prediction_v1_6/service.rb +8 -16
  205. data/generated/google/apis/proximitybeacon_v1beta1.rb +31 -0
  206. data/generated/google/apis/proximitybeacon_v1beta1/classes.rb +639 -0
  207. data/generated/google/apis/proximitybeacon_v1beta1/representations.rb +274 -0
  208. data/generated/google/apis/proximitybeacon_v1beta1/service.rb +591 -0
  209. data/generated/google/apis/pubsub_v1.rb +37 -0
  210. data/generated/google/apis/pubsub_v1/classes.rb +614 -0
  211. data/generated/google/apis/pubsub_v1/representations.rb +281 -0
  212. data/generated/google/apis/pubsub_v1/service.rb +774 -0
  213. data/generated/google/apis/pubsub_v1beta2.rb +1 -1
  214. data/generated/google/apis/pubsub_v1beta2/classes.rb +78 -283
  215. data/generated/google/apis/pubsub_v1beta2/representations.rb +1 -85
  216. data/generated/google/apis/pubsub_v1beta2/service.rb +79 -87
  217. data/generated/google/apis/qpx_express_v1/service.rb +1 -2
  218. data/generated/google/apis/replicapool_v1beta2.rb +3 -0
  219. data/generated/google/apis/replicapool_v1beta2/service.rb +12 -24
  220. data/generated/google/apis/replicapoolupdater_v1beta1.rb +4 -1
  221. data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +46 -2
  222. data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +16 -0
  223. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +58 -18
  224. data/generated/google/apis/reseller_v1.rb +1 -1
  225. data/generated/google/apis/reseller_v1/classes.rb +19 -1
  226. data/generated/google/apis/reseller_v1/representations.rb +1 -0
  227. data/generated/google/apis/reseller_v1/service.rb +16 -30
  228. data/generated/google/apis/resourceviews_v1beta2.rb +3 -0
  229. data/generated/google/apis/resourceviews_v1beta2/service.rb +16 -27
  230. data/generated/google/apis/script_v1.rb +61 -0
  231. data/generated/google/apis/script_v1/classes.rb +259 -0
  232. data/generated/google/apis/script_v1/representations.rb +106 -0
  233. data/generated/google/apis/script_v1/service.rb +98 -0
  234. data/generated/google/apis/site_verification_v1.rb +1 -1
  235. data/generated/google/apis/site_verification_v1/service.rb +8 -15
  236. data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
  237. data/generated/google/apis/sqladmin_v1beta4/classes.rb +186 -2
  238. data/generated/google/apis/sqladmin_v1beta4/representations.rb +70 -0
  239. data/generated/google/apis/sqladmin_v1beta4/service.rb +166 -75
  240. data/generated/google/apis/storage_v1.rb +5 -2
  241. data/generated/google/apis/storage_v1/classes.rb +47 -4
  242. data/generated/google/apis/storage_v1/representations.rb +18 -0
  243. data/generated/google/apis/storage_v1/service.rb +77 -94
  244. data/generated/google/apis/storagetransfer_v1.rb +35 -0
  245. data/generated/google/apis/storagetransfer_v1/classes.rb +1046 -0
  246. data/generated/google/apis/storagetransfer_v1/representations.rb +370 -0
  247. data/generated/google/apis/storagetransfer_v1/service.rb +473 -0
  248. data/generated/google/apis/tagmanager_v1.rb +1 -1
  249. data/generated/google/apis/tagmanager_v1/classes.rb +189 -31
  250. data/generated/google/apis/tagmanager_v1/representations.rb +69 -15
  251. data/generated/google/apis/tagmanager_v1/service.rb +114 -275
  252. data/generated/google/apis/taskqueue_v1beta2/service.rb +8 -16
  253. data/generated/google/apis/tasks_v1/service.rb +14 -28
  254. data/generated/google/apis/translate_v2/service.rb +3 -6
  255. data/generated/google/apis/urlshortener_v1/service.rb +3 -6
  256. data/generated/google/apis/webmasters_v3.rb +3 -3
  257. data/generated/google/apis/webmasters_v3/classes.rb +4 -4
  258. data/generated/google/apis/webmasters_v3/service.rb +16 -30
  259. data/generated/google/apis/youtube_analytics_v1.rb +1 -1
  260. data/generated/google/apis/youtube_analytics_v1/classes.rb +6 -0
  261. data/generated/google/apis/youtube_analytics_v1/representations.rb +1 -0
  262. data/generated/google/apis/youtube_analytics_v1/service.rb +16 -21
  263. data/generated/google/apis/youtube_v3.rb +1 -1
  264. data/generated/google/apis/youtube_v3/classes.rb +111 -78
  265. data/generated/google/apis/youtube_v3/representations.rb +2 -0
  266. data/generated/google/apis/youtube_v3/service.rb +78 -246
  267. data/generated/google/apis/youtubereporting_v1.rb +38 -0
  268. data/generated/google/apis/youtubereporting_v1/classes.rb +258 -0
  269. data/generated/google/apis/youtubereporting_v1/representations.rb +128 -0
  270. data/generated/google/apis/youtubereporting_v1/service.rb +364 -0
  271. data/google-api-client.gemspec +3 -3
  272. data/lib/google/api_client/auth/installed_app.rb +2 -2
  273. data/lib/google/api_client/auth/key_utils.rb +1 -0
  274. data/lib/google/api_client/auth/storage.rb +1 -0
  275. data/lib/google/api_client/auth/storages/file_store.rb +1 -0
  276. data/lib/google/api_client/auth/storages/redis_store.rb +1 -0
  277. data/lib/google/api_client/client_secrets.rb +4 -5
  278. data/lib/google/apis/core/api_command.rb +2 -2
  279. data/lib/google/apis/core/base_service.rb +1 -0
  280. data/lib/google/apis/core/batch.rb +25 -8
  281. data/lib/google/apis/core/download.rb +1 -1
  282. data/lib/google/apis/core/http_command.rb +24 -12
  283. data/lib/google/apis/core/multipart.rb +20 -6
  284. data/lib/google/apis/core/upload.rb +11 -4
  285. data/lib/google/apis/generator/annotator.rb +29 -10
  286. data/lib/google/apis/generator/helpers.rb +1 -1
  287. data/lib/google/apis/generator/templates/_method.tmpl +5 -6
  288. data/lib/google/apis/options.rb +7 -3
  289. data/lib/google/apis/version.rb +1 -1
  290. data/samples/calendar/calendar.rb +1 -1
  291. data/samples/drive/drive.rb +9 -2
  292. data/samples/pubsub/pubsub.rb +5 -6
  293. data/samples/translate/translate.rb +1 -5
  294. data/script/generate +20 -5
  295. data/spec/fixtures/files/child/.gitignore +0 -0
  296. data/spec/fixtures/files/invalid.json +1 -0
  297. data/spec/google/api_client/client_secrets_spec.rb +38 -1
  298. data/spec/google/apis/core/batch_spec.rb +22 -8
  299. data/spec/google/apis/core/download_spec.rb +13 -0
  300. data/spec/google/apis/core/http_command_spec.rb +26 -9
  301. data/spec/google/apis/core/upload_spec.rb +65 -17
  302. data/spec/google/apis/options_spec.rb +8 -0
  303. data/spec/integration_tests/adsense_spec.rb +28 -0
  304. data/spec/integration_tests/pubsub_spec.rb +3 -3
  305. data/spec/spec_helper.rb +5 -1
  306. data/third_party/hurley_patches.rb +103 -0
  307. metadata +87 -7
@@ -25,7 +25,7 @@ module Google
25
25
  # @see https://developers.google.com/drive/
26
26
  module DriveV2
27
27
  VERSION = 'V2'
28
- REVISION = '20150716'
28
+ REVISION = '20151209'
29
29
 
30
30
  # View and manage the files in your Google Drive
31
31
  AUTH_DRIVE = 'https://www.googleapis.com/auth/drive'
@@ -33,10 +33,10 @@ module Google
33
33
  attr_accessor :additional_role_info
34
34
 
35
35
  # The domain sharing policy for the current user. Possible values are:
36
- # - ALLOWED
37
- # - ALLOWED_WITH_WARNING
38
- # - INCOMING_ONLY
39
- # - DISALLOWED
36
+ # - allowed
37
+ # - allowedWithWarning
38
+ # - incomingOnly
39
+ # - disallowed
40
40
  # Corresponds to the JSON property `domainSharingPolicy`
41
41
  # @return [String]
42
42
  attr_accessor :domain_sharing_policy
@@ -152,7 +152,7 @@ module Google
152
152
  # @return [String]
153
153
  attr_accessor :self_link
154
154
 
155
- # The JSON template for a user.
155
+ # Information about a Drive user.
156
156
  # Corresponds to the JSON property `user`
157
157
  # @return [Google::Apis::DriveV2::User]
158
158
  attr_accessor :user
@@ -892,7 +892,7 @@ module Google
892
892
  end
893
893
  end
894
894
 
895
- # A JSON representation of a comment on a file in Google Drive.
895
+ # A comment on a file in Google Drive.
896
896
  class Comment
897
897
  include Google::Apis::Core::Hashable
898
898
 
@@ -902,7 +902,7 @@ module Google
902
902
  # @return [String]
903
903
  attr_accessor :anchor
904
904
 
905
- # The JSON template for a user.
905
+ # Information about a Drive user.
906
906
  # Corresponds to the JSON property `author`
907
907
  # @return [Google::Apis::DriveV2::User]
908
908
  attr_accessor :author
@@ -1030,7 +1030,7 @@ module Google
1030
1030
  end
1031
1031
  end
1032
1032
 
1033
- # A JSON representation of a list of comments on a file in Google Drive.
1033
+ # A list of comments on a file in Google Drive.
1034
1034
  class CommentList
1035
1035
  include Google::Apis::Core::Hashable
1036
1036
 
@@ -1073,11 +1073,11 @@ module Google
1073
1073
  end
1074
1074
  end
1075
1075
 
1076
- # A JSON representation of a reply to a comment on a file in Google Drive.
1076
+ # A comment on a file in Google Drive.
1077
1077
  class CommentReply
1078
1078
  include Google::Apis::Core::Hashable
1079
1079
 
1080
- # The JSON template for a user.
1080
+ # Information about a Drive user.
1081
1081
  # Corresponds to the JSON property `author`
1082
1082
  # @return [Google::Apis::DriveV2::User]
1083
1083
  attr_accessor :author
@@ -1148,8 +1148,7 @@ module Google
1148
1148
  end
1149
1149
  end
1150
1150
 
1151
- # A JSON representation of a list of replies to a comment on a file in Google
1152
- # Drive.
1151
+ # A list of replies to a comment on a file in Google Drive.
1153
1152
  class CommentReplyList
1154
1153
  include Google::Apis::Core::Hashable
1155
1154
 
@@ -1268,15 +1267,16 @@ module Google
1268
1267
  # @return [Hash<String,String>]
1269
1268
  attr_accessor :export_links
1270
1269
 
1271
- # The file extension used when downloading this file. This field is read only.
1272
- # To set the extension, include it in the title when creating the file. This is
1273
- # only populated for files with content stored in Drive.
1270
+ # The final component of fullFileExtension with trailing text that does not
1271
+ # appear to be part of the extension removed. This field is only populated for
1272
+ # files with content stored in Drive; it is not populated for Google Docs or
1273
+ # shortcut files.
1274
1274
  # Corresponds to the JSON property `fileExtension`
1275
1275
  # @return [String]
1276
1276
  attr_accessor :file_extension
1277
1277
 
1278
- # The size of the file in bytes. This is only populated for files with content
1279
- # stored in Drive.
1278
+ # The size of the file in bytes. This field is only populated for files with
1279
+ # content stored in Drive; it is not populated for Google Docs or shortcut files.
1280
1280
  # Corresponds to the JSON property `fileSize`
1281
1281
  # @return [String]
1282
1282
  attr_accessor :file_size
@@ -1289,8 +1289,18 @@ module Google
1289
1289
  # @return [String]
1290
1290
  attr_accessor :folder_color_rgb
1291
1291
 
1292
- # The ID of the file's head revision. This will only be populated for files with
1293
- # content stored in Drive.
1292
+ # The full file extension; extracted from the title. May contain multiple
1293
+ # concatenated extensions, such as "tar.gz". Removing an extension from the
1294
+ # title does not clear this field; however, changing the extension on the title
1295
+ # does update this field. This field is only populated for files with content
1296
+ # stored in Drive; it is not populated for Google Docs or shortcut files.
1297
+ # Corresponds to the JSON property `fullFileExtension`
1298
+ # @return [String]
1299
+ attr_accessor :full_file_extension
1300
+
1301
+ # The ID of the file's head revision. This field is only populated for files
1302
+ # with content stored in Drive; it is not populated for Google Docs or shortcut
1303
+ # files.
1294
1304
  # Corresponds to the JSON property `headRevisionId`
1295
1305
  # @return [String]
1296
1306
  attr_accessor :head_revision_id
@@ -1326,7 +1336,7 @@ module Google
1326
1336
  # @return [Google::Apis::DriveV2::File::Labels]
1327
1337
  attr_accessor :labels
1328
1338
 
1329
- # The JSON template for a user.
1339
+ # Information about a Drive user.
1330
1340
  # Corresponds to the JSON property `lastModifyingUser`
1331
1341
  # @return [Google::Apis::DriveV2::User]
1332
1342
  attr_accessor :last_modifying_user
@@ -1341,14 +1351,14 @@ module Google
1341
1351
  # @return [DateTime]
1342
1352
  attr_accessor :last_viewed_by_me_date
1343
1353
 
1344
- # Time this file was explicitly marked viewed by the user (formatted RFC 3339
1345
- # timestamp).
1354
+ # Deprecated.
1346
1355
  # Corresponds to the JSON property `markedViewedByMeDate`
1347
1356
  # @return [DateTime]
1348
1357
  attr_accessor :marked_viewed_by_me_date
1349
1358
 
1350
- # An MD5 checksum for the content of this file. This is populated only for files
1351
- # with content stored in Drive.
1359
+ # An MD5 checksum for the content of this file. This field is only populated for
1360
+ # files with content stored in Drive; it is not populated for Google Docs or
1361
+ # shortcut files.
1352
1362
  # Corresponds to the JSON property `md5Checksum`
1353
1363
  # @return [String]
1354
1364
  attr_accessor :md5_checksum
@@ -1381,8 +1391,8 @@ module Google
1381
1391
 
1382
1392
  # The original filename if the file was uploaded manually, or the original title
1383
1393
  # if the file was inserted through the API. Note that renames of the title will
1384
- # not change the original filename. This will only be populated on files with
1385
- # content stored in Drive.
1394
+ # not change the original filename. This field is only populated for files with
1395
+ # content stored in Drive; it is not populated for Google Docs or shortcut files.
1386
1396
  # Corresponds to the JSON property `originalFilename`
1387
1397
  # @return [String]
1388
1398
  attr_accessor :original_filename
@@ -1449,7 +1459,7 @@ module Google
1449
1459
  # @return [DateTime]
1450
1460
  attr_accessor :shared_with_me_date
1451
1461
 
1452
- # The JSON template for a user.
1462
+ # Information about a Drive user.
1453
1463
  # Corresponds to the JSON property `sharingUser`
1454
1464
  # @return [Google::Apis::DriveV2::User]
1455
1465
  attr_accessor :sharing_user
@@ -1535,6 +1545,7 @@ module Google
1535
1545
  @file_extension = args[:file_extension] unless args[:file_extension].nil?
1536
1546
  @file_size = args[:file_size] unless args[:file_size].nil?
1537
1547
  @folder_color_rgb = args[:folder_color_rgb] unless args[:folder_color_rgb].nil?
1548
+ @full_file_extension = args[:full_file_extension] unless args[:full_file_extension].nil?
1538
1549
  @head_revision_id = args[:head_revision_id] unless args[:head_revision_id].nil?
1539
1550
  @icon_link = args[:icon_link] unless args[:icon_link].nil?
1540
1551
  @id = args[:id] unless args[:id].nil?
@@ -1778,7 +1789,8 @@ module Google
1778
1789
  attr_accessor :hidden
1779
1790
  alias_method :hidden?, :hidden
1780
1791
 
1781
- # Whether viewers are prevented from downloading this file.
1792
+ # Whether viewers and commenters are prevented from downloading, printing, and
1793
+ # copying this file.
1782
1794
  # Corresponds to the JSON property `restricted`
1783
1795
  # @return [Boolean]
1784
1796
  attr_accessor :restricted
@@ -1925,6 +1937,37 @@ module Google
1925
1937
  end
1926
1938
  end
1927
1939
 
1940
+ # A list of generated IDs which can be provided in insert requests
1941
+ class GeneratedIds
1942
+ include Google::Apis::Core::Hashable
1943
+
1944
+ # The IDs generated for the requesting user in the specified space.
1945
+ # Corresponds to the JSON property `ids`
1946
+ # @return [Array<String>]
1947
+ attr_accessor :ids
1948
+
1949
+ # This is always drive#generatedIds
1950
+ # Corresponds to the JSON property `kind`
1951
+ # @return [String]
1952
+ attr_accessor :kind
1953
+
1954
+ # The type of file that can be created with these IDs.
1955
+ # Corresponds to the JSON property `space`
1956
+ # @return [String]
1957
+ attr_accessor :space
1958
+
1959
+ def initialize(**args)
1960
+ update!(**args)
1961
+ end
1962
+
1963
+ # Update properties of this object
1964
+ def update!(**args)
1965
+ @ids = args[:ids] unless args[:ids].nil?
1966
+ @kind = args[:kind] unless args[:kind].nil?
1967
+ @space = args[:space] unless args[:space].nil?
1968
+ end
1969
+ end
1970
+
1928
1971
  # A list of a file's parents.
1929
1972
  class ParentList
1930
1973
  include Google::Apis::Core::Hashable
@@ -2309,7 +2352,7 @@ module Google
2309
2352
  # @return [String]
2310
2353
  attr_accessor :kind
2311
2354
 
2312
- # The JSON template for a user.
2355
+ # Information about a Drive user.
2313
2356
  # Corresponds to the JSON property `lastModifyingUser`
2314
2357
  # @return [Google::Apis::DriveV2::User]
2315
2358
  attr_accessor :last_modifying_user
@@ -2445,7 +2488,7 @@ module Google
2445
2488
  end
2446
2489
  end
2447
2490
 
2448
- # The JSON template for a user.
2491
+ # Information about a Drive user.
2449
2492
  class User
2450
2493
  include Google::Apis::Core::Hashable
2451
2494
 
@@ -138,6 +138,10 @@ module Google
138
138
  class Representation < Google::Apis::Core::JsonRepresentation; end
139
139
  end
140
140
 
141
+ class GeneratedIds
142
+ class Representation < Google::Apis::Core::JsonRepresentation; end
143
+ end
144
+
141
145
  class ParentList
142
146
  class Representation < Google::Apis::Core::JsonRepresentation; end
143
147
  end
@@ -492,6 +496,7 @@ module Google
492
496
  property :file_extension, as: 'fileExtension'
493
497
  property :file_size, as: 'fileSize'
494
498
  property :folder_color_rgb, as: 'folderColorRgb'
499
+ property :full_file_extension, as: 'fullFileExtension'
495
500
  property :head_revision_id, as: 'headRevisionId'
496
501
  property :icon_link, as: 'iconLink'
497
502
  property :id, as: 'id'
@@ -636,6 +641,15 @@ module Google
636
641
  end
637
642
  end
638
643
 
644
+ class GeneratedIds
645
+ # @private
646
+ class Representation < Google::Apis::Core::JsonRepresentation
647
+ collection :ids, as: 'ids'
648
+ property :kind, as: 'kind'
649
+ property :space, as: 'space'
650
+ end
651
+ end
652
+
639
653
  class ParentList
640
654
  # @private
641
655
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -85,8 +85,7 @@ module Google
85
85
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
86
86
  # @raise [Google::Apis::AuthorizationError] Authorization is required
87
87
  def get_about(include_subscribed: nil, max_change_id_count: nil, start_change_id: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
88
- path = 'about'
89
- command = make_simple_command(:get, path, options)
88
+ command = make_simple_command(:get, 'about', options)
90
89
  command.response_representation = Google::Apis::DriveV2::About::Representation
91
90
  command.response_class = Google::Apis::DriveV2::About
92
91
  command.query['includeSubscribed'] = include_subscribed unless include_subscribed.nil?
@@ -123,8 +122,7 @@ module Google
123
122
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
124
123
  # @raise [Google::Apis::AuthorizationError] Authorization is required
125
124
  def get_app(app_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
126
- path = 'apps/{appId}'
127
- command = make_simple_command(:get, path, options)
125
+ command = make_simple_command(:get, 'apps/{appId}', options)
128
126
  command.response_representation = Google::Apis::DriveV2::App::Representation
129
127
  command.response_class = Google::Apis::DriveV2::App
130
128
  command.params['appId'] = app_id unless app_id.nil?
@@ -170,8 +168,7 @@ module Google
170
168
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
171
169
  # @raise [Google::Apis::AuthorizationError] Authorization is required
172
170
  def list_apps(app_filter_extensions: nil, app_filter_mime_types: nil, language_code: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
173
- path = 'apps'
174
- command = make_simple_command(:get, path, options)
171
+ command = make_simple_command(:get, 'apps', options)
175
172
  command.response_representation = Google::Apis::DriveV2::AppList::Representation
176
173
  command.response_class = Google::Apis::DriveV2::AppList
177
174
  command.query['appFilterExtensions'] = app_filter_extensions unless app_filter_extensions.nil?
@@ -208,8 +205,7 @@ module Google
208
205
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
209
206
  # @raise [Google::Apis::AuthorizationError] Authorization is required
210
207
  def get_change(change_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
211
- path = 'changes/{changeId}'
212
- command = make_simple_command(:get, path, options)
208
+ command = make_simple_command(:get, 'changes/{changeId}', options)
213
209
  command.response_representation = Google::Apis::DriveV2::Change::Representation
214
210
  command.response_class = Google::Apis::DriveV2::Change
215
211
  command.params['changeId'] = change_id unless change_id.nil?
@@ -257,8 +253,7 @@ module Google
257
253
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
258
254
  # @raise [Google::Apis::AuthorizationError] Authorization is required
259
255
  def list_changes(include_deleted: nil, include_subscribed: nil, max_results: nil, page_token: nil, spaces: nil, start_change_id: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
260
- path = 'changes'
261
- command = make_simple_command(:get, path, options)
256
+ command = make_simple_command(:get, 'changes', options)
262
257
  command.response_representation = Google::Apis::DriveV2::ChangeList::Representation
263
258
  command.response_class = Google::Apis::DriveV2::ChangeList
264
259
  command.query['includeDeleted'] = include_deleted unless include_deleted.nil?
@@ -312,8 +307,7 @@ module Google
312
307
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
313
308
  # @raise [Google::Apis::AuthorizationError] Authorization is required
314
309
  def watch_change(channel_object = nil, include_deleted: nil, include_subscribed: nil, max_results: nil, page_token: nil, spaces: nil, start_change_id: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
315
- path = 'changes/watch'
316
- command = make_simple_command(:post, path, options)
310
+ command = make_simple_command(:post, 'changes/watch', options)
317
311
  command.request_representation = Google::Apis::DriveV2::Channel::Representation
318
312
  command.request_object = channel_object
319
313
  command.response_representation = Google::Apis::DriveV2::Channel::Representation
@@ -354,8 +348,7 @@ module Google
354
348
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
355
349
  # @raise [Google::Apis::AuthorizationError] Authorization is required
356
350
  def stop_channel(channel_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
357
- path = 'channels/stop'
358
- command = make_simple_command(:post, path, options)
351
+ command = make_simple_command(:post, 'channels/stop', options)
359
352
  command.request_representation = Google::Apis::DriveV2::Channel::Representation
360
353
  command.request_object = channel_object
361
354
  command.query['fields'] = fields unless fields.nil?
@@ -391,8 +384,7 @@ module Google
391
384
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
392
385
  # @raise [Google::Apis::AuthorizationError] Authorization is required
393
386
  def delete_child(folder_id, child_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
394
- path = 'files/{folderId}/children/{childId}'
395
- command = make_simple_command(:delete, path, options)
387
+ command = make_simple_command(:delete, 'files/{folderId}/children/{childId}', options)
396
388
  command.params['folderId'] = folder_id unless folder_id.nil?
397
389
  command.params['childId'] = child_id unless child_id.nil?
398
390
  command.query['fields'] = fields unless fields.nil?
@@ -428,8 +420,7 @@ module Google
428
420
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
429
421
  # @raise [Google::Apis::AuthorizationError] Authorization is required
430
422
  def get_child(folder_id, child_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
431
- path = 'files/{folderId}/children/{childId}'
432
- command = make_simple_command(:get, path, options)
423
+ command = make_simple_command(:get, 'files/{folderId}/children/{childId}', options)
433
424
  command.response_representation = Google::Apis::DriveV2::ChildReference::Representation
434
425
  command.response_class = Google::Apis::DriveV2::ChildReference
435
426
  command.params['folderId'] = folder_id unless folder_id.nil?
@@ -466,8 +457,7 @@ module Google
466
457
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
467
458
  # @raise [Google::Apis::AuthorizationError] Authorization is required
468
459
  def insert_child(folder_id, child_reference_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
469
- path = 'files/{folderId}/children'
470
- command = make_simple_command(:post, path, options)
460
+ command = make_simple_command(:post, 'files/{folderId}/children', options)
471
461
  command.request_representation = Google::Apis::DriveV2::ChildReference::Representation
472
462
  command.request_object = child_reference_object
473
463
  command.response_representation = Google::Apis::DriveV2::ChildReference::Representation
@@ -484,6 +474,14 @@ module Google
484
474
  # The ID of the folder.
485
475
  # @param [Fixnum] max_results
486
476
  # Maximum number of children to return.
477
+ # @param [String] order_by
478
+ # A comma-separated list of sort keys. Valid keys are 'createdDate', 'folder', '
479
+ # lastViewedByMeDate', 'modifiedByMeDate', 'modifiedDate', 'quotaBytesUsed', '
480
+ # recency', 'sharedWithMeDate', 'starred', and 'title'. Each key sorts ascending
481
+ # by default, but may be reversed with the 'desc' modifier. Example usage: ?
482
+ # orderBy=folder,modifiedDate desc,title. Please note that there is a current
483
+ # limitation for users with approximately one million files in which the
484
+ # requested sort order is ignored.
487
485
  # @param [String] page_token
488
486
  # Page token for children.
489
487
  # @param [String] q
@@ -509,13 +507,13 @@ module Google
509
507
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
510
508
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
511
509
  # @raise [Google::Apis::AuthorizationError] Authorization is required
512
- def list_children(folder_id, max_results: nil, page_token: nil, q: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
513
- path = 'files/{folderId}/children'
514
- command = make_simple_command(:get, path, options)
510
+ def list_children(folder_id, max_results: nil, order_by: nil, page_token: nil, q: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
511
+ command = make_simple_command(:get, 'files/{folderId}/children', options)
515
512
  command.response_representation = Google::Apis::DriveV2::ChildList::Representation
516
513
  command.response_class = Google::Apis::DriveV2::ChildList
517
514
  command.params['folderId'] = folder_id unless folder_id.nil?
518
515
  command.query['maxResults'] = max_results unless max_results.nil?
516
+ command.query['orderBy'] = order_by unless order_by.nil?
519
517
  command.query['pageToken'] = page_token unless page_token.nil?
520
518
  command.query['q'] = q unless q.nil?
521
519
  command.query['fields'] = fields unless fields.nil?
@@ -551,8 +549,7 @@ module Google
551
549
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
552
550
  # @raise [Google::Apis::AuthorizationError] Authorization is required
553
551
  def delete_comment(file_id, comment_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
554
- path = 'files/{fileId}/comments/{commentId}'
555
- command = make_simple_command(:delete, path, options)
552
+ command = make_simple_command(:delete, 'files/{fileId}/comments/{commentId}', options)
556
553
  command.params['fileId'] = file_id unless file_id.nil?
557
554
  command.params['commentId'] = comment_id unless comment_id.nil?
558
555
  command.query['fields'] = fields unless fields.nil?
@@ -591,8 +588,7 @@ module Google
591
588
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
592
589
  # @raise [Google::Apis::AuthorizationError] Authorization is required
593
590
  def get_comment(file_id, comment_id, include_deleted: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
594
- path = 'files/{fileId}/comments/{commentId}'
595
- command = make_simple_command(:get, path, options)
591
+ command = make_simple_command(:get, 'files/{fileId}/comments/{commentId}', options)
596
592
  command.response_representation = Google::Apis::DriveV2::Comment::Representation
597
593
  command.response_class = Google::Apis::DriveV2::Comment
598
594
  command.params['fileId'] = file_id unless file_id.nil?
@@ -630,8 +626,7 @@ module Google
630
626
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
631
627
  # @raise [Google::Apis::AuthorizationError] Authorization is required
632
628
  def insert_comment(file_id, comment_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
633
- path = 'files/{fileId}/comments'
634
- command = make_simple_command(:post, path, options)
629
+ command = make_simple_command(:post, 'files/{fileId}/comments', options)
635
630
  command.request_representation = Google::Apis::DriveV2::Comment::Representation
636
631
  command.request_object = comment_object
637
632
  command.response_representation = Google::Apis::DriveV2::Comment::Representation
@@ -680,8 +675,7 @@ module Google
680
675
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
681
676
  # @raise [Google::Apis::AuthorizationError] Authorization is required
682
677
  def list_comments(file_id, include_deleted: nil, max_results: nil, page_token: nil, updated_min: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
683
- path = 'files/{fileId}/comments'
684
- command = make_simple_command(:get, path, options)
678
+ command = make_simple_command(:get, 'files/{fileId}/comments', options)
685
679
  command.response_representation = Google::Apis::DriveV2::CommentList::Representation
686
680
  command.response_class = Google::Apis::DriveV2::CommentList
687
681
  command.params['fileId'] = file_id unless file_id.nil?
@@ -723,8 +717,7 @@ module Google
723
717
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
724
718
  # @raise [Google::Apis::AuthorizationError] Authorization is required
725
719
  def patch_comment(file_id, comment_id, comment_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
726
- path = 'files/{fileId}/comments/{commentId}'
727
- command = make_simple_command(:patch, path, options)
720
+ command = make_simple_command(:patch, 'files/{fileId}/comments/{commentId}', options)
728
721
  command.request_representation = Google::Apis::DriveV2::Comment::Representation
729
722
  command.request_object = comment_object
730
723
  command.response_representation = Google::Apis::DriveV2::Comment::Representation
@@ -765,8 +758,7 @@ module Google
765
758
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
766
759
  # @raise [Google::Apis::AuthorizationError] Authorization is required
767
760
  def update_comment(file_id, comment_id, comment_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
768
- path = 'files/{fileId}/comments/{commentId}'
769
- command = make_simple_command(:put, path, options)
761
+ command = make_simple_command(:put, 'files/{fileId}/comments/{commentId}', options)
770
762
  command.request_representation = Google::Apis::DriveV2::Comment::Representation
771
763
  command.request_object = comment_object
772
764
  command.response_representation = Google::Apis::DriveV2::Comment::Representation
@@ -821,8 +813,7 @@ module Google
821
813
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
822
814
  # @raise [Google::Apis::AuthorizationError] Authorization is required
823
815
  def copy_file(file_id, file_object = nil, convert: nil, ocr: nil, ocr_language: nil, pinned: nil, timed_text_language: nil, timed_text_track_name: nil, visibility: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
824
- path = 'files/{fileId}/copy'
825
- command = make_simple_command(:post, path, options)
816
+ command = make_simple_command(:post, 'files/{fileId}/copy', options)
826
817
  command.request_representation = Google::Apis::DriveV2::File::Representation
827
818
  command.request_object = file_object
828
819
  command.response_representation = Google::Apis::DriveV2::File::Representation
@@ -867,8 +858,7 @@ module Google
867
858
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
868
859
  # @raise [Google::Apis::AuthorizationError] Authorization is required
869
860
  def delete_file(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
870
- path = 'files/{fileId}'
871
- command = make_simple_command(:delete, path, options)
861
+ command = make_simple_command(:delete, 'files/{fileId}', options)
872
862
  command.params['fileId'] = file_id unless file_id.nil?
873
863
  command.query['fields'] = fields unless fields.nil?
874
864
  command.query['quotaUser'] = quota_user unless quota_user.nil?
@@ -899,8 +889,46 @@ module Google
899
889
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
900
890
  # @raise [Google::Apis::AuthorizationError] Authorization is required
901
891
  def empty_trash(fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
902
- path = 'files/trash'
903
- command = make_simple_command(:delete, path, options)
892
+ command = make_simple_command(:delete, 'files/trash', options)
893
+ command.query['fields'] = fields unless fields.nil?
894
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
895
+ command.query['userIp'] = user_ip unless user_ip.nil?
896
+ execute_or_queue_command(command, &block)
897
+ end
898
+
899
+ # Generates a set of file IDs which can be provided in insert requests.
900
+ # @param [Fixnum] max_results
901
+ # Maximum number of IDs to return.
902
+ # @param [String] space
903
+ # The space in which the IDs can be used to create new files. Supported values
904
+ # are 'drive' and 'appDataFolder'.
905
+ # @param [String] fields
906
+ # Selector specifying which fields to include in a partial response.
907
+ # @param [String] quota_user
908
+ # Available to use for quota purposes for server-side applications. Can be any
909
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
910
+ # Overrides userIp if both are provided.
911
+ # @param [String] user_ip
912
+ # IP address of the site where the request originates. Use this if you want to
913
+ # enforce per-user limits.
914
+ # @param [Google::Apis::RequestOptions] options
915
+ # Request-specific options
916
+ #
917
+ # @yield [result, err] Result & error if block supplied
918
+ # @yieldparam result [Google::Apis::DriveV2::GeneratedIds] parsed result object
919
+ # @yieldparam err [StandardError] error object if request failed
920
+ #
921
+ # @return [Google::Apis::DriveV2::GeneratedIds]
922
+ #
923
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
924
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
925
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
926
+ def generate_file_ids(max_results: nil, space: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
927
+ command = make_simple_command(:get, 'files/generateIds', options)
928
+ command.response_representation = Google::Apis::DriveV2::GeneratedIds::Representation
929
+ command.response_class = Google::Apis::DriveV2::GeneratedIds
930
+ command.query['maxResults'] = max_results unless max_results.nil?
931
+ command.query['space'] = space unless space.nil?
904
932
  command.query['fields'] = fields unless fields.nil?
905
933
  command.query['quotaUser'] = quota_user unless quota_user.nil?
906
934
  command.query['userIp'] = user_ip unless user_ip.nil?
@@ -919,7 +947,8 @@ module Google
919
947
  # Specifies the Revision ID that should be downloaded. Ignored unless alt=media
920
948
  # is specified.
921
949
  # @param [Boolean] update_viewed_date
922
- # Whether to update the view date after successfully retrieving the file.
950
+ # Deprecated: Use files.update with modifiedDateBehavior=noChange,
951
+ # updateViewedDate=true and an empty request body.
923
952
  # @param [String] fields
924
953
  # Selector specifying which fields to include in a partial response.
925
954
  # @param [String] quota_user
@@ -944,11 +973,10 @@ module Google
944
973
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
945
974
  # @raise [Google::Apis::AuthorizationError] Authorization is required
946
975
  def get_file(file_id, acknowledge_abuse: nil, projection: nil, revision_id: nil, update_viewed_date: nil, fields: nil, quota_user: nil, user_ip: nil, download_dest: nil, options: nil, &block)
947
- path = 'files/{fileId}'
948
976
  if download_dest.nil?
949
- command = make_simple_command(:get, path, options)
977
+ command = make_simple_command(:get, 'files/{fileId}', options)
950
978
  else
951
- command = make_download_command(:get, path, options)
979
+ command = make_download_command(:get, 'files/{fileId}', options)
952
980
  command.download_dest = download_dest
953
981
  end
954
982
  command.response_representation = Google::Apis::DriveV2::File::Representation
@@ -1010,11 +1038,10 @@ module Google
1010
1038
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1011
1039
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1012
1040
  def insert_file(file_object = nil, convert: nil, ocr: nil, ocr_language: nil, pinned: nil, timed_text_language: nil, timed_text_track_name: nil, use_content_as_indexable_text: nil, visibility: nil, fields: nil, quota_user: nil, user_ip: nil, upload_source: nil, content_type: nil, options: nil, &block)
1013
- path = 'files'
1014
1041
  if upload_source.nil?
1015
- command = make_simple_command(:post, path, options)
1042
+ command = make_simple_command(:post, 'files', options)
1016
1043
  else
1017
- command = make_upload_command(:post, path, options)
1044
+ command = make_upload_command(:post, 'files', options)
1018
1045
  command.upload_source = upload_source
1019
1046
  command.upload_content_type = content_type
1020
1047
  end
@@ -1041,6 +1068,14 @@ module Google
1041
1068
  # The body of items (files/documents) to which the query applies.
1042
1069
  # @param [Fixnum] max_results
1043
1070
  # Maximum number of files to return.
1071
+ # @param [String] order_by
1072
+ # A comma-separated list of sort keys. Valid keys are 'createdDate', 'folder', '
1073
+ # lastViewedByMeDate', 'modifiedByMeDate', 'modifiedDate', 'quotaBytesUsed', '
1074
+ # recency', 'sharedWithMeDate', 'starred', and 'title'. Each key sorts ascending
1075
+ # by default, but may be reversed with the 'desc' modifier. Example usage: ?
1076
+ # orderBy=folder,modifiedDate desc,title. Please note that there is a current
1077
+ # limitation for users with approximately one million files in which the
1078
+ # requested sort order is ignored.
1044
1079
  # @param [String] page_token
1045
1080
  # Page token for files.
1046
1081
  # @param [String] projection
@@ -1071,13 +1106,13 @@ module Google
1071
1106
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1072
1107
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1073
1108
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1074
- def list_files(corpus: nil, max_results: nil, page_token: nil, projection: nil, q: nil, spaces: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1075
- path = 'files'
1076
- command = make_simple_command(:get, path, options)
1109
+ def list_files(corpus: nil, max_results: nil, order_by: nil, page_token: nil, projection: nil, q: nil, spaces: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1110
+ command = make_simple_command(:get, 'files', options)
1077
1111
  command.response_representation = Google::Apis::DriveV2::FileList::Representation
1078
1112
  command.response_class = Google::Apis::DriveV2::FileList
1079
1113
  command.query['corpus'] = corpus unless corpus.nil?
1080
1114
  command.query['maxResults'] = max_results unless max_results.nil?
1115
+ command.query['orderBy'] = order_by unless order_by.nil?
1081
1116
  command.query['pageToken'] = page_token unless page_token.nil?
1082
1117
  command.query['projection'] = projection unless projection.nil?
1083
1118
  command.query['q'] = q unless q.nil?
@@ -1095,15 +1130,17 @@ module Google
1095
1130
  # @param [String] add_parents
1096
1131
  # Comma-separated list of parent IDs to add.
1097
1132
  # @param [Boolean] convert
1098
- # Whether to convert this file to the corresponding Google Docs format.
1133
+ # This parameter is deprecated and has no function.
1099
1134
  # @param [String] modified_date_behavior
1100
- # How the modifiedDate field should be updated. This overrides setModifiedDate.
1135
+ # Determines the behavior in which modifiedDate is updated. This overrides
1136
+ # setModifiedDate.
1101
1137
  # @param [Boolean] new_revision
1102
1138
  # Whether a blob upload should create a new revision. If false, the blob data in
1103
1139
  # the current head revision is replaced. If true or not set, a new blob is
1104
1140
  # created as head revision, and previous unpinned revisions are preserved for a
1105
1141
  # short period of time. Pinned revisions are stored indefinitely, using
1106
- # additional storage quota, up to a maximum of 200 revisions.
1142
+ # additional storage quota, up to a maximum of 200 revisions. For details on how
1143
+ # revisions are retained, see the Drive Help Center.
1107
1144
  # @param [Boolean] ocr
1108
1145
  # Whether to attempt OCR on .jpg, .png, .gif, or .pdf uploads.
1109
1146
  # @param [String] ocr_language
@@ -1145,8 +1182,7 @@ module Google
1145
1182
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1146
1183
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1147
1184
  def patch_file(file_id, file_object = nil, add_parents: nil, convert: nil, modified_date_behavior: nil, new_revision: nil, ocr: nil, ocr_language: nil, pinned: nil, remove_parents: nil, set_modified_date: nil, timed_text_language: nil, timed_text_track_name: nil, update_viewed_date: nil, use_content_as_indexable_text: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1148
- path = 'files/{fileId}'
1149
- command = make_simple_command(:patch, path, options)
1185
+ command = make_simple_command(:patch, 'files/{fileId}', options)
1150
1186
  command.request_representation = Google::Apis::DriveV2::File::Representation
1151
1187
  command.request_object = file_object
1152
1188
  command.response_representation = Google::Apis::DriveV2::File::Representation
@@ -1196,8 +1232,7 @@ module Google
1196
1232
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1197
1233
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1198
1234
  def touch_file(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1199
- path = 'files/{fileId}/touch'
1200
- command = make_simple_command(:post, path, options)
1235
+ command = make_simple_command(:post, 'files/{fileId}/touch', options)
1201
1236
  command.response_representation = Google::Apis::DriveV2::File::Representation
1202
1237
  command.response_class = Google::Apis::DriveV2::File
1203
1238
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1232,8 +1267,7 @@ module Google
1232
1267
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1233
1268
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1234
1269
  def trash_file(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1235
- path = 'files/{fileId}/trash'
1236
- command = make_simple_command(:post, path, options)
1270
+ command = make_simple_command(:post, 'files/{fileId}/trash', options)
1237
1271
  command.response_representation = Google::Apis::DriveV2::File::Representation
1238
1272
  command.response_class = Google::Apis::DriveV2::File
1239
1273
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1268,8 +1302,7 @@ module Google
1268
1302
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1269
1303
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1270
1304
  def untrash_file(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1271
- path = 'files/{fileId}/untrash'
1272
- command = make_simple_command(:post, path, options)
1305
+ command = make_simple_command(:post, 'files/{fileId}/untrash', options)
1273
1306
  command.response_representation = Google::Apis::DriveV2::File::Representation
1274
1307
  command.response_class = Google::Apis::DriveV2::File
1275
1308
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1286,15 +1319,17 @@ module Google
1286
1319
  # @param [String] add_parents
1287
1320
  # Comma-separated list of parent IDs to add.
1288
1321
  # @param [Boolean] convert
1289
- # Whether to convert this file to the corresponding Google Docs format.
1322
+ # This parameter is deprecated and has no function.
1290
1323
  # @param [String] modified_date_behavior
1291
- # How the modifiedDate field should be updated. This overrides setModifiedDate.
1324
+ # Determines the behavior in which modifiedDate is updated. This overrides
1325
+ # setModifiedDate.
1292
1326
  # @param [Boolean] new_revision
1293
1327
  # Whether a blob upload should create a new revision. If false, the blob data in
1294
1328
  # the current head revision is replaced. If true or not set, a new blob is
1295
1329
  # created as head revision, and previous unpinned revisions are preserved for a
1296
1330
  # short period of time. Pinned revisions are stored indefinitely, using
1297
- # additional storage quota, up to a maximum of 200 revisions.
1331
+ # additional storage quota, up to a maximum of 200 revisions. For details on how
1332
+ # revisions are retained, see the Drive Help Center.
1298
1333
  # @param [Boolean] ocr
1299
1334
  # Whether to attempt OCR on .jpg, .png, .gif, or .pdf uploads.
1300
1335
  # @param [String] ocr_language
@@ -1340,11 +1375,10 @@ module Google
1340
1375
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1341
1376
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1342
1377
  def update_file(file_id, file_object = nil, add_parents: nil, convert: nil, modified_date_behavior: nil, new_revision: nil, ocr: nil, ocr_language: nil, pinned: nil, remove_parents: nil, set_modified_date: nil, timed_text_language: nil, timed_text_track_name: nil, update_viewed_date: nil, use_content_as_indexable_text: nil, fields: nil, quota_user: nil, user_ip: nil, upload_source: nil, content_type: nil, options: nil, &block)
1343
- path = 'files/{fileId}'
1344
1378
  if upload_source.nil?
1345
- command = make_simple_command(:put, path, options)
1379
+ command = make_simple_command(:put, 'files/{fileId}', options)
1346
1380
  else
1347
- command = make_upload_command(:put, path, options)
1381
+ command = make_upload_command(:put, 'files/{fileId}', options)
1348
1382
  command.upload_source = upload_source
1349
1383
  command.upload_content_type = content_type
1350
1384
  end
@@ -1385,7 +1419,8 @@ module Google
1385
1419
  # Specifies the Revision ID that should be downloaded. Ignored unless alt=media
1386
1420
  # is specified.
1387
1421
  # @param [Boolean] update_viewed_date
1388
- # Whether to update the view date after successfully retrieving the file.
1422
+ # Deprecated: Use files.update with modifiedDateBehavior=noChange,
1423
+ # updateViewedDate=true and an empty request body.
1389
1424
  # @param [String] fields
1390
1425
  # Selector specifying which fields to include in a partial response.
1391
1426
  # @param [String] quota_user
@@ -1410,11 +1445,10 @@ module Google
1410
1445
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1411
1446
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1412
1447
  def watch_file(file_id, channel_object = nil, acknowledge_abuse: nil, projection: nil, revision_id: nil, update_viewed_date: nil, fields: nil, quota_user: nil, user_ip: nil, download_dest: nil, options: nil, &block)
1413
- path = 'files/{fileId}/watch'
1414
1448
  if download_dest.nil?
1415
- command = make_simple_command(:post, path, options)
1449
+ command = make_simple_command(:post, 'files/{fileId}/watch', options)
1416
1450
  else
1417
- command = make_download_command(:post, path, options)
1451
+ command = make_download_command(:post, 'files/{fileId}/watch', options)
1418
1452
  command.download_dest = download_dest
1419
1453
  end
1420
1454
  command.request_representation = Google::Apis::DriveV2::Channel::Representation
@@ -1459,8 +1493,7 @@ module Google
1459
1493
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1460
1494
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1461
1495
  def delete_parent(file_id, parent_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1462
- path = 'files/{fileId}/parents/{parentId}'
1463
- command = make_simple_command(:delete, path, options)
1496
+ command = make_simple_command(:delete, 'files/{fileId}/parents/{parentId}', options)
1464
1497
  command.params['fileId'] = file_id unless file_id.nil?
1465
1498
  command.params['parentId'] = parent_id unless parent_id.nil?
1466
1499
  command.query['fields'] = fields unless fields.nil?
@@ -1496,8 +1529,7 @@ module Google
1496
1529
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1497
1530
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1498
1531
  def get_parent(file_id, parent_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1499
- path = 'files/{fileId}/parents/{parentId}'
1500
- command = make_simple_command(:get, path, options)
1532
+ command = make_simple_command(:get, 'files/{fileId}/parents/{parentId}', options)
1501
1533
  command.response_representation = Google::Apis::DriveV2::ParentReference::Representation
1502
1534
  command.response_class = Google::Apis::DriveV2::ParentReference
1503
1535
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1534,8 +1566,7 @@ module Google
1534
1566
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1535
1567
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1536
1568
  def insert_parent(file_id, parent_reference_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1537
- path = 'files/{fileId}/parents'
1538
- command = make_simple_command(:post, path, options)
1569
+ command = make_simple_command(:post, 'files/{fileId}/parents', options)
1539
1570
  command.request_representation = Google::Apis::DriveV2::ParentReference::Representation
1540
1571
  command.request_object = parent_reference_object
1541
1572
  command.response_representation = Google::Apis::DriveV2::ParentReference::Representation
@@ -1572,8 +1603,7 @@ module Google
1572
1603
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1573
1604
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1574
1605
  def list_parents(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1575
- path = 'files/{fileId}/parents'
1576
- command = make_simple_command(:get, path, options)
1606
+ command = make_simple_command(:get, 'files/{fileId}/parents', options)
1577
1607
  command.response_representation = Google::Apis::DriveV2::ParentList::Representation
1578
1608
  command.response_class = Google::Apis::DriveV2::ParentList
1579
1609
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1610,8 +1640,7 @@ module Google
1610
1640
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1611
1641
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1612
1642
  def delete_permission(file_id, permission_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1613
- path = 'files/{fileId}/permissions/{permissionId}'
1614
- command = make_simple_command(:delete, path, options)
1643
+ command = make_simple_command(:delete, 'files/{fileId}/permissions/{permissionId}', options)
1615
1644
  command.params['fileId'] = file_id unless file_id.nil?
1616
1645
  command.params['permissionId'] = permission_id unless permission_id.nil?
1617
1646
  command.query['fields'] = fields unless fields.nil?
@@ -1647,8 +1676,7 @@ module Google
1647
1676
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1648
1677
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1649
1678
  def get_permission(file_id, permission_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1650
- path = 'files/{fileId}/permissions/{permissionId}'
1651
- command = make_simple_command(:get, path, options)
1679
+ command = make_simple_command(:get, 'files/{fileId}/permissions/{permissionId}', options)
1652
1680
  command.response_representation = Google::Apis::DriveV2::Permission::Representation
1653
1681
  command.response_class = Google::Apis::DriveV2::Permission
1654
1682
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1684,8 +1712,7 @@ module Google
1684
1712
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1685
1713
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1686
1714
  def get_permission_id_for_email(email, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1687
- path = 'permissionIds/{email}'
1688
- command = make_simple_command(:get, path, options)
1715
+ command = make_simple_command(:get, 'permissionIds/{email}', options)
1689
1716
  command.response_representation = Google::Apis::DriveV2::PermissionId::Representation
1690
1717
  command.response_class = Google::Apis::DriveV2::PermissionId
1691
1718
  command.params['email'] = email unless email.nil?
@@ -1726,8 +1753,7 @@ module Google
1726
1753
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1727
1754
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1728
1755
  def insert_permission(file_id, permission_object = nil, email_message: nil, send_notification_emails: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1729
- path = 'files/{fileId}/permissions'
1730
- command = make_simple_command(:post, path, options)
1756
+ command = make_simple_command(:post, 'files/{fileId}/permissions', options)
1731
1757
  command.request_representation = Google::Apis::DriveV2::Permission::Representation
1732
1758
  command.request_object = permission_object
1733
1759
  command.response_representation = Google::Apis::DriveV2::Permission::Representation
@@ -1766,8 +1792,7 @@ module Google
1766
1792
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1767
1793
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1768
1794
  def list_permissions(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1769
- path = 'files/{fileId}/permissions'
1770
- command = make_simple_command(:get, path, options)
1795
+ command = make_simple_command(:get, 'files/{fileId}/permissions', options)
1771
1796
  command.response_representation = Google::Apis::DriveV2::PermissionList::Representation
1772
1797
  command.response_class = Google::Apis::DriveV2::PermissionList
1773
1798
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1777,7 +1802,7 @@ module Google
1777
1802
  execute_or_queue_command(command, &block)
1778
1803
  end
1779
1804
 
1780
- # Updates a permission. This method supports patch semantics.
1805
+ # Updates a permission using patch semantics.
1781
1806
  # @param [String] file_id
1782
1807
  # The ID for the file.
1783
1808
  # @param [String] permission_id
@@ -1808,8 +1833,7 @@ module Google
1808
1833
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1809
1834
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1810
1835
  def patch_permission(file_id, permission_id, permission_object = nil, transfer_ownership: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1811
- path = 'files/{fileId}/permissions/{permissionId}'
1812
- command = make_simple_command(:patch, path, options)
1836
+ command = make_simple_command(:patch, 'files/{fileId}/permissions/{permissionId}', options)
1813
1837
  command.request_representation = Google::Apis::DriveV2::Permission::Representation
1814
1838
  command.request_object = permission_object
1815
1839
  command.response_representation = Google::Apis::DriveV2::Permission::Representation
@@ -1854,8 +1878,7 @@ module Google
1854
1878
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1855
1879
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1856
1880
  def update_permission(file_id, permission_id, permission_object = nil, transfer_ownership: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1857
- path = 'files/{fileId}/permissions/{permissionId}'
1858
- command = make_simple_command(:put, path, options)
1881
+ command = make_simple_command(:put, 'files/{fileId}/permissions/{permissionId}', options)
1859
1882
  command.request_representation = Google::Apis::DriveV2::Permission::Representation
1860
1883
  command.request_object = permission_object
1861
1884
  command.response_representation = Google::Apis::DriveV2::Permission::Representation
@@ -1898,8 +1921,7 @@ module Google
1898
1921
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1899
1922
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1900
1923
  def delete_property(file_id, property_key, visibility: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1901
- path = 'files/{fileId}/properties/{propertyKey}'
1902
- command = make_simple_command(:delete, path, options)
1924
+ command = make_simple_command(:delete, 'files/{fileId}/properties/{propertyKey}', options)
1903
1925
  command.params['fileId'] = file_id unless file_id.nil?
1904
1926
  command.params['propertyKey'] = property_key unless property_key.nil?
1905
1927
  command.query['visibility'] = visibility unless visibility.nil?
@@ -1938,8 +1960,7 @@ module Google
1938
1960
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1939
1961
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1940
1962
  def get_property(file_id, property_key, visibility: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1941
- path = 'files/{fileId}/properties/{propertyKey}'
1942
- command = make_simple_command(:get, path, options)
1963
+ command = make_simple_command(:get, 'files/{fileId}/properties/{propertyKey}', options)
1943
1964
  command.response_representation = Google::Apis::DriveV2::Property::Representation
1944
1965
  command.response_class = Google::Apis::DriveV2::Property
1945
1966
  command.params['fileId'] = file_id unless file_id.nil?
@@ -1977,8 +1998,7 @@ module Google
1977
1998
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1978
1999
  # @raise [Google::Apis::AuthorizationError] Authorization is required
1979
2000
  def insert_property(file_id, property_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
1980
- path = 'files/{fileId}/properties'
1981
- command = make_simple_command(:post, path, options)
2001
+ command = make_simple_command(:post, 'files/{fileId}/properties', options)
1982
2002
  command.request_representation = Google::Apis::DriveV2::Property::Representation
1983
2003
  command.request_object = property_object
1984
2004
  command.response_representation = Google::Apis::DriveV2::Property::Representation
@@ -2015,8 +2035,7 @@ module Google
2015
2035
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2016
2036
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2017
2037
  def list_properties(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2018
- path = 'files/{fileId}/properties'
2019
- command = make_simple_command(:get, path, options)
2038
+ command = make_simple_command(:get, 'files/{fileId}/properties', options)
2020
2039
  command.response_representation = Google::Apis::DriveV2::PropertyList::Representation
2021
2040
  command.response_class = Google::Apis::DriveV2::PropertyList
2022
2041
  command.params['fileId'] = file_id unless file_id.nil?
@@ -2056,8 +2075,7 @@ module Google
2056
2075
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2057
2076
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2058
2077
  def patch_property(file_id, property_key, property_object = nil, visibility: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2059
- path = 'files/{fileId}/properties/{propertyKey}'
2060
- command = make_simple_command(:patch, path, options)
2078
+ command = make_simple_command(:patch, 'files/{fileId}/properties/{propertyKey}', options)
2061
2079
  command.request_representation = Google::Apis::DriveV2::Property::Representation
2062
2080
  command.request_object = property_object
2063
2081
  command.response_representation = Google::Apis::DriveV2::Property::Representation
@@ -2101,8 +2119,7 @@ module Google
2101
2119
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2102
2120
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2103
2121
  def update_property(file_id, property_key, property_object = nil, visibility: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2104
- path = 'files/{fileId}/properties/{propertyKey}'
2105
- command = make_simple_command(:put, path, options)
2122
+ command = make_simple_command(:put, 'files/{fileId}/properties/{propertyKey}', options)
2106
2123
  command.request_representation = Google::Apis::DriveV2::Property::Representation
2107
2124
  command.request_object = property_object
2108
2125
  command.response_representation = Google::Apis::DriveV2::Property::Representation
@@ -2148,11 +2165,10 @@ module Google
2148
2165
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2149
2166
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2150
2167
  def get_realtime(file_id, revision: nil, fields: nil, quota_user: nil, user_ip: nil, download_dest: nil, options: nil, &block)
2151
- path = 'files/{fileId}/realtime'
2152
2168
  if download_dest.nil?
2153
- command = make_simple_command(:get, path, options)
2169
+ command = make_simple_command(:get, 'files/{fileId}/realtime', options)
2154
2170
  else
2155
- command = make_download_command(:get, path, options)
2171
+ command = make_download_command(:get, 'files/{fileId}/realtime', options)
2156
2172
  command.download_dest = download_dest
2157
2173
  end
2158
2174
  command.params['fileId'] = file_id unless file_id.nil?
@@ -2198,11 +2214,10 @@ module Google
2198
2214
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2199
2215
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2200
2216
  def update_realtime(file_id, base_revision: nil, fields: nil, quota_user: nil, user_ip: nil, upload_source: nil, content_type: nil, options: nil, &block)
2201
- path = 'files/{fileId}/realtime'
2202
2217
  if upload_source.nil?
2203
- command = make_simple_command(:put, path, options)
2218
+ command = make_simple_command(:put, 'files/{fileId}/realtime', options)
2204
2219
  else
2205
- command = make_upload_command(:put, path, options)
2220
+ command = make_upload_command(:put, 'files/{fileId}/realtime', options)
2206
2221
  command.upload_source = upload_source
2207
2222
  command.upload_content_type = content_type
2208
2223
  end
@@ -2243,8 +2258,7 @@ module Google
2243
2258
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2244
2259
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2245
2260
  def delete_reply(file_id, comment_id, reply_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2246
- path = 'files/{fileId}/comments/{commentId}/replies/{replyId}'
2247
- command = make_simple_command(:delete, path, options)
2261
+ command = make_simple_command(:delete, 'files/{fileId}/comments/{commentId}/replies/{replyId}', options)
2248
2262
  command.params['fileId'] = file_id unless file_id.nil?
2249
2263
  command.params['commentId'] = comment_id unless comment_id.nil?
2250
2264
  command.params['replyId'] = reply_id unless reply_id.nil?
@@ -2285,8 +2299,7 @@ module Google
2285
2299
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2286
2300
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2287
2301
  def get_reply(file_id, comment_id, reply_id, include_deleted: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2288
- path = 'files/{fileId}/comments/{commentId}/replies/{replyId}'
2289
- command = make_simple_command(:get, path, options)
2302
+ command = make_simple_command(:get, 'files/{fileId}/comments/{commentId}/replies/{replyId}', options)
2290
2303
  command.response_representation = Google::Apis::DriveV2::CommentReply::Representation
2291
2304
  command.response_class = Google::Apis::DriveV2::CommentReply
2292
2305
  command.params['fileId'] = file_id unless file_id.nil?
@@ -2327,8 +2340,7 @@ module Google
2327
2340
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2328
2341
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2329
2342
  def insert_reply(file_id, comment_id, comment_reply_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2330
- path = 'files/{fileId}/comments/{commentId}/replies'
2331
- command = make_simple_command(:post, path, options)
2343
+ command = make_simple_command(:post, 'files/{fileId}/comments/{commentId}/replies', options)
2332
2344
  command.request_representation = Google::Apis::DriveV2::CommentReply::Representation
2333
2345
  command.request_object = comment_reply_object
2334
2346
  command.response_representation = Google::Apis::DriveV2::CommentReply::Representation
@@ -2377,8 +2389,7 @@ module Google
2377
2389
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2378
2390
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2379
2391
  def list_replies(file_id, comment_id, include_deleted: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2380
- path = 'files/{fileId}/comments/{commentId}/replies'
2381
- command = make_simple_command(:get, path, options)
2392
+ command = make_simple_command(:get, 'files/{fileId}/comments/{commentId}/replies', options)
2382
2393
  command.response_representation = Google::Apis::DriveV2::CommentReplyList::Representation
2383
2394
  command.response_class = Google::Apis::DriveV2::CommentReplyList
2384
2395
  command.params['fileId'] = file_id unless file_id.nil?
@@ -2422,8 +2433,7 @@ module Google
2422
2433
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2423
2434
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2424
2435
  def patch_reply(file_id, comment_id, reply_id, comment_reply_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2425
- path = 'files/{fileId}/comments/{commentId}/replies/{replyId}'
2426
- command = make_simple_command(:patch, path, options)
2436
+ command = make_simple_command(:patch, 'files/{fileId}/comments/{commentId}/replies/{replyId}', options)
2427
2437
  command.request_representation = Google::Apis::DriveV2::CommentReply::Representation
2428
2438
  command.request_object = comment_reply_object
2429
2439
  command.response_representation = Google::Apis::DriveV2::CommentReply::Representation
@@ -2467,8 +2477,7 @@ module Google
2467
2477
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2468
2478
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2469
2479
  def update_reply(file_id, comment_id, reply_id, comment_reply_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2470
- path = 'files/{fileId}/comments/{commentId}/replies/{replyId}'
2471
- command = make_simple_command(:put, path, options)
2480
+ command = make_simple_command(:put, 'files/{fileId}/comments/{commentId}/replies/{replyId}', options)
2472
2481
  command.request_representation = Google::Apis::DriveV2::CommentReply::Representation
2473
2482
  command.request_object = comment_reply_object
2474
2483
  command.response_representation = Google::Apis::DriveV2::CommentReply::Representation
@@ -2509,8 +2518,7 @@ module Google
2509
2518
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2510
2519
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2511
2520
  def delete_revision(file_id, revision_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2512
- path = 'files/{fileId}/revisions/{revisionId}'
2513
- command = make_simple_command(:delete, path, options)
2521
+ command = make_simple_command(:delete, 'files/{fileId}/revisions/{revisionId}', options)
2514
2522
  command.params['fileId'] = file_id unless file_id.nil?
2515
2523
  command.params['revisionId'] = revision_id unless revision_id.nil?
2516
2524
  command.query['fields'] = fields unless fields.nil?
@@ -2546,8 +2554,7 @@ module Google
2546
2554
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2547
2555
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2548
2556
  def get_revision(file_id, revision_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2549
- path = 'files/{fileId}/revisions/{revisionId}'
2550
- command = make_simple_command(:get, path, options)
2557
+ command = make_simple_command(:get, 'files/{fileId}/revisions/{revisionId}', options)
2551
2558
  command.response_representation = Google::Apis::DriveV2::Revision::Representation
2552
2559
  command.response_class = Google::Apis::DriveV2::Revision
2553
2560
  command.params['fileId'] = file_id unless file_id.nil?
@@ -2583,8 +2590,7 @@ module Google
2583
2590
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2584
2591
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2585
2592
  def list_revisions(file_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2586
- path = 'files/{fileId}/revisions'
2587
- command = make_simple_command(:get, path, options)
2593
+ command = make_simple_command(:get, 'files/{fileId}/revisions', options)
2588
2594
  command.response_representation = Google::Apis::DriveV2::RevisionList::Representation
2589
2595
  command.response_class = Google::Apis::DriveV2::RevisionList
2590
2596
  command.params['fileId'] = file_id unless file_id.nil?
@@ -2622,8 +2628,7 @@ module Google
2622
2628
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2623
2629
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2624
2630
  def patch_revision(file_id, revision_id, revision_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2625
- path = 'files/{fileId}/revisions/{revisionId}'
2626
- command = make_simple_command(:patch, path, options)
2631
+ command = make_simple_command(:patch, 'files/{fileId}/revisions/{revisionId}', options)
2627
2632
  command.request_representation = Google::Apis::DriveV2::Revision::Representation
2628
2633
  command.request_object = revision_object
2629
2634
  command.response_representation = Google::Apis::DriveV2::Revision::Representation
@@ -2664,8 +2669,7 @@ module Google
2664
2669
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
2665
2670
  # @raise [Google::Apis::AuthorizationError] Authorization is required
2666
2671
  def update_revision(file_id, revision_id, revision_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
2667
- path = 'files/{fileId}/revisions/{revisionId}'
2668
- command = make_simple_command(:put, path, options)
2672
+ command = make_simple_command(:put, 'files/{fileId}/revisions/{revisionId}', options)
2669
2673
  command.request_representation = Google::Apis::DriveV2::Revision::Representation
2670
2674
  command.request_object = revision_object
2671
2675
  command.response_representation = Google::Apis::DriveV2::Revision::Representation