google-api-client 0.12.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (315) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +7 -0
  3. data/api_names.yaml +945 -41609
  4. data/generated/google/apis/acceleratedmobilepageurl_v1/classes.rb +12 -12
  5. data/generated/google/apis/acceleratedmobilepageurl_v1/representations.rb +2 -2
  6. data/generated/google/apis/adexchangebuyer2_v2beta1.rb +1 -1
  7. data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +1437 -412
  8. data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +516 -71
  9. data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +1098 -422
  10. data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +6 -6
  11. data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +3 -3
  12. data/generated/google/apis/adexchangebuyer_v1_4/service.rb +3 -3
  13. data/generated/google/apis/adexchangeseller_v2_0/service.rb +10 -10
  14. data/generated/google/apis/admin_directory_v1/service.rb +26 -26
  15. data/generated/google/apis/adsense_v1_4.rb +1 -1
  16. data/generated/google/apis/adsense_v1_4/classes.rb +2 -2
  17. data/generated/google/apis/adsense_v1_4/representations.rb +3 -3
  18. data/generated/google/apis/adsense_v1_4/service.rb +44 -44
  19. data/generated/google/apis/adsensehost_v4_1.rb +1 -1
  20. data/generated/google/apis/adsensehost_v4_1/service.rb +22 -22
  21. data/generated/google/apis/analytics_v3/classes.rb +3 -3
  22. data/generated/google/apis/analytics_v3/representations.rb +3 -3
  23. data/generated/google/apis/analytics_v3/service.rb +82 -82
  24. data/generated/google/apis/analyticsreporting_v4/classes.rb +937 -937
  25. data/generated/google/apis/analyticsreporting_v4/representations.rb +128 -128
  26. data/generated/google/apis/analyticsreporting_v4/service.rb +1 -1
  27. data/generated/google/apis/androidenterprise_v1.rb +1 -1
  28. data/generated/google/apis/androidenterprise_v1/classes.rb +10 -10
  29. data/generated/google/apis/androidenterprise_v1/representations.rb +20 -20
  30. data/generated/google/apis/androidenterprise_v1/service.rb +43 -43
  31. data/generated/google/apis/androidpublisher_v2/classes.rb +26 -26
  32. data/generated/google/apis/androidpublisher_v2/representations.rb +46 -46
  33. data/generated/google/apis/androidpublisher_v2/service.rb +95 -95
  34. data/generated/google/apis/appengine_v1.rb +4 -4
  35. data/generated/google/apis/appengine_v1/classes.rb +1570 -1512
  36. data/generated/google/apis/appengine_v1/representations.rb +362 -343
  37. data/generated/google/apis/appengine_v1/service.rb +220 -220
  38. data/generated/google/apis/appstate_v1.rb +1 -1
  39. data/generated/google/apis/bigquery_v2.rb +1 -1
  40. data/generated/google/apis/bigquery_v2/classes.rb +5 -5
  41. data/generated/google/apis/bigquery_v2/representations.rb +8 -8
  42. data/generated/google/apis/bigquery_v2/service.rb +13 -13
  43. data/generated/google/apis/blogger_v3/service.rb +3 -3
  44. data/generated/google/apis/books_v1/classes.rb +55 -55
  45. data/generated/google/apis/books_v1/representations.rb +67 -67
  46. data/generated/google/apis/books_v1/service.rb +82 -82
  47. data/generated/google/apis/calendar_v3.rb +1 -1
  48. data/generated/google/apis/calendar_v3/classes.rb +6 -6
  49. data/generated/google/apis/calendar_v3/representations.rb +3 -3
  50. data/generated/google/apis/calendar_v3/service.rb +2 -2
  51. data/generated/google/apis/civicinfo_v2/classes.rb +2 -2
  52. data/generated/google/apis/civicinfo_v2/representations.rb +4 -4
  53. data/generated/google/apis/civicinfo_v2/service.rb +12 -12
  54. data/generated/google/apis/classroom_v1.rb +7 -7
  55. data/generated/google/apis/classroom_v1/classes.rb +1013 -991
  56. data/generated/google/apis/classroom_v1/representations.rb +207 -204
  57. data/generated/google/apis/classroom_v1/service.rb +709 -709
  58. data/generated/google/apis/cloudbuild_v1.rb +1 -1
  59. data/generated/google/apis/cloudbuild_v1/classes.rb +307 -307
  60. data/generated/google/apis/cloudbuild_v1/representations.rb +84 -84
  61. data/generated/google/apis/cloudbuild_v1/service.rb +125 -125
  62. data/generated/google/apis/clouddebugger_v2/classes.rb +673 -673
  63. data/generated/google/apis/clouddebugger_v2/representations.rb +152 -152
  64. data/generated/google/apis/clouddebugger_v2/service.rb +55 -55
  65. data/generated/google/apis/clouderrorreporting_v1beta1.rb +1 -1
  66. data/generated/google/apis/clouderrorreporting_v1beta1/classes.rb +121 -121
  67. data/generated/google/apis/clouderrorreporting_v1beta1/representations.rb +25 -25
  68. data/generated/google/apis/clouderrorreporting_v1beta1/service.rb +74 -74
  69. data/generated/google/apis/cloudkms_v1.rb +1 -1
  70. data/generated/google/apis/cloudkms_v1/classes.rb +668 -613
  71. data/generated/google/apis/cloudkms_v1/representations.rb +151 -133
  72. data/generated/google/apis/cloudkms_v1/service.rb +267 -267
  73. data/generated/google/apis/cloudresourcemanager_v1.rb +4 -4
  74. data/generated/google/apis/cloudresourcemanager_v1/classes.rb +1167 -1168
  75. data/generated/google/apis/cloudresourcemanager_v1/representations.rb +193 -193
  76. data/generated/google/apis/cloudresourcemanager_v1/service.rb +470 -469
  77. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +1 -1
  78. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +508 -509
  79. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +94 -94
  80. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +157 -156
  81. data/generated/google/apis/cloudtrace_v1/service.rb +34 -34
  82. data/generated/google/apis/compute_beta.rb +1 -1
  83. data/generated/google/apis/compute_beta/classes.rb +163 -15
  84. data/generated/google/apis/compute_beta/representations.rb +54 -14
  85. data/generated/google/apis/compute_beta/service.rb +2258 -482
  86. data/generated/google/apis/compute_v1.rb +1 -1
  87. data/generated/google/apis/compute_v1/classes.rb +465 -13
  88. data/generated/google/apis/compute_v1/representations.rb +202 -16
  89. data/generated/google/apis/compute_v1/service.rb +573 -309
  90. data/generated/google/apis/container_v1.rb +1 -1
  91. data/generated/google/apis/container_v1/classes.rb +635 -589
  92. data/generated/google/apis/container_v1/representations.rb +139 -111
  93. data/generated/google/apis/container_v1/service.rb +272 -227
  94. data/generated/google/apis/content_v2.rb +1 -1
  95. data/generated/google/apis/content_v2/classes.rb +86 -74
  96. data/generated/google/apis/content_v2/representations.rb +107 -105
  97. data/generated/google/apis/content_v2/service.rb +131 -130
  98. data/generated/google/apis/customsearch_v1.rb +2 -2
  99. data/generated/google/apis/customsearch_v1/classes.rb +0 -6
  100. data/generated/google/apis/customsearch_v1/representations.rb +0 -1
  101. data/generated/google/apis/customsearch_v1/service.rb +2 -5
  102. data/generated/google/apis/dataflow_v1b3.rb +7 -4
  103. data/generated/google/apis/dataflow_v1b3/classes.rb +3405 -3405
  104. data/generated/google/apis/dataflow_v1b3/representations.rb +834 -834
  105. data/generated/google/apis/dataflow_v1b3/service.rb +244 -244
  106. data/generated/google/apis/dataproc_v1.rb +1 -1
  107. data/generated/google/apis/dataproc_v1/classes.rb +543 -691
  108. data/generated/google/apis/dataproc_v1/representations.rb +129 -185
  109. data/generated/google/apis/dataproc_v1/service.rb +347 -347
  110. data/generated/google/apis/datastore_v1.rb +4 -4
  111. data/generated/google/apis/datastore_v1/classes.rb +833 -833
  112. data/generated/google/apis/datastore_v1/representations.rb +182 -182
  113. data/generated/google/apis/datastore_v1/service.rb +45 -45
  114. data/generated/google/apis/deploymentmanager_v2/classes.rb +5 -5
  115. data/generated/google/apis/deploymentmanager_v2/representations.rb +10 -10
  116. data/generated/google/apis/deploymentmanager_v2/service.rb +20 -20
  117. data/generated/google/apis/discovery_v1/classes.rb +4 -4
  118. data/generated/google/apis/discovery_v1/representations.rb +2 -2
  119. data/generated/google/apis/discovery_v1/service.rb +1 -1
  120. data/generated/google/apis/dns_v1.rb +1 -1
  121. data/generated/google/apis/dns_v1/classes.rb +3 -3
  122. data/generated/google/apis/dns_v1/representations.rb +6 -6
  123. data/generated/google/apis/dns_v1/service.rb +12 -12
  124. data/generated/google/apis/dns_v2beta1.rb +1 -1
  125. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +8 -8
  126. data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
  127. data/generated/google/apis/drive_v2.rb +1 -1
  128. data/generated/google/apis/drive_v2/classes.rb +1 -1
  129. data/generated/google/apis/drive_v2/service.rb +1 -1
  130. data/generated/google/apis/drive_v3.rb +1 -1
  131. data/generated/google/apis/drive_v3/service.rb +1 -1
  132. data/generated/google/apis/firebasedynamiclinks_v1.rb +1 -1
  133. data/generated/google/apis/firebasedynamiclinks_v1/classes.rb +160 -110
  134. data/generated/google/apis/firebasedynamiclinks_v1/representations.rb +60 -31
  135. data/generated/google/apis/firebasedynamiclinks_v1/service.rb +38 -3
  136. data/generated/google/apis/firebaserules_v1/classes.rb +354 -354
  137. data/generated/google/apis/firebaserules_v1/representations.rb +87 -87
  138. data/generated/google/apis/firebaserules_v1/service.rb +103 -103
  139. data/generated/google/apis/fusiontables_v2/service.rb +2 -2
  140. data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
  141. data/generated/google/apis/games_configuration_v1configuration/classes.rb +2 -2
  142. data/generated/google/apis/games_configuration_v1configuration/representations.rb +4 -4
  143. data/generated/google/apis/games_configuration_v1configuration/service.rb +8 -8
  144. data/generated/google/apis/games_management_v1management.rb +1 -1
  145. data/generated/google/apis/games_v1.rb +1 -1
  146. data/generated/google/apis/games_v1/classes.rb +23 -23
  147. data/generated/google/apis/games_v1/representations.rb +43 -43
  148. data/generated/google/apis/games_v1/service.rb +72 -72
  149. data/generated/google/apis/genomics_v1.rb +1 -1
  150. data/generated/google/apis/genomics_v1/classes.rb +2316 -2316
  151. data/generated/google/apis/genomics_v1/representations.rb +291 -291
  152. data/generated/google/apis/genomics_v1/service.rb +821 -821
  153. data/generated/google/apis/gmail_v1.rb +1 -1
  154. data/generated/google/apis/groupsmigration_v1.rb +1 -1
  155. data/generated/google/apis/groupssettings_v1.rb +1 -1
  156. data/generated/google/apis/groupssettings_v1/classes.rb +2 -2
  157. data/generated/google/apis/groupssettings_v1/service.rb +3 -0
  158. data/generated/google/apis/iam_v1/classes.rb +338 -338
  159. data/generated/google/apis/iam_v1/representations.rb +98 -98
  160. data/generated/google/apis/iam_v1/service.rb +35 -35
  161. data/generated/google/apis/identitytoolkit_v3/classes.rb +15 -15
  162. data/generated/google/apis/identitytoolkit_v3/representations.rb +30 -30
  163. data/generated/google/apis/identitytoolkit_v3/service.rb +64 -64
  164. data/generated/google/apis/kgsearch_v1/service.rb +13 -13
  165. data/generated/google/apis/language_v1.rb +1 -1
  166. data/generated/google/apis/language_v1/classes.rb +374 -374
  167. data/generated/google/apis/language_v1/representations.rb +97 -97
  168. data/generated/google/apis/language_v1/service.rb +16 -16
  169. data/generated/google/apis/language_v1beta1.rb +1 -1
  170. data/generated/google/apis/language_v1beta1/classes.rb +441 -441
  171. data/generated/google/apis/language_v1beta1/representations.rb +108 -108
  172. data/generated/google/apis/language_v1beta1/service.rb +30 -30
  173. data/generated/google/apis/licensing_v1/service.rb +2 -2
  174. data/generated/google/apis/logging_v2.rb +1 -1
  175. data/generated/google/apis/logging_v2/classes.rb +712 -712
  176. data/generated/google/apis/logging_v2/representations.rb +109 -109
  177. data/generated/google/apis/logging_v2/service.rb +543 -539
  178. data/generated/google/apis/logging_v2beta1.rb +1 -1
  179. data/generated/google/apis/logging_v2beta1/classes.rb +752 -752
  180. data/generated/google/apis/logging_v2beta1/representations.rb +94 -94
  181. data/generated/google/apis/logging_v2beta1/service.rb +257 -256
  182. data/generated/google/apis/manufacturers_v1/classes.rb +130 -130
  183. data/generated/google/apis/manufacturers_v1/representations.rb +28 -28
  184. data/generated/google/apis/mirror_v1/classes.rb +5 -5
  185. data/generated/google/apis/mirror_v1/representations.rb +10 -10
  186. data/generated/google/apis/mirror_v1/service.rb +20 -20
  187. data/generated/google/apis/ml_v1.rb +1 -1
  188. data/generated/google/apis/ml_v1/classes.rb +1830 -1210
  189. data/generated/google/apis/ml_v1/representations.rb +342 -120
  190. data/generated/google/apis/ml_v1/service.rb +365 -258
  191. data/generated/google/apis/monitoring_v3.rb +4 -4
  192. data/generated/google/apis/monitoring_v3/classes.rb +889 -889
  193. data/generated/google/apis/monitoring_v3/representations.rb +174 -174
  194. data/generated/google/apis/monitoring_v3/service.rb +119 -119
  195. data/generated/google/apis/mybusiness_v3/service.rb +5 -5
  196. data/generated/google/apis/oauth2_v2/service.rb +1 -1
  197. data/generated/google/apis/pagespeedonline_v2/classes.rb +11 -11
  198. data/generated/google/apis/pagespeedonline_v2/representations.rb +13 -13
  199. data/generated/google/apis/pagespeedonline_v2/service.rb +1 -1
  200. data/generated/google/apis/partners_v2.rb +1 -1
  201. data/generated/google/apis/partners_v2/classes.rb +550 -536
  202. data/generated/google/apis/partners_v2/representations.rb +118 -116
  203. data/generated/google/apis/partners_v2/service.rb +439 -439
  204. data/generated/google/apis/people_v1.rb +4 -4
  205. data/generated/google/apis/people_v1/classes.rb +414 -413
  206. data/generated/google/apis/people_v1/representations.rb +85 -85
  207. data/generated/google/apis/people_v1/service.rb +111 -18
  208. data/generated/google/apis/plus_domains_v1.rb +1 -1
  209. data/generated/google/apis/plus_domains_v1/service.rb +4 -4
  210. data/generated/google/apis/plus_v1.rb +1 -1
  211. data/generated/google/apis/plus_v1/service.rb +1 -1
  212. data/generated/google/apis/prediction_v1_6/service.rb +8 -8
  213. data/generated/google/apis/proximitybeacon_v1beta1.rb +1 -1
  214. data/generated/google/apis/proximitybeacon_v1beta1/classes.rb +443 -443
  215. data/generated/google/apis/proximitybeacon_v1beta1/representations.rb +92 -92
  216. data/generated/google/apis/proximitybeacon_v1beta1/service.rb +152 -152
  217. data/generated/google/apis/pubsub_v1/classes.rb +249 -249
  218. data/generated/google/apis/pubsub_v1/representations.rb +80 -80
  219. data/generated/google/apis/pubsub_v1/service.rb +415 -415
  220. data/generated/google/apis/qpx_express_v1/classes.rb +2 -2
  221. data/generated/google/apis/qpx_express_v1/representations.rb +4 -4
  222. data/generated/google/apis/qpx_express_v1/service.rb +8 -8
  223. data/generated/google/apis/replicapool_v1beta2/classes.rb +5 -5
  224. data/generated/google/apis/replicapool_v1beta2/representations.rb +10 -10
  225. data/generated/google/apis/replicapool_v1beta2/service.rb +21 -21
  226. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +1 -1
  227. data/generated/google/apis/resourceviews_v1beta2/classes.rb +5 -5
  228. data/generated/google/apis/resourceviews_v1beta2/representations.rb +10 -10
  229. data/generated/google/apis/resourceviews_v1beta2/service.rb +20 -20
  230. data/generated/google/apis/runtimeconfig_v1.rb +4 -4
  231. data/generated/google/apis/runtimeconfig_v1/classes.rb +15 -15
  232. data/generated/google/apis/runtimeconfig_v1/representations.rb +2 -2
  233. data/generated/google/apis/runtimeconfig_v1/service.rb +4 -4
  234. data/generated/google/apis/script_v1.rb +17 -17
  235. data/generated/google/apis/script_v1/classes.rb +27 -27
  236. data/generated/google/apis/script_v1/representations.rb +5 -5
  237. data/generated/google/apis/script_v1/service.rb +4 -4
  238. data/generated/google/apis/searchconsole_v1.rb +1 -1
  239. data/generated/google/apis/searchconsole_v1/classes.rb +53 -53
  240. data/generated/google/apis/searchconsole_v1/representations.rb +23 -23
  241. data/generated/google/apis/searchconsole_v1/service.rb +4 -4
  242. data/generated/google/apis/servicecontrol_v1.rb +1 -1
  243. data/generated/google/apis/servicecontrol_v1/classes.rb +1175 -1175
  244. data/generated/google/apis/servicecontrol_v1/representations.rb +206 -206
  245. data/generated/google/apis/servicecontrol_v1/service.rb +116 -116
  246. data/generated/google/apis/servicemanagement_v1.rb +1 -1
  247. data/generated/google/apis/servicemanagement_v1/classes.rb +1186 -1125
  248. data/generated/google/apis/servicemanagement_v1/representations.rb +241 -223
  249. data/generated/google/apis/servicemanagement_v1/service.rb +201 -201
  250. data/generated/google/apis/serviceuser_v1.rb +1 -1
  251. data/generated/google/apis/serviceuser_v1/classes.rb +2645 -2641
  252. data/generated/google/apis/serviceuser_v1/representations.rb +234 -234
  253. data/generated/google/apis/serviceuser_v1/service.rb +37 -37
  254. data/generated/google/apis/sheets_v4.rb +1 -1
  255. data/generated/google/apis/sheets_v4/classes.rb +5042 -4111
  256. data/generated/google/apis/sheets_v4/representations.rb +994 -824
  257. data/generated/google/apis/sheets_v4/service.rb +80 -80
  258. data/generated/google/apis/site_verification_v1/classes.rb +6 -6
  259. data/generated/google/apis/site_verification_v1/representations.rb +8 -8
  260. data/generated/google/apis/site_verification_v1/service.rb +12 -12
  261. data/generated/google/apis/slides_v1.rb +1 -1
  262. data/generated/google/apis/slides_v1/classes.rb +2885 -2885
  263. data/generated/google/apis/slides_v1/representations.rb +310 -310
  264. data/generated/google/apis/slides_v1/service.rb +54 -54
  265. data/generated/google/apis/sourcerepo_v1/classes.rb +206 -206
  266. data/generated/google/apis/sourcerepo_v1/representations.rb +52 -52
  267. data/generated/google/apis/sourcerepo_v1/service.rb +5 -5
  268. data/generated/google/apis/spanner_v1.rb +1 -1
  269. data/generated/google/apis/spanner_v1/classes.rb +2142 -2141
  270. data/generated/google/apis/spanner_v1/representations.rb +174 -174
  271. data/generated/google/apis/spanner_v1/service.rb +497 -497
  272. data/generated/google/apis/speech_v1beta1.rb +1 -1
  273. data/generated/google/apis/speech_v1beta1/classes.rb +227 -227
  274. data/generated/google/apis/speech_v1beta1/representations.rb +50 -50
  275. data/generated/google/apis/speech_v1beta1/service.rb +33 -33
  276. data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
  277. data/generated/google/apis/sqladmin_v1beta4/classes.rb +21 -21
  278. data/generated/google/apis/sqladmin_v1beta4/representations.rb +29 -29
  279. data/generated/google/apis/sqladmin_v1beta4/service.rb +56 -56
  280. data/generated/google/apis/storage_v1.rb +1 -1
  281. data/generated/google/apis/storage_v1/classes.rb +40 -6
  282. data/generated/google/apis/storage_v1/representations.rb +20 -4
  283. data/generated/google/apis/storage_v1/service.rb +61 -46
  284. data/generated/google/apis/storagetransfer_v1.rb +1 -1
  285. data/generated/google/apis/storagetransfer_v1/classes.rb +184 -184
  286. data/generated/google/apis/storagetransfer_v1/representations.rb +35 -35
  287. data/generated/google/apis/storagetransfer_v1/service.rb +70 -70
  288. data/generated/google/apis/tagmanager_v1/service.rb +33 -33
  289. data/generated/google/apis/toolresults_v1beta3.rb +1 -1
  290. data/generated/google/apis/translate_v2/classes.rb +12 -12
  291. data/generated/google/apis/translate_v2/representations.rb +10 -10
  292. data/generated/google/apis/translate_v2/service.rb +62 -62
  293. data/generated/google/apis/vision_v1.rb +1 -1
  294. data/generated/google/apis/vision_v1/classes.rb +1267 -1267
  295. data/generated/google/apis/vision_v1/representations.rb +200 -200
  296. data/generated/google/apis/vision_v1/service.rb +10 -10
  297. data/generated/google/apis/webmasters_v3.rb +1 -1
  298. data/generated/google/apis/webmasters_v3/classes.rb +4 -4
  299. data/generated/google/apis/webmasters_v3/representations.rb +8 -8
  300. data/generated/google/apis/webmasters_v3/service.rb +21 -21
  301. data/generated/google/apis/youtube_analytics_v1.rb +1 -1
  302. data/generated/google/apis/youtube_analytics_v1/classes.rb +2 -2
  303. data/generated/google/apis/youtube_analytics_v1/representations.rb +4 -4
  304. data/generated/google/apis/youtube_analytics_v1/service.rb +8 -8
  305. data/generated/google/apis/youtube_v3/classes.rb +20 -20
  306. data/generated/google/apis/youtube_v3/representations.rb +40 -40
  307. data/generated/google/apis/youtube_v3/service.rb +80 -80
  308. data/generated/google/apis/youtubereporting_v1.rb +1 -1
  309. data/generated/google/apis/youtubereporting_v1/classes.rb +129 -129
  310. data/generated/google/apis/youtubereporting_v1/representations.rb +38 -38
  311. data/generated/google/apis/youtubereporting_v1/service.rb +97 -97
  312. data/lib/google/apis/generator/annotator.rb +2 -2
  313. data/lib/google/apis/generator/model.rb +2 -2
  314. data/lib/google/apis/version.rb +1 -1
  315. metadata +2 -2
@@ -22,300 +22,300 @@ module Google
22
22
  module Apis
23
23
  module PubsubV1
24
24
 
25
- class PublishResponse
25
+ class ListTopicSubscriptionsResponse
26
26
  class Representation < Google::Apis::Core::JsonRepresentation; end
27
27
 
28
28
  include Google::Apis::Core::JsonObjectSupport
29
29
  end
30
30
 
31
- class Subscription
31
+ class PullResponse
32
32
  class Representation < Google::Apis::Core::JsonRepresentation; end
33
33
 
34
34
  include Google::Apis::Core::JsonObjectSupport
35
35
  end
36
36
 
37
- class TestIamPermissionsRequest
37
+ class ReceivedMessage
38
38
  class Representation < Google::Apis::Core::JsonRepresentation; end
39
39
 
40
40
  include Google::Apis::Core::JsonObjectSupport
41
41
  end
42
42
 
43
- class Topic
43
+ class PushConfig
44
44
  class Representation < Google::Apis::Core::JsonRepresentation; end
45
45
 
46
46
  include Google::Apis::Core::JsonObjectSupport
47
47
  end
48
48
 
49
- class Policy
49
+ class TestIamPermissionsResponse
50
50
  class Representation < Google::Apis::Core::JsonRepresentation; end
51
51
 
52
52
  include Google::Apis::Core::JsonObjectSupport
53
53
  end
54
54
 
55
- class ModifyAckDeadlineRequest
55
+ class PullRequest
56
56
  class Representation < Google::Apis::Core::JsonRepresentation; end
57
57
 
58
58
  include Google::Apis::Core::JsonObjectSupport
59
59
  end
60
60
 
61
- class SetIamPolicyRequest
61
+ class ListSubscriptionsResponse
62
62
  class Representation < Google::Apis::Core::JsonRepresentation; end
63
63
 
64
64
  include Google::Apis::Core::JsonObjectSupport
65
65
  end
66
66
 
67
- class ModifyPushConfigRequest
67
+ class PublishRequest
68
68
  class Representation < Google::Apis::Core::JsonRepresentation; end
69
69
 
70
70
  include Google::Apis::Core::JsonObjectSupport
71
71
  end
72
72
 
73
- class PubsubMessage
73
+ class PublishResponse
74
74
  class Representation < Google::Apis::Core::JsonRepresentation; end
75
75
 
76
76
  include Google::Apis::Core::JsonObjectSupport
77
77
  end
78
78
 
79
- class Binding
79
+ class Subscription
80
80
  class Representation < Google::Apis::Core::JsonRepresentation; end
81
81
 
82
82
  include Google::Apis::Core::JsonObjectSupport
83
83
  end
84
84
 
85
- class AcknowledgeRequest
85
+ class TestIamPermissionsRequest
86
86
  class Representation < Google::Apis::Core::JsonRepresentation; end
87
87
 
88
88
  include Google::Apis::Core::JsonObjectSupport
89
89
  end
90
90
 
91
- class Empty
91
+ class Topic
92
92
  class Representation < Google::Apis::Core::JsonRepresentation; end
93
93
 
94
94
  include Google::Apis::Core::JsonObjectSupport
95
95
  end
96
96
 
97
- class ListTopicsResponse
97
+ class Policy
98
98
  class Representation < Google::Apis::Core::JsonRepresentation; end
99
99
 
100
100
  include Google::Apis::Core::JsonObjectSupport
101
101
  end
102
102
 
103
- class ListTopicSubscriptionsResponse
103
+ class ModifyAckDeadlineRequest
104
104
  class Representation < Google::Apis::Core::JsonRepresentation; end
105
105
 
106
106
  include Google::Apis::Core::JsonObjectSupport
107
107
  end
108
108
 
109
- class PullResponse
109
+ class SetIamPolicyRequest
110
110
  class Representation < Google::Apis::Core::JsonRepresentation; end
111
111
 
112
112
  include Google::Apis::Core::JsonObjectSupport
113
113
  end
114
114
 
115
- class ReceivedMessage
115
+ class ModifyPushConfigRequest
116
116
  class Representation < Google::Apis::Core::JsonRepresentation; end
117
117
 
118
118
  include Google::Apis::Core::JsonObjectSupport
119
119
  end
120
120
 
121
- class PushConfig
121
+ class Message
122
122
  class Representation < Google::Apis::Core::JsonRepresentation; end
123
123
 
124
124
  include Google::Apis::Core::JsonObjectSupport
125
125
  end
126
126
 
127
- class TestIamPermissionsResponse
127
+ class Binding
128
128
  class Representation < Google::Apis::Core::JsonRepresentation; end
129
129
 
130
130
  include Google::Apis::Core::JsonObjectSupport
131
131
  end
132
132
 
133
- class PullRequest
133
+ class ListTopicsResponse
134
134
  class Representation < Google::Apis::Core::JsonRepresentation; end
135
135
 
136
136
  include Google::Apis::Core::JsonObjectSupport
137
137
  end
138
138
 
139
- class ListSubscriptionsResponse
139
+ class Empty
140
140
  class Representation < Google::Apis::Core::JsonRepresentation; end
141
141
 
142
142
  include Google::Apis::Core::JsonObjectSupport
143
143
  end
144
144
 
145
- class PublishRequest
145
+ class AcknowledgeRequest
146
146
  class Representation < Google::Apis::Core::JsonRepresentation; end
147
147
 
148
148
  include Google::Apis::Core::JsonObjectSupport
149
149
  end
150
150
 
151
- class PublishResponse
151
+ class ListTopicSubscriptionsResponse
152
152
  # @private
153
153
  class Representation < Google::Apis::Core::JsonRepresentation
154
- collection :message_ids, as: 'messageIds'
154
+ property :next_page_token, as: 'nextPageToken'
155
+ collection :subscriptions, as: 'subscriptions'
155
156
  end
156
157
  end
157
158
 
158
- class Subscription
159
+ class PullResponse
159
160
  # @private
160
161
  class Representation < Google::Apis::Core::JsonRepresentation
161
- property :topic, as: 'topic'
162
- property :push_config, as: 'pushConfig', class: Google::Apis::PubsubV1::PushConfig, decorator: Google::Apis::PubsubV1::PushConfig::Representation
162
+ collection :received_messages, as: 'receivedMessages', class: Google::Apis::PubsubV1::ReceivedMessage, decorator: Google::Apis::PubsubV1::ReceivedMessage::Representation
163
163
 
164
- property :ack_deadline_seconds, as: 'ackDeadlineSeconds'
165
- property :name, as: 'name'
166
164
  end
167
165
  end
168
166
 
169
- class TestIamPermissionsRequest
167
+ class ReceivedMessage
170
168
  # @private
171
169
  class Representation < Google::Apis::Core::JsonRepresentation
172
- collection :permissions, as: 'permissions'
170
+ property :message, as: 'message', class: Google::Apis::PubsubV1::Message, decorator: Google::Apis::PubsubV1::Message::Representation
171
+
172
+ property :ack_id, as: 'ackId'
173
173
  end
174
174
  end
175
175
 
176
- class Topic
176
+ class PushConfig
177
177
  # @private
178
178
  class Representation < Google::Apis::Core::JsonRepresentation
179
- property :name, as: 'name'
179
+ property :push_endpoint, as: 'pushEndpoint'
180
+ hash :attributes, as: 'attributes'
180
181
  end
181
182
  end
182
183
 
183
- class Policy
184
+ class TestIamPermissionsResponse
184
185
  # @private
185
186
  class Representation < Google::Apis::Core::JsonRepresentation
186
- property :etag, :base64 => true, as: 'etag'
187
- property :version, as: 'version'
188
- collection :bindings, as: 'bindings', class: Google::Apis::PubsubV1::Binding, decorator: Google::Apis::PubsubV1::Binding::Representation
189
-
187
+ collection :permissions, as: 'permissions'
190
188
  end
191
189
  end
192
190
 
193
- class ModifyAckDeadlineRequest
191
+ class PullRequest
194
192
  # @private
195
193
  class Representation < Google::Apis::Core::JsonRepresentation
196
- property :ack_deadline_seconds, as: 'ackDeadlineSeconds'
197
- collection :ack_ids, as: 'ackIds'
194
+ property :return_immediately, as: 'returnImmediately'
195
+ property :max_messages, as: 'maxMessages'
198
196
  end
199
197
  end
200
198
 
201
- class SetIamPolicyRequest
199
+ class ListSubscriptionsResponse
202
200
  # @private
203
201
  class Representation < Google::Apis::Core::JsonRepresentation
204
- property :policy, as: 'policy', class: Google::Apis::PubsubV1::Policy, decorator: Google::Apis::PubsubV1::Policy::Representation
202
+ property :next_page_token, as: 'nextPageToken'
203
+ collection :subscriptions, as: 'subscriptions', class: Google::Apis::PubsubV1::Subscription, decorator: Google::Apis::PubsubV1::Subscription::Representation
205
204
 
206
205
  end
207
206
  end
208
207
 
209
- class ModifyPushConfigRequest
208
+ class PublishRequest
210
209
  # @private
211
210
  class Representation < Google::Apis::Core::JsonRepresentation
212
- property :push_config, as: 'pushConfig', class: Google::Apis::PubsubV1::PushConfig, decorator: Google::Apis::PubsubV1::PushConfig::Representation
211
+ collection :messages, as: 'messages', class: Google::Apis::PubsubV1::Message, decorator: Google::Apis::PubsubV1::Message::Representation
213
212
 
214
213
  end
215
214
  end
216
215
 
217
- class PubsubMessage
216
+ class PublishResponse
218
217
  # @private
219
218
  class Representation < Google::Apis::Core::JsonRepresentation
220
- hash :attributes, as: 'attributes'
221
- property :message_id, as: 'messageId'
222
- property :publish_time, as: 'publishTime'
223
- property :data, :base64 => true, as: 'data'
219
+ collection :message_ids, as: 'messageIds'
224
220
  end
225
221
  end
226
222
 
227
- class Binding
223
+ class Subscription
228
224
  # @private
229
225
  class Representation < Google::Apis::Core::JsonRepresentation
230
- collection :members, as: 'members'
231
- property :role, as: 'role'
226
+ property :push_config, as: 'pushConfig', class: Google::Apis::PubsubV1::PushConfig, decorator: Google::Apis::PubsubV1::PushConfig::Representation
227
+
228
+ property :ack_deadline_seconds, as: 'ackDeadlineSeconds'
229
+ property :name, as: 'name'
230
+ property :topic, as: 'topic'
232
231
  end
233
232
  end
234
233
 
235
- class AcknowledgeRequest
234
+ class TestIamPermissionsRequest
236
235
  # @private
237
236
  class Representation < Google::Apis::Core::JsonRepresentation
238
- collection :ack_ids, as: 'ackIds'
237
+ collection :permissions, as: 'permissions'
239
238
  end
240
239
  end
241
240
 
242
- class Empty
241
+ class Topic
243
242
  # @private
244
243
  class Representation < Google::Apis::Core::JsonRepresentation
244
+ property :name, as: 'name'
245
245
  end
246
246
  end
247
247
 
248
- class ListTopicsResponse
248
+ class Policy
249
249
  # @private
250
250
  class Representation < Google::Apis::Core::JsonRepresentation
251
- property :next_page_token, as: 'nextPageToken'
252
- collection :topics, as: 'topics', class: Google::Apis::PubsubV1::Topic, decorator: Google::Apis::PubsubV1::Topic::Representation
251
+ property :etag, :base64 => true, as: 'etag'
252
+ property :version, as: 'version'
253
+ collection :bindings, as: 'bindings', class: Google::Apis::PubsubV1::Binding, decorator: Google::Apis::PubsubV1::Binding::Representation
253
254
 
254
255
  end
255
256
  end
256
257
 
257
- class ListTopicSubscriptionsResponse
258
+ class ModifyAckDeadlineRequest
258
259
  # @private
259
260
  class Representation < Google::Apis::Core::JsonRepresentation
260
- property :next_page_token, as: 'nextPageToken'
261
- collection :subscriptions, as: 'subscriptions'
261
+ property :ack_deadline_seconds, as: 'ackDeadlineSeconds'
262
+ collection :ack_ids, as: 'ackIds'
262
263
  end
263
264
  end
264
265
 
265
- class PullResponse
266
+ class SetIamPolicyRequest
266
267
  # @private
267
268
  class Representation < Google::Apis::Core::JsonRepresentation
268
- collection :received_messages, as: 'receivedMessages', class: Google::Apis::PubsubV1::ReceivedMessage, decorator: Google::Apis::PubsubV1::ReceivedMessage::Representation
269
+ property :policy, as: 'policy', class: Google::Apis::PubsubV1::Policy, decorator: Google::Apis::PubsubV1::Policy::Representation
269
270
 
270
271
  end
271
272
  end
272
273
 
273
- class ReceivedMessage
274
+ class ModifyPushConfigRequest
274
275
  # @private
275
276
  class Representation < Google::Apis::Core::JsonRepresentation
276
- property :message, as: 'message', class: Google::Apis::PubsubV1::PubsubMessage, decorator: Google::Apis::PubsubV1::PubsubMessage::Representation
277
+ property :push_config, as: 'pushConfig', class: Google::Apis::PubsubV1::PushConfig, decorator: Google::Apis::PubsubV1::PushConfig::Representation
277
278
 
278
- property :ack_id, as: 'ackId'
279
279
  end
280
280
  end
281
281
 
282
- class PushConfig
282
+ class Message
283
283
  # @private
284
284
  class Representation < Google::Apis::Core::JsonRepresentation
285
- property :push_endpoint, as: 'pushEndpoint'
285
+ property :data, :base64 => true, as: 'data'
286
286
  hash :attributes, as: 'attributes'
287
+ property :message_id, as: 'messageId'
288
+ property :publish_time, as: 'publishTime'
287
289
  end
288
290
  end
289
291
 
290
- class TestIamPermissionsResponse
292
+ class Binding
291
293
  # @private
292
294
  class Representation < Google::Apis::Core::JsonRepresentation
293
- collection :permissions, as: 'permissions'
295
+ collection :members, as: 'members'
296
+ property :role, as: 'role'
294
297
  end
295
298
  end
296
299
 
297
- class PullRequest
300
+ class ListTopicsResponse
298
301
  # @private
299
302
  class Representation < Google::Apis::Core::JsonRepresentation
300
- property :return_immediately, as: 'returnImmediately'
301
- property :max_messages, as: 'maxMessages'
303
+ collection :topics, as: 'topics', class: Google::Apis::PubsubV1::Topic, decorator: Google::Apis::PubsubV1::Topic::Representation
304
+
305
+ property :next_page_token, as: 'nextPageToken'
302
306
  end
303
307
  end
304
308
 
305
- class ListSubscriptionsResponse
309
+ class Empty
306
310
  # @private
307
311
  class Representation < Google::Apis::Core::JsonRepresentation
308
- property :next_page_token, as: 'nextPageToken'
309
- collection :subscriptions, as: 'subscriptions', class: Google::Apis::PubsubV1::Subscription, decorator: Google::Apis::PubsubV1::Subscription::Representation
310
-
311
312
  end
312
313
  end
313
314
 
314
- class PublishRequest
315
+ class AcknowledgeRequest
315
316
  # @private
316
317
  class Representation < Google::Apis::Core::JsonRepresentation
317
- collection :messages, as: 'messages', class: Google::Apis::PubsubV1::PubsubMessage, decorator: Google::Apis::PubsubV1::PubsubMessage::Representation
318
-
318
+ collection :ack_ids, as: 'ackIds'
319
319
  end
320
320
  end
321
321
  end
@@ -47,231 +47,290 @@ module Google
47
47
  @batch_path = 'batch'
48
48
  end
49
49
 
50
- # Creates the given topic with the given name.
51
- # @param [String] name
52
- # The name of the topic. It must have the format
53
- # `"projects/`project`/topics/`topic`"`. ``topic`` must start with a letter,
54
- # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
55
- # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
56
- # signs (`%`). It must be between 3 and 255 characters in length, and it
57
- # must not start with `"goog"`.
58
- # @param [Google::Apis::PubsubV1::Topic] topic_object
59
- # @param [String] fields
60
- # Selector specifying which fields to include in a partial response.
50
+ # Returns permissions that a caller has on the specified resource.
51
+ # If the resource does not exist, this will return an empty set of
52
+ # permissions, not a NOT_FOUND error.
53
+ # Note: This operation is designed to be used for building permission-aware
54
+ # UIs and command-line tools, not for authorization checking. This operation
55
+ # may "fail open" without warning.
56
+ # @param [String] resource
57
+ # REQUIRED: The resource for which the policy detail is being requested.
58
+ # See the operation documentation for the appropriate value for this field.
59
+ # @param [Google::Apis::PubsubV1::TestIamPermissionsRequest] test_iam_permissions_request_object
61
60
  # @param [String] quota_user
62
61
  # Available to use for quota purposes for server-side applications. Can be any
63
62
  # arbitrary string assigned to a user, but should not exceed 40 characters.
63
+ # @param [String] fields
64
+ # Selector specifying which fields to include in a partial response.
64
65
  # @param [Google::Apis::RequestOptions] options
65
66
  # Request-specific options
66
67
  #
67
68
  # @yield [result, err] Result & error if block supplied
68
- # @yieldparam result [Google::Apis::PubsubV1::Topic] parsed result object
69
+ # @yieldparam result [Google::Apis::PubsubV1::TestIamPermissionsResponse] parsed result object
69
70
  # @yieldparam err [StandardError] error object if request failed
70
71
  #
71
- # @return [Google::Apis::PubsubV1::Topic]
72
+ # @return [Google::Apis::PubsubV1::TestIamPermissionsResponse]
72
73
  #
73
74
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
74
75
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
75
76
  # @raise [Google::Apis::AuthorizationError] Authorization is required
76
- def create_project_topic(name, topic_object = nil, fields: nil, quota_user: nil, options: nil, &block)
77
- command = make_simple_command(:put, 'v1/{+name}', options)
78
- command.request_representation = Google::Apis::PubsubV1::Topic::Representation
79
- command.request_object = topic_object
80
- command.response_representation = Google::Apis::PubsubV1::Topic::Representation
81
- command.response_class = Google::Apis::PubsubV1::Topic
82
- command.params['name'] = name unless name.nil?
83
- command.query['fields'] = fields unless fields.nil?
77
+ def test_subscription_iam_permissions(resource, test_iam_permissions_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
78
+ command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
79
+ command.request_representation = Google::Apis::PubsubV1::TestIamPermissionsRequest::Representation
80
+ command.request_object = test_iam_permissions_request_object
81
+ command.response_representation = Google::Apis::PubsubV1::TestIamPermissionsResponse::Representation
82
+ command.response_class = Google::Apis::PubsubV1::TestIamPermissionsResponse
83
+ command.params['resource'] = resource unless resource.nil?
84
84
  command.query['quotaUser'] = quota_user unless quota_user.nil?
85
+ command.query['fields'] = fields unless fields.nil?
85
86
  execute_or_queue_command(command, &block)
86
87
  end
87
88
 
88
- # Sets the access control policy on the specified resource. Replaces any
89
- # existing policy.
90
- # @param [String] resource
91
- # REQUIRED: The resource for which the policy is being specified.
92
- # See the operation documentation for the appropriate value for this field.
93
- # @param [Google::Apis::PubsubV1::SetIamPolicyRequest] set_iam_policy_request_object
94
- # @param [String] fields
95
- # Selector specifying which fields to include in a partial response.
89
+ # Modifies the `PushConfig` for a specified subscription.
90
+ # This may be used to change a push subscription to a pull one (signified by
91
+ # an empty `PushConfig`) or vice versa, or change the endpoint URL and other
92
+ # attributes of a push subscription. Messages will accumulate for delivery
93
+ # continuously through the call regardless of changes to the `PushConfig`.
94
+ # @param [String] subscription
95
+ # The name of the subscription.
96
+ # Format is `projects/`project`/subscriptions/`sub``.
97
+ # @param [Google::Apis::PubsubV1::ModifyPushConfigRequest] modify_push_config_request_object
96
98
  # @param [String] quota_user
97
99
  # Available to use for quota purposes for server-side applications. Can be any
98
100
  # arbitrary string assigned to a user, but should not exceed 40 characters.
101
+ # @param [String] fields
102
+ # Selector specifying which fields to include in a partial response.
99
103
  # @param [Google::Apis::RequestOptions] options
100
104
  # Request-specific options
101
105
  #
102
106
  # @yield [result, err] Result & error if block supplied
103
- # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
107
+ # @yieldparam result [Google::Apis::PubsubV1::Empty] parsed result object
104
108
  # @yieldparam err [StandardError] error object if request failed
105
109
  #
106
- # @return [Google::Apis::PubsubV1::Policy]
110
+ # @return [Google::Apis::PubsubV1::Empty]
107
111
  #
108
112
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
109
113
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
110
114
  # @raise [Google::Apis::AuthorizationError] Authorization is required
111
- def set_topic_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
112
- command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
113
- command.request_representation = Google::Apis::PubsubV1::SetIamPolicyRequest::Representation
114
- command.request_object = set_iam_policy_request_object
115
- command.response_representation = Google::Apis::PubsubV1::Policy::Representation
116
- command.response_class = Google::Apis::PubsubV1::Policy
117
- command.params['resource'] = resource unless resource.nil?
118
- command.query['fields'] = fields unless fields.nil?
115
+ def modify_subscription_push_config(subscription, modify_push_config_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
116
+ command = make_simple_command(:post, 'v1/{+subscription}:modifyPushConfig', options)
117
+ command.request_representation = Google::Apis::PubsubV1::ModifyPushConfigRequest::Representation
118
+ command.request_object = modify_push_config_request_object
119
+ command.response_representation = Google::Apis::PubsubV1::Empty::Representation
120
+ command.response_class = Google::Apis::PubsubV1::Empty
121
+ command.params['subscription'] = subscription unless subscription.nil?
119
122
  command.query['quotaUser'] = quota_user unless quota_user.nil?
123
+ command.query['fields'] = fields unless fields.nil?
120
124
  execute_or_queue_command(command, &block)
121
125
  end
122
126
 
123
- # Gets the access control policy for a resource.
124
- # Returns an empty policy if the resource exists and does not have a policy
125
- # set.
126
- # @param [String] resource
127
- # REQUIRED: The resource for which the policy is being requested.
128
- # See the operation documentation for the appropriate value for this field.
129
- # @param [String] fields
130
- # Selector specifying which fields to include in a partial response.
127
+ # Deletes an existing subscription. All messages retained in the subscription
128
+ # are immediately dropped. Calls to `Pull` after deletion will return
129
+ # `NOT_FOUND`. After a subscription is deleted, a new one may be created with
130
+ # the same name, but the new one has no association with the old
131
+ # subscription or its topic unless the same topic is specified.
132
+ # @param [String] subscription
133
+ # The subscription to delete.
134
+ # Format is `projects/`project`/subscriptions/`sub``.
131
135
  # @param [String] quota_user
132
136
  # Available to use for quota purposes for server-side applications. Can be any
133
137
  # arbitrary string assigned to a user, but should not exceed 40 characters.
138
+ # @param [String] fields
139
+ # Selector specifying which fields to include in a partial response.
134
140
  # @param [Google::Apis::RequestOptions] options
135
141
  # Request-specific options
136
142
  #
137
143
  # @yield [result, err] Result & error if block supplied
138
- # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
144
+ # @yieldparam result [Google::Apis::PubsubV1::Empty] parsed result object
139
145
  # @yieldparam err [StandardError] error object if request failed
140
146
  #
141
- # @return [Google::Apis::PubsubV1::Policy]
147
+ # @return [Google::Apis::PubsubV1::Empty]
142
148
  #
143
149
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
144
150
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
145
151
  # @raise [Google::Apis::AuthorizationError] Authorization is required
146
- def get_project_topic_iam_policy(resource, fields: nil, quota_user: nil, options: nil, &block)
147
- command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
148
- command.response_representation = Google::Apis::PubsubV1::Policy::Representation
149
- command.response_class = Google::Apis::PubsubV1::Policy
150
- command.params['resource'] = resource unless resource.nil?
151
- command.query['fields'] = fields unless fields.nil?
152
+ def delete_subscription(subscription, quota_user: nil, fields: nil, options: nil, &block)
153
+ command = make_simple_command(:delete, 'v1/{+subscription}', options)
154
+ command.response_representation = Google::Apis::PubsubV1::Empty::Representation
155
+ command.response_class = Google::Apis::PubsubV1::Empty
156
+ command.params['subscription'] = subscription unless subscription.nil?
152
157
  command.query['quotaUser'] = quota_user unless quota_user.nil?
158
+ command.query['fields'] = fields unless fields.nil?
153
159
  execute_or_queue_command(command, &block)
154
160
  end
155
161
 
156
- # Gets the configuration of a topic.
157
- # @param [String] topic
158
- # The name of the topic to get.
159
- # Format is `projects/`project`/topics/`topic``.
160
- # @param [String] fields
161
- # Selector specifying which fields to include in a partial response.
162
+ # Pulls messages from the server. Returns an empty list if there are no
163
+ # messages available in the backlog. The server may return `UNAVAILABLE` if
164
+ # there are too many concurrent pull requests pending for the given
165
+ # subscription.
166
+ # @param [String] subscription
167
+ # The subscription from which messages should be pulled.
168
+ # Format is `projects/`project`/subscriptions/`sub``.
169
+ # @param [Google::Apis::PubsubV1::PullRequest] pull_request_object
162
170
  # @param [String] quota_user
163
171
  # Available to use for quota purposes for server-side applications. Can be any
164
172
  # arbitrary string assigned to a user, but should not exceed 40 characters.
173
+ # @param [String] fields
174
+ # Selector specifying which fields to include in a partial response.
165
175
  # @param [Google::Apis::RequestOptions] options
166
176
  # Request-specific options
167
177
  #
168
178
  # @yield [result, err] Result & error if block supplied
169
- # @yieldparam result [Google::Apis::PubsubV1::Topic] parsed result object
179
+ # @yieldparam result [Google::Apis::PubsubV1::PullResponse] parsed result object
170
180
  # @yieldparam err [StandardError] error object if request failed
171
181
  #
172
- # @return [Google::Apis::PubsubV1::Topic]
182
+ # @return [Google::Apis::PubsubV1::PullResponse]
173
183
  #
174
184
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
175
185
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
176
186
  # @raise [Google::Apis::AuthorizationError] Authorization is required
177
- def get_project_topic(topic, fields: nil, quota_user: nil, options: nil, &block)
178
- command = make_simple_command(:get, 'v1/{+topic}', options)
179
- command.response_representation = Google::Apis::PubsubV1::Topic::Representation
180
- command.response_class = Google::Apis::PubsubV1::Topic
181
- command.params['topic'] = topic unless topic.nil?
182
- command.query['fields'] = fields unless fields.nil?
187
+ def pull_subscription(subscription, pull_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
188
+ command = make_simple_command(:post, 'v1/{+subscription}:pull', options)
189
+ command.request_representation = Google::Apis::PubsubV1::PullRequest::Representation
190
+ command.request_object = pull_request_object
191
+ command.response_representation = Google::Apis::PubsubV1::PullResponse::Representation
192
+ command.response_class = Google::Apis::PubsubV1::PullResponse
193
+ command.params['subscription'] = subscription unless subscription.nil?
183
194
  command.query['quotaUser'] = quota_user unless quota_user.nil?
195
+ command.query['fields'] = fields unless fields.nil?
184
196
  execute_or_queue_command(command, &block)
185
197
  end
186
198
 
187
- # Adds one or more messages to the topic. Returns `NOT_FOUND` if the topic
188
- # does not exist. The message payload must not be empty; it must contain
189
- # either a non-empty data field, or at least one attribute.
190
- # @param [String] topic
191
- # The messages in the request will be published on this topic.
192
- # Format is `projects/`project`/topics/`topic``.
193
- # @param [Google::Apis::PubsubV1::PublishRequest] publish_request_object
194
- # @param [String] fields
195
- # Selector specifying which fields to include in a partial response.
199
+ # Lists matching subscriptions.
200
+ # @param [String] project
201
+ # The name of the cloud project that subscriptions belong to.
202
+ # Format is `projects/`project``.
203
+ # @param [String] page_token
204
+ # The value returned by the last `ListSubscriptionsResponse`; indicates that
205
+ # this is a continuation of a prior `ListSubscriptions` call, and that the
206
+ # system should return the next page of data.
207
+ # @param [Fixnum] page_size
208
+ # Maximum number of subscriptions to return.
196
209
  # @param [String] quota_user
197
210
  # Available to use for quota purposes for server-side applications. Can be any
198
211
  # arbitrary string assigned to a user, but should not exceed 40 characters.
212
+ # @param [String] fields
213
+ # Selector specifying which fields to include in a partial response.
199
214
  # @param [Google::Apis::RequestOptions] options
200
215
  # Request-specific options
201
216
  #
202
217
  # @yield [result, err] Result & error if block supplied
203
- # @yieldparam result [Google::Apis::PubsubV1::PublishResponse] parsed result object
218
+ # @yieldparam result [Google::Apis::PubsubV1::ListSubscriptionsResponse] parsed result object
204
219
  # @yieldparam err [StandardError] error object if request failed
205
220
  #
206
- # @return [Google::Apis::PubsubV1::PublishResponse]
221
+ # @return [Google::Apis::PubsubV1::ListSubscriptionsResponse]
207
222
  #
208
223
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
209
224
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
210
225
  # @raise [Google::Apis::AuthorizationError] Authorization is required
211
- def publish_topic(topic, publish_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
212
- command = make_simple_command(:post, 'v1/{+topic}:publish', options)
213
- command.request_representation = Google::Apis::PubsubV1::PublishRequest::Representation
214
- command.request_object = publish_request_object
215
- command.response_representation = Google::Apis::PubsubV1::PublishResponse::Representation
216
- command.response_class = Google::Apis::PubsubV1::PublishResponse
217
- command.params['topic'] = topic unless topic.nil?
218
- command.query['fields'] = fields unless fields.nil?
226
+ def list_subscriptions(project, page_token: nil, page_size: nil, quota_user: nil, fields: nil, options: nil, &block)
227
+ command = make_simple_command(:get, 'v1/{+project}/subscriptions', options)
228
+ command.response_representation = Google::Apis::PubsubV1::ListSubscriptionsResponse::Representation
229
+ command.response_class = Google::Apis::PubsubV1::ListSubscriptionsResponse
230
+ command.params['project'] = project unless project.nil?
231
+ command.query['pageToken'] = page_token unless page_token.nil?
232
+ command.query['pageSize'] = page_size unless page_size.nil?
219
233
  command.query['quotaUser'] = quota_user unless quota_user.nil?
234
+ command.query['fields'] = fields unless fields.nil?
220
235
  execute_or_queue_command(command, &block)
221
236
  end
222
237
 
223
- # Returns permissions that a caller has on the specified resource.
224
- # If the resource does not exist, this will return an empty set of
225
- # permissions, not a NOT_FOUND error.
226
- # Note: This operation is designed to be used for building permission-aware
227
- # UIs and command-line tools, not for authorization checking. This operation
228
- # may "fail open" without warning.
238
+ # Sets the access control policy on the specified resource. Replaces any
239
+ # existing policy.
229
240
  # @param [String] resource
230
- # REQUIRED: The resource for which the policy detail is being requested.
241
+ # REQUIRED: The resource for which the policy is being specified.
231
242
  # See the operation documentation for the appropriate value for this field.
232
- # @param [Google::Apis::PubsubV1::TestIamPermissionsRequest] test_iam_permissions_request_object
233
- # @param [String] fields
234
- # Selector specifying which fields to include in a partial response.
243
+ # @param [Google::Apis::PubsubV1::SetIamPolicyRequest] set_iam_policy_request_object
235
244
  # @param [String] quota_user
236
245
  # Available to use for quota purposes for server-side applications. Can be any
237
246
  # arbitrary string assigned to a user, but should not exceed 40 characters.
247
+ # @param [String] fields
248
+ # Selector specifying which fields to include in a partial response.
238
249
  # @param [Google::Apis::RequestOptions] options
239
250
  # Request-specific options
240
251
  #
241
252
  # @yield [result, err] Result & error if block supplied
242
- # @yieldparam result [Google::Apis::PubsubV1::TestIamPermissionsResponse] parsed result object
253
+ # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
243
254
  # @yieldparam err [StandardError] error object if request failed
244
255
  #
245
- # @return [Google::Apis::PubsubV1::TestIamPermissionsResponse]
256
+ # @return [Google::Apis::PubsubV1::Policy]
246
257
  #
247
258
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
248
259
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
249
260
  # @raise [Google::Apis::AuthorizationError] Authorization is required
250
- def test_topic_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
251
- command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
252
- command.request_representation = Google::Apis::PubsubV1::TestIamPermissionsRequest::Representation
253
- command.request_object = test_iam_permissions_request_object
254
- command.response_representation = Google::Apis::PubsubV1::TestIamPermissionsResponse::Representation
255
- command.response_class = Google::Apis::PubsubV1::TestIamPermissionsResponse
261
+ def set_subscription_iam_policy(resource, set_iam_policy_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
262
+ command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
263
+ command.request_representation = Google::Apis::PubsubV1::SetIamPolicyRequest::Representation
264
+ command.request_object = set_iam_policy_request_object
265
+ command.response_representation = Google::Apis::PubsubV1::Policy::Representation
266
+ command.response_class = Google::Apis::PubsubV1::Policy
256
267
  command.params['resource'] = resource unless resource.nil?
257
- command.query['fields'] = fields unless fields.nil?
258
268
  command.query['quotaUser'] = quota_user unless quota_user.nil?
269
+ command.query['fields'] = fields unless fields.nil?
259
270
  execute_or_queue_command(command, &block)
260
271
  end
261
272
 
262
- # Deletes the topic with the given name. Returns `NOT_FOUND` if the topic
263
- # does not exist. After a topic is deleted, a new topic may be created with
264
- # the same name; this is an entirely new topic with none of the old
265
- # configuration or subscriptions. Existing subscriptions to this topic are
266
- # not deleted, but their `topic` field is set to `_deleted-topic_`.
267
- # @param [String] topic
268
- # Name of the topic to delete.
269
- # Format is `projects/`project`/topics/`topic``.
273
+ # Creates a subscription to a given topic.
274
+ # If the subscription already exists, returns `ALREADY_EXISTS`.
275
+ # If the corresponding topic doesn't exist, returns `NOT_FOUND`.
276
+ # If the name is not provided in the request, the server will assign a random
277
+ # name for this subscription on the same project as the topic, conforming
278
+ # to the
279
+ # [resource name format](https://cloud.google.com/pubsub/docs/overview#names).
280
+ # The generated name is populated in the returned Subscription object.
281
+ # Note that for REST API requests, you must specify a name in the request.
282
+ # @param [String] name
283
+ # The name of the subscription. It must have the format
284
+ # `"projects/`project`/subscriptions/`subscription`"`. ``subscription`` must
285
+ # start with a letter, and contain only letters (`[A-Za-z]`), numbers
286
+ # (`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
287
+ # plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
288
+ # in length, and it must not start with `"goog"`.
289
+ # @param [Google::Apis::PubsubV1::Subscription] subscription_object
290
+ # @param [String] quota_user
291
+ # Available to use for quota purposes for server-side applications. Can be any
292
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
270
293
  # @param [String] fields
271
294
  # Selector specifying which fields to include in a partial response.
295
+ # @param [Google::Apis::RequestOptions] options
296
+ # Request-specific options
297
+ #
298
+ # @yield [result, err] Result & error if block supplied
299
+ # @yieldparam result [Google::Apis::PubsubV1::Subscription] parsed result object
300
+ # @yieldparam err [StandardError] error object if request failed
301
+ #
302
+ # @return [Google::Apis::PubsubV1::Subscription]
303
+ #
304
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
305
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
306
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
307
+ def create_subscription(name, subscription_object = nil, quota_user: nil, fields: nil, options: nil, &block)
308
+ command = make_simple_command(:put, 'v1/{+name}', options)
309
+ command.request_representation = Google::Apis::PubsubV1::Subscription::Representation
310
+ command.request_object = subscription_object
311
+ command.response_representation = Google::Apis::PubsubV1::Subscription::Representation
312
+ command.response_class = Google::Apis::PubsubV1::Subscription
313
+ command.params['name'] = name unless name.nil?
314
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
315
+ command.query['fields'] = fields unless fields.nil?
316
+ execute_or_queue_command(command, &block)
317
+ end
318
+
319
+ # Acknowledges the messages associated with the `ack_ids` in the
320
+ # `AcknowledgeRequest`. The Pub/Sub system can remove the relevant messages
321
+ # from the subscription.
322
+ # Acknowledging a message whose ack deadline has expired may succeed,
323
+ # but such a message may be redelivered later. Acknowledging a message more
324
+ # than once will not result in an error.
325
+ # @param [String] subscription
326
+ # The subscription whose message is being acknowledged.
327
+ # Format is `projects/`project`/subscriptions/`sub``.
328
+ # @param [Google::Apis::PubsubV1::AcknowledgeRequest] acknowledge_request_object
272
329
  # @param [String] quota_user
273
330
  # Available to use for quota purposes for server-side applications. Can be any
274
331
  # arbitrary string assigned to a user, but should not exceed 40 characters.
332
+ # @param [String] fields
333
+ # Selector specifying which fields to include in a partial response.
275
334
  # @param [Google::Apis::RequestOptions] options
276
335
  # Request-specific options
277
336
  #
@@ -284,91 +343,86 @@ module Google
284
343
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
285
344
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
286
345
  # @raise [Google::Apis::AuthorizationError] Authorization is required
287
- def delete_project_topic(topic, fields: nil, quota_user: nil, options: nil, &block)
288
- command = make_simple_command(:delete, 'v1/{+topic}', options)
346
+ def acknowledge_subscription(subscription, acknowledge_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
347
+ command = make_simple_command(:post, 'v1/{+subscription}:acknowledge', options)
348
+ command.request_representation = Google::Apis::PubsubV1::AcknowledgeRequest::Representation
349
+ command.request_object = acknowledge_request_object
289
350
  command.response_representation = Google::Apis::PubsubV1::Empty::Representation
290
351
  command.response_class = Google::Apis::PubsubV1::Empty
291
- command.params['topic'] = topic unless topic.nil?
292
- command.query['fields'] = fields unless fields.nil?
352
+ command.params['subscription'] = subscription unless subscription.nil?
293
353
  command.query['quotaUser'] = quota_user unless quota_user.nil?
354
+ command.query['fields'] = fields unless fields.nil?
294
355
  execute_or_queue_command(command, &block)
295
356
  end
296
357
 
297
- # Lists matching topics.
298
- # @param [String] project
299
- # The name of the cloud project that topics belong to.
300
- # Format is `projects/`project``.
301
- # @param [String] page_token
302
- # The value returned by the last `ListTopicsResponse`; indicates that this is
303
- # a continuation of a prior `ListTopics` call, and that the system should
304
- # return the next page of data.
305
- # @param [Fixnum] page_size
306
- # Maximum number of topics to return.
307
- # @param [String] fields
308
- # Selector specifying which fields to include in a partial response.
358
+ # Modifies the ack deadline for a specific message. This method is useful
359
+ # to indicate that more time is needed to process a message by the
360
+ # subscriber, or to make the message available for redelivery if the
361
+ # processing was interrupted. Note that this does not modify the
362
+ # subscription-level `ackDeadlineSeconds` used for subsequent messages.
363
+ # @param [String] subscription
364
+ # The name of the subscription.
365
+ # Format is `projects/`project`/subscriptions/`sub``.
366
+ # @param [Google::Apis::PubsubV1::ModifyAckDeadlineRequest] modify_ack_deadline_request_object
309
367
  # @param [String] quota_user
310
368
  # Available to use for quota purposes for server-side applications. Can be any
311
369
  # arbitrary string assigned to a user, but should not exceed 40 characters.
370
+ # @param [String] fields
371
+ # Selector specifying which fields to include in a partial response.
312
372
  # @param [Google::Apis::RequestOptions] options
313
373
  # Request-specific options
314
374
  #
315
375
  # @yield [result, err] Result & error if block supplied
316
- # @yieldparam result [Google::Apis::PubsubV1::ListTopicsResponse] parsed result object
376
+ # @yieldparam result [Google::Apis::PubsubV1::Empty] parsed result object
317
377
  # @yieldparam err [StandardError] error object if request failed
318
378
  #
319
- # @return [Google::Apis::PubsubV1::ListTopicsResponse]
379
+ # @return [Google::Apis::PubsubV1::Empty]
320
380
  #
321
381
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
322
382
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
323
383
  # @raise [Google::Apis::AuthorizationError] Authorization is required
324
- def list_project_topics(project, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
325
- command = make_simple_command(:get, 'v1/{+project}/topics', options)
326
- command.response_representation = Google::Apis::PubsubV1::ListTopicsResponse::Representation
327
- command.response_class = Google::Apis::PubsubV1::ListTopicsResponse
328
- command.params['project'] = project unless project.nil?
329
- command.query['pageToken'] = page_token unless page_token.nil?
330
- command.query['pageSize'] = page_size unless page_size.nil?
331
- command.query['fields'] = fields unless fields.nil?
384
+ def modify_subscription_ack_deadline(subscription, modify_ack_deadline_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
385
+ command = make_simple_command(:post, 'v1/{+subscription}:modifyAckDeadline', options)
386
+ command.request_representation = Google::Apis::PubsubV1::ModifyAckDeadlineRequest::Representation
387
+ command.request_object = modify_ack_deadline_request_object
388
+ command.response_representation = Google::Apis::PubsubV1::Empty::Representation
389
+ command.response_class = Google::Apis::PubsubV1::Empty
390
+ command.params['subscription'] = subscription unless subscription.nil?
332
391
  command.query['quotaUser'] = quota_user unless quota_user.nil?
392
+ command.query['fields'] = fields unless fields.nil?
333
393
  execute_or_queue_command(command, &block)
334
394
  end
335
395
 
336
- # Lists the name of the subscriptions for this topic.
337
- # @param [String] topic
338
- # The name of the topic that subscriptions are attached to.
339
- # Format is `projects/`project`/topics/`topic``.
340
- # @param [String] page_token
341
- # The value returned by the last `ListTopicSubscriptionsResponse`; indicates
342
- # that this is a continuation of a prior `ListTopicSubscriptions` call, and
343
- # that the system should return the next page of data.
344
- # @param [Fixnum] page_size
345
- # Maximum number of subscription names to return.
346
- # @param [String] fields
347
- # Selector specifying which fields to include in a partial response.
396
+ # Gets the access control policy for a resource.
397
+ # Returns an empty policy if the resource exists and does not have a policy
398
+ # set.
399
+ # @param [String] resource
400
+ # REQUIRED: The resource for which the policy is being requested.
401
+ # See the operation documentation for the appropriate value for this field.
348
402
  # @param [String] quota_user
349
403
  # Available to use for quota purposes for server-side applications. Can be any
350
404
  # arbitrary string assigned to a user, but should not exceed 40 characters.
405
+ # @param [String] fields
406
+ # Selector specifying which fields to include in a partial response.
351
407
  # @param [Google::Apis::RequestOptions] options
352
408
  # Request-specific options
353
409
  #
354
410
  # @yield [result, err] Result & error if block supplied
355
- # @yieldparam result [Google::Apis::PubsubV1::ListTopicSubscriptionsResponse] parsed result object
411
+ # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
356
412
  # @yieldparam err [StandardError] error object if request failed
357
413
  #
358
- # @return [Google::Apis::PubsubV1::ListTopicSubscriptionsResponse]
414
+ # @return [Google::Apis::PubsubV1::Policy]
359
415
  #
360
416
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
361
417
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
362
418
  # @raise [Google::Apis::AuthorizationError] Authorization is required
363
- def list_project_topic_subscriptions(topic, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
364
- command = make_simple_command(:get, 'v1/{+topic}/subscriptions', options)
365
- command.response_representation = Google::Apis::PubsubV1::ListTopicSubscriptionsResponse::Representation
366
- command.response_class = Google::Apis::PubsubV1::ListTopicSubscriptionsResponse
367
- command.params['topic'] = topic unless topic.nil?
368
- command.query['pageToken'] = page_token unless page_token.nil?
369
- command.query['pageSize'] = page_size unless page_size.nil?
370
- command.query['fields'] = fields unless fields.nil?
419
+ def get_project_subscription_iam_policy(resource, quota_user: nil, fields: nil, options: nil, &block)
420
+ command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
421
+ command.response_representation = Google::Apis::PubsubV1::Policy::Representation
422
+ command.response_class = Google::Apis::PubsubV1::Policy
423
+ command.params['resource'] = resource unless resource.nil?
371
424
  command.query['quotaUser'] = quota_user unless quota_user.nil?
425
+ command.query['fields'] = fields unless fields.nil?
372
426
  execute_or_queue_command(command, &block)
373
427
  end
374
428
 
@@ -376,11 +430,11 @@ module Google
376
430
  # @param [String] subscription
377
431
  # The name of the subscription to get.
378
432
  # Format is `projects/`project`/subscriptions/`sub``.
379
- # @param [String] fields
380
- # Selector specifying which fields to include in a partial response.
381
433
  # @param [String] quota_user
382
434
  # Available to use for quota purposes for server-side applications. Can be any
383
435
  # arbitrary string assigned to a user, but should not exceed 40 characters.
436
+ # @param [String] fields
437
+ # Selector specifying which fields to include in a partial response.
384
438
  # @param [Google::Apis::RequestOptions] options
385
439
  # Request-specific options
386
440
  #
@@ -393,13 +447,13 @@ module Google
393
447
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
394
448
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
395
449
  # @raise [Google::Apis::AuthorizationError] Authorization is required
396
- def get_project_subscription(subscription, fields: nil, quota_user: nil, options: nil, &block)
450
+ def get_subscription(subscription, quota_user: nil, fields: nil, options: nil, &block)
397
451
  command = make_simple_command(:get, 'v1/{+subscription}', options)
398
452
  command.response_representation = Google::Apis::PubsubV1::Subscription::Representation
399
453
  command.response_class = Google::Apis::PubsubV1::Subscription
400
454
  command.params['subscription'] = subscription unless subscription.nil?
401
- command.query['fields'] = fields unless fields.nil?
402
455
  command.query['quotaUser'] = quota_user unless quota_user.nil?
456
+ command.query['fields'] = fields unless fields.nil?
403
457
  execute_or_queue_command(command, &block)
404
458
  end
405
459
 
@@ -413,11 +467,11 @@ module Google
413
467
  # REQUIRED: The resource for which the policy detail is being requested.
414
468
  # See the operation documentation for the appropriate value for this field.
415
469
  # @param [Google::Apis::PubsubV1::TestIamPermissionsRequest] test_iam_permissions_request_object
416
- # @param [String] fields
417
- # Selector specifying which fields to include in a partial response.
418
470
  # @param [String] quota_user
419
471
  # Available to use for quota purposes for server-side applications. Can be any
420
472
  # arbitrary string assigned to a user, but should not exceed 40 characters.
473
+ # @param [String] fields
474
+ # Selector specifying which fields to include in a partial response.
421
475
  # @param [Google::Apis::RequestOptions] options
422
476
  # Request-specific options
423
477
  #
@@ -430,301 +484,238 @@ module Google
430
484
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
431
485
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
432
486
  # @raise [Google::Apis::AuthorizationError] Authorization is required
433
- def test_subscription_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
487
+ def test_snapshot_iam_permissions(resource, test_iam_permissions_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
434
488
  command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
435
489
  command.request_representation = Google::Apis::PubsubV1::TestIamPermissionsRequest::Representation
436
490
  command.request_object = test_iam_permissions_request_object
437
491
  command.response_representation = Google::Apis::PubsubV1::TestIamPermissionsResponse::Representation
438
492
  command.response_class = Google::Apis::PubsubV1::TestIamPermissionsResponse
439
493
  command.params['resource'] = resource unless resource.nil?
440
- command.query['fields'] = fields unless fields.nil?
441
494
  command.query['quotaUser'] = quota_user unless quota_user.nil?
495
+ command.query['fields'] = fields unless fields.nil?
442
496
  execute_or_queue_command(command, &block)
443
497
  end
444
498
 
445
- # Modifies the `PushConfig` for a specified subscription.
446
- # This may be used to change a push subscription to a pull one (signified by
447
- # an empty `PushConfig`) or vice versa, or change the endpoint URL and other
448
- # attributes of a push subscription. Messages will accumulate for delivery
449
- # continuously through the call regardless of changes to the `PushConfig`.
450
- # @param [String] subscription
451
- # The name of the subscription.
452
- # Format is `projects/`project`/subscriptions/`sub``.
453
- # @param [Google::Apis::PubsubV1::ModifyPushConfigRequest] modify_push_config_request_object
454
- # @param [String] fields
455
- # Selector specifying which fields to include in a partial response.
499
+ # Gets the access control policy for a resource.
500
+ # Returns an empty policy if the resource exists and does not have a policy
501
+ # set.
502
+ # @param [String] resource
503
+ # REQUIRED: The resource for which the policy is being requested.
504
+ # See the operation documentation for the appropriate value for this field.
456
505
  # @param [String] quota_user
457
506
  # Available to use for quota purposes for server-side applications. Can be any
458
507
  # arbitrary string assigned to a user, but should not exceed 40 characters.
459
- # @param [Google::Apis::RequestOptions] options
460
- # Request-specific options
461
- #
462
- # @yield [result, err] Result & error if block supplied
463
- # @yieldparam result [Google::Apis::PubsubV1::Empty] parsed result object
464
- # @yieldparam err [StandardError] error object if request failed
465
- #
466
- # @return [Google::Apis::PubsubV1::Empty]
467
- #
468
- # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
469
- # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
470
- # @raise [Google::Apis::AuthorizationError] Authorization is required
471
- def modify_subscription_push_config(subscription, modify_push_config_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
472
- command = make_simple_command(:post, 'v1/{+subscription}:modifyPushConfig', options)
473
- command.request_representation = Google::Apis::PubsubV1::ModifyPushConfigRequest::Representation
474
- command.request_object = modify_push_config_request_object
475
- command.response_representation = Google::Apis::PubsubV1::Empty::Representation
476
- command.response_class = Google::Apis::PubsubV1::Empty
477
- command.params['subscription'] = subscription unless subscription.nil?
478
- command.query['fields'] = fields unless fields.nil?
479
- command.query['quotaUser'] = quota_user unless quota_user.nil?
480
- execute_or_queue_command(command, &block)
481
- end
482
-
483
- # Deletes an existing subscription. All messages retained in the subscription
484
- # are immediately dropped. Calls to `Pull` after deletion will return
485
- # `NOT_FOUND`. After a subscription is deleted, a new one may be created with
486
- # the same name, but the new one has no association with the old
487
- # subscription or its topic unless the same topic is specified.
488
- # @param [String] subscription
489
- # The subscription to delete.
490
- # Format is `projects/`project`/subscriptions/`sub``.
491
508
  # @param [String] fields
492
509
  # Selector specifying which fields to include in a partial response.
493
- # @param [String] quota_user
494
- # Available to use for quota purposes for server-side applications. Can be any
495
- # arbitrary string assigned to a user, but should not exceed 40 characters.
496
510
  # @param [Google::Apis::RequestOptions] options
497
511
  # Request-specific options
498
512
  #
499
513
  # @yield [result, err] Result & error if block supplied
500
- # @yieldparam result [Google::Apis::PubsubV1::Empty] parsed result object
514
+ # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
501
515
  # @yieldparam err [StandardError] error object if request failed
502
516
  #
503
- # @return [Google::Apis::PubsubV1::Empty]
517
+ # @return [Google::Apis::PubsubV1::Policy]
504
518
  #
505
519
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
506
520
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
507
521
  # @raise [Google::Apis::AuthorizationError] Authorization is required
508
- def delete_project_subscription(subscription, fields: nil, quota_user: nil, options: nil, &block)
509
- command = make_simple_command(:delete, 'v1/{+subscription}', options)
510
- command.response_representation = Google::Apis::PubsubV1::Empty::Representation
511
- command.response_class = Google::Apis::PubsubV1::Empty
512
- command.params['subscription'] = subscription unless subscription.nil?
513
- command.query['fields'] = fields unless fields.nil?
522
+ def get_project_snapshot_iam_policy(resource, quota_user: nil, fields: nil, options: nil, &block)
523
+ command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
524
+ command.response_representation = Google::Apis::PubsubV1::Policy::Representation
525
+ command.response_class = Google::Apis::PubsubV1::Policy
526
+ command.params['resource'] = resource unless resource.nil?
514
527
  command.query['quotaUser'] = quota_user unless quota_user.nil?
528
+ command.query['fields'] = fields unless fields.nil?
515
529
  execute_or_queue_command(command, &block)
516
530
  end
517
531
 
518
- # Pulls messages from the server. Returns an empty list if there are no
519
- # messages available in the backlog. The server may return `UNAVAILABLE` if
520
- # there are too many concurrent pull requests pending for the given
521
- # subscription.
522
- # @param [String] subscription
523
- # The subscription from which messages should be pulled.
524
- # Format is `projects/`project`/subscriptions/`sub``.
525
- # @param [Google::Apis::PubsubV1::PullRequest] pull_request_object
526
- # @param [String] fields
527
- # Selector specifying which fields to include in a partial response.
532
+ # Sets the access control policy on the specified resource. Replaces any
533
+ # existing policy.
534
+ # @param [String] resource
535
+ # REQUIRED: The resource for which the policy is being specified.
536
+ # See the operation documentation for the appropriate value for this field.
537
+ # @param [Google::Apis::PubsubV1::SetIamPolicyRequest] set_iam_policy_request_object
528
538
  # @param [String] quota_user
529
539
  # Available to use for quota purposes for server-side applications. Can be any
530
540
  # arbitrary string assigned to a user, but should not exceed 40 characters.
541
+ # @param [String] fields
542
+ # Selector specifying which fields to include in a partial response.
531
543
  # @param [Google::Apis::RequestOptions] options
532
544
  # Request-specific options
533
545
  #
534
546
  # @yield [result, err] Result & error if block supplied
535
- # @yieldparam result [Google::Apis::PubsubV1::PullResponse] parsed result object
547
+ # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
536
548
  # @yieldparam err [StandardError] error object if request failed
537
549
  #
538
- # @return [Google::Apis::PubsubV1::PullResponse]
550
+ # @return [Google::Apis::PubsubV1::Policy]
539
551
  #
540
552
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
541
553
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
542
554
  # @raise [Google::Apis::AuthorizationError] Authorization is required
543
- def pull_subscription(subscription, pull_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
544
- command = make_simple_command(:post, 'v1/{+subscription}:pull', options)
545
- command.request_representation = Google::Apis::PubsubV1::PullRequest::Representation
546
- command.request_object = pull_request_object
547
- command.response_representation = Google::Apis::PubsubV1::PullResponse::Representation
548
- command.response_class = Google::Apis::PubsubV1::PullResponse
549
- command.params['subscription'] = subscription unless subscription.nil?
550
- command.query['fields'] = fields unless fields.nil?
555
+ def set_snapshot_iam_policy(resource, set_iam_policy_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
556
+ command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
557
+ command.request_representation = Google::Apis::PubsubV1::SetIamPolicyRequest::Representation
558
+ command.request_object = set_iam_policy_request_object
559
+ command.response_representation = Google::Apis::PubsubV1::Policy::Representation
560
+ command.response_class = Google::Apis::PubsubV1::Policy
561
+ command.params['resource'] = resource unless resource.nil?
551
562
  command.query['quotaUser'] = quota_user unless quota_user.nil?
563
+ command.query['fields'] = fields unless fields.nil?
552
564
  execute_or_queue_command(command, &block)
553
565
  end
554
566
 
555
- # Lists matching subscriptions.
556
- # @param [String] project
557
- # The name of the cloud project that subscriptions belong to.
558
- # Format is `projects/`project``.
559
- # @param [String] page_token
560
- # The value returned by the last `ListSubscriptionsResponse`; indicates that
561
- # this is a continuation of a prior `ListSubscriptions` call, and that the
562
- # system should return the next page of data.
563
- # @param [Fixnum] page_size
564
- # Maximum number of subscriptions to return.
565
- # @param [String] fields
566
- # Selector specifying which fields to include in a partial response.
567
+ # Gets the access control policy for a resource.
568
+ # Returns an empty policy if the resource exists and does not have a policy
569
+ # set.
570
+ # @param [String] resource
571
+ # REQUIRED: The resource for which the policy is being requested.
572
+ # See the operation documentation for the appropriate value for this field.
567
573
  # @param [String] quota_user
568
574
  # Available to use for quota purposes for server-side applications. Can be any
569
575
  # arbitrary string assigned to a user, but should not exceed 40 characters.
576
+ # @param [String] fields
577
+ # Selector specifying which fields to include in a partial response.
570
578
  # @param [Google::Apis::RequestOptions] options
571
579
  # Request-specific options
572
580
  #
573
581
  # @yield [result, err] Result & error if block supplied
574
- # @yieldparam result [Google::Apis::PubsubV1::ListSubscriptionsResponse] parsed result object
582
+ # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
575
583
  # @yieldparam err [StandardError] error object if request failed
576
584
  #
577
- # @return [Google::Apis::PubsubV1::ListSubscriptionsResponse]
585
+ # @return [Google::Apis::PubsubV1::Policy]
578
586
  #
579
587
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
580
588
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
581
589
  # @raise [Google::Apis::AuthorizationError] Authorization is required
582
- def list_project_subscriptions(project, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
583
- command = make_simple_command(:get, 'v1/{+project}/subscriptions', options)
584
- command.response_representation = Google::Apis::PubsubV1::ListSubscriptionsResponse::Representation
585
- command.response_class = Google::Apis::PubsubV1::ListSubscriptionsResponse
586
- command.params['project'] = project unless project.nil?
587
- command.query['pageToken'] = page_token unless page_token.nil?
588
- command.query['pageSize'] = page_size unless page_size.nil?
589
- command.query['fields'] = fields unless fields.nil?
590
- command.query['quotaUser'] = quota_user unless quota_user.nil?
591
- execute_or_queue_command(command, &block)
592
- end
593
-
594
- # Creates a subscription to a given topic.
595
- # If the subscription already exists, returns `ALREADY_EXISTS`.
596
- # If the corresponding topic doesn't exist, returns `NOT_FOUND`.
597
- # If the name is not provided in the request, the server will assign a random
598
- # name for this subscription on the same project as the topic, conforming
599
- # to the
600
- # [resource name format](https://cloud.google.com/pubsub/docs/overview#names).
601
- # The generated name is populated in the returned Subscription object.
602
- # Note that for REST API requests, you must specify a name in the request.
603
- # @param [String] name
604
- # The name of the subscription. It must have the format
605
- # `"projects/`project`/subscriptions/`subscription`"`. ``subscription`` must
606
- # start with a letter, and contain only letters (`[A-Za-z]`), numbers
607
- # (`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
608
- # plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
609
- # in length, and it must not start with `"goog"`.
610
- # @param [Google::Apis::PubsubV1::Subscription] subscription_object
611
- # @param [String] fields
612
- # Selector specifying which fields to include in a partial response.
590
+ def get_project_topic_iam_policy(resource, quota_user: nil, fields: nil, options: nil, &block)
591
+ command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
592
+ command.response_representation = Google::Apis::PubsubV1::Policy::Representation
593
+ command.response_class = Google::Apis::PubsubV1::Policy
594
+ command.params['resource'] = resource unless resource.nil?
595
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
596
+ command.query['fields'] = fields unless fields.nil?
597
+ execute_or_queue_command(command, &block)
598
+ end
599
+
600
+ # Gets the configuration of a topic.
601
+ # @param [String] topic
602
+ # The name of the topic to get.
603
+ # Format is `projects/`project`/topics/`topic``.
613
604
  # @param [String] quota_user
614
605
  # Available to use for quota purposes for server-side applications. Can be any
615
606
  # arbitrary string assigned to a user, but should not exceed 40 characters.
607
+ # @param [String] fields
608
+ # Selector specifying which fields to include in a partial response.
616
609
  # @param [Google::Apis::RequestOptions] options
617
610
  # Request-specific options
618
611
  #
619
612
  # @yield [result, err] Result & error if block supplied
620
- # @yieldparam result [Google::Apis::PubsubV1::Subscription] parsed result object
613
+ # @yieldparam result [Google::Apis::PubsubV1::Topic] parsed result object
621
614
  # @yieldparam err [StandardError] error object if request failed
622
615
  #
623
- # @return [Google::Apis::PubsubV1::Subscription]
616
+ # @return [Google::Apis::PubsubV1::Topic]
624
617
  #
625
618
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
626
619
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
627
620
  # @raise [Google::Apis::AuthorizationError] Authorization is required
628
- def create_project_subscription(name, subscription_object = nil, fields: nil, quota_user: nil, options: nil, &block)
629
- command = make_simple_command(:put, 'v1/{+name}', options)
630
- command.request_representation = Google::Apis::PubsubV1::Subscription::Representation
631
- command.request_object = subscription_object
632
- command.response_representation = Google::Apis::PubsubV1::Subscription::Representation
633
- command.response_class = Google::Apis::PubsubV1::Subscription
634
- command.params['name'] = name unless name.nil?
635
- command.query['fields'] = fields unless fields.nil?
621
+ def get_topic(topic, quota_user: nil, fields: nil, options: nil, &block)
622
+ command = make_simple_command(:get, 'v1/{+topic}', options)
623
+ command.response_representation = Google::Apis::PubsubV1::Topic::Representation
624
+ command.response_class = Google::Apis::PubsubV1::Topic
625
+ command.params['topic'] = topic unless topic.nil?
636
626
  command.query['quotaUser'] = quota_user unless quota_user.nil?
627
+ command.query['fields'] = fields unless fields.nil?
637
628
  execute_or_queue_command(command, &block)
638
629
  end
639
630
 
640
- # Sets the access control policy on the specified resource. Replaces any
641
- # existing policy.
642
- # @param [String] resource
643
- # REQUIRED: The resource for which the policy is being specified.
644
- # See the operation documentation for the appropriate value for this field.
645
- # @param [Google::Apis::PubsubV1::SetIamPolicyRequest] set_iam_policy_request_object
646
- # @param [String] fields
647
- # Selector specifying which fields to include in a partial response.
631
+ # Adds one or more messages to the topic. Returns `NOT_FOUND` if the topic
632
+ # does not exist. The message payload must not be empty; it must contain
633
+ # either a non-empty data field, or at least one attribute.
634
+ # @param [String] topic
635
+ # The messages in the request will be published on this topic.
636
+ # Format is `projects/`project`/topics/`topic``.
637
+ # @param [Google::Apis::PubsubV1::PublishRequest] publish_request_object
648
638
  # @param [String] quota_user
649
639
  # Available to use for quota purposes for server-side applications. Can be any
650
640
  # arbitrary string assigned to a user, but should not exceed 40 characters.
641
+ # @param [String] fields
642
+ # Selector specifying which fields to include in a partial response.
651
643
  # @param [Google::Apis::RequestOptions] options
652
644
  # Request-specific options
653
645
  #
654
646
  # @yield [result, err] Result & error if block supplied
655
- # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
647
+ # @yieldparam result [Google::Apis::PubsubV1::PublishResponse] parsed result object
656
648
  # @yieldparam err [StandardError] error object if request failed
657
649
  #
658
- # @return [Google::Apis::PubsubV1::Policy]
650
+ # @return [Google::Apis::PubsubV1::PublishResponse]
659
651
  #
660
652
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
661
653
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
662
654
  # @raise [Google::Apis::AuthorizationError] Authorization is required
663
- def set_subscription_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
664
- command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
665
- command.request_representation = Google::Apis::PubsubV1::SetIamPolicyRequest::Representation
666
- command.request_object = set_iam_policy_request_object
667
- command.response_representation = Google::Apis::PubsubV1::Policy::Representation
668
- command.response_class = Google::Apis::PubsubV1::Policy
669
- command.params['resource'] = resource unless resource.nil?
670
- command.query['fields'] = fields unless fields.nil?
655
+ def publish_topic(topic, publish_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
656
+ command = make_simple_command(:post, 'v1/{+topic}:publish', options)
657
+ command.request_representation = Google::Apis::PubsubV1::PublishRequest::Representation
658
+ command.request_object = publish_request_object
659
+ command.response_representation = Google::Apis::PubsubV1::PublishResponse::Representation
660
+ command.response_class = Google::Apis::PubsubV1::PublishResponse
661
+ command.params['topic'] = topic unless topic.nil?
671
662
  command.query['quotaUser'] = quota_user unless quota_user.nil?
663
+ command.query['fields'] = fields unless fields.nil?
672
664
  execute_or_queue_command(command, &block)
673
665
  end
674
666
 
675
- # Acknowledges the messages associated with the `ack_ids` in the
676
- # `AcknowledgeRequest`. The Pub/Sub system can remove the relevant messages
677
- # from the subscription.
678
- # Acknowledging a message whose ack deadline has expired may succeed,
679
- # but such a message may be redelivered later. Acknowledging a message more
680
- # than once will not result in an error.
681
- # @param [String] subscription
682
- # The subscription whose message is being acknowledged.
683
- # Format is `projects/`project`/subscriptions/`sub``.
684
- # @param [Google::Apis::PubsubV1::AcknowledgeRequest] acknowledge_request_object
685
- # @param [String] fields
686
- # Selector specifying which fields to include in a partial response.
667
+ # Returns permissions that a caller has on the specified resource.
668
+ # If the resource does not exist, this will return an empty set of
669
+ # permissions, not a NOT_FOUND error.
670
+ # Note: This operation is designed to be used for building permission-aware
671
+ # UIs and command-line tools, not for authorization checking. This operation
672
+ # may "fail open" without warning.
673
+ # @param [String] resource
674
+ # REQUIRED: The resource for which the policy detail is being requested.
675
+ # See the operation documentation for the appropriate value for this field.
676
+ # @param [Google::Apis::PubsubV1::TestIamPermissionsRequest] test_iam_permissions_request_object
687
677
  # @param [String] quota_user
688
678
  # Available to use for quota purposes for server-side applications. Can be any
689
679
  # arbitrary string assigned to a user, but should not exceed 40 characters.
680
+ # @param [String] fields
681
+ # Selector specifying which fields to include in a partial response.
690
682
  # @param [Google::Apis::RequestOptions] options
691
683
  # Request-specific options
692
684
  #
693
685
  # @yield [result, err] Result & error if block supplied
694
- # @yieldparam result [Google::Apis::PubsubV1::Empty] parsed result object
686
+ # @yieldparam result [Google::Apis::PubsubV1::TestIamPermissionsResponse] parsed result object
695
687
  # @yieldparam err [StandardError] error object if request failed
696
688
  #
697
- # @return [Google::Apis::PubsubV1::Empty]
689
+ # @return [Google::Apis::PubsubV1::TestIamPermissionsResponse]
698
690
  #
699
691
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
700
692
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
701
693
  # @raise [Google::Apis::AuthorizationError] Authorization is required
702
- def acknowledge_subscription(subscription, acknowledge_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
703
- command = make_simple_command(:post, 'v1/{+subscription}:acknowledge', options)
704
- command.request_representation = Google::Apis::PubsubV1::AcknowledgeRequest::Representation
705
- command.request_object = acknowledge_request_object
706
- command.response_representation = Google::Apis::PubsubV1::Empty::Representation
707
- command.response_class = Google::Apis::PubsubV1::Empty
708
- command.params['subscription'] = subscription unless subscription.nil?
709
- command.query['fields'] = fields unless fields.nil?
694
+ def test_topic_iam_permissions(resource, test_iam_permissions_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
695
+ command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
696
+ command.request_representation = Google::Apis::PubsubV1::TestIamPermissionsRequest::Representation
697
+ command.request_object = test_iam_permissions_request_object
698
+ command.response_representation = Google::Apis::PubsubV1::TestIamPermissionsResponse::Representation
699
+ command.response_class = Google::Apis::PubsubV1::TestIamPermissionsResponse
700
+ command.params['resource'] = resource unless resource.nil?
710
701
  command.query['quotaUser'] = quota_user unless quota_user.nil?
702
+ command.query['fields'] = fields unless fields.nil?
711
703
  execute_or_queue_command(command, &block)
712
704
  end
713
705
 
714
- # Modifies the ack deadline for a specific message. This method is useful
715
- # to indicate that more time is needed to process a message by the
716
- # subscriber, or to make the message available for redelivery if the
717
- # processing was interrupted. Note that this does not modify the
718
- # subscription-level `ackDeadlineSeconds` used for subsequent messages.
719
- # @param [String] subscription
720
- # The name of the subscription.
721
- # Format is `projects/`project`/subscriptions/`sub``.
722
- # @param [Google::Apis::PubsubV1::ModifyAckDeadlineRequest] modify_ack_deadline_request_object
723
- # @param [String] fields
724
- # Selector specifying which fields to include in a partial response.
706
+ # Deletes the topic with the given name. Returns `NOT_FOUND` if the topic
707
+ # does not exist. After a topic is deleted, a new topic may be created with
708
+ # the same name; this is an entirely new topic with none of the old
709
+ # configuration or subscriptions. Existing subscriptions to this topic are
710
+ # not deleted, but their `topic` field is set to `_deleted-topic_`.
711
+ # @param [String] topic
712
+ # Name of the topic to delete.
713
+ # Format is `projects/`project`/topics/`topic``.
725
714
  # @param [String] quota_user
726
715
  # Available to use for quota purposes for server-side applications. Can be any
727
716
  # arbitrary string assigned to a user, but should not exceed 40 characters.
717
+ # @param [String] fields
718
+ # Selector specifying which fields to include in a partial response.
728
719
  # @param [Google::Apis::RequestOptions] options
729
720
  # Request-specific options
730
721
  #
@@ -737,81 +728,90 @@ module Google
737
728
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
738
729
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
739
730
  # @raise [Google::Apis::AuthorizationError] Authorization is required
740
- def modify_subscription_ack_deadline(subscription, modify_ack_deadline_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
741
- command = make_simple_command(:post, 'v1/{+subscription}:modifyAckDeadline', options)
742
- command.request_representation = Google::Apis::PubsubV1::ModifyAckDeadlineRequest::Representation
743
- command.request_object = modify_ack_deadline_request_object
731
+ def delete_topic(topic, quota_user: nil, fields: nil, options: nil, &block)
732
+ command = make_simple_command(:delete, 'v1/{+topic}', options)
744
733
  command.response_representation = Google::Apis::PubsubV1::Empty::Representation
745
734
  command.response_class = Google::Apis::PubsubV1::Empty
746
- command.params['subscription'] = subscription unless subscription.nil?
747
- command.query['fields'] = fields unless fields.nil?
735
+ command.params['topic'] = topic unless topic.nil?
748
736
  command.query['quotaUser'] = quota_user unless quota_user.nil?
737
+ command.query['fields'] = fields unless fields.nil?
749
738
  execute_or_queue_command(command, &block)
750
739
  end
751
740
 
752
- # Gets the access control policy for a resource.
753
- # Returns an empty policy if the resource exists and does not have a policy
754
- # set.
755
- # @param [String] resource
756
- # REQUIRED: The resource for which the policy is being requested.
757
- # See the operation documentation for the appropriate value for this field.
758
- # @param [String] fields
759
- # Selector specifying which fields to include in a partial response.
741
+ # Lists matching topics.
742
+ # @param [String] project
743
+ # The name of the cloud project that topics belong to.
744
+ # Format is `projects/`project``.
745
+ # @param [Fixnum] page_size
746
+ # Maximum number of topics to return.
747
+ # @param [String] page_token
748
+ # The value returned by the last `ListTopicsResponse`; indicates that this is
749
+ # a continuation of a prior `ListTopics` call, and that the system should
750
+ # return the next page of data.
760
751
  # @param [String] quota_user
761
752
  # Available to use for quota purposes for server-side applications. Can be any
762
753
  # arbitrary string assigned to a user, but should not exceed 40 characters.
754
+ # @param [String] fields
755
+ # Selector specifying which fields to include in a partial response.
763
756
  # @param [Google::Apis::RequestOptions] options
764
757
  # Request-specific options
765
758
  #
766
759
  # @yield [result, err] Result & error if block supplied
767
- # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
760
+ # @yieldparam result [Google::Apis::PubsubV1::ListTopicsResponse] parsed result object
768
761
  # @yieldparam err [StandardError] error object if request failed
769
762
  #
770
- # @return [Google::Apis::PubsubV1::Policy]
763
+ # @return [Google::Apis::PubsubV1::ListTopicsResponse]
771
764
  #
772
765
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
773
766
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
774
767
  # @raise [Google::Apis::AuthorizationError] Authorization is required
775
- def get_project_subscription_iam_policy(resource, fields: nil, quota_user: nil, options: nil, &block)
776
- command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
777
- command.response_representation = Google::Apis::PubsubV1::Policy::Representation
778
- command.response_class = Google::Apis::PubsubV1::Policy
779
- command.params['resource'] = resource unless resource.nil?
780
- command.query['fields'] = fields unless fields.nil?
768
+ def list_topics(project, page_size: nil, page_token: nil, quota_user: nil, fields: nil, options: nil, &block)
769
+ command = make_simple_command(:get, 'v1/{+project}/topics', options)
770
+ command.response_representation = Google::Apis::PubsubV1::ListTopicsResponse::Representation
771
+ command.response_class = Google::Apis::PubsubV1::ListTopicsResponse
772
+ command.params['project'] = project unless project.nil?
773
+ command.query['pageSize'] = page_size unless page_size.nil?
774
+ command.query['pageToken'] = page_token unless page_token.nil?
781
775
  command.query['quotaUser'] = quota_user unless quota_user.nil?
776
+ command.query['fields'] = fields unless fields.nil?
782
777
  execute_or_queue_command(command, &block)
783
778
  end
784
779
 
785
- # Gets the access control policy for a resource.
786
- # Returns an empty policy if the resource exists and does not have a policy
787
- # set.
788
- # @param [String] resource
789
- # REQUIRED: The resource for which the policy is being requested.
790
- # See the operation documentation for the appropriate value for this field.
791
- # @param [String] fields
792
- # Selector specifying which fields to include in a partial response.
780
+ # Creates the given topic with the given name.
781
+ # @param [String] name
782
+ # The name of the topic. It must have the format
783
+ # `"projects/`project`/topics/`topic`"`. ``topic`` must start with a letter,
784
+ # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
785
+ # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
786
+ # signs (`%`). It must be between 3 and 255 characters in length, and it
787
+ # must not start with `"goog"`.
788
+ # @param [Google::Apis::PubsubV1::Topic] topic_object
793
789
  # @param [String] quota_user
794
790
  # Available to use for quota purposes for server-side applications. Can be any
795
791
  # arbitrary string assigned to a user, but should not exceed 40 characters.
792
+ # @param [String] fields
793
+ # Selector specifying which fields to include in a partial response.
796
794
  # @param [Google::Apis::RequestOptions] options
797
795
  # Request-specific options
798
796
  #
799
797
  # @yield [result, err] Result & error if block supplied
800
- # @yieldparam result [Google::Apis::PubsubV1::Policy] parsed result object
798
+ # @yieldparam result [Google::Apis::PubsubV1::Topic] parsed result object
801
799
  # @yieldparam err [StandardError] error object if request failed
802
800
  #
803
- # @return [Google::Apis::PubsubV1::Policy]
801
+ # @return [Google::Apis::PubsubV1::Topic]
804
802
  #
805
803
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
806
804
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
807
805
  # @raise [Google::Apis::AuthorizationError] Authorization is required
808
- def get_project_snapshot_iam_policy(resource, fields: nil, quota_user: nil, options: nil, &block)
809
- command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
810
- command.response_representation = Google::Apis::PubsubV1::Policy::Representation
811
- command.response_class = Google::Apis::PubsubV1::Policy
812
- command.params['resource'] = resource unless resource.nil?
813
- command.query['fields'] = fields unless fields.nil?
806
+ def create_topic(name, topic_object = nil, quota_user: nil, fields: nil, options: nil, &block)
807
+ command = make_simple_command(:put, 'v1/{+name}', options)
808
+ command.request_representation = Google::Apis::PubsubV1::Topic::Representation
809
+ command.request_object = topic_object
810
+ command.response_representation = Google::Apis::PubsubV1::Topic::Representation
811
+ command.response_class = Google::Apis::PubsubV1::Topic
812
+ command.params['name'] = name unless name.nil?
814
813
  command.query['quotaUser'] = quota_user unless quota_user.nil?
814
+ command.query['fields'] = fields unless fields.nil?
815
815
  execute_or_queue_command(command, &block)
816
816
  end
817
817
 
@@ -821,11 +821,11 @@ module Google
821
821
  # REQUIRED: The resource for which the policy is being specified.
822
822
  # See the operation documentation for the appropriate value for this field.
823
823
  # @param [Google::Apis::PubsubV1::SetIamPolicyRequest] set_iam_policy_request_object
824
- # @param [String] fields
825
- # Selector specifying which fields to include in a partial response.
826
824
  # @param [String] quota_user
827
825
  # Available to use for quota purposes for server-side applications. Can be any
828
826
  # arbitrary string assigned to a user, but should not exceed 40 characters.
827
+ # @param [String] fields
828
+ # Selector specifying which fields to include in a partial response.
829
829
  # @param [Google::Apis::RequestOptions] options
830
830
  # Request-specific options
831
831
  #
@@ -838,54 +838,54 @@ module Google
838
838
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
839
839
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
840
840
  # @raise [Google::Apis::AuthorizationError] Authorization is required
841
- def set_snapshot_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
841
+ def set_topic_iam_policy(resource, set_iam_policy_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
842
842
  command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
843
843
  command.request_representation = Google::Apis::PubsubV1::SetIamPolicyRequest::Representation
844
844
  command.request_object = set_iam_policy_request_object
845
845
  command.response_representation = Google::Apis::PubsubV1::Policy::Representation
846
846
  command.response_class = Google::Apis::PubsubV1::Policy
847
847
  command.params['resource'] = resource unless resource.nil?
848
- command.query['fields'] = fields unless fields.nil?
849
848
  command.query['quotaUser'] = quota_user unless quota_user.nil?
849
+ command.query['fields'] = fields unless fields.nil?
850
850
  execute_or_queue_command(command, &block)
851
851
  end
852
852
 
853
- # Returns permissions that a caller has on the specified resource.
854
- # If the resource does not exist, this will return an empty set of
855
- # permissions, not a NOT_FOUND error.
856
- # Note: This operation is designed to be used for building permission-aware
857
- # UIs and command-line tools, not for authorization checking. This operation
858
- # may "fail open" without warning.
859
- # @param [String] resource
860
- # REQUIRED: The resource for which the policy detail is being requested.
861
- # See the operation documentation for the appropriate value for this field.
862
- # @param [Google::Apis::PubsubV1::TestIamPermissionsRequest] test_iam_permissions_request_object
863
- # @param [String] fields
864
- # Selector specifying which fields to include in a partial response.
853
+ # Lists the name of the subscriptions for this topic.
854
+ # @param [String] topic
855
+ # The name of the topic that subscriptions are attached to.
856
+ # Format is `projects/`project`/topics/`topic``.
857
+ # @param [String] page_token
858
+ # The value returned by the last `ListTopicSubscriptionsResponse`; indicates
859
+ # that this is a continuation of a prior `ListTopicSubscriptions` call, and
860
+ # that the system should return the next page of data.
861
+ # @param [Fixnum] page_size
862
+ # Maximum number of subscription names to return.
865
863
  # @param [String] quota_user
866
864
  # Available to use for quota purposes for server-side applications. Can be any
867
865
  # arbitrary string assigned to a user, but should not exceed 40 characters.
866
+ # @param [String] fields
867
+ # Selector specifying which fields to include in a partial response.
868
868
  # @param [Google::Apis::RequestOptions] options
869
869
  # Request-specific options
870
870
  #
871
871
  # @yield [result, err] Result & error if block supplied
872
- # @yieldparam result [Google::Apis::PubsubV1::TestIamPermissionsResponse] parsed result object
872
+ # @yieldparam result [Google::Apis::PubsubV1::ListTopicSubscriptionsResponse] parsed result object
873
873
  # @yieldparam err [StandardError] error object if request failed
874
874
  #
875
- # @return [Google::Apis::PubsubV1::TestIamPermissionsResponse]
875
+ # @return [Google::Apis::PubsubV1::ListTopicSubscriptionsResponse]
876
876
  #
877
877
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
878
878
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
879
879
  # @raise [Google::Apis::AuthorizationError] Authorization is required
880
- def test_snapshot_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
881
- command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
882
- command.request_representation = Google::Apis::PubsubV1::TestIamPermissionsRequest::Representation
883
- command.request_object = test_iam_permissions_request_object
884
- command.response_representation = Google::Apis::PubsubV1::TestIamPermissionsResponse::Representation
885
- command.response_class = Google::Apis::PubsubV1::TestIamPermissionsResponse
886
- command.params['resource'] = resource unless resource.nil?
887
- command.query['fields'] = fields unless fields.nil?
880
+ def list_topic_subscriptions(topic, page_token: nil, page_size: nil, quota_user: nil, fields: nil, options: nil, &block)
881
+ command = make_simple_command(:get, 'v1/{+topic}/subscriptions', options)
882
+ command.response_representation = Google::Apis::PubsubV1::ListTopicSubscriptionsResponse::Representation
883
+ command.response_class = Google::Apis::PubsubV1::ListTopicSubscriptionsResponse
884
+ command.params['topic'] = topic unless topic.nil?
885
+ command.query['pageToken'] = page_token unless page_token.nil?
886
+ command.query['pageSize'] = page_size unless page_size.nil?
888
887
  command.query['quotaUser'] = quota_user unless quota_user.nil?
888
+ command.query['fields'] = fields unless fields.nil?
889
889
  execute_or_queue_command(command, &block)
890
890
  end
891
891