google-api-client 0.8.6 → 0.9.3

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 (537) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +20 -0
  3. data/.rspec +2 -0
  4. data/.rubocop.yml +7 -0
  5. data/.rubocop_todo.yml +63 -0
  6. data/.travis.yml +23 -0
  7. data/.yardopts +12 -0
  8. data/CHANGELOG.md +58 -2
  9. data/CONTRIBUTING.md +31 -0
  10. data/Gemfile +38 -2
  11. data/MIGRATING.md +171 -0
  12. data/README.md +189 -147
  13. data/Rakefile +1 -40
  14. data/api_names.yaml +1088 -0
  15. data/api_names_out.yaml +26978 -0
  16. data/bin/generate-api +109 -0
  17. data/generated/google/apis/adexchangebuyer_v1_3/classes.rb +1335 -0
  18. data/generated/google/apis/adexchangebuyer_v1_3/representations.rb +446 -0
  19. data/generated/google/apis/adexchangebuyer_v1_3/service.rb +872 -0
  20. data/generated/google/apis/adexchangebuyer_v1_3.rb +35 -0
  21. data/generated/google/apis/adexchangebuyer_v1_4/classes.rb +3025 -0
  22. data/generated/google/apis/adexchangebuyer_v1_4/representations.rb +1240 -0
  23. data/generated/google/apis/adexchangebuyer_v1_4/service.rb +1446 -0
  24. data/generated/google/apis/adexchangebuyer_v1_4.rb +35 -0
  25. data/generated/google/apis/adexchangeseller_v2_0/classes.rb +792 -0
  26. data/generated/google/apis/adexchangeseller_v2_0/representations.rb +347 -0
  27. data/generated/google/apis/adexchangeseller_v2_0/service.rb +668 -0
  28. data/generated/google/apis/adexchangeseller_v2_0.rb +38 -0
  29. data/generated/google/apis/admin_datatransfer_v1/classes.rb +267 -0
  30. data/generated/google/apis/admin_datatransfer_v1/representations.rb +130 -0
  31. data/generated/google/apis/admin_datatransfer_v1/service.rb +262 -0
  32. data/generated/google/apis/admin_datatransfer_v1.rb +37 -0
  33. data/generated/google/apis/admin_directory_v1/classes.rb +3141 -0
  34. data/generated/google/apis/admin_directory_v1/representations.rb +1147 -0
  35. data/generated/google/apis/admin_directory_v1/service.rb +3818 -0
  36. data/generated/google/apis/admin_directory_v1.rb +113 -0
  37. data/generated/google/apis/admin_reports_v1/classes.rb +582 -0
  38. data/generated/google/apis/admin_reports_v1/representations.rb +257 -0
  39. data/generated/google/apis/admin_reports_v1/service.rb +336 -0
  40. data/generated/google/apis/admin_reports_v1.rb +38 -0
  41. data/generated/google/apis/adsense_v1_4/classes.rb +1280 -0
  42. data/generated/google/apis/adsense_v1_4/representations.rb +555 -0
  43. data/generated/google/apis/adsense_v1_4/service.rb +1714 -0
  44. data/generated/google/apis/adsense_v1_4.rb +38 -0
  45. data/generated/google/apis/adsensehost_v4_1/classes.rb +837 -0
  46. data/generated/google/apis/adsensehost_v4_1/representations.rb +367 -0
  47. data/generated/google/apis/adsensehost_v4_1/service.rb +1164 -0
  48. data/generated/google/apis/adsensehost_v4_1.rb +35 -0
  49. data/generated/google/apis/analytics_v3/classes.rb +5118 -0
  50. data/generated/google/apis/analytics_v3/representations.rb +1850 -0
  51. data/generated/google/apis/analytics_v3/service.rb +3568 -0
  52. data/generated/google/apis/analytics_v3.rb +49 -0
  53. data/generated/google/apis/androidenterprise_v1/classes.rb +1443 -0
  54. data/generated/google/apis/androidenterprise_v1/representations.rb +614 -0
  55. data/generated/google/apis/androidenterprise_v1/service.rb +2607 -0
  56. data/generated/google/apis/androidenterprise_v1.rb +35 -0
  57. data/generated/google/apis/androidpublisher_v2/classes.rb +1411 -0
  58. data/generated/google/apis/androidpublisher_v2/representations.rb +738 -0
  59. data/generated/google/apis/androidpublisher_v2/service.rb +2338 -0
  60. data/generated/google/apis/androidpublisher_v2.rb +34 -0
  61. data/generated/google/apis/appengine_v1beta4/classes.rb +1585 -0
  62. data/generated/google/apis/appengine_v1beta4/representations.rb +542 -0
  63. data/generated/google/apis/appengine_v1beta4/service.rb +477 -0
  64. data/generated/google/apis/appengine_v1beta4.rb +35 -0
  65. data/generated/google/apis/appengine_v1beta5/classes.rb +1544 -0
  66. data/generated/google/apis/appengine_v1beta5/representations.rb +594 -0
  67. data/generated/google/apis/appengine_v1beta5/service.rb +521 -0
  68. data/generated/google/apis/appengine_v1beta5.rb +35 -0
  69. data/generated/google/apis/appsactivity_v1/classes.rb +392 -0
  70. data/generated/google/apis/appsactivity_v1/representations.rb +206 -0
  71. data/generated/google/apis/appsactivity_v1/service.rb +128 -0
  72. data/generated/google/apis/appsactivity_v1.rb +46 -0
  73. data/generated/google/apis/appstate_v1/classes.rb +154 -0
  74. data/generated/google/apis/appstate_v1/representations.rb +87 -0
  75. data/generated/google/apis/appstate_v1/service.rb +260 -0
  76. data/generated/google/apis/appstate_v1.rb +34 -0
  77. data/generated/google/apis/autoscaler_v1beta2/classes.rb +747 -0
  78. data/generated/google/apis/autoscaler_v1beta2/representations.rb +313 -0
  79. data/generated/google/apis/autoscaler_v1beta2/service.rb +478 -0
  80. data/generated/google/apis/autoscaler_v1beta2.rb +38 -0
  81. data/generated/google/apis/bigquery_v2/classes.rb +2503 -0
  82. data/generated/google/apis/bigquery_v2/representations.rb +914 -0
  83. data/generated/google/apis/bigquery_v2/service.rb +982 -0
  84. data/generated/google/apis/bigquery_v2.rb +52 -0
  85. data/generated/google/apis/blogger_v3/classes.rb +1354 -0
  86. data/generated/google/apis/blogger_v3/representations.rb +632 -0
  87. data/generated/google/apis/blogger_v3/service.rb +1587 -0
  88. data/generated/google/apis/blogger_v3.rb +37 -0
  89. data/generated/google/apis/books_v1/classes.rb +4006 -0
  90. data/generated/google/apis/books_v1/representations.rb +1742 -0
  91. data/generated/google/apis/books_v1/service.rb +2293 -0
  92. data/generated/google/apis/books_v1.rb +34 -0
  93. data/generated/google/apis/calendar_v3/classes.rb +1742 -0
  94. data/generated/google/apis/calendar_v3/representations.rb +631 -0
  95. data/generated/google/apis/calendar_v3/service.rb +1968 -0
  96. data/generated/google/apis/calendar_v3.rb +37 -0
  97. data/generated/google/apis/civicinfo_v2/classes.rb +1127 -0
  98. data/generated/google/apis/civicinfo_v2/representations.rb +423 -0
  99. data/generated/google/apis/civicinfo_v2/service.rb +279 -0
  100. data/generated/google/apis/civicinfo_v2.rb +31 -0
  101. data/generated/google/apis/classroom_v1/classes.rb +512 -0
  102. data/generated/google/apis/classroom_v1/representations.rb +245 -0
  103. data/generated/google/apis/classroom_v1/service.rb +970 -0
  104. data/generated/google/apis/classroom_v1.rb +49 -0
  105. data/generated/google/apis/classroom_v1beta1/classes.rb +447 -0
  106. data/generated/google/apis/classroom_v1beta1/representations.rb +190 -0
  107. data/generated/google/apis/classroom_v1beta1/service.rb +791 -0
  108. data/generated/google/apis/classroom_v1beta1.rb +49 -0
  109. data/generated/google/apis/cloudbilling_v1/classes.rb +169 -0
  110. data/generated/google/apis/cloudbilling_v1/representations.rb +87 -0
  111. data/generated/google/apis/cloudbilling_v1/service.rb +258 -0
  112. data/generated/google/apis/cloudbilling_v1.rb +35 -0
  113. data/generated/google/apis/cloudbuild_v1/classes.rb +521 -0
  114. data/generated/google/apis/cloudbuild_v1/representations.rb +214 -0
  115. data/generated/google/apis/cloudbuild_v1/service.rb +278 -0
  116. data/generated/google/apis/cloudbuild_v1.rb +35 -0
  117. data/generated/google/apis/clouddebugger_v2/classes.rb +1004 -0
  118. data/generated/google/apis/clouddebugger_v2/representations.rb +464 -0
  119. data/generated/google/apis/clouddebugger_v2/service.rb +370 -0
  120. data/generated/google/apis/clouddebugger_v2.rb +41 -0
  121. data/generated/google/apis/cloudlatencytest_v2/classes.rb +195 -0
  122. data/generated/google/apis/cloudlatencytest_v2/representations.rb +127 -0
  123. data/generated/google/apis/cloudlatencytest_v2/service.rb +135 -0
  124. data/generated/google/apis/cloudlatencytest_v2.rb +34 -0
  125. data/generated/google/apis/cloudmonitoring_v2beta2/classes.rb +679 -0
  126. data/generated/google/apis/cloudmonitoring_v2beta2/representations.rb +353 -0
  127. data/generated/google/apis/cloudmonitoring_v2beta2/service.rb +452 -0
  128. data/generated/google/apis/cloudmonitoring_v2beta2.rb +37 -0
  129. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +450 -0
  130. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +226 -0
  131. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +626 -0
  132. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +38 -0
  133. data/generated/google/apis/cloudtrace_v1/classes.rb +188 -0
  134. data/generated/google/apis/cloudtrace_v1/representations.rb +102 -0
  135. data/generated/google/apis/cloudtrace_v1/service.rb +190 -0
  136. data/generated/google/apis/cloudtrace_v1.rb +35 -0
  137. data/generated/google/apis/clouduseraccounts_beta/classes.rb +823 -0
  138. data/generated/google/apis/clouduseraccounts_beta/representations.rb +351 -0
  139. data/generated/google/apis/clouduseraccounts_beta/service.rb +854 -0
  140. data/generated/google/apis/clouduseraccounts_beta.rb +43 -0
  141. data/generated/google/apis/compute_beta/classes.rb +9741 -0
  142. data/generated/google/apis/compute_beta/representations.rb +3649 -0
  143. data/generated/google/apis/compute_beta/service.rb +10636 -0
  144. data/generated/google/apis/compute_beta.rb +49 -0
  145. data/generated/google/apis/compute_v1/classes.rb +9095 -0
  146. data/generated/google/apis/compute_v1/representations.rb +3389 -0
  147. data/generated/google/apis/compute_v1/service.rb +9627 -0
  148. data/generated/google/apis/compute_v1.rb +49 -0
  149. data/generated/google/apis/container_v1/classes.rb +463 -0
  150. data/generated/google/apis/container_v1/representations.rb +195 -0
  151. data/generated/google/apis/container_v1/service.rb +367 -0
  152. data/generated/google/apis/container_v1.rb +35 -0
  153. data/generated/google/apis/container_v1beta1/classes.rb +466 -0
  154. data/generated/google/apis/container_v1beta1/representations.rb +177 -0
  155. data/generated/google/apis/container_v1beta1/service.rb +394 -0
  156. data/generated/google/apis/container_v1beta1.rb +35 -0
  157. data/generated/google/apis/content_v2/classes.rb +6114 -0
  158. data/generated/google/apis/content_v2/representations.rb +2624 -0
  159. data/generated/google/apis/content_v2/service.rb +2338 -0
  160. data/generated/google/apis/content_v2.rb +35 -0
  161. data/generated/google/apis/coordinate_v1/classes.rb +669 -0
  162. data/generated/google/apis/coordinate_v1/representations.rb +321 -0
  163. data/generated/google/apis/coordinate_v1/service.rb +678 -0
  164. data/generated/google/apis/coordinate_v1.rb +37 -0
  165. data/generated/google/apis/customsearch_v1/classes.rb +771 -0
  166. data/generated/google/apis/customsearch_v1/representations.rb +302 -0
  167. data/generated/google/apis/customsearch_v1/service.rb +207 -0
  168. data/{lib/google/api_client/auth/compute_service_account.rb → generated/google/apis/customsearch_v1.rb} +13 -10
  169. data/generated/google/apis/dataproc_v1/classes.rb +1590 -0
  170. data/generated/google/apis/dataproc_v1/representations.rb +653 -0
  171. data/generated/google/apis/dataproc_v1/service.rb +719 -0
  172. data/generated/google/apis/dataproc_v1.rb +43 -0
  173. data/generated/google/apis/datastore_v1beta2/classes.rb +1186 -0
  174. data/generated/google/apis/datastore_v1beta2/representations.rb +594 -0
  175. data/generated/google/apis/datastore_v1beta2/service.rb +294 -0
  176. data/generated/google/apis/datastore_v1beta2.rb +40 -0
  177. data/generated/google/apis/deploymentmanager_v2/classes.rb +1162 -0
  178. data/generated/google/apis/deploymentmanager_v2/representations.rb +508 -0
  179. data/generated/google/apis/deploymentmanager_v2/service.rb +862 -0
  180. data/generated/google/apis/deploymentmanager_v2.rb +44 -0
  181. data/generated/google/apis/deploymentmanager_v2beta2/classes.rb +843 -0
  182. data/generated/google/apis/deploymentmanager_v2beta2/representations.rb +306 -0
  183. data/generated/google/apis/deploymentmanager_v2beta2/service.rb +689 -0
  184. data/generated/google/apis/deploymentmanager_v2beta2.rb +44 -0
  185. data/generated/google/apis/dfareporting_v2_1/classes.rb +10770 -0
  186. data/generated/google/apis/dfareporting_v2_1/representations.rb +3438 -0
  187. data/generated/google/apis/dfareporting_v2_1/service.rb +8585 -0
  188. data/generated/google/apis/dfareporting_v2_1.rb +37 -0
  189. data/generated/google/apis/dfareporting_v2_3/classes.rb +10830 -0
  190. data/generated/google/apis/dfareporting_v2_3/representations.rb +3829 -0
  191. data/generated/google/apis/dfareporting_v2_3/service.rb +8581 -0
  192. data/generated/google/apis/dfareporting_v2_3.rb +37 -0
  193. data/generated/google/apis/discovery_v1/classes.rb +961 -0
  194. data/generated/google/apis/discovery_v1/representations.rb +397 -0
  195. data/generated/google/apis/discovery_v1/service.rb +142 -0
  196. data/generated/google/apis/discovery_v1.rb +32 -0
  197. data/generated/google/apis/dns_v1/classes.rb +406 -0
  198. data/generated/google/apis/dns_v1/representations.rb +167 -0
  199. data/generated/google/apis/dns_v1/service.rb +454 -0
  200. data/generated/google/apis/dns_v1.rb +44 -0
  201. data/generated/google/apis/doubleclickbidmanager_v1/classes.rb +802 -0
  202. data/generated/google/apis/doubleclickbidmanager_v1/representations.rb +371 -0
  203. data/generated/google/apis/doubleclickbidmanager_v1/service.rb +374 -0
  204. data/generated/google/apis/doubleclickbidmanager_v1.rb +31 -0
  205. data/generated/google/apis/doubleclicksearch_v2/classes.rb +958 -0
  206. data/generated/google/apis/doubleclicksearch_v2/representations.rb +350 -0
  207. data/generated/google/apis/doubleclicksearch_v2/service.rb +480 -0
  208. data/generated/google/apis/doubleclicksearch_v2.rb +35 -0
  209. data/generated/google/apis/drive_v2/classes.rb +2569 -0
  210. data/generated/google/apis/drive_v2/representations.rb +878 -0
  211. data/generated/google/apis/drive_v2/service.rb +2740 -0
  212. data/generated/google/apis/drive_v2.rb +58 -0
  213. data/generated/google/apis/drive_v3/classes.rb +1541 -0
  214. data/generated/google/apis/drive_v3/representations.rb +548 -0
  215. data/generated/google/apis/drive_v3/service.rb +1542 -0
  216. data/generated/google/apis/drive_v3.rb +55 -0
  217. data/generated/google/apis/fitness_v1/classes.rb +885 -0
  218. data/generated/google/apis/fitness_v1/representations.rb +360 -0
  219. data/generated/google/apis/fitness_v1/service.rb +675 -0
  220. data/generated/google/apis/fitness_v1.rb +49 -0
  221. data/generated/google/apis/fusiontables_v2/classes.rb +1048 -0
  222. data/generated/google/apis/fusiontables_v2/representations.rb +457 -0
  223. data/generated/google/apis/fusiontables_v2/service.rb +1463 -0
  224. data/generated/google/apis/fusiontables_v2.rb +37 -0
  225. data/generated/google/apis/games_configuration_v1configuration/classes.rb +506 -0
  226. data/generated/google/apis/games_configuration_v1configuration/representations.rb +228 -0
  227. data/generated/google/apis/games_configuration_v1configuration/service.rb +565 -0
  228. data/generated/google/apis/games_configuration_v1configuration.rb +34 -0
  229. data/generated/google/apis/games_management_v1management/classes.rb +533 -0
  230. data/generated/google/apis/games_management_v1management/representations.rb +262 -0
  231. data/generated/google/apis/games_management_v1management/service.rb +994 -0
  232. data/generated/google/apis/games_management_v1management.rb +37 -0
  233. data/generated/google/apis/games_v1/classes.rb +4626 -0
  234. data/generated/google/apis/games_v1/representations.rb +1783 -0
  235. data/generated/google/apis/games_v1/service.rb +2290 -0
  236. data/generated/google/apis/games_v1.rb +40 -0
  237. data/generated/google/apis/gan_v1beta1/classes.rb +1428 -0
  238. data/generated/google/apis/gan_v1beta1/representations.rb +462 -0
  239. data/generated/google/apis/gan_v1beta1/service.rb +682 -0
  240. data/generated/google/apis/gan_v1beta1.rb +31 -0
  241. data/generated/google/apis/genomics_v1/classes.rb +2609 -0
  242. data/generated/google/apis/genomics_v1/representations.rb +1029 -0
  243. data/generated/google/apis/genomics_v1/service.rb +1676 -0
  244. data/generated/google/apis/genomics_v1.rb +49 -0
  245. data/generated/google/apis/genomics_v1beta2/classes.rb +3288 -0
  246. data/generated/google/apis/genomics_v1beta2/representations.rb +1194 -0
  247. data/generated/google/apis/genomics_v1beta2/service.rb +2392 -0
  248. data/generated/google/apis/genomics_v1beta2.rb +46 -0
  249. data/generated/google/apis/gmail_v1/classes.rb +794 -0
  250. data/generated/google/apis/gmail_v1/representations.rb +383 -0
  251. data/generated/google/apis/gmail_v1/service.rb +1470 -0
  252. data/generated/google/apis/gmail_v1.rb +52 -0
  253. data/generated/google/apis/groupsmigration_v1/classes.rb +51 -0
  254. data/generated/google/apis/groupsmigration_v1/representations.rb +40 -0
  255. data/generated/google/apis/groupsmigration_v1/service.rb +110 -0
  256. data/generated/google/apis/groupsmigration_v1.rb +34 -0
  257. data/generated/google/apis/groupssettings_v1/classes.rb +221 -0
  258. data/generated/google/apis/groupssettings_v1/representations.rb +66 -0
  259. data/generated/google/apis/groupssettings_v1/service.rb +179 -0
  260. data/generated/google/apis/groupssettings_v1.rb +34 -0
  261. data/generated/google/apis/identitytoolkit_v3/classes.rb +1637 -0
  262. data/generated/google/apis/identitytoolkit_v3/representations.rb +618 -0
  263. data/generated/google/apis/identitytoolkit_v3/service.rb +616 -0
  264. data/generated/google/apis/identitytoolkit_v3.rb +31 -0
  265. data/generated/google/apis/kgsearch_v1/classes.rb +59 -0
  266. data/generated/google/apis/kgsearch_v1/representations.rb +41 -0
  267. data/generated/google/apis/kgsearch_v1/service.rb +111 -0
  268. data/{spec/google/api_client/request_spec.rb → generated/google/apis/kgsearch_v1.rb} +16 -13
  269. data/generated/google/apis/licensing_v1/classes.rb +132 -0
  270. data/generated/google/apis/licensing_v1/representations.rb +74 -0
  271. data/generated/google/apis/licensing_v1/service.rb +369 -0
  272. data/generated/google/apis/licensing_v1.rb +34 -0
  273. data/generated/google/apis/logging_v1beta3/classes.rb +1079 -0
  274. data/generated/google/apis/logging_v1beta3/representations.rb +366 -0
  275. data/generated/google/apis/logging_v1beta3/service.rb +1001 -0
  276. data/generated/google/apis/logging_v1beta3.rb +47 -0
  277. data/generated/google/apis/logging_v2beta1/classes.rb +990 -0
  278. data/generated/google/apis/logging_v2beta1/representations.rb +377 -0
  279. data/generated/google/apis/logging_v2beta1/service.rb +547 -0
  280. data/generated/google/apis/logging_v2beta1.rb +47 -0
  281. data/generated/google/apis/manager_v1beta2/classes.rb +1287 -0
  282. data/generated/google/apis/manager_v1beta2/representations.rb +606 -0
  283. data/generated/google/apis/manager_v1beta2/service.rb +372 -0
  284. data/generated/google/apis/manager_v1beta2.rb +53 -0
  285. data/generated/google/apis/mirror_v1/classes.rb +1072 -0
  286. data/generated/google/apis/mirror_v1/representations.rb +390 -0
  287. data/generated/google/apis/mirror_v1/service.rb +977 -0
  288. data/generated/google/apis/mirror_v1.rb +37 -0
  289. data/generated/google/apis/oauth2_v2/classes.rb +245 -0
  290. data/generated/google/apis/oauth2_v2/representations.rb +102 -0
  291. data/generated/google/apis/oauth2_v2/service.rb +199 -0
  292. data/generated/google/apis/oauth2_v2.rb +43 -0
  293. data/generated/google/apis/pagespeedonline_v2/classes.rb +614 -0
  294. data/generated/google/apis/pagespeedonline_v2/representations.rb +272 -0
  295. data/generated/google/apis/pagespeedonline_v2/service.rb +119 -0
  296. data/generated/google/apis/pagespeedonline_v2.rb +32 -0
  297. data/generated/google/apis/partners_v2/classes.rb +942 -0
  298. data/generated/google/apis/partners_v2/representations.rb +454 -0
  299. data/generated/google/apis/partners_v2/service.rb +400 -0
  300. data/generated/google/apis/partners_v2.rb +32 -0
  301. data/generated/google/apis/people_v1/classes.rb +1521 -0
  302. data/generated/google/apis/people_v1/representations.rb +663 -0
  303. data/generated/google/apis/people_v1/service.rb +189 -0
  304. data/generated/google/apis/people_v1.rb +59 -0
  305. data/generated/google/apis/plus_domains_v1/classes.rb +2609 -0
  306. data/generated/google/apis/plus_domains_v1/representations.rb +1111 -0
  307. data/generated/google/apis/plus_domains_v1/service.rb +904 -0
  308. data/generated/google/apis/plus_domains_v1.rb +61 -0
  309. data/generated/google/apis/plus_v1/classes.rb +2094 -0
  310. data/generated/google/apis/plus_v1/representations.rb +907 -0
  311. data/generated/google/apis/plus_v1/service.rb +470 -0
  312. data/generated/google/apis/plus_v1.rb +43 -0
  313. data/generated/google/apis/prediction_v1_6/classes.rb +751 -0
  314. data/generated/google/apis/prediction_v1_6/representations.rb +369 -0
  315. data/generated/google/apis/prediction_v1_6/service.rb +380 -0
  316. data/generated/google/apis/prediction_v1_6.rb +44 -0
  317. data/generated/google/apis/proximitybeacon_v1beta1/classes.rb +639 -0
  318. data/generated/google/apis/proximitybeacon_v1beta1/representations.rb +312 -0
  319. data/generated/google/apis/proximitybeacon_v1beta1/service.rb +591 -0
  320. data/generated/google/apis/proximitybeacon_v1beta1.rb +31 -0
  321. data/generated/google/apis/pubsub_v1/classes.rb +614 -0
  322. data/generated/google/apis/pubsub_v1/representations.rb +323 -0
  323. data/generated/google/apis/pubsub_v1/service.rb +774 -0
  324. data/generated/google/apis/pubsub_v1.rb +37 -0
  325. data/generated/google/apis/pubsub_v1beta2/classes.rb +620 -0
  326. data/generated/google/apis/pubsub_v1beta2/representations.rb +282 -0
  327. data/generated/google/apis/pubsub_v1beta2/service.rb +774 -0
  328. data/generated/google/apis/pubsub_v1beta2.rb +37 -0
  329. data/generated/google/apis/qpx_express_v1/classes.rb +1268 -0
  330. data/generated/google/apis/qpx_express_v1/representations.rb +472 -0
  331. data/generated/google/apis/qpx_express_v1/service.rb +100 -0
  332. data/generated/google/apis/qpx_express_v1.rb +31 -0
  333. data/generated/google/apis/replicapool_v1beta2/classes.rb +631 -0
  334. data/generated/google/apis/replicapool_v1beta2/representations.rb +264 -0
  335. data/generated/google/apis/replicapool_v1beta2/service.rb +608 -0
  336. data/generated/google/apis/replicapool_v1beta2.rb +44 -0
  337. data/generated/google/apis/replicapoolupdater_v1beta1/classes.rb +733 -0
  338. data/generated/google/apis/replicapoolupdater_v1beta1/representations.rb +294 -0
  339. data/generated/google/apis/replicapoolupdater_v1beta1/service.rb +508 -0
  340. data/generated/google/apis/replicapoolupdater_v1beta1.rb +44 -0
  341. data/generated/google/apis/reseller_v1/classes.rb +526 -0
  342. data/generated/google/apis/reseller_v1/representations.rb +223 -0
  343. data/generated/google/apis/reseller_v1/service.rb +623 -0
  344. data/generated/google/apis/reseller_v1.rb +37 -0
  345. data/generated/google/apis/resourceviews_v1beta2/classes.rb +660 -0
  346. data/generated/google/apis/resourceviews_v1beta2/representations.rb +301 -0
  347. data/generated/google/apis/resourceviews_v1beta2/service.rb +563 -0
  348. data/generated/google/apis/resourceviews_v1beta2.rb +50 -0
  349. data/generated/google/apis/script_v1/classes.rb +259 -0
  350. data/generated/google/apis/script_v1/representations.rb +118 -0
  351. data/generated/google/apis/script_v1/service.rb +98 -0
  352. data/generated/google/apis/script_v1.rb +61 -0
  353. data/generated/google/apis/site_verification_v1/classes.rb +185 -0
  354. data/generated/google/apis/site_verification_v1/representations.rb +113 -0
  355. data/generated/google/apis/site_verification_v1/service.rb +315 -0
  356. data/generated/google/apis/site_verification_v1.rb +37 -0
  357. data/generated/google/apis/sqladmin_v1beta4/classes.rb +2030 -0
  358. data/generated/google/apis/sqladmin_v1beta4/representations.rb +856 -0
  359. data/generated/google/apis/sqladmin_v1beta4/service.rb +1625 -0
  360. data/generated/google/apis/sqladmin_v1beta4.rb +37 -0
  361. data/generated/google/apis/storage_v1/classes.rb +1222 -0
  362. data/generated/google/apis/storage_v1/representations.rb +497 -0
  363. data/generated/google/apis/storage_v1/service.rb +1903 -0
  364. data/generated/google/apis/storage_v1.rb +46 -0
  365. data/generated/google/apis/storagetransfer_v1/classes.rb +1046 -0
  366. data/generated/google/apis/storagetransfer_v1/representations.rb +418 -0
  367. data/generated/google/apis/storagetransfer_v1/service.rb +473 -0
  368. data/generated/google/apis/storagetransfer_v1.rb +35 -0
  369. data/generated/google/apis/tagmanager_v1/classes.rb +1494 -0
  370. data/generated/google/apis/tagmanager_v1/representations.rb +611 -0
  371. data/generated/google/apis/tagmanager_v1/service.rb +2119 -0
  372. data/generated/google/apis/tagmanager_v1.rb +52 -0
  373. data/generated/google/apis/taskqueue_v1beta2/classes.rb +254 -0
  374. data/generated/google/apis/taskqueue_v1beta2/representations.rb +126 -0
  375. data/generated/google/apis/taskqueue_v1beta2/service.rb +408 -0
  376. data/generated/google/apis/taskqueue_v1beta2.rb +37 -0
  377. data/generated/google/apis/tasks_v1/classes.rb +296 -0
  378. data/generated/google/apis/tasks_v1/representations.rb +125 -0
  379. data/generated/google/apis/tasks_v1/service.rb +643 -0
  380. data/generated/google/apis/tasks_v1.rb +37 -0
  381. data/generated/google/apis/translate_v2/classes.rb +168 -0
  382. data/generated/google/apis/translate_v2/representations.rb +121 -0
  383. data/generated/google/apis/translate_v2/service.rb +182 -0
  384. data/generated/google/apis/translate_v2.rb +31 -0
  385. data/generated/google/apis/urlshortener_v1/classes.rb +246 -0
  386. data/generated/google/apis/urlshortener_v1/representations.rb +121 -0
  387. data/generated/google/apis/urlshortener_v1/service.rb +176 -0
  388. data/generated/google/apis/urlshortener_v1.rb +34 -0
  389. data/generated/google/apis/vision_v1/classes.rb +1259 -0
  390. data/generated/google/apis/vision_v1/representations.rb +418 -0
  391. data/generated/google/apis/vision_v1/service.rb +91 -0
  392. data/generated/google/apis/vision_v1.rb +37 -0
  393. data/generated/google/apis/webmasters_v3/classes.rb +563 -0
  394. data/generated/google/apis/webmasters_v3/representations.rb +282 -0
  395. data/generated/google/apis/webmasters_v3/service.rb +573 -0
  396. data/generated/google/apis/webmasters_v3.rb +37 -0
  397. data/generated/google/apis/youtube_analytics_v1/classes.rb +546 -0
  398. data/generated/google/apis/youtube_analytics_v1/representations.rb +273 -0
  399. data/generated/google/apis/youtube_analytics_v1/service.rb +562 -0
  400. data/generated/google/apis/youtube_analytics_v1.rb +46 -0
  401. data/generated/google/apis/youtube_v3/classes.rb +8071 -0
  402. data/generated/google/apis/youtube_v3/representations.rb +3134 -0
  403. data/generated/google/apis/youtube_v3/service.rb +4403 -0
  404. data/generated/google/apis/youtube_v3.rb +49 -0
  405. data/generated/google/apis/youtubereporting_v1/classes.rb +258 -0
  406. data/generated/google/apis/youtubereporting_v1/representations.rb +144 -0
  407. data/generated/google/apis/youtubereporting_v1/service.rb +364 -0
  408. data/generated/google/apis/youtubereporting_v1.rb +38 -0
  409. data/google-api-client.gemspec +25 -39
  410. data/lib/google/api_client/auth/installed_app.rb +7 -5
  411. data/lib/google/api_client/auth/key_utils.rb +1 -0
  412. data/lib/google/api_client/auth/storage.rb +4 -2
  413. data/lib/google/api_client/auth/storages/file_store.rb +2 -3
  414. data/lib/google/api_client/auth/storages/redis_store.rb +7 -2
  415. data/lib/google/api_client/client_secrets.rb +7 -9
  416. data/lib/google/apis/core/api_command.rb +136 -0
  417. data/lib/google/apis/core/base_service.rb +317 -0
  418. data/lib/google/apis/core/batch.rb +239 -0
  419. data/lib/google/apis/core/download.rb +94 -0
  420. data/lib/google/apis/core/hashable.rb +44 -0
  421. data/lib/google/apis/core/http_client_adapter.rb +82 -0
  422. data/lib/google/apis/core/http_command.rb +328 -0
  423. data/lib/google/apis/core/json_representation.rb +145 -0
  424. data/lib/google/{api_client/version.rb → apis/core/logging.rb} +12 -8
  425. data/lib/google/apis/core/multipart.rb +187 -0
  426. data/lib/google/apis/core/upload.rb +289 -0
  427. data/lib/google/{api_client → apis}/errors.rb +39 -28
  428. data/lib/google/apis/generator/annotator.rb +295 -0
  429. data/lib/google/apis/generator/helpers.rb +74 -0
  430. data/lib/google/apis/generator/model.rb +143 -0
  431. data/lib/google/apis/generator/template.rb +124 -0
  432. data/lib/google/apis/generator/templates/_class.tmpl +40 -0
  433. data/lib/google/apis/generator/templates/_method.tmpl +92 -0
  434. data/lib/google/apis/generator/templates/_representation.tmpl +51 -0
  435. data/lib/google/apis/generator/templates/_representation_stub.tmpl +17 -0
  436. data/lib/google/apis/generator/templates/_representation_type.tmpl +10 -0
  437. data/lib/google/{api_client/reference.rb → apis/generator/templates/classes.rb.tmpl} +11 -9
  438. data/lib/google/apis/generator/templates/module.rb.tmpl +40 -0
  439. data/lib/google/apis/generator/templates/representations.rb.tmpl +32 -0
  440. data/lib/google/apis/generator/templates/service.rb.tmpl +60 -0
  441. data/lib/google/apis/generator.rb +70 -0
  442. data/lib/google/apis/options.rb +85 -0
  443. data/lib/google/apis/version.rb +39 -0
  444. data/lib/google/apis.rb +48 -0
  445. data/rakelib/metrics.rake +22 -0
  446. data/rakelib/rubocop.rake +10 -0
  447. data/rakelib/spec.rake +11 -0
  448. data/rakelib/yard.rake +11 -0
  449. data/samples/cli/Gemfile +7 -0
  450. data/samples/cli/README.md +51 -0
  451. data/samples/cli/google-api-samples +32 -0
  452. data/samples/cli/lib/base_cli.rb +95 -0
  453. data/samples/cli/lib/samples/analytics.rb +62 -0
  454. data/samples/cli/lib/samples/androidpublisher.rb +47 -0
  455. data/samples/cli/lib/samples/calendar.rb +83 -0
  456. data/samples/cli/lib/samples/drive.rb +82 -0
  457. data/samples/cli/lib/samples/gmail.rb +50 -0
  458. data/samples/cli/lib/samples/pubsub.rb +114 -0
  459. data/samples/cli/lib/samples/translate.rb +44 -0
  460. data/samples/cli/lib/samples/you_tube.rb +44 -0
  461. data/samples/web/Gemfile +7 -0
  462. data/samples/web/README.md +44 -0
  463. data/samples/web/app.rb +120 -0
  464. data/samples/web/views/calendar.erb +34 -0
  465. data/{lib/google/api_client/service_account.rb → samples/web/views/drive.erb} +20 -8
  466. data/samples/web/views/home.erb +35 -0
  467. data/samples/web/views/layout.erb +40 -0
  468. data/script/generate +100 -0
  469. data/script/package +8 -0
  470. data/script/release +15 -0
  471. data/spec/fixtures/files/api_names.yaml +3 -0
  472. data/spec/fixtures/files/auth_stored_credentials.json +8 -0
  473. data/spec/fixtures/files/child/.gitignore +0 -0
  474. data/spec/fixtures/files/client_secrets.json +1 -0
  475. data/spec/fixtures/files/invalid.json +1 -0
  476. data/spec/fixtures/files/test.blah +1 -0
  477. data/spec/fixtures/files/test.txt +1 -0
  478. data/spec/fixtures/files/test_api.json +440 -0
  479. data/spec/google/api_client/auth/storage_spec.rb +1 -3
  480. data/spec/google/api_client/auth/storages/file_store_spec.rb +1 -2
  481. data/spec/google/api_client/auth/storages/redis_store_spec.rb +1 -3
  482. data/spec/google/api_client/client_secrets_spec.rb +338 -2
  483. data/spec/google/apis/core/api_command_spec.rb +209 -0
  484. data/spec/google/apis/core/batch_spec.rb +142 -0
  485. data/spec/google/apis/core/download_spec.rb +103 -0
  486. data/spec/google/apis/core/hashable_spec.rb +60 -0
  487. data/spec/google/apis/core/http_command_spec.rb +303 -0
  488. data/spec/google/apis/core/json_representation_spec.rb +199 -0
  489. data/spec/google/apis/core/service_spec.rb +247 -0
  490. data/spec/google/apis/core/upload_spec.rb +300 -0
  491. data/{lib/google/api_client/discovery.rb → spec/google/apis/generated_spec.rb} +13 -5
  492. data/spec/google/apis/generator/generator_spec.rb +324 -0
  493. data/spec/google/apis/logging_spec.rb +45 -0
  494. data/spec/google/apis/options_spec.rb +40 -0
  495. data/spec/integration_tests/adsense_spec.rb +29 -0
  496. data/spec/integration_tests/drive_spec.rb +35 -0
  497. data/spec/integration_tests/pubsub_spec.rb +48 -0
  498. data/spec/integration_tests/url_shortener_spec.rb +45 -0
  499. data/spec/spec_helper/load_path_spec.rb +33 -0
  500. data/spec/spec_helper.rb +131 -44
  501. data/third_party/hurley_patches.rb +103 -0
  502. metadata +563 -188
  503. data/lib/compat/multi_json.rb +0 -19
  504. data/lib/google/api_client/auth/file_storage.rb +0 -59
  505. data/lib/google/api_client/auth/jwt_asserter.rb +0 -126
  506. data/lib/google/api_client/auth/pkcs12.rb +0 -41
  507. data/lib/google/api_client/batch.rb +0 -326
  508. data/lib/google/api_client/charset.rb +0 -33
  509. data/lib/google/api_client/discovery/api.rb +0 -310
  510. data/lib/google/api_client/discovery/media.rb +0 -77
  511. data/lib/google/api_client/discovery/method.rb +0 -363
  512. data/lib/google/api_client/discovery/resource.rb +0 -156
  513. data/lib/google/api_client/discovery/schema.rb +0 -117
  514. data/lib/google/api_client/environment.rb +0 -42
  515. data/lib/google/api_client/gzip.rb +0 -28
  516. data/lib/google/api_client/logging.rb +0 -32
  517. data/lib/google/api_client/media.rb +0 -259
  518. data/lib/google/api_client/railtie.rb +0 -18
  519. data/lib/google/api_client/request.rb +0 -350
  520. data/lib/google/api_client/result.rb +0 -255
  521. data/lib/google/api_client/service/batch.rb +0 -110
  522. data/lib/google/api_client/service/request.rb +0 -144
  523. data/lib/google/api_client/service/resource.rb +0 -40
  524. data/lib/google/api_client/service/result.rb +0 -162
  525. data/lib/google/api_client/service/simple_file_store.rb +0 -151
  526. data/lib/google/api_client/service/stub_generator.rb +0 -61
  527. data/lib/google/api_client/service.rb +0 -233
  528. data/lib/google/api_client.rb +0 -750
  529. data/spec/google/api_client/batch_spec.rb +0 -248
  530. data/spec/google/api_client/discovery_spec.rb +0 -708
  531. data/spec/google/api_client/gzip_spec.rb +0 -98
  532. data/spec/google/api_client/media_spec.rb +0 -178
  533. data/spec/google/api_client/result_spec.rb +0 -207
  534. data/spec/google/api_client/service_account_spec.rb +0 -169
  535. data/spec/google/api_client/service_spec.rb +0 -618
  536. data/spec/google/api_client/simple_file_store_spec.rb +0 -133
  537. data/spec/google/api_client_spec.rb +0 -352
@@ -0,0 +1,2030 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module SqladminV1beta4
24
+
25
+ # An entry for an Access Control list.
26
+ class AclEntry
27
+ include Google::Apis::Core::Hashable
28
+
29
+ # The time when this access control entry expires in RFC 3339 format, for
30
+ # example 2012-11-15T16:19:00.094Z.
31
+ # Corresponds to the JSON property `expirationTime`
32
+ # @return [DateTime]
33
+ attr_accessor :expiration_time
34
+
35
+ # This is always sql#aclEntry.
36
+ # Corresponds to the JSON property `kind`
37
+ # @return [String]
38
+ attr_accessor :kind
39
+
40
+ # An optional label to identify this entry.
41
+ # Corresponds to the JSON property `name`
42
+ # @return [String]
43
+ attr_accessor :name
44
+
45
+ # The whitelisted value for the access control list.
46
+ # Corresponds to the JSON property `value`
47
+ # @return [String]
48
+ attr_accessor :value
49
+
50
+ def initialize(**args)
51
+ update!(**args)
52
+ end
53
+
54
+ # Update properties of this object
55
+ def update!(**args)
56
+ @expiration_time = args[:expiration_time] if args.key?(:expiration_time)
57
+ @kind = args[:kind] if args.key?(:kind)
58
+ @name = args[:name] if args.key?(:name)
59
+ @value = args[:value] if args.key?(:value)
60
+ end
61
+ end
62
+
63
+ # Database instance backup configuration.
64
+ class BackupConfiguration
65
+ include Google::Apis::Core::Hashable
66
+
67
+ # Whether binary log is enabled. If backup configuration is disabled, binary log
68
+ # must be disabled as well.
69
+ # Corresponds to the JSON property `binaryLogEnabled`
70
+ # @return [Boolean]
71
+ attr_accessor :binary_log_enabled
72
+ alias_method :binary_log_enabled?, :binary_log_enabled
73
+
74
+ # Whether this configuration is enabled.
75
+ # Corresponds to the JSON property `enabled`
76
+ # @return [Boolean]
77
+ attr_accessor :enabled
78
+ alias_method :enabled?, :enabled
79
+
80
+ # This is always sql#backupConfiguration.
81
+ # Corresponds to the JSON property `kind`
82
+ # @return [String]
83
+ attr_accessor :kind
84
+
85
+ # Start time for the daily backup configuration in UTC timezone in the 24 hour
86
+ # format - HH:MM.
87
+ # Corresponds to the JSON property `startTime`
88
+ # @return [String]
89
+ attr_accessor :start_time
90
+
91
+ def initialize(**args)
92
+ update!(**args)
93
+ end
94
+
95
+ # Update properties of this object
96
+ def update!(**args)
97
+ @binary_log_enabled = args[:binary_log_enabled] if args.key?(:binary_log_enabled)
98
+ @enabled = args[:enabled] if args.key?(:enabled)
99
+ @kind = args[:kind] if args.key?(:kind)
100
+ @start_time = args[:start_time] if args.key?(:start_time)
101
+ end
102
+ end
103
+
104
+ # A database instance backup run resource.
105
+ class BackupRun
106
+ include Google::Apis::Core::Hashable
107
+
108
+ # The time the backup operation completed in UTC timezone in RFC 3339 format,
109
+ # for example 2012-11-15T16:19:00.094Z.
110
+ # Corresponds to the JSON property `endTime`
111
+ # @return [DateTime]
112
+ attr_accessor :end_time
113
+
114
+ # The time the run was enqueued in UTC timezone in RFC 3339 format, for example
115
+ # 2012-11-15T16:19:00.094Z.
116
+ # Corresponds to the JSON property `enqueuedTime`
117
+ # @return [DateTime]
118
+ attr_accessor :enqueued_time
119
+
120
+ # Database instance operation error.
121
+ # Corresponds to the JSON property `error`
122
+ # @return [Google::Apis::SqladminV1beta4::OperationError]
123
+ attr_accessor :error
124
+
125
+ # A unique identifier for this backup run. Note that this is unique only within
126
+ # the scope of a particular Cloud SQL instance.
127
+ # Corresponds to the JSON property `id`
128
+ # @return [String]
129
+ attr_accessor :id
130
+
131
+ # Name of the database instance.
132
+ # Corresponds to the JSON property `instance`
133
+ # @return [String]
134
+ attr_accessor :instance
135
+
136
+ # This is always sql#backupRun.
137
+ # Corresponds to the JSON property `kind`
138
+ # @return [String]
139
+ attr_accessor :kind
140
+
141
+ # The URI of this resource.
142
+ # Corresponds to the JSON property `selfLink`
143
+ # @return [String]
144
+ attr_accessor :self_link
145
+
146
+ # The time the backup operation actually started in UTC timezone in RFC 3339
147
+ # format, for example 2012-11-15T16:19:00.094Z.
148
+ # Corresponds to the JSON property `startTime`
149
+ # @return [DateTime]
150
+ attr_accessor :start_time
151
+
152
+ # The status of this run.
153
+ # Corresponds to the JSON property `status`
154
+ # @return [String]
155
+ attr_accessor :status
156
+
157
+ # The start time of the backup window during which this the backup was attempted
158
+ # in RFC 3339 format, for example 2012-11-15T16:19:00.094Z.
159
+ # Corresponds to the JSON property `windowStartTime`
160
+ # @return [DateTime]
161
+ attr_accessor :window_start_time
162
+
163
+ def initialize(**args)
164
+ update!(**args)
165
+ end
166
+
167
+ # Update properties of this object
168
+ def update!(**args)
169
+ @end_time = args[:end_time] if args.key?(:end_time)
170
+ @enqueued_time = args[:enqueued_time] if args.key?(:enqueued_time)
171
+ @error = args[:error] if args.key?(:error)
172
+ @id = args[:id] if args.key?(:id)
173
+ @instance = args[:instance] if args.key?(:instance)
174
+ @kind = args[:kind] if args.key?(:kind)
175
+ @self_link = args[:self_link] if args.key?(:self_link)
176
+ @start_time = args[:start_time] if args.key?(:start_time)
177
+ @status = args[:status] if args.key?(:status)
178
+ @window_start_time = args[:window_start_time] if args.key?(:window_start_time)
179
+ end
180
+ end
181
+
182
+ # Backup run list results.
183
+ class ListBackupRunsResponse
184
+ include Google::Apis::Core::Hashable
185
+
186
+ # A list of backup runs in reverse chronological order of the enqueued time.
187
+ # Corresponds to the JSON property `items`
188
+ # @return [Array<Google::Apis::SqladminV1beta4::BackupRun>]
189
+ attr_accessor :items
190
+
191
+ # This is always sql#backupRunsList.
192
+ # Corresponds to the JSON property `kind`
193
+ # @return [String]
194
+ attr_accessor :kind
195
+
196
+ # The continuation token, used to page through large result sets. Provide this
197
+ # value in a subsequent request to return the next page of results.
198
+ # Corresponds to the JSON property `nextPageToken`
199
+ # @return [String]
200
+ attr_accessor :next_page_token
201
+
202
+ def initialize(**args)
203
+ update!(**args)
204
+ end
205
+
206
+ # Update properties of this object
207
+ def update!(**args)
208
+ @items = args[:items] if args.key?(:items)
209
+ @kind = args[:kind] if args.key?(:kind)
210
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
211
+ end
212
+ end
213
+
214
+ # Binary log coordinates.
215
+ class BinLogCoordinates
216
+ include Google::Apis::Core::Hashable
217
+
218
+ # Name of the binary log file for a Cloud SQL instance.
219
+ # Corresponds to the JSON property `binLogFileName`
220
+ # @return [String]
221
+ attr_accessor :bin_log_file_name
222
+
223
+ # Position (offset) within the binary log file.
224
+ # Corresponds to the JSON property `binLogPosition`
225
+ # @return [String]
226
+ attr_accessor :bin_log_position
227
+
228
+ # This is always sql#binLogCoordinates.
229
+ # Corresponds to the JSON property `kind`
230
+ # @return [String]
231
+ attr_accessor :kind
232
+
233
+ def initialize(**args)
234
+ update!(**args)
235
+ end
236
+
237
+ # Update properties of this object
238
+ def update!(**args)
239
+ @bin_log_file_name = args[:bin_log_file_name] if args.key?(:bin_log_file_name)
240
+ @bin_log_position = args[:bin_log_position] if args.key?(:bin_log_position)
241
+ @kind = args[:kind] if args.key?(:kind)
242
+ end
243
+ end
244
+
245
+ # Database instance clone context.
246
+ class CloneContext
247
+ include Google::Apis::Core::Hashable
248
+
249
+ # Binary log coordinates.
250
+ # Corresponds to the JSON property `binLogCoordinates`
251
+ # @return [Google::Apis::SqladminV1beta4::BinLogCoordinates]
252
+ attr_accessor :bin_log_coordinates
253
+
254
+ # Name of the Cloud SQL instance to be created as a clone.
255
+ # Corresponds to the JSON property `destinationInstanceName`
256
+ # @return [String]
257
+ attr_accessor :destination_instance_name
258
+
259
+ # This is always sql#cloneContext.
260
+ # Corresponds to the JSON property `kind`
261
+ # @return [String]
262
+ attr_accessor :kind
263
+
264
+ def initialize(**args)
265
+ update!(**args)
266
+ end
267
+
268
+ # Update properties of this object
269
+ def update!(**args)
270
+ @bin_log_coordinates = args[:bin_log_coordinates] if args.key?(:bin_log_coordinates)
271
+ @destination_instance_name = args[:destination_instance_name] if args.key?(:destination_instance_name)
272
+ @kind = args[:kind] if args.key?(:kind)
273
+ end
274
+ end
275
+
276
+ # A database resource inside a Cloud SQL instance.
277
+ class Database
278
+ include Google::Apis::Core::Hashable
279
+
280
+ # The MySQL charset value.
281
+ # Corresponds to the JSON property `charset`
282
+ # @return [String]
283
+ attr_accessor :charset
284
+
285
+ # The MySQL collation value.
286
+ # Corresponds to the JSON property `collation`
287
+ # @return [String]
288
+ attr_accessor :collation
289
+
290
+ # HTTP 1.1 Entity tag for the resource.
291
+ # Corresponds to the JSON property `etag`
292
+ # @return [String]
293
+ attr_accessor :etag
294
+
295
+ # The name of the Cloud SQL instance. This does not include the project ID.
296
+ # Corresponds to the JSON property `instance`
297
+ # @return [String]
298
+ attr_accessor :instance
299
+
300
+ # This is always sql#database.
301
+ # Corresponds to the JSON property `kind`
302
+ # @return [String]
303
+ attr_accessor :kind
304
+
305
+ # The name of the database in the Cloud SQL instance. This does not include the
306
+ # project ID or instance name.
307
+ # Corresponds to the JSON property `name`
308
+ # @return [String]
309
+ attr_accessor :name
310
+
311
+ # The project ID of the project containing the Cloud SQL database. The Google
312
+ # apps domain is prefixed if applicable.
313
+ # Corresponds to the JSON property `project`
314
+ # @return [String]
315
+ attr_accessor :project
316
+
317
+ # The URI of this resource.
318
+ # Corresponds to the JSON property `selfLink`
319
+ # @return [String]
320
+ attr_accessor :self_link
321
+
322
+ def initialize(**args)
323
+ update!(**args)
324
+ end
325
+
326
+ # Update properties of this object
327
+ def update!(**args)
328
+ @charset = args[:charset] if args.key?(:charset)
329
+ @collation = args[:collation] if args.key?(:collation)
330
+ @etag = args[:etag] if args.key?(:etag)
331
+ @instance = args[:instance] if args.key?(:instance)
332
+ @kind = args[:kind] if args.key?(:kind)
333
+ @name = args[:name] if args.key?(:name)
334
+ @project = args[:project] if args.key?(:project)
335
+ @self_link = args[:self_link] if args.key?(:self_link)
336
+ end
337
+ end
338
+
339
+ # MySQL flags for Cloud SQL instances.
340
+ class DatabaseFlags
341
+ include Google::Apis::Core::Hashable
342
+
343
+ # The name of the flag. These flags are passed at instance startup, so include
344
+ # both MySQL server options and MySQL system variables. Flags should be
345
+ # specified with underscores, not hyphens. For more information, see Configuring
346
+ # MySQL Flags in the Google Cloud SQL documentation, as well as the official
347
+ # MySQL documentation for server options and system variables.
348
+ # Corresponds to the JSON property `name`
349
+ # @return [String]
350
+ attr_accessor :name
351
+
352
+ # The value of the flag. Booleans should be set to on for true and off for false.
353
+ # This field must be omitted if the flag doesn't take a value.
354
+ # Corresponds to the JSON property `value`
355
+ # @return [String]
356
+ attr_accessor :value
357
+
358
+ def initialize(**args)
359
+ update!(**args)
360
+ end
361
+
362
+ # Update properties of this object
363
+ def update!(**args)
364
+ @name = args[:name] if args.key?(:name)
365
+ @value = args[:value] if args.key?(:value)
366
+ end
367
+ end
368
+
369
+ # A Cloud SQL instance resource.
370
+ class DatabaseInstance
371
+ include Google::Apis::Core::Hashable
372
+
373
+ # FIRST_GEN: Basic Cloud SQL instance that runs in a Google-managed container.
374
+ # SECOND_GEN: A newer Cloud SQL backend that runs in a Compute Engine VM.
375
+ # EXTERNAL: A MySQL server that is not managed by Google.
376
+ # Corresponds to the JSON property `backendType`
377
+ # @return [String]
378
+ attr_accessor :backend_type
379
+
380
+ # The current disk usage of the instance in bytes. This property has been
381
+ # deprecated. Users should use the "cloudsql.googleapis.com/database/disk/
382
+ # bytes_used" metric in Cloud Monitoring API instead. Please see https://groups.
383
+ # google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ for
384
+ # details.
385
+ # Corresponds to the JSON property `currentDiskSize`
386
+ # @return [String]
387
+ attr_accessor :current_disk_size
388
+
389
+ # The database engine type and version. Can be MYSQL_5_5 or MYSQL_5_6. Defaults
390
+ # to MYSQL_5_6. The databaseVersion can not be changed after instance creation.
391
+ # Corresponds to the JSON property `databaseVersion`
392
+ # @return [String]
393
+ attr_accessor :database_version
394
+
395
+ # HTTP 1.1 Entity tag for the resource.
396
+ # Corresponds to the JSON property `etag`
397
+ # @return [String]
398
+ attr_accessor :etag
399
+
400
+ # The name and status of the failover replica. This property is applicable only
401
+ # to Second Generation instances.
402
+ # Corresponds to the JSON property `failoverReplica`
403
+ # @return [Google::Apis::SqladminV1beta4::DatabaseInstance::FailoverReplica]
404
+ attr_accessor :failover_replica
405
+
406
+ # The instance type. This can be one of the following.
407
+ # CLOUD_SQL_INSTANCE: A Cloud SQL instance that is not replicating from a master.
408
+ # ON_PREMISES_INSTANCE: An instance running on the customer's premises.
409
+ # READ_REPLICA_INSTANCE: A Cloud SQL instance configured as a read-replica.
410
+ # Corresponds to the JSON property `instanceType`
411
+ # @return [String]
412
+ attr_accessor :instance_type
413
+
414
+ # The assigned IP addresses for the instance.
415
+ # Corresponds to the JSON property `ipAddresses`
416
+ # @return [Array<Google::Apis::SqladminV1beta4::IpMapping>]
417
+ attr_accessor :ip_addresses
418
+
419
+ # The IPv6 address assigned to the instance. This property is applicable only to
420
+ # First Generation instances.
421
+ # Corresponds to the JSON property `ipv6Address`
422
+ # @return [String]
423
+ attr_accessor :ipv6_address
424
+
425
+ # This is always sql#instance.
426
+ # Corresponds to the JSON property `kind`
427
+ # @return [String]
428
+ attr_accessor :kind
429
+
430
+ # The name of the instance which will act as master in the replication setup.
431
+ # Corresponds to the JSON property `masterInstanceName`
432
+ # @return [String]
433
+ attr_accessor :master_instance_name
434
+
435
+ # The maximum disk size of the instance in bytes.
436
+ # Corresponds to the JSON property `maxDiskSize`
437
+ # @return [String]
438
+ attr_accessor :max_disk_size
439
+
440
+ # Name of the Cloud SQL instance. This does not include the project ID.
441
+ # Corresponds to the JSON property `name`
442
+ # @return [String]
443
+ attr_accessor :name
444
+
445
+ # On-premises instance configuration.
446
+ # Corresponds to the JSON property `onPremisesConfiguration`
447
+ # @return [Google::Apis::SqladminV1beta4::OnPremisesConfiguration]
448
+ attr_accessor :on_premises_configuration
449
+
450
+ # The project ID of the project containing the Cloud SQL instance. The Google
451
+ # apps domain is prefixed if applicable.
452
+ # Corresponds to the JSON property `project`
453
+ # @return [String]
454
+ attr_accessor :project
455
+
456
+ # The geographical region. Can be us-central (FIRST_GEN instances only), us-
457
+ # central1 (SECOND_GEN instances only), asia-east1 or europe-west1. Defaults to
458
+ # us-central or us-central1 depending on the instance type (First Generation or
459
+ # Second Generation). The region can not be changed after instance creation.
460
+ # Corresponds to the JSON property `region`
461
+ # @return [String]
462
+ attr_accessor :region
463
+
464
+ # Read-replica configuration for connecting to the master.
465
+ # Corresponds to the JSON property `replicaConfiguration`
466
+ # @return [Google::Apis::SqladminV1beta4::ReplicaConfiguration]
467
+ attr_accessor :replica_configuration
468
+
469
+ # The replicas of the instance.
470
+ # Corresponds to the JSON property `replicaNames`
471
+ # @return [Array<String>]
472
+ attr_accessor :replica_names
473
+
474
+ # The URI of this resource.
475
+ # Corresponds to the JSON property `selfLink`
476
+ # @return [String]
477
+ attr_accessor :self_link
478
+
479
+ # SslCerts Resource
480
+ # Corresponds to the JSON property `serverCaCert`
481
+ # @return [Google::Apis::SqladminV1beta4::SslCert]
482
+ attr_accessor :server_ca_cert
483
+
484
+ # The service account email address assigned to the instance. This property is
485
+ # applicable only to Second Generation instances.
486
+ # Corresponds to the JSON property `serviceAccountEmailAddress`
487
+ # @return [String]
488
+ attr_accessor :service_account_email_address
489
+
490
+ # Database instance settings.
491
+ # Corresponds to the JSON property `settings`
492
+ # @return [Google::Apis::SqladminV1beta4::Settings]
493
+ attr_accessor :settings
494
+
495
+ # The current serving state of the Cloud SQL instance. This can be one of the
496
+ # following.
497
+ # RUNNABLE: The instance is running, or is ready to run when accessed.
498
+ # SUSPENDED: The instance is not available, for example due to problems with
499
+ # billing.
500
+ # PENDING_CREATE: The instance is being created.
501
+ # MAINTENANCE: The instance is down for maintenance.
502
+ # FAILED: The instance creation failed.
503
+ # UNKNOWN_STATE: The state of the instance is unknown.
504
+ # Corresponds to the JSON property `state`
505
+ # @return [String]
506
+ attr_accessor :state
507
+
508
+ # If the instance state is SUSPENDED, the reason for the suspension.
509
+ # Corresponds to the JSON property `suspensionReason`
510
+ # @return [Array<String>]
511
+ attr_accessor :suspension_reason
512
+
513
+ def initialize(**args)
514
+ update!(**args)
515
+ end
516
+
517
+ # Update properties of this object
518
+ def update!(**args)
519
+ @backend_type = args[:backend_type] if args.key?(:backend_type)
520
+ @current_disk_size = args[:current_disk_size] if args.key?(:current_disk_size)
521
+ @database_version = args[:database_version] if args.key?(:database_version)
522
+ @etag = args[:etag] if args.key?(:etag)
523
+ @failover_replica = args[:failover_replica] if args.key?(:failover_replica)
524
+ @instance_type = args[:instance_type] if args.key?(:instance_type)
525
+ @ip_addresses = args[:ip_addresses] if args.key?(:ip_addresses)
526
+ @ipv6_address = args[:ipv6_address] if args.key?(:ipv6_address)
527
+ @kind = args[:kind] if args.key?(:kind)
528
+ @master_instance_name = args[:master_instance_name] if args.key?(:master_instance_name)
529
+ @max_disk_size = args[:max_disk_size] if args.key?(:max_disk_size)
530
+ @name = args[:name] if args.key?(:name)
531
+ @on_premises_configuration = args[:on_premises_configuration] if args.key?(:on_premises_configuration)
532
+ @project = args[:project] if args.key?(:project)
533
+ @region = args[:region] if args.key?(:region)
534
+ @replica_configuration = args[:replica_configuration] if args.key?(:replica_configuration)
535
+ @replica_names = args[:replica_names] if args.key?(:replica_names)
536
+ @self_link = args[:self_link] if args.key?(:self_link)
537
+ @server_ca_cert = args[:server_ca_cert] if args.key?(:server_ca_cert)
538
+ @service_account_email_address = args[:service_account_email_address] if args.key?(:service_account_email_address)
539
+ @settings = args[:settings] if args.key?(:settings)
540
+ @state = args[:state] if args.key?(:state)
541
+ @suspension_reason = args[:suspension_reason] if args.key?(:suspension_reason)
542
+ end
543
+
544
+ # The name and status of the failover replica. This property is applicable only
545
+ # to Second Generation instances.
546
+ class FailoverReplica
547
+ include Google::Apis::Core::Hashable
548
+
549
+ # The availability status of the failover replica. A false status indicates that
550
+ # the failover replica is out of sync. The master can only failover to the
551
+ # falover replica when the status is true.
552
+ # Corresponds to the JSON property `available`
553
+ # @return [Boolean]
554
+ attr_accessor :available
555
+ alias_method :available?, :available
556
+
557
+ # The name of the failover replica.
558
+ # Corresponds to the JSON property `name`
559
+ # @return [String]
560
+ attr_accessor :name
561
+
562
+ def initialize(**args)
563
+ update!(**args)
564
+ end
565
+
566
+ # Update properties of this object
567
+ def update!(**args)
568
+ @available = args[:available] if args.key?(:available)
569
+ @name = args[:name] if args.key?(:name)
570
+ end
571
+ end
572
+ end
573
+
574
+ # Database list response.
575
+ class ListDatabasesResponse
576
+ include Google::Apis::Core::Hashable
577
+
578
+ # List of database resources in the instance.
579
+ # Corresponds to the JSON property `items`
580
+ # @return [Array<Google::Apis::SqladminV1beta4::Database>]
581
+ attr_accessor :items
582
+
583
+ # This is always sql#databasesList.
584
+ # Corresponds to the JSON property `kind`
585
+ # @return [String]
586
+ attr_accessor :kind
587
+
588
+ def initialize(**args)
589
+ update!(**args)
590
+ end
591
+
592
+ # Update properties of this object
593
+ def update!(**args)
594
+ @items = args[:items] if args.key?(:items)
595
+ @kind = args[:kind] if args.key?(:kind)
596
+ end
597
+ end
598
+
599
+ # Database instance export context.
600
+ class ExportContext
601
+ include Google::Apis::Core::Hashable
602
+
603
+ # Options for exporting data as CSV.
604
+ # Corresponds to the JSON property `csvExportOptions`
605
+ # @return [Google::Apis::SqladminV1beta4::ExportContext::CsvExportOptions]
606
+ attr_accessor :csv_export_options
607
+
608
+ # Databases (for example, guestbook) from which the export is made. If fileType
609
+ # is SQL and no database is specified, all databases are exported. If fileType
610
+ # is CSV, you can optionally specify at most one database to export. If
611
+ # csvExportOptions.selectQuery also specifies the database, this field will be
612
+ # ignored.
613
+ # Corresponds to the JSON property `databases`
614
+ # @return [Array<String>]
615
+ attr_accessor :databases
616
+
617
+ # The file type for the specified uri.
618
+ # SQL: The file contains SQL statements.
619
+ # CSV: The file contains CSV data.
620
+ # Corresponds to the JSON property `fileType`
621
+ # @return [String]
622
+ attr_accessor :file_type
623
+
624
+ # This is always sql#exportContext.
625
+ # Corresponds to the JSON property `kind`
626
+ # @return [String]
627
+ attr_accessor :kind
628
+
629
+ # Options for exporting data as SQL statements.
630
+ # Corresponds to the JSON property `sqlExportOptions`
631
+ # @return [Google::Apis::SqladminV1beta4::ExportContext::SqlExportOptions]
632
+ attr_accessor :sql_export_options
633
+
634
+ # The path to the file in Google Cloud Storage where the export will be stored.
635
+ # The URI is in the form gs://bucketName/fileName. If the file already exists,
636
+ # the operation fails. If fileType is SQL and the filename ends with .gz, the
637
+ # contents are compressed.
638
+ # Corresponds to the JSON property `uri`
639
+ # @return [String]
640
+ attr_accessor :uri
641
+
642
+ def initialize(**args)
643
+ update!(**args)
644
+ end
645
+
646
+ # Update properties of this object
647
+ def update!(**args)
648
+ @csv_export_options = args[:csv_export_options] if args.key?(:csv_export_options)
649
+ @databases = args[:databases] if args.key?(:databases)
650
+ @file_type = args[:file_type] if args.key?(:file_type)
651
+ @kind = args[:kind] if args.key?(:kind)
652
+ @sql_export_options = args[:sql_export_options] if args.key?(:sql_export_options)
653
+ @uri = args[:uri] if args.key?(:uri)
654
+ end
655
+
656
+ # Options for exporting data as CSV.
657
+ class CsvExportOptions
658
+ include Google::Apis::Core::Hashable
659
+
660
+ # The select query used to extract the data.
661
+ # Corresponds to the JSON property `selectQuery`
662
+ # @return [String]
663
+ attr_accessor :select_query
664
+
665
+ def initialize(**args)
666
+ update!(**args)
667
+ end
668
+
669
+ # Update properties of this object
670
+ def update!(**args)
671
+ @select_query = args[:select_query] if args.key?(:select_query)
672
+ end
673
+ end
674
+
675
+ # Options for exporting data as SQL statements.
676
+ class SqlExportOptions
677
+ include Google::Apis::Core::Hashable
678
+
679
+ # Export only schemas.
680
+ # Corresponds to the JSON property `schemaOnly`
681
+ # @return [Boolean]
682
+ attr_accessor :schema_only
683
+ alias_method :schema_only?, :schema_only
684
+
685
+ # Tables to export, or that were exported, from the specified database. If you
686
+ # specify tables, specify one and only one database.
687
+ # Corresponds to the JSON property `tables`
688
+ # @return [Array<String>]
689
+ attr_accessor :tables
690
+
691
+ def initialize(**args)
692
+ update!(**args)
693
+ end
694
+
695
+ # Update properties of this object
696
+ def update!(**args)
697
+ @schema_only = args[:schema_only] if args.key?(:schema_only)
698
+ @tables = args[:tables] if args.key?(:tables)
699
+ end
700
+ end
701
+ end
702
+
703
+ # Database instance failover context.
704
+ class FailoverContext
705
+ include Google::Apis::Core::Hashable
706
+
707
+ # This is always sql#failoverContext.
708
+ # Corresponds to the JSON property `kind`
709
+ # @return [String]
710
+ attr_accessor :kind
711
+
712
+ # The current settings version of this instance. Request will be rejected if
713
+ # this version doesn't match the current settings version.
714
+ # Corresponds to the JSON property `settingsVersion`
715
+ # @return [String]
716
+ attr_accessor :settings_version
717
+
718
+ def initialize(**args)
719
+ update!(**args)
720
+ end
721
+
722
+ # Update properties of this object
723
+ def update!(**args)
724
+ @kind = args[:kind] if args.key?(:kind)
725
+ @settings_version = args[:settings_version] if args.key?(:settings_version)
726
+ end
727
+ end
728
+
729
+ # A Google Cloud SQL service flag resource.
730
+ class Flag
731
+ include Google::Apis::Core::Hashable
732
+
733
+ # For STRING flags, a list of strings that the value can be set to.
734
+ # Corresponds to the JSON property `allowedStringValues`
735
+ # @return [Array<String>]
736
+ attr_accessor :allowed_string_values
737
+
738
+ # The database version this flag applies to. Can be MYSQL_5_5, MYSQL_5_6, or
739
+ # both.
740
+ # Corresponds to the JSON property `appliesTo`
741
+ # @return [Array<String>]
742
+ attr_accessor :applies_to
743
+
744
+ # This is always sql#flag.
745
+ # Corresponds to the JSON property `kind`
746
+ # @return [String]
747
+ attr_accessor :kind
748
+
749
+ # For INTEGER flags, the maximum allowed value.
750
+ # Corresponds to the JSON property `maxValue`
751
+ # @return [String]
752
+ attr_accessor :max_value
753
+
754
+ # For INTEGER flags, the minimum allowed value.
755
+ # Corresponds to the JSON property `minValue`
756
+ # @return [String]
757
+ attr_accessor :min_value
758
+
759
+ # This is the name of the flag. Flag names always use underscores, not hyphens,
760
+ # e.g. max_allowed_packet
761
+ # Corresponds to the JSON property `name`
762
+ # @return [String]
763
+ attr_accessor :name
764
+
765
+ # Indicates whether changing this flag will trigger a database restart. Only
766
+ # applicable to Second Generation instances.
767
+ # Corresponds to the JSON property `requiresRestart`
768
+ # @return [Boolean]
769
+ attr_accessor :requires_restart
770
+ alias_method :requires_restart?, :requires_restart
771
+
772
+ # The type of the flag. Flags are typed to being BOOLEAN, STRING, INTEGER or
773
+ # NONE. NONE is used for flags which do not take a value, such as
774
+ # skip_grant_tables.
775
+ # Corresponds to the JSON property `type`
776
+ # @return [String]
777
+ attr_accessor :type
778
+
779
+ def initialize(**args)
780
+ update!(**args)
781
+ end
782
+
783
+ # Update properties of this object
784
+ def update!(**args)
785
+ @allowed_string_values = args[:allowed_string_values] if args.key?(:allowed_string_values)
786
+ @applies_to = args[:applies_to] if args.key?(:applies_to)
787
+ @kind = args[:kind] if args.key?(:kind)
788
+ @max_value = args[:max_value] if args.key?(:max_value)
789
+ @min_value = args[:min_value] if args.key?(:min_value)
790
+ @name = args[:name] if args.key?(:name)
791
+ @requires_restart = args[:requires_restart] if args.key?(:requires_restart)
792
+ @type = args[:type] if args.key?(:type)
793
+ end
794
+ end
795
+
796
+ # Flags list response.
797
+ class ListFlagsResponse
798
+ include Google::Apis::Core::Hashable
799
+
800
+ # List of flags.
801
+ # Corresponds to the JSON property `items`
802
+ # @return [Array<Google::Apis::SqladminV1beta4::Flag>]
803
+ attr_accessor :items
804
+
805
+ # This is always sql#flagsList.
806
+ # Corresponds to the JSON property `kind`
807
+ # @return [String]
808
+ attr_accessor :kind
809
+
810
+ def initialize(**args)
811
+ update!(**args)
812
+ end
813
+
814
+ # Update properties of this object
815
+ def update!(**args)
816
+ @items = args[:items] if args.key?(:items)
817
+ @kind = args[:kind] if args.key?(:kind)
818
+ end
819
+ end
820
+
821
+ # Database instance import context.
822
+ class ImportContext
823
+ include Google::Apis::Core::Hashable
824
+
825
+ # Options for importing data as CSV.
826
+ # Corresponds to the JSON property `csvImportOptions`
827
+ # @return [Google::Apis::SqladminV1beta4::ImportContext::CsvImportOptions]
828
+ attr_accessor :csv_import_options
829
+
830
+ # The database (for example, guestbook) to which the import is made. If fileType
831
+ # is SQL and no database is specified, it is assumed that the database is
832
+ # specified in the file to be imported. If fileType is CSV, it must be specified.
833
+ # Corresponds to the JSON property `database`
834
+ # @return [String]
835
+ attr_accessor :database
836
+
837
+ # The file type for the specified uri.
838
+ # SQL: The file contains SQL statements.
839
+ # CSV: The file contains CSV data.
840
+ # Corresponds to the JSON property `fileType`
841
+ # @return [String]
842
+ attr_accessor :file_type
843
+
844
+ # This is always sql#importContext.
845
+ # Corresponds to the JSON property `kind`
846
+ # @return [String]
847
+ attr_accessor :kind
848
+
849
+ # A path to the file in Google Cloud Storage from which the import is made. The
850
+ # URI is in the form gs://bucketName/fileName. Compressed gzip files (.gz) are
851
+ # supported when fileType is SQL.
852
+ # Corresponds to the JSON property `uri`
853
+ # @return [String]
854
+ attr_accessor :uri
855
+
856
+ def initialize(**args)
857
+ update!(**args)
858
+ end
859
+
860
+ # Update properties of this object
861
+ def update!(**args)
862
+ @csv_import_options = args[:csv_import_options] if args.key?(:csv_import_options)
863
+ @database = args[:database] if args.key?(:database)
864
+ @file_type = args[:file_type] if args.key?(:file_type)
865
+ @kind = args[:kind] if args.key?(:kind)
866
+ @uri = args[:uri] if args.key?(:uri)
867
+ end
868
+
869
+ # Options for importing data as CSV.
870
+ class CsvImportOptions
871
+ include Google::Apis::Core::Hashable
872
+
873
+ # The columns to which CSV data is imported. If not specified, all columns of
874
+ # the database table are loaded with CSV data.
875
+ # Corresponds to the JSON property `columns`
876
+ # @return [Array<String>]
877
+ attr_accessor :columns
878
+
879
+ # The table to which CSV data is imported.
880
+ # Corresponds to the JSON property `table`
881
+ # @return [String]
882
+ attr_accessor :table
883
+
884
+ def initialize(**args)
885
+ update!(**args)
886
+ end
887
+
888
+ # Update properties of this object
889
+ def update!(**args)
890
+ @columns = args[:columns] if args.key?(:columns)
891
+ @table = args[:table] if args.key?(:table)
892
+ end
893
+ end
894
+ end
895
+
896
+ # Database instance clone request.
897
+ class CloneInstancesRequest
898
+ include Google::Apis::Core::Hashable
899
+
900
+ # Database instance clone context.
901
+ # Corresponds to the JSON property `cloneContext`
902
+ # @return [Google::Apis::SqladminV1beta4::CloneContext]
903
+ attr_accessor :clone_context
904
+
905
+ def initialize(**args)
906
+ update!(**args)
907
+ end
908
+
909
+ # Update properties of this object
910
+ def update!(**args)
911
+ @clone_context = args[:clone_context] if args.key?(:clone_context)
912
+ end
913
+ end
914
+
915
+ # Database instance export request.
916
+ class ExportInstancesRequest
917
+ include Google::Apis::Core::Hashable
918
+
919
+ # Database instance export context.
920
+ # Corresponds to the JSON property `exportContext`
921
+ # @return [Google::Apis::SqladminV1beta4::ExportContext]
922
+ attr_accessor :export_context
923
+
924
+ def initialize(**args)
925
+ update!(**args)
926
+ end
927
+
928
+ # Update properties of this object
929
+ def update!(**args)
930
+ @export_context = args[:export_context] if args.key?(:export_context)
931
+ end
932
+ end
933
+
934
+ # Instance failover request.
935
+ class InstancesFailoverRequest
936
+ include Google::Apis::Core::Hashable
937
+
938
+ # Database instance failover context.
939
+ # Corresponds to the JSON property `failoverContext`
940
+ # @return [Google::Apis::SqladminV1beta4::FailoverContext]
941
+ attr_accessor :failover_context
942
+
943
+ def initialize(**args)
944
+ update!(**args)
945
+ end
946
+
947
+ # Update properties of this object
948
+ def update!(**args)
949
+ @failover_context = args[:failover_context] if args.key?(:failover_context)
950
+ end
951
+ end
952
+
953
+ # Database instance import request.
954
+ class ImportInstancesRequest
955
+ include Google::Apis::Core::Hashable
956
+
957
+ # Database instance import context.
958
+ # Corresponds to the JSON property `importContext`
959
+ # @return [Google::Apis::SqladminV1beta4::ImportContext]
960
+ attr_accessor :import_context
961
+
962
+ def initialize(**args)
963
+ update!(**args)
964
+ end
965
+
966
+ # Update properties of this object
967
+ def update!(**args)
968
+ @import_context = args[:import_context] if args.key?(:import_context)
969
+ end
970
+ end
971
+
972
+ # Database instances list response.
973
+ class ListInstancesResponse
974
+ include Google::Apis::Core::Hashable
975
+
976
+ # List of database instance resources.
977
+ # Corresponds to the JSON property `items`
978
+ # @return [Array<Google::Apis::SqladminV1beta4::DatabaseInstance>]
979
+ attr_accessor :items
980
+
981
+ # This is always sql#instancesList.
982
+ # Corresponds to the JSON property `kind`
983
+ # @return [String]
984
+ attr_accessor :kind
985
+
986
+ # The continuation token, used to page through large result sets. Provide this
987
+ # value in a subsequent request to return the next page of results.
988
+ # Corresponds to the JSON property `nextPageToken`
989
+ # @return [String]
990
+ attr_accessor :next_page_token
991
+
992
+ def initialize(**args)
993
+ update!(**args)
994
+ end
995
+
996
+ # Update properties of this object
997
+ def update!(**args)
998
+ @items = args[:items] if args.key?(:items)
999
+ @kind = args[:kind] if args.key?(:kind)
1000
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1001
+ end
1002
+ end
1003
+
1004
+ # Database instance restore backup request.
1005
+ class RestoreInstancesBackupRequest
1006
+ include Google::Apis::Core::Hashable
1007
+
1008
+ # Database instance restore from backup context.
1009
+ # Corresponds to the JSON property `restoreBackupContext`
1010
+ # @return [Google::Apis::SqladminV1beta4::RestoreBackupContext]
1011
+ attr_accessor :restore_backup_context
1012
+
1013
+ def initialize(**args)
1014
+ update!(**args)
1015
+ end
1016
+
1017
+ # Update properties of this object
1018
+ def update!(**args)
1019
+ @restore_backup_context = args[:restore_backup_context] if args.key?(:restore_backup_context)
1020
+ end
1021
+ end
1022
+
1023
+ # IP Management configuration.
1024
+ class IpConfiguration
1025
+ include Google::Apis::Core::Hashable
1026
+
1027
+ # The list of external networks that are allowed to connect to the instance
1028
+ # using the IP. In CIDR notation, also known as 'slash' notation (e.g. 192.168.
1029
+ # 100.0/24).
1030
+ # Corresponds to the JSON property `authorizedNetworks`
1031
+ # @return [Array<Google::Apis::SqladminV1beta4::AclEntry>]
1032
+ attr_accessor :authorized_networks
1033
+
1034
+ # Whether the instance should be assigned an IP address or not.
1035
+ # Corresponds to the JSON property `ipv4Enabled`
1036
+ # @return [Boolean]
1037
+ attr_accessor :ipv4_enabled
1038
+ alias_method :ipv4_enabled?, :ipv4_enabled
1039
+
1040
+ # Whether the mysqld should default to 'REQUIRE X509' for users connecting over
1041
+ # IP.
1042
+ # Corresponds to the JSON property `requireSsl`
1043
+ # @return [Boolean]
1044
+ attr_accessor :require_ssl
1045
+ alias_method :require_ssl?, :require_ssl
1046
+
1047
+ def initialize(**args)
1048
+ update!(**args)
1049
+ end
1050
+
1051
+ # Update properties of this object
1052
+ def update!(**args)
1053
+ @authorized_networks = args[:authorized_networks] if args.key?(:authorized_networks)
1054
+ @ipv4_enabled = args[:ipv4_enabled] if args.key?(:ipv4_enabled)
1055
+ @require_ssl = args[:require_ssl] if args.key?(:require_ssl)
1056
+ end
1057
+ end
1058
+
1059
+ # Database instance IP Mapping.
1060
+ class IpMapping
1061
+ include Google::Apis::Core::Hashable
1062
+
1063
+ # The IP address assigned.
1064
+ # Corresponds to the JSON property `ipAddress`
1065
+ # @return [String]
1066
+ attr_accessor :ip_address
1067
+
1068
+ # The due time for this IP to be retired in RFC 3339 format, for example 2012-11-
1069
+ # 15T16:19:00.094Z. This field is only available when the IP is scheduled to be
1070
+ # retired.
1071
+ # Corresponds to the JSON property `timeToRetire`
1072
+ # @return [DateTime]
1073
+ attr_accessor :time_to_retire
1074
+
1075
+ def initialize(**args)
1076
+ update!(**args)
1077
+ end
1078
+
1079
+ # Update properties of this object
1080
+ def update!(**args)
1081
+ @ip_address = args[:ip_address] if args.key?(:ip_address)
1082
+ @time_to_retire = args[:time_to_retire] if args.key?(:time_to_retire)
1083
+ end
1084
+ end
1085
+
1086
+ # Preferred location. This specifies where a Cloud SQL instance should
1087
+ # preferably be located, either in a specific Compute Engine zone, or co-located
1088
+ # with an App Engine application. Note that if the preferred location is not
1089
+ # available, the instance will be located as close as possible within the region.
1090
+ # Only one location may be specified.
1091
+ class LocationPreference
1092
+ include Google::Apis::Core::Hashable
1093
+
1094
+ # The AppEngine application to follow, it must be in the same region as the
1095
+ # Cloud SQL instance.
1096
+ # Corresponds to the JSON property `followGaeApplication`
1097
+ # @return [String]
1098
+ attr_accessor :follow_gae_application
1099
+
1100
+ # This is always sql#locationPreference.
1101
+ # Corresponds to the JSON property `kind`
1102
+ # @return [String]
1103
+ attr_accessor :kind
1104
+
1105
+ # The preferred Compute Engine zone (e.g. us-centra1-a, us-central1-b, etc.).
1106
+ # Corresponds to the JSON property `zone`
1107
+ # @return [String]
1108
+ attr_accessor :zone
1109
+
1110
+ def initialize(**args)
1111
+ update!(**args)
1112
+ end
1113
+
1114
+ # Update properties of this object
1115
+ def update!(**args)
1116
+ @follow_gae_application = args[:follow_gae_application] if args.key?(:follow_gae_application)
1117
+ @kind = args[:kind] if args.key?(:kind)
1118
+ @zone = args[:zone] if args.key?(:zone)
1119
+ end
1120
+ end
1121
+
1122
+ # Maintenance window. This specifies when a v2 Cloud SQL instance should
1123
+ # preferably be restarted for system maintenance puruposes.
1124
+ class MaintenanceWindow
1125
+ include Google::Apis::Core::Hashable
1126
+
1127
+ # day of week (1-7), starting on Monday.
1128
+ # Corresponds to the JSON property `day`
1129
+ # @return [Fixnum]
1130
+ attr_accessor :day
1131
+
1132
+ # hour of day - 0 to 23.
1133
+ # Corresponds to the JSON property `hour`
1134
+ # @return [Fixnum]
1135
+ attr_accessor :hour
1136
+
1137
+ # This is always sql#maintenanceWindow.
1138
+ # Corresponds to the JSON property `kind`
1139
+ # @return [String]
1140
+ attr_accessor :kind
1141
+
1142
+ #
1143
+ # Corresponds to the JSON property `updateTrack`
1144
+ # @return [String]
1145
+ attr_accessor :update_track
1146
+
1147
+ def initialize(**args)
1148
+ update!(**args)
1149
+ end
1150
+
1151
+ # Update properties of this object
1152
+ def update!(**args)
1153
+ @day = args[:day] if args.key?(:day)
1154
+ @hour = args[:hour] if args.key?(:hour)
1155
+ @kind = args[:kind] if args.key?(:kind)
1156
+ @update_track = args[:update_track] if args.key?(:update_track)
1157
+ end
1158
+ end
1159
+
1160
+ # Read-replica configuration specific to MySQL databases.
1161
+ class MySqlReplicaConfiguration
1162
+ include Google::Apis::Core::Hashable
1163
+
1164
+ # PEM representation of the trusted CA's x509 certificate.
1165
+ # Corresponds to the JSON property `caCertificate`
1166
+ # @return [String]
1167
+ attr_accessor :ca_certificate
1168
+
1169
+ # PEM representation of the slave's x509 certificate.
1170
+ # Corresponds to the JSON property `clientCertificate`
1171
+ # @return [String]
1172
+ attr_accessor :client_certificate
1173
+
1174
+ # PEM representation of the slave's private key. The corresponsing public key is
1175
+ # encoded in the client's certificate.
1176
+ # Corresponds to the JSON property `clientKey`
1177
+ # @return [String]
1178
+ attr_accessor :client_key
1179
+
1180
+ # Seconds to wait between connect retries. MySQL's default is 60 seconds.
1181
+ # Corresponds to the JSON property `connectRetryInterval`
1182
+ # @return [Fixnum]
1183
+ attr_accessor :connect_retry_interval
1184
+
1185
+ # Path to a SQL dump file in Google Cloud Storage from which the slave instance
1186
+ # is to be created. The URI is in the form gs://bucketName/fileName. Compressed
1187
+ # gzip files (.gz) are also supported. Dumps should have the binlog co-ordinates
1188
+ # from which replication should begin. This can be accomplished by setting --
1189
+ # master-data to 1 when using mysqldump.
1190
+ # Corresponds to the JSON property `dumpFilePath`
1191
+ # @return [String]
1192
+ attr_accessor :dump_file_path
1193
+
1194
+ # This is always sql#mysqlReplicaConfiguration.
1195
+ # Corresponds to the JSON property `kind`
1196
+ # @return [String]
1197
+ attr_accessor :kind
1198
+
1199
+ # Interval in milliseconds between replication heartbeats.
1200
+ # Corresponds to the JSON property `masterHeartbeatPeriod`
1201
+ # @return [String]
1202
+ attr_accessor :master_heartbeat_period
1203
+
1204
+ # The password for the replication connection.
1205
+ # Corresponds to the JSON property `password`
1206
+ # @return [String]
1207
+ attr_accessor :password
1208
+
1209
+ # A list of permissible ciphers to use for SSL encryption.
1210
+ # Corresponds to the JSON property `sslCipher`
1211
+ # @return [String]
1212
+ attr_accessor :ssl_cipher
1213
+
1214
+ # The username for the replication connection.
1215
+ # Corresponds to the JSON property `username`
1216
+ # @return [String]
1217
+ attr_accessor :username
1218
+
1219
+ # Whether or not to check the master's Common Name value in the certificate that
1220
+ # it sends during the SSL handshake.
1221
+ # Corresponds to the JSON property `verifyServerCertificate`
1222
+ # @return [Boolean]
1223
+ attr_accessor :verify_server_certificate
1224
+ alias_method :verify_server_certificate?, :verify_server_certificate
1225
+
1226
+ def initialize(**args)
1227
+ update!(**args)
1228
+ end
1229
+
1230
+ # Update properties of this object
1231
+ def update!(**args)
1232
+ @ca_certificate = args[:ca_certificate] if args.key?(:ca_certificate)
1233
+ @client_certificate = args[:client_certificate] if args.key?(:client_certificate)
1234
+ @client_key = args[:client_key] if args.key?(:client_key)
1235
+ @connect_retry_interval = args[:connect_retry_interval] if args.key?(:connect_retry_interval)
1236
+ @dump_file_path = args[:dump_file_path] if args.key?(:dump_file_path)
1237
+ @kind = args[:kind] if args.key?(:kind)
1238
+ @master_heartbeat_period = args[:master_heartbeat_period] if args.key?(:master_heartbeat_period)
1239
+ @password = args[:password] if args.key?(:password)
1240
+ @ssl_cipher = args[:ssl_cipher] if args.key?(:ssl_cipher)
1241
+ @username = args[:username] if args.key?(:username)
1242
+ @verify_server_certificate = args[:verify_server_certificate] if args.key?(:verify_server_certificate)
1243
+ end
1244
+ end
1245
+
1246
+ # On-premises instance configuration.
1247
+ class OnPremisesConfiguration
1248
+ include Google::Apis::Core::Hashable
1249
+
1250
+ # The host and port of the on-premises instance in host:port format
1251
+ # Corresponds to the JSON property `hostPort`
1252
+ # @return [String]
1253
+ attr_accessor :host_port
1254
+
1255
+ # This is always sql#onPremisesConfiguration.
1256
+ # Corresponds to the JSON property `kind`
1257
+ # @return [String]
1258
+ attr_accessor :kind
1259
+
1260
+ def initialize(**args)
1261
+ update!(**args)
1262
+ end
1263
+
1264
+ # Update properties of this object
1265
+ def update!(**args)
1266
+ @host_port = args[:host_port] if args.key?(:host_port)
1267
+ @kind = args[:kind] if args.key?(:kind)
1268
+ end
1269
+ end
1270
+
1271
+ # An Operations resource contains information about database instance operations
1272
+ # such as create, delete, and restart. Operations resources are created in
1273
+ # response to operations that were initiated; you never create them directly.
1274
+ class Operation
1275
+ include Google::Apis::Core::Hashable
1276
+
1277
+ # The time this operation finished in UTC timezone in RFC 3339 format, for
1278
+ # example 2012-11-15T16:19:00.094Z.
1279
+ # Corresponds to the JSON property `endTime`
1280
+ # @return [DateTime]
1281
+ attr_accessor :end_time
1282
+
1283
+ # Database instance operation errors list wrapper.
1284
+ # Corresponds to the JSON property `error`
1285
+ # @return [Google::Apis::SqladminV1beta4::OperationErrors]
1286
+ attr_accessor :error
1287
+
1288
+ # Database instance export context.
1289
+ # Corresponds to the JSON property `exportContext`
1290
+ # @return [Google::Apis::SqladminV1beta4::ExportContext]
1291
+ attr_accessor :export_context
1292
+
1293
+ # Database instance import context.
1294
+ # Corresponds to the JSON property `importContext`
1295
+ # @return [Google::Apis::SqladminV1beta4::ImportContext]
1296
+ attr_accessor :import_context
1297
+
1298
+ # The time this operation was enqueued in UTC timezone in RFC 3339 format, for
1299
+ # example 2012-11-15T16:19:00.094Z.
1300
+ # Corresponds to the JSON property `insertTime`
1301
+ # @return [DateTime]
1302
+ attr_accessor :insert_time
1303
+
1304
+ # This is always sql#operation.
1305
+ # Corresponds to the JSON property `kind`
1306
+ # @return [String]
1307
+ attr_accessor :kind
1308
+
1309
+ # An identifier that uniquely identifies the operation. You can use this
1310
+ # identifier to retrieve the Operations resource that has information about the
1311
+ # operation.
1312
+ # Corresponds to the JSON property `name`
1313
+ # @return [String]
1314
+ attr_accessor :name
1315
+
1316
+ # The type of the operation. Valid values are CREATE, DELETE, UPDATE, RESTART,
1317
+ # IMPORT, EXPORT, BACKUP_VOLUME, RESTORE_VOLUME, CREATE_USER, DELETE_USER,
1318
+ # CREATE_DATABASE, DELETE_DATABASE .
1319
+ # Corresponds to the JSON property `operationType`
1320
+ # @return [String]
1321
+ attr_accessor :operation_type
1322
+
1323
+ # The URI of this resource.
1324
+ # Corresponds to the JSON property `selfLink`
1325
+ # @return [String]
1326
+ attr_accessor :self_link
1327
+
1328
+ # The time this operation actually started in UTC timezone in RFC 3339 format,
1329
+ # for example 2012-11-15T16:19:00.094Z.
1330
+ # Corresponds to the JSON property `startTime`
1331
+ # @return [DateTime]
1332
+ attr_accessor :start_time
1333
+
1334
+ # The status of an operation. Valid values are PENDING, RUNNING, DONE, UNKNOWN.
1335
+ # Corresponds to the JSON property `status`
1336
+ # @return [String]
1337
+ attr_accessor :status
1338
+
1339
+ # Name of the database instance related to this operation.
1340
+ # Corresponds to the JSON property `targetId`
1341
+ # @return [String]
1342
+ attr_accessor :target_id
1343
+
1344
+ # The URI of the instance related to the operation.
1345
+ # Corresponds to the JSON property `targetLink`
1346
+ # @return [String]
1347
+ attr_accessor :target_link
1348
+
1349
+ # The project ID of the target instance related to this operation.
1350
+ # Corresponds to the JSON property `targetProject`
1351
+ # @return [String]
1352
+ attr_accessor :target_project
1353
+
1354
+ # The email address of the user who initiated this operation.
1355
+ # Corresponds to the JSON property `user`
1356
+ # @return [String]
1357
+ attr_accessor :user
1358
+
1359
+ def initialize(**args)
1360
+ update!(**args)
1361
+ end
1362
+
1363
+ # Update properties of this object
1364
+ def update!(**args)
1365
+ @end_time = args[:end_time] if args.key?(:end_time)
1366
+ @error = args[:error] if args.key?(:error)
1367
+ @export_context = args[:export_context] if args.key?(:export_context)
1368
+ @import_context = args[:import_context] if args.key?(:import_context)
1369
+ @insert_time = args[:insert_time] if args.key?(:insert_time)
1370
+ @kind = args[:kind] if args.key?(:kind)
1371
+ @name = args[:name] if args.key?(:name)
1372
+ @operation_type = args[:operation_type] if args.key?(:operation_type)
1373
+ @self_link = args[:self_link] if args.key?(:self_link)
1374
+ @start_time = args[:start_time] if args.key?(:start_time)
1375
+ @status = args[:status] if args.key?(:status)
1376
+ @target_id = args[:target_id] if args.key?(:target_id)
1377
+ @target_link = args[:target_link] if args.key?(:target_link)
1378
+ @target_project = args[:target_project] if args.key?(:target_project)
1379
+ @user = args[:user] if args.key?(:user)
1380
+ end
1381
+ end
1382
+
1383
+ # Database instance operation error.
1384
+ class OperationError
1385
+ include Google::Apis::Core::Hashable
1386
+
1387
+ # Identifies the specific error that occurred.
1388
+ # Corresponds to the JSON property `code`
1389
+ # @return [String]
1390
+ attr_accessor :code
1391
+
1392
+ # This is always sql#operationError.
1393
+ # Corresponds to the JSON property `kind`
1394
+ # @return [String]
1395
+ attr_accessor :kind
1396
+
1397
+ # Additional information about the error encountered.
1398
+ # Corresponds to the JSON property `message`
1399
+ # @return [String]
1400
+ attr_accessor :message
1401
+
1402
+ def initialize(**args)
1403
+ update!(**args)
1404
+ end
1405
+
1406
+ # Update properties of this object
1407
+ def update!(**args)
1408
+ @code = args[:code] if args.key?(:code)
1409
+ @kind = args[:kind] if args.key?(:kind)
1410
+ @message = args[:message] if args.key?(:message)
1411
+ end
1412
+ end
1413
+
1414
+ # Database instance operation errors list wrapper.
1415
+ class OperationErrors
1416
+ include Google::Apis::Core::Hashable
1417
+
1418
+ # The list of errors encountered while processing this operation.
1419
+ # Corresponds to the JSON property `errors`
1420
+ # @return [Array<Google::Apis::SqladminV1beta4::OperationError>]
1421
+ attr_accessor :errors
1422
+
1423
+ # This is always sql#operationErrors.
1424
+ # Corresponds to the JSON property `kind`
1425
+ # @return [String]
1426
+ attr_accessor :kind
1427
+
1428
+ def initialize(**args)
1429
+ update!(**args)
1430
+ end
1431
+
1432
+ # Update properties of this object
1433
+ def update!(**args)
1434
+ @errors = args[:errors] if args.key?(:errors)
1435
+ @kind = args[:kind] if args.key?(:kind)
1436
+ end
1437
+ end
1438
+
1439
+ # Database instance list operations response.
1440
+ class ListOperationsResponse
1441
+ include Google::Apis::Core::Hashable
1442
+
1443
+ # List of operation resources.
1444
+ # Corresponds to the JSON property `items`
1445
+ # @return [Array<Google::Apis::SqladminV1beta4::Operation>]
1446
+ attr_accessor :items
1447
+
1448
+ # This is always sql#operationsList.
1449
+ # Corresponds to the JSON property `kind`
1450
+ # @return [String]
1451
+ attr_accessor :kind
1452
+
1453
+ # The continuation token, used to page through large result sets. Provide this
1454
+ # value in a subsequent request to return the next page of results.
1455
+ # Corresponds to the JSON property `nextPageToken`
1456
+ # @return [String]
1457
+ attr_accessor :next_page_token
1458
+
1459
+ def initialize(**args)
1460
+ update!(**args)
1461
+ end
1462
+
1463
+ # Update properties of this object
1464
+ def update!(**args)
1465
+ @items = args[:items] if args.key?(:items)
1466
+ @kind = args[:kind] if args.key?(:kind)
1467
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1468
+ end
1469
+ end
1470
+
1471
+ # Read-replica configuration for connecting to the master.
1472
+ class ReplicaConfiguration
1473
+ include Google::Apis::Core::Hashable
1474
+
1475
+ # Specifies if the replica is the failover target. If the field is set to true
1476
+ # the replica will be designated as a failover replica. In case the master
1477
+ # instance fails, the replica instance will be promoted as the new master
1478
+ # instance.
1479
+ # Only one replica can be specified as failover target, and the replica has to
1480
+ # be in different zone with the master instance.
1481
+ # Corresponds to the JSON property `failoverTarget`
1482
+ # @return [Boolean]
1483
+ attr_accessor :failover_target
1484
+ alias_method :failover_target?, :failover_target
1485
+
1486
+ # This is always sql#replicaConfiguration.
1487
+ # Corresponds to the JSON property `kind`
1488
+ # @return [String]
1489
+ attr_accessor :kind
1490
+
1491
+ # Read-replica configuration specific to MySQL databases.
1492
+ # Corresponds to the JSON property `mysqlReplicaConfiguration`
1493
+ # @return [Google::Apis::SqladminV1beta4::MySqlReplicaConfiguration]
1494
+ attr_accessor :mysql_replica_configuration
1495
+
1496
+ def initialize(**args)
1497
+ update!(**args)
1498
+ end
1499
+
1500
+ # Update properties of this object
1501
+ def update!(**args)
1502
+ @failover_target = args[:failover_target] if args.key?(:failover_target)
1503
+ @kind = args[:kind] if args.key?(:kind)
1504
+ @mysql_replica_configuration = args[:mysql_replica_configuration] if args.key?(:mysql_replica_configuration)
1505
+ end
1506
+ end
1507
+
1508
+ # Database instance restore from backup context.
1509
+ class RestoreBackupContext
1510
+ include Google::Apis::Core::Hashable
1511
+
1512
+ # The ID of the backup run to restore from.
1513
+ # Corresponds to the JSON property `backupRunId`
1514
+ # @return [String]
1515
+ attr_accessor :backup_run_id
1516
+
1517
+ # The ID of the instance that the backup was taken from.
1518
+ # Corresponds to the JSON property `instanceId`
1519
+ # @return [String]
1520
+ attr_accessor :instance_id
1521
+
1522
+ # This is always sql#restoreBackupContext.
1523
+ # Corresponds to the JSON property `kind`
1524
+ # @return [String]
1525
+ attr_accessor :kind
1526
+
1527
+ def initialize(**args)
1528
+ update!(**args)
1529
+ end
1530
+
1531
+ # Update properties of this object
1532
+ def update!(**args)
1533
+ @backup_run_id = args[:backup_run_id] if args.key?(:backup_run_id)
1534
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
1535
+ @kind = args[:kind] if args.key?(:kind)
1536
+ end
1537
+ end
1538
+
1539
+ # Database instance settings.
1540
+ class Settings
1541
+ include Google::Apis::Core::Hashable
1542
+
1543
+ # The activation policy for this instance. This specifies when the instance
1544
+ # should be activated and is applicable only when the instance state is RUNNABLE.
1545
+ # This can be one of the following.
1546
+ # ALWAYS: The instance should always be active.
1547
+ # NEVER: The instance should never be activated.
1548
+ # ON_DEMAND: The instance is activated upon receiving requests; only applicable
1549
+ # to First Generation instances.
1550
+ # Corresponds to the JSON property `activationPolicy`
1551
+ # @return [String]
1552
+ attr_accessor :activation_policy
1553
+
1554
+ # The App Engine app IDs that can access this instance. This property is only
1555
+ # applicable to First Generation instances.
1556
+ # Corresponds to the JSON property `authorizedGaeApplications`
1557
+ # @return [Array<String>]
1558
+ attr_accessor :authorized_gae_applications
1559
+
1560
+ # Database instance backup configuration.
1561
+ # Corresponds to the JSON property `backupConfiguration`
1562
+ # @return [Google::Apis::SqladminV1beta4::BackupConfiguration]
1563
+ attr_accessor :backup_configuration
1564
+
1565
+ # Configuration specific to read replica instances. Indicates whether database
1566
+ # flags for crash-safe replication are enabled. This property is only applicable
1567
+ # to First Generation instances.
1568
+ # Corresponds to the JSON property `crashSafeReplicationEnabled`
1569
+ # @return [Boolean]
1570
+ attr_accessor :crash_safe_replication_enabled
1571
+ alias_method :crash_safe_replication_enabled?, :crash_safe_replication_enabled
1572
+
1573
+ # The size of data disk, in GB. The data disk size minimum is 10GB. This
1574
+ # property is only applicable to Second Generation instances.
1575
+ # Corresponds to the JSON property `dataDiskSizeGb`
1576
+ # @return [String]
1577
+ attr_accessor :data_disk_size_gb
1578
+
1579
+ # The type of data disk. Only supported for Second Generation instances. The
1580
+ # default type is PD_SSD. This property is only applicable to Second Generation
1581
+ # instances.
1582
+ # Corresponds to the JSON property `dataDiskType`
1583
+ # @return [String]
1584
+ attr_accessor :data_disk_type
1585
+
1586
+ # The database flags passed to the instance at startup.
1587
+ # Corresponds to the JSON property `databaseFlags`
1588
+ # @return [Array<Google::Apis::SqladminV1beta4::DatabaseFlags>]
1589
+ attr_accessor :database_flags
1590
+
1591
+ # Configuration specific to read replica instances. Indicates whether
1592
+ # replication is enabled or not.
1593
+ # Corresponds to the JSON property `databaseReplicationEnabled`
1594
+ # @return [Boolean]
1595
+ attr_accessor :database_replication_enabled
1596
+ alias_method :database_replication_enabled?, :database_replication_enabled
1597
+
1598
+ # IP Management configuration.
1599
+ # Corresponds to the JSON property `ipConfiguration`
1600
+ # @return [Google::Apis::SqladminV1beta4::IpConfiguration]
1601
+ attr_accessor :ip_configuration
1602
+
1603
+ # This is always sql#settings.
1604
+ # Corresponds to the JSON property `kind`
1605
+ # @return [String]
1606
+ attr_accessor :kind
1607
+
1608
+ # Preferred location. This specifies where a Cloud SQL instance should
1609
+ # preferably be located, either in a specific Compute Engine zone, or co-located
1610
+ # with an App Engine application. Note that if the preferred location is not
1611
+ # available, the instance will be located as close as possible within the region.
1612
+ # Only one location may be specified.
1613
+ # Corresponds to the JSON property `locationPreference`
1614
+ # @return [Google::Apis::SqladminV1beta4::LocationPreference]
1615
+ attr_accessor :location_preference
1616
+
1617
+ # Maintenance window. This specifies when a v2 Cloud SQL instance should
1618
+ # preferably be restarted for system maintenance puruposes.
1619
+ # Corresponds to the JSON property `maintenanceWindow`
1620
+ # @return [Google::Apis::SqladminV1beta4::MaintenanceWindow]
1621
+ attr_accessor :maintenance_window
1622
+
1623
+ # The pricing plan for this instance. This can be either PER_USE or PACKAGE.
1624
+ # Only PER_USE is supported for Second Generation instances.
1625
+ # Corresponds to the JSON property `pricingPlan`
1626
+ # @return [String]
1627
+ attr_accessor :pricing_plan
1628
+
1629
+ # The type of replication this instance uses. This can be either ASYNCHRONOUS or
1630
+ # SYNCHRONOUS. This property is only applicable to First Generation instances.
1631
+ # Corresponds to the JSON property `replicationType`
1632
+ # @return [String]
1633
+ attr_accessor :replication_type
1634
+
1635
+ # The version of instance settings. This is a required field for update method
1636
+ # to make sure concurrent updates are handled properly. During update, use the
1637
+ # most recent settingsVersion value for this instance and do not try to update
1638
+ # this value.
1639
+ # Corresponds to the JSON property `settingsVersion`
1640
+ # @return [String]
1641
+ attr_accessor :settings_version
1642
+
1643
+ # The tier of service for this instance, for example D1, D2. For more
1644
+ # information, see pricing.
1645
+ # Corresponds to the JSON property `tier`
1646
+ # @return [String]
1647
+ attr_accessor :tier
1648
+
1649
+ def initialize(**args)
1650
+ update!(**args)
1651
+ end
1652
+
1653
+ # Update properties of this object
1654
+ def update!(**args)
1655
+ @activation_policy = args[:activation_policy] if args.key?(:activation_policy)
1656
+ @authorized_gae_applications = args[:authorized_gae_applications] if args.key?(:authorized_gae_applications)
1657
+ @backup_configuration = args[:backup_configuration] if args.key?(:backup_configuration)
1658
+ @crash_safe_replication_enabled = args[:crash_safe_replication_enabled] if args.key?(:crash_safe_replication_enabled)
1659
+ @data_disk_size_gb = args[:data_disk_size_gb] if args.key?(:data_disk_size_gb)
1660
+ @data_disk_type = args[:data_disk_type] if args.key?(:data_disk_type)
1661
+ @database_flags = args[:database_flags] if args.key?(:database_flags)
1662
+ @database_replication_enabled = args[:database_replication_enabled] if args.key?(:database_replication_enabled)
1663
+ @ip_configuration = args[:ip_configuration] if args.key?(:ip_configuration)
1664
+ @kind = args[:kind] if args.key?(:kind)
1665
+ @location_preference = args[:location_preference] if args.key?(:location_preference)
1666
+ @maintenance_window = args[:maintenance_window] if args.key?(:maintenance_window)
1667
+ @pricing_plan = args[:pricing_plan] if args.key?(:pricing_plan)
1668
+ @replication_type = args[:replication_type] if args.key?(:replication_type)
1669
+ @settings_version = args[:settings_version] if args.key?(:settings_version)
1670
+ @tier = args[:tier] if args.key?(:tier)
1671
+ end
1672
+ end
1673
+
1674
+ # SslCerts Resource
1675
+ class SslCert
1676
+ include Google::Apis::Core::Hashable
1677
+
1678
+ # PEM representation.
1679
+ # Corresponds to the JSON property `cert`
1680
+ # @return [String]
1681
+ attr_accessor :cert
1682
+
1683
+ # Serial number, as extracted from the certificate.
1684
+ # Corresponds to the JSON property `certSerialNumber`
1685
+ # @return [String]
1686
+ attr_accessor :cert_serial_number
1687
+
1688
+ # User supplied name. Constrained to [a-zA-Z.-_ ]+.
1689
+ # Corresponds to the JSON property `commonName`
1690
+ # @return [String]
1691
+ attr_accessor :common_name
1692
+
1693
+ # The time when the certificate was created in RFC 3339 format, for example 2012-
1694
+ # 11-15T16:19:00.094Z
1695
+ # Corresponds to the JSON property `createTime`
1696
+ # @return [DateTime]
1697
+ attr_accessor :create_time
1698
+
1699
+ # The time when the certificate expires in RFC 3339 format, for example 2012-11-
1700
+ # 15T16:19:00.094Z.
1701
+ # Corresponds to the JSON property `expirationTime`
1702
+ # @return [DateTime]
1703
+ attr_accessor :expiration_time
1704
+
1705
+ # Name of the database instance.
1706
+ # Corresponds to the JSON property `instance`
1707
+ # @return [String]
1708
+ attr_accessor :instance
1709
+
1710
+ # This is always sql#sslCert.
1711
+ # Corresponds to the JSON property `kind`
1712
+ # @return [String]
1713
+ attr_accessor :kind
1714
+
1715
+ # The URI of this resource.
1716
+ # Corresponds to the JSON property `selfLink`
1717
+ # @return [String]
1718
+ attr_accessor :self_link
1719
+
1720
+ # Sha1 Fingerprint.
1721
+ # Corresponds to the JSON property `sha1Fingerprint`
1722
+ # @return [String]
1723
+ attr_accessor :sha1_fingerprint
1724
+
1725
+ def initialize(**args)
1726
+ update!(**args)
1727
+ end
1728
+
1729
+ # Update properties of this object
1730
+ def update!(**args)
1731
+ @cert = args[:cert] if args.key?(:cert)
1732
+ @cert_serial_number = args[:cert_serial_number] if args.key?(:cert_serial_number)
1733
+ @common_name = args[:common_name] if args.key?(:common_name)
1734
+ @create_time = args[:create_time] if args.key?(:create_time)
1735
+ @expiration_time = args[:expiration_time] if args.key?(:expiration_time)
1736
+ @instance = args[:instance] if args.key?(:instance)
1737
+ @kind = args[:kind] if args.key?(:kind)
1738
+ @self_link = args[:self_link] if args.key?(:self_link)
1739
+ @sha1_fingerprint = args[:sha1_fingerprint] if args.key?(:sha1_fingerprint)
1740
+ end
1741
+ end
1742
+
1743
+ # SslCertDetail.
1744
+ class SslCertDetail
1745
+ include Google::Apis::Core::Hashable
1746
+
1747
+ # SslCerts Resource
1748
+ # Corresponds to the JSON property `certInfo`
1749
+ # @return [Google::Apis::SqladminV1beta4::SslCert]
1750
+ attr_accessor :cert_info
1751
+
1752
+ # The private key for the client cert, in pem format. Keep private in order to
1753
+ # protect your security.
1754
+ # Corresponds to the JSON property `certPrivateKey`
1755
+ # @return [String]
1756
+ attr_accessor :cert_private_key
1757
+
1758
+ def initialize(**args)
1759
+ update!(**args)
1760
+ end
1761
+
1762
+ # Update properties of this object
1763
+ def update!(**args)
1764
+ @cert_info = args[:cert_info] if args.key?(:cert_info)
1765
+ @cert_private_key = args[:cert_private_key] if args.key?(:cert_private_key)
1766
+ end
1767
+ end
1768
+
1769
+ # SslCerts create ephemeral certificate request.
1770
+ class SslCertsCreateEphemeralRequest
1771
+ include Google::Apis::Core::Hashable
1772
+
1773
+ # PEM encoded public key to include in the signed certificate.
1774
+ # Corresponds to the JSON property `public_key`
1775
+ # @return [String]
1776
+ attr_accessor :public_key
1777
+
1778
+ def initialize(**args)
1779
+ update!(**args)
1780
+ end
1781
+
1782
+ # Update properties of this object
1783
+ def update!(**args)
1784
+ @public_key = args[:public_key] if args.key?(:public_key)
1785
+ end
1786
+ end
1787
+
1788
+ # SslCerts insert request.
1789
+ class InsertSslCertsRequest
1790
+ include Google::Apis::Core::Hashable
1791
+
1792
+ # User supplied name. Must be a distinct name from the other certificates for
1793
+ # this instance. New certificates will not be usable until the instance is
1794
+ # restarted.
1795
+ # Corresponds to the JSON property `commonName`
1796
+ # @return [String]
1797
+ attr_accessor :common_name
1798
+
1799
+ def initialize(**args)
1800
+ update!(**args)
1801
+ end
1802
+
1803
+ # Update properties of this object
1804
+ def update!(**args)
1805
+ @common_name = args[:common_name] if args.key?(:common_name)
1806
+ end
1807
+ end
1808
+
1809
+ # SslCert insert response.
1810
+ class InsertSslCertsResponse
1811
+ include Google::Apis::Core::Hashable
1812
+
1813
+ # SslCertDetail.
1814
+ # Corresponds to the JSON property `clientCert`
1815
+ # @return [Google::Apis::SqladminV1beta4::SslCertDetail]
1816
+ attr_accessor :client_cert
1817
+
1818
+ # This is always sql#sslCertsInsert.
1819
+ # Corresponds to the JSON property `kind`
1820
+ # @return [String]
1821
+ attr_accessor :kind
1822
+
1823
+ # SslCerts Resource
1824
+ # Corresponds to the JSON property `serverCaCert`
1825
+ # @return [Google::Apis::SqladminV1beta4::SslCert]
1826
+ attr_accessor :server_ca_cert
1827
+
1828
+ def initialize(**args)
1829
+ update!(**args)
1830
+ end
1831
+
1832
+ # Update properties of this object
1833
+ def update!(**args)
1834
+ @client_cert = args[:client_cert] if args.key?(:client_cert)
1835
+ @kind = args[:kind] if args.key?(:kind)
1836
+ @server_ca_cert = args[:server_ca_cert] if args.key?(:server_ca_cert)
1837
+ end
1838
+ end
1839
+
1840
+ # SslCerts list response.
1841
+ class ListSslCertsResponse
1842
+ include Google::Apis::Core::Hashable
1843
+
1844
+ # List of client certificates for the instance.
1845
+ # Corresponds to the JSON property `items`
1846
+ # @return [Array<Google::Apis::SqladminV1beta4::SslCert>]
1847
+ attr_accessor :items
1848
+
1849
+ # This is always sql#sslCertsList.
1850
+ # Corresponds to the JSON property `kind`
1851
+ # @return [String]
1852
+ attr_accessor :kind
1853
+
1854
+ def initialize(**args)
1855
+ update!(**args)
1856
+ end
1857
+
1858
+ # Update properties of this object
1859
+ def update!(**args)
1860
+ @items = args[:items] if args.key?(:items)
1861
+ @kind = args[:kind] if args.key?(:kind)
1862
+ end
1863
+ end
1864
+
1865
+ # A Google Cloud SQL service tier resource.
1866
+ class Tier
1867
+ include Google::Apis::Core::Hashable
1868
+
1869
+ # The maximum disk size of this tier in bytes.
1870
+ # Corresponds to the JSON property `DiskQuota`
1871
+ # @return [String]
1872
+ attr_accessor :disk_quota
1873
+
1874
+ # The maximum RAM usage of this tier in bytes.
1875
+ # Corresponds to the JSON property `RAM`
1876
+ # @return [String]
1877
+ attr_accessor :ram
1878
+
1879
+ # This is always sql#tier.
1880
+ # Corresponds to the JSON property `kind`
1881
+ # @return [String]
1882
+ attr_accessor :kind
1883
+
1884
+ # The applicable regions for this tier. Can be us-east1, europe-west1 or asia-
1885
+ # east1.
1886
+ # Corresponds to the JSON property `region`
1887
+ # @return [Array<String>]
1888
+ attr_accessor :region
1889
+
1890
+ # An identifier for the service tier, for example D1, D2 etc. For related
1891
+ # information, see Pricing.
1892
+ # Corresponds to the JSON property `tier`
1893
+ # @return [String]
1894
+ attr_accessor :tier
1895
+
1896
+ def initialize(**args)
1897
+ update!(**args)
1898
+ end
1899
+
1900
+ # Update properties of this object
1901
+ def update!(**args)
1902
+ @disk_quota = args[:disk_quota] if args.key?(:disk_quota)
1903
+ @ram = args[:ram] if args.key?(:ram)
1904
+ @kind = args[:kind] if args.key?(:kind)
1905
+ @region = args[:region] if args.key?(:region)
1906
+ @tier = args[:tier] if args.key?(:tier)
1907
+ end
1908
+ end
1909
+
1910
+ # Tiers list response.
1911
+ class ListTiersResponse
1912
+ include Google::Apis::Core::Hashable
1913
+
1914
+ # List of tiers.
1915
+ # Corresponds to the JSON property `items`
1916
+ # @return [Array<Google::Apis::SqladminV1beta4::Tier>]
1917
+ attr_accessor :items
1918
+
1919
+ # This is always sql#tiersList.
1920
+ # Corresponds to the JSON property `kind`
1921
+ # @return [String]
1922
+ attr_accessor :kind
1923
+
1924
+ def initialize(**args)
1925
+ update!(**args)
1926
+ end
1927
+
1928
+ # Update properties of this object
1929
+ def update!(**args)
1930
+ @items = args[:items] if args.key?(:items)
1931
+ @kind = args[:kind] if args.key?(:kind)
1932
+ end
1933
+ end
1934
+
1935
+ # A Cloud SQL user resource.
1936
+ class User
1937
+ include Google::Apis::Core::Hashable
1938
+
1939
+ # HTTP 1.1 Entity tag for the resource.
1940
+ # Corresponds to the JSON property `etag`
1941
+ # @return [String]
1942
+ attr_accessor :etag
1943
+
1944
+ # The host name from which the user can connect. For insert operations, host
1945
+ # defaults to an empty string. For update operations, host is specified as part
1946
+ # of the request URL. The host name cannot be updated after insertion.
1947
+ # Corresponds to the JSON property `host`
1948
+ # @return [String]
1949
+ attr_accessor :host
1950
+
1951
+ # The name of the Cloud SQL instance. This does not include the project ID. Can
1952
+ # be omitted for update since it is already specified on the URL.
1953
+ # Corresponds to the JSON property `instance`
1954
+ # @return [String]
1955
+ attr_accessor :instance
1956
+
1957
+ # This is always sql#user.
1958
+ # Corresponds to the JSON property `kind`
1959
+ # @return [String]
1960
+ attr_accessor :kind
1961
+
1962
+ # The name of the user in the Cloud SQL instance. Can be omitted for update
1963
+ # since it is already specified on the URL.
1964
+ # Corresponds to the JSON property `name`
1965
+ # @return [String]
1966
+ attr_accessor :name
1967
+
1968
+ # The password for the user.
1969
+ # Corresponds to the JSON property `password`
1970
+ # @return [String]
1971
+ attr_accessor :password
1972
+
1973
+ # The project ID of the project containing the Cloud SQL database. The Google
1974
+ # apps domain is prefixed if applicable. Can be omitted for update since it is
1975
+ # already specified on the URL.
1976
+ # Corresponds to the JSON property `project`
1977
+ # @return [String]
1978
+ attr_accessor :project
1979
+
1980
+ def initialize(**args)
1981
+ update!(**args)
1982
+ end
1983
+
1984
+ # Update properties of this object
1985
+ def update!(**args)
1986
+ @etag = args[:etag] if args.key?(:etag)
1987
+ @host = args[:host] if args.key?(:host)
1988
+ @instance = args[:instance] if args.key?(:instance)
1989
+ @kind = args[:kind] if args.key?(:kind)
1990
+ @name = args[:name] if args.key?(:name)
1991
+ @password = args[:password] if args.key?(:password)
1992
+ @project = args[:project] if args.key?(:project)
1993
+ end
1994
+ end
1995
+
1996
+ # User list response.
1997
+ class ListUsersResponse
1998
+ include Google::Apis::Core::Hashable
1999
+
2000
+ # List of user resources in the instance.
2001
+ # Corresponds to the JSON property `items`
2002
+ # @return [Array<Google::Apis::SqladminV1beta4::User>]
2003
+ attr_accessor :items
2004
+
2005
+ # This is always sql#usersList.
2006
+ # Corresponds to the JSON property `kind`
2007
+ # @return [String]
2008
+ attr_accessor :kind
2009
+
2010
+ # An identifier that uniquely identifies the operation. You can use this
2011
+ # identifier to retrieve the Operations resource that has information about the
2012
+ # operation.
2013
+ # Corresponds to the JSON property `nextPageToken`
2014
+ # @return [String]
2015
+ attr_accessor :next_page_token
2016
+
2017
+ def initialize(**args)
2018
+ update!(**args)
2019
+ end
2020
+
2021
+ # Update properties of this object
2022
+ def update!(**args)
2023
+ @items = args[:items] if args.key?(:items)
2024
+ @kind = args[:kind] if args.key?(:kind)
2025
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
2026
+ end
2027
+ end
2028
+ end
2029
+ end
2030
+ end