google-api-client 0.25.0 → 0.26.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (265) hide show
  1. checksums.yaml +4 -4
  2. data/{CONTRIBUTING.md → .github/CONTRIBUTING.md} +0 -0
  3. data/.github/ISSUE_TEMPLATE/bug_report.md +36 -0
  4. data/.github/ISSUE_TEMPLATE/feature_request.md +21 -0
  5. data/.github/ISSUE_TEMPLATE/support_request.md +7 -0
  6. data/.kokoro/build.bat +8 -0
  7. data/.kokoro/build.sh +36 -0
  8. data/.kokoro/common.cfg +22 -0
  9. data/.kokoro/continuous/common.cfg +20 -0
  10. data/.kokoro/continuous/linux.cfg +15 -0
  11. data/.kokoro/continuous/osx.cfg +3 -0
  12. data/.kokoro/continuous/windows.cfg +3 -0
  13. data/.kokoro/osx.sh +35 -0
  14. data/.kokoro/presubmit/common.cfg +19 -0
  15. data/.kokoro/presubmit/linux.cfg +14 -0
  16. data/.kokoro/presubmit/osx.cfg +3 -0
  17. data/.kokoro/presubmit/windows.cfg +3 -0
  18. data/.kokoro/trampoline.sh +24 -0
  19. data/.kokoro/windows.sh +32 -0
  20. data/CHANGELOG.md +83 -0
  21. data/Gemfile +2 -2
  22. data/generated/google/apis/adexchangebuyer2_v2beta1.rb +1 -1
  23. data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +3 -1
  24. data/generated/google/apis/alertcenter_v1beta1.rb +5 -3
  25. data/generated/google/apis/alertcenter_v1beta1/classes.rb +110 -101
  26. data/generated/google/apis/alertcenter_v1beta1/representations.rb +13 -0
  27. data/generated/google/apis/alertcenter_v1beta1/service.rb +83 -76
  28. data/generated/google/apis/androiddeviceprovisioning_v1.rb +1 -1
  29. data/generated/google/apis/androiddeviceprovisioning_v1/classes.rb +7 -0
  30. data/generated/google/apis/androiddeviceprovisioning_v1/representations.rb +2 -0
  31. data/generated/google/apis/androiddeviceprovisioning_v1/service.rb +1 -1
  32. data/generated/google/apis/androidenterprise_v1.rb +1 -1
  33. data/generated/google/apis/androidenterprise_v1/classes.rb +129 -44
  34. data/generated/google/apis/androidenterprise_v1/representations.rb +48 -0
  35. data/generated/google/apis/androidenterprise_v1/service.rb +218 -0
  36. data/generated/google/apis/androidmanagement_v1.rb +1 -1
  37. data/generated/google/apis/androidmanagement_v1/classes.rb +1 -1
  38. data/generated/google/apis/androidpublisher_v3.rb +1 -1
  39. data/generated/google/apis/androidpublisher_v3/classes.rb +8 -0
  40. data/generated/google/apis/androidpublisher_v3/representations.rb +1 -0
  41. data/generated/google/apis/appengine_v1.rb +1 -1
  42. data/generated/google/apis/appengine_v1beta.rb +1 -1
  43. data/generated/google/apis/bigquery_v2.rb +1 -1
  44. data/generated/google/apis/bigquery_v2/classes.rb +87 -29
  45. data/generated/google/apis/bigquery_v2/representations.rb +21 -0
  46. data/generated/google/apis/bigquery_v2/service.rb +7 -9
  47. data/generated/google/apis/calendar_v3.rb +2 -2
  48. data/generated/google/apis/calendar_v3/classes.rb +14 -6
  49. data/generated/google/apis/classroom_v1.rb +1 -1
  50. data/generated/google/apis/classroom_v1/service.rb +1 -1
  51. data/generated/google/apis/cloudasset_v1beta1.rb +1 -1
  52. data/generated/google/apis/cloudasset_v1beta1/classes.rb +14 -10
  53. data/generated/google/apis/cloudasset_v1beta1/service.rb +4 -4
  54. data/generated/google/apis/clouddebugger_v2.rb +1 -1
  55. data/generated/google/apis/clouddebugger_v2/classes.rb +2 -2
  56. data/generated/google/apis/cloudfunctions_v1.rb +1 -1
  57. data/generated/google/apis/cloudfunctions_v1/classes.rb +2 -3
  58. data/generated/google/apis/cloudfunctions_v1beta2.rb +1 -1
  59. data/generated/google/apis/cloudfunctions_v1beta2/classes.rb +2 -3
  60. data/generated/google/apis/cloudiot_v1.rb +1 -1
  61. data/generated/google/apis/cloudiot_v1/classes.rb +127 -0
  62. data/generated/google/apis/cloudiot_v1/representations.rb +70 -0
  63. data/generated/google/apis/cloudiot_v1/service.rb +172 -2
  64. data/generated/google/apis/cloudkms_v1.rb +1 -1
  65. data/generated/google/apis/cloudkms_v1/service.rb +107 -0
  66. data/generated/google/apis/{cloudiot_v1beta1.rb → cloudscheduler_v1beta1.rb} +8 -12
  67. data/generated/google/apis/cloudscheduler_v1beta1/classes.rb +882 -0
  68. data/generated/google/apis/cloudscheduler_v1beta1/representations.rb +264 -0
  69. data/generated/google/apis/cloudscheduler_v1beta1/service.rb +445 -0
  70. data/generated/google/apis/cloudsearch_v1.rb +1 -1
  71. data/generated/google/apis/cloudsearch_v1/classes.rb +79 -1
  72. data/generated/google/apis/cloudsearch_v1/representations.rb +44 -0
  73. data/generated/google/apis/cloudsearch_v1/service.rb +88 -3
  74. data/generated/google/apis/composer_v1.rb +1 -1
  75. data/generated/google/apis/composer_v1/classes.rb +9 -0
  76. data/generated/google/apis/composer_v1/representations.rb +1 -0
  77. data/generated/google/apis/compute_alpha.rb +1 -1
  78. data/generated/google/apis/compute_alpha/classes.rb +938 -117
  79. data/generated/google/apis/compute_alpha/representations.rb +310 -2
  80. data/generated/google/apis/compute_alpha/service.rb +1203 -245
  81. data/generated/google/apis/compute_beta.rb +1 -1
  82. data/generated/google/apis/compute_beta/classes.rb +1175 -219
  83. data/generated/google/apis/compute_beta/representations.rb +375 -2
  84. data/generated/google/apis/compute_beta/service.rb +907 -139
  85. data/generated/google/apis/compute_v1.rb +1 -1
  86. data/generated/google/apis/compute_v1/classes.rb +1485 -143
  87. data/generated/google/apis/compute_v1/representations.rb +503 -0
  88. data/generated/google/apis/compute_v1/service.rb +1375 -85
  89. data/generated/google/apis/container_v1.rb +3 -3
  90. data/generated/google/apis/container_v1/classes.rb +99 -6
  91. data/generated/google/apis/container_v1/representations.rb +39 -0
  92. data/generated/google/apis/container_v1/service.rb +2 -2
  93. data/generated/google/apis/container_v1beta1.rb +3 -3
  94. data/generated/google/apis/container_v1beta1/classes.rb +162 -9
  95. data/generated/google/apis/container_v1beta1/representations.rb +80 -0
  96. data/generated/google/apis/container_v1beta1/service.rb +3 -3
  97. data/generated/google/apis/content_v2.rb +1 -1
  98. data/generated/google/apis/content_v2/classes.rb +40 -32
  99. data/generated/google/apis/content_v2/representations.rb +0 -1
  100. data/generated/google/apis/content_v2/service.rb +3 -3
  101. data/generated/google/apis/content_v2_1.rb +35 -0
  102. data/generated/google/apis/content_v2_1/classes.rb +9104 -0
  103. data/generated/google/apis/content_v2_1/representations.rb +3967 -0
  104. data/generated/google/apis/content_v2_1/service.rb +3463 -0
  105. data/generated/google/apis/dataflow_v1b3.rb +1 -1
  106. data/generated/google/apis/dataflow_v1b3/classes.rb +82 -0
  107. data/generated/google/apis/dataflow_v1b3/representations.rb +33 -0
  108. data/generated/google/apis/dataflow_v1b3/service.rb +97 -6
  109. data/generated/google/apis/dataproc_v1.rb +1 -1
  110. data/generated/google/apis/dataproc_v1/classes.rb +15 -1
  111. data/generated/google/apis/dataproc_v1/representations.rb +2 -0
  112. data/generated/google/apis/dataproc_v1beta2.rb +1 -1
  113. data/generated/google/apis/dataproc_v1beta2/classes.rb +125 -1
  114. data/generated/google/apis/dataproc_v1beta2/representations.rb +41 -0
  115. data/generated/google/apis/dialogflow_v2.rb +1 -1
  116. data/generated/google/apis/dialogflow_v2/classes.rb +13 -6
  117. data/generated/google/apis/dialogflow_v2/service.rb +2 -0
  118. data/generated/google/apis/dialogflow_v2beta1.rb +1 -1
  119. data/generated/google/apis/dialogflow_v2beta1/classes.rb +26 -6
  120. data/generated/google/apis/dialogflow_v2beta1/representations.rb +12 -0
  121. data/generated/google/apis/dialogflow_v2beta1/service.rb +261 -12
  122. data/generated/google/apis/dlp_v2.rb +1 -1
  123. data/generated/google/apis/dlp_v2/classes.rb +4 -4
  124. data/generated/google/apis/dns_v1beta2.rb +1 -1
  125. data/generated/google/apis/dns_v1beta2/classes.rb +326 -0
  126. data/generated/google/apis/dns_v1beta2/representations.rb +149 -0
  127. data/generated/google/apis/dns_v1beta2/service.rb +246 -0
  128. data/generated/google/apis/drive_v2.rb +3 -3
  129. data/generated/google/apis/drive_v3.rb +3 -3
  130. data/generated/google/apis/driveactivity_v2.rb +37 -0
  131. data/generated/google/apis/driveactivity_v2/classes.rb +1388 -0
  132. data/generated/google/apis/driveactivity_v2/representations.rb +799 -0
  133. data/generated/google/apis/driveactivity_v2/service.rb +89 -0
  134. data/generated/google/apis/firebasedynamiclinks_v1.rb +1 -1
  135. data/generated/google/apis/firebasedynamiclinks_v1/classes.rb +8 -1
  136. data/generated/google/apis/firebasedynamiclinks_v1/representations.rb +1 -0
  137. data/generated/google/apis/firebasehosting_v1beta1.rb +3 -2
  138. data/generated/google/apis/firebasehosting_v1beta1/classes.rb +43 -17
  139. data/generated/google/apis/firebasehosting_v1beta1/representations.rb +13 -0
  140. data/generated/google/apis/firebasehosting_v1beta1/service.rb +74 -1
  141. data/generated/google/apis/firestore_v1.rb +1 -1
  142. data/generated/google/apis/firestore_v1/classes.rb +2225 -520
  143. data/generated/google/apis/firestore_v1/representations.rb +800 -33
  144. data/generated/google/apis/firestore_v1/service.rb +526 -0
  145. data/generated/google/apis/fitness_v1.rb +1 -1
  146. data/generated/google/apis/fitness_v1/classes.rb +1 -2
  147. data/generated/google/apis/fitness_v1/service.rb +7 -3
  148. data/generated/google/apis/games_management_v1management.rb +1 -4
  149. data/generated/google/apis/games_v1.rb +1 -4
  150. data/generated/google/apis/genomics_v2alpha1.rb +1 -1
  151. data/generated/google/apis/genomics_v2alpha1/classes.rb +6 -1
  152. data/generated/google/apis/gmail_v1.rb +2 -2
  153. data/generated/google/apis/iap_v1.rb +34 -0
  154. data/generated/google/apis/iap_v1/classes.rb +308 -0
  155. data/generated/google/apis/iap_v1/representations.rb +126 -0
  156. data/generated/google/apis/iap_v1/service.rb +725 -0
  157. data/generated/google/apis/iap_v1beta1.rb +1 -1
  158. data/generated/google/apis/iap_v1beta1/classes.rb +0 -132
  159. data/generated/google/apis/iap_v1beta1/representations.rb +0 -32
  160. data/generated/google/apis/jobs_v2.rb +1 -1
  161. data/generated/google/apis/jobs_v2/classes.rb +8 -9
  162. data/generated/google/apis/jobs_v3.rb +1 -1
  163. data/generated/google/apis/jobs_v3/classes.rb +6 -6
  164. data/generated/google/apis/jobs_v3/service.rb +8 -8
  165. data/generated/google/apis/jobs_v3p1beta1.rb +1 -1
  166. data/generated/google/apis/jobs_v3p1beta1/classes.rb +9 -9
  167. data/generated/google/apis/jobs_v3p1beta1/service.rb +8 -8
  168. data/generated/google/apis/monitoring_v3.rb +1 -1
  169. data/generated/google/apis/monitoring_v3/classes.rb +20 -7
  170. data/generated/google/apis/monitoring_v3/representations.rb +1 -0
  171. data/generated/google/apis/monitoring_v3/service.rb +0 -365
  172. data/generated/google/apis/pagespeedonline_v5.rb +32 -0
  173. data/generated/google/apis/pagespeedonline_v5/classes.rb +724 -0
  174. data/generated/google/apis/pagespeedonline_v5/representations.rb +315 -0
  175. data/generated/google/apis/pagespeedonline_v5/service.rb +116 -0
  176. data/generated/google/apis/people_v1.rb +3 -3
  177. data/generated/google/apis/pubsub_v1.rb +1 -1
  178. data/generated/google/apis/pubsub_v1/classes.rb +63 -12
  179. data/generated/google/apis/pubsub_v1/representations.rb +15 -0
  180. data/generated/google/apis/pubsub_v1/service.rb +26 -18
  181. data/generated/google/apis/redis_v1.rb +2 -3
  182. data/generated/google/apis/redis_v1/service.rb +1 -2
  183. data/generated/google/apis/redis_v1beta1.rb +2 -3
  184. data/generated/google/apis/redis_v1beta1/service.rb +1 -2
  185. data/generated/google/apis/runtimeconfig_v1beta1.rb +1 -1
  186. data/generated/google/apis/runtimeconfig_v1beta1/classes.rb +2 -2
  187. data/generated/google/apis/script_v1.rb +24 -6
  188. data/generated/google/apis/serviceconsumermanagement_v1.rb +1 -1
  189. data/generated/google/apis/serviceconsumermanagement_v1/classes.rb +66 -1
  190. data/generated/google/apis/serviceconsumermanagement_v1/representations.rb +30 -0
  191. data/generated/google/apis/serviceconsumermanagement_v1/service.rb +89 -0
  192. data/generated/google/apis/servicecontrol_v1.rb +1 -1
  193. data/generated/google/apis/servicemanagement_v1.rb +1 -1
  194. data/generated/google/apis/servicemanagement_v1/classes.rb +7 -0
  195. data/generated/google/apis/servicemanagement_v1/representations.rb +1 -0
  196. data/generated/google/apis/servicenetworking_v1beta.rb +1 -1
  197. data/generated/google/apis/servicenetworking_v1beta/classes.rb +84 -37
  198. data/generated/google/apis/servicenetworking_v1beta/representations.rb +15 -0
  199. data/generated/google/apis/servicenetworking_v1beta/service.rb +132 -43
  200. data/generated/google/apis/serviceusage_v1.rb +1 -1
  201. data/generated/google/apis/serviceusage_v1/classes.rb +1 -1
  202. data/generated/google/apis/serviceusage_v1beta1.rb +1 -1
  203. data/generated/google/apis/serviceusage_v1beta1/classes.rb +1 -1
  204. data/generated/google/apis/sheets_v4.rb +4 -4
  205. data/generated/google/apis/slides_v1.rb +4 -4
  206. data/generated/google/apis/slides_v1/classes.rb +187 -2
  207. data/generated/google/apis/slides_v1/representations.rb +67 -0
  208. data/generated/google/apis/slides_v1/service.rb +4 -3
  209. data/generated/google/apis/sourcerepo_v1.rb +2 -2
  210. data/generated/google/apis/sourcerepo_v1/service.rb +1 -1
  211. data/generated/google/apis/speech_v1.rb +1 -1
  212. data/generated/google/apis/speech_v1/classes.rb +58 -10
  213. data/generated/google/apis/speech_v1/representations.rb +29 -1
  214. data/generated/google/apis/{speech_v1beta1.rb → speech_v1p1beta1.rb} +6 -6
  215. data/generated/google/apis/speech_v1p1beta1/classes.rb +922 -0
  216. data/generated/google/apis/speech_v1p1beta1/representations.rb +294 -0
  217. data/generated/google/apis/{speech_v1beta1 → speech_v1p1beta1}/service.rb +33 -35
  218. data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
  219. data/generated/google/apis/sqladmin_v1beta4/classes.rb +64 -3
  220. data/generated/google/apis/sqladmin_v1beta4/representations.rb +31 -0
  221. data/generated/google/apis/storage_v1.rb +1 -1
  222. data/generated/google/apis/storage_v1/classes.rb +54 -0
  223. data/generated/google/apis/storage_v1/representations.rb +31 -0
  224. data/generated/google/apis/streetviewpublish_v1.rb +1 -1
  225. data/generated/google/apis/streetviewpublish_v1/classes.rb +26 -0
  226. data/generated/google/apis/streetviewpublish_v1/representations.rb +4 -0
  227. data/generated/google/apis/streetviewpublish_v1/service.rb +29 -3
  228. data/generated/google/apis/tasks_v1.rb +1 -1
  229. data/generated/google/apis/testing_v1.rb +1 -1
  230. data/generated/google/apis/testing_v1/classes.rb +49 -19
  231. data/generated/google/apis/testing_v1/representations.rb +20 -2
  232. data/generated/google/apis/toolresults_v1beta3.rb +1 -1
  233. data/generated/google/apis/toolresults_v1beta3/classes.rb +77 -70
  234. data/generated/google/apis/vault_v1.rb +1 -1
  235. data/generated/google/apis/vault_v1/classes.rb +78 -7
  236. data/generated/google/apis/vault_v1/representations.rb +34 -1
  237. data/generated/google/apis/vault_v1/service.rb +141 -0
  238. data/generated/google/apis/vision_v1.rb +1 -1
  239. data/generated/google/apis/vision_v1/classes.rb +33 -0
  240. data/generated/google/apis/vision_v1/representations.rb +16 -0
  241. data/generated/google/apis/vision_v1/service.rb +2 -2
  242. data/generated/google/apis/vision_v1p1beta1.rb +1 -1
  243. data/generated/google/apis/vision_v1p1beta1/classes.rb +33 -0
  244. data/generated/google/apis/vision_v1p1beta1/representations.rb +16 -0
  245. data/generated/google/apis/vision_v1p2beta1.rb +1 -1
  246. data/generated/google/apis/vision_v1p2beta1/classes.rb +33 -0
  247. data/generated/google/apis/vision_v1p2beta1/representations.rb +16 -0
  248. data/generated/google/apis/youtube_partner_v1.rb +1 -1
  249. data/google-api-client.gemspec +1 -1
  250. data/lib/google/api_client/auth/installed_app.rb +17 -2
  251. data/lib/google/api_client/client_secrets.rb +1 -1
  252. data/lib/google/apis/core/download.rb +2 -2
  253. data/lib/google/apis/errors.rb +9 -0
  254. data/lib/google/apis/generator/annotator.rb +2 -2
  255. data/lib/google/apis/version.rb +1 -1
  256. metadata +46 -17
  257. data/generated/google/apis/cloudiot_v1beta1/classes.rb +0 -959
  258. data/generated/google/apis/cloudiot_v1beta1/representations.rb +0 -375
  259. data/generated/google/apis/cloudiot_v1beta1/service.rb +0 -618
  260. data/generated/google/apis/dfareporting_v3_0.rb +0 -40
  261. data/generated/google/apis/dfareporting_v3_0/classes.rb +0 -12119
  262. data/generated/google/apis/dfareporting_v3_0/representations.rb +0 -4336
  263. data/generated/google/apis/dfareporting_v3_0/service.rb +0 -8701
  264. data/generated/google/apis/speech_v1beta1/classes.rb +0 -480
  265. data/generated/google/apis/speech_v1beta1/representations.rb +0 -194
@@ -0,0 +1,89 @@
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 'google/apis/core/base_service'
16
+ require 'google/apis/core/json_representation'
17
+ require 'google/apis/core/hashable'
18
+ require 'google/apis/errors'
19
+
20
+ module Google
21
+ module Apis
22
+ module DriveactivityV2
23
+ # Drive Activity API
24
+ #
25
+ # Provides a historical view of activity in Google Drive.
26
+ #
27
+ # @example
28
+ # require 'google/apis/driveactivity_v2'
29
+ #
30
+ # Driveactivity = Google::Apis::DriveactivityV2 # Alias the module
31
+ # service = Driveactivity::DriveActivityService.new
32
+ #
33
+ # @see https://developers.google.com/drive/activity/
34
+ class DriveActivityService < Google::Apis::Core::BaseService
35
+ # @return [String]
36
+ # API key. Your API key identifies your project and provides you with API access,
37
+ # quota, and reports. Required unless you provide an OAuth 2.0 token.
38
+ attr_accessor :key
39
+
40
+ # @return [String]
41
+ # Available to use for quota purposes for server-side applications. Can be any
42
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
43
+ attr_accessor :quota_user
44
+
45
+ def initialize
46
+ super('https://driveactivity.googleapis.com/', '')
47
+ @batch_path = 'batch'
48
+ end
49
+
50
+ # Query past activity in Google Drive.
51
+ # @param [Google::Apis::DriveactivityV2::QueryDriveActivityRequest] query_drive_activity_request_object
52
+ # @param [String] fields
53
+ # Selector specifying which fields to include in a partial response.
54
+ # @param [String] quota_user
55
+ # Available to use for quota purposes for server-side applications. Can be any
56
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
57
+ # @param [Google::Apis::RequestOptions] options
58
+ # Request-specific options
59
+ #
60
+ # @yield [result, err] Result & error if block supplied
61
+ # @yieldparam result [Google::Apis::DriveactivityV2::QueryDriveActivityResponse] parsed result object
62
+ # @yieldparam err [StandardError] error object if request failed
63
+ #
64
+ # @return [Google::Apis::DriveactivityV2::QueryDriveActivityResponse]
65
+ #
66
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
67
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
68
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
69
+ def query_drive_activity(query_drive_activity_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
70
+ command = make_simple_command(:post, 'v2/activity:query', options)
71
+ command.request_representation = Google::Apis::DriveactivityV2::QueryDriveActivityRequest::Representation
72
+ command.request_object = query_drive_activity_request_object
73
+ command.response_representation = Google::Apis::DriveactivityV2::QueryDriveActivityResponse::Representation
74
+ command.response_class = Google::Apis::DriveactivityV2::QueryDriveActivityResponse
75
+ command.query['fields'] = fields unless fields.nil?
76
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
77
+ execute_or_queue_command(command, &block)
78
+ end
79
+
80
+ protected
81
+
82
+ def apply_command_defaults(command)
83
+ command.query['key'] = key unless key.nil?
84
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
85
+ end
86
+ end
87
+ end
88
+ end
89
+ end
@@ -25,7 +25,7 @@ module Google
25
25
  # @see https://firebase.google.com/docs/dynamic-links/
26
26
  module FirebasedynamiclinksV1
27
27
  VERSION = 'V1'
28
- REVISION = '20181002'
28
+ REVISION = '20181121'
29
29
 
30
30
  # View and administer all your Firebase data and settings
31
31
  AUTH_FIREBASE = 'https://www.googleapis.com/auth/firebase'
@@ -371,6 +371,7 @@ module Google
371
371
  # E.g. https://maps.app.goo.gl, https://maps.page.link, https://g.co/maps
372
372
  # More examples can be found in description of getNormalizedUriPrefix in
373
373
  # j/c/g/firebase/dynamiclinks/uri/DdlDomain.java
374
+ # Will fallback to dynamic_link_domain is this field is missing
374
375
  # Corresponds to the JSON property `domainUriPrefix`
375
376
  # @return [String]
376
377
  attr_accessor :domain_uri_prefix
@@ -378,7 +379,7 @@ module Google
378
379
  # Dynamic Links domain that the project owns, e.g. abcd.app.goo.gl
379
380
  # [Learn more](https://firebase.google.com/docs/dynamic-links/android/receive)
380
381
  # on how to set up Dynamic Link domain associated with your Firebase project.
381
- # Required.
382
+ # Required if missing domain_uri_prefix.
382
383
  # Corresponds to the JSON property `dynamicLinkDomain`
383
384
  # @return [String]
384
385
  attr_accessor :dynamic_link_domain
@@ -887,6 +888,11 @@ module Google
887
888
  # @return [String]
888
889
  attr_accessor :ios_ipad_fallback_link
889
890
 
891
+ # iOS minimum version.
892
+ # Corresponds to the JSON property `iosMinimumVersion`
893
+ # @return [String]
894
+ attr_accessor :ios_minimum_version
895
+
890
896
  def initialize(**args)
891
897
  update!(**args)
892
898
  end
@@ -899,6 +905,7 @@ module Google
899
905
  @ios_fallback_link = args[:ios_fallback_link] if args.key?(:ios_fallback_link)
900
906
  @ios_ipad_bundle_id = args[:ios_ipad_bundle_id] if args.key?(:ios_ipad_bundle_id)
901
907
  @ios_ipad_fallback_link = args[:ios_ipad_fallback_link] if args.key?(:ios_ipad_fallback_link)
908
+ @ios_minimum_version = args[:ios_minimum_version] if args.key?(:ios_minimum_version)
902
909
  end
903
910
  end
904
911
 
@@ -380,6 +380,7 @@ module Google
380
380
  property :ios_fallback_link, as: 'iosFallbackLink'
381
381
  property :ios_ipad_bundle_id, as: 'iosIpadBundleId'
382
382
  property :ios_ipad_fallback_link, as: 'iosIpadFallbackLink'
383
+ property :ios_minimum_version, as: 'iosMinimumVersion'
383
384
  end
384
385
  end
385
386
 
@@ -20,12 +20,13 @@ module Google
20
20
  module Apis
21
21
  # Firebase Hosting API
22
22
  #
23
- #
23
+ # The Firebase Hosting REST API enables programmatic custom deployment for
24
+ # releasing versions of your Firebase hosted content and configuration files.
24
25
  #
25
26
  # @see https://firebase.google.com/docs/hosting/
26
27
  module FirebasehostingV1beta1
27
28
  VERSION = 'V1beta1'
28
- REVISION = '20181004'
29
+ REVISION = '20181129'
29
30
 
30
31
  # View and manage your data across Google Cloud Platform services
31
32
  AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
@@ -262,14 +262,14 @@ module Google
262
262
  end
263
263
  end
264
264
 
265
- # A `Header` defines custom headers to add to a response should the request
266
- # URL path match the pattern.
265
+ # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
266
+ # add to a response should the request URL path match the pattern.
267
267
  class Header
268
268
  include Google::Apis::Core::Hashable
269
269
 
270
270
  # Required. The user-supplied
271
- # [glob pattern](/docs/hosting/full-config#section-glob) to match against
272
- # the request URL path.
271
+ # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
272
+ # against the request URL path.
273
273
  # Corresponds to the JSON property `glob`
274
274
  # @return [String]
275
275
  attr_accessor :glob
@@ -420,21 +420,22 @@ module Google
420
420
  end
421
421
  end
422
422
 
423
- # A `Redirect` represents the configuration for returning an HTTP redirect
424
- # response given a matching request URL path.
423
+ # A [`redirect`](/docs/hosting/full-config#redirects) represents the
424
+ # configuration for returning an HTTP redirect response given a matching
425
+ # request URL path.
425
426
  class Redirect
426
427
  include Google::Apis::Core::Hashable
427
428
 
428
429
  # Required. The user-supplied
429
- # [glob pattern](/docs/hosting/full-config#section-glob) to match against
430
- # the request URL path.
430
+ # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
431
+ # against the request URL path.
431
432
  # Corresponds to the JSON property `glob`
432
433
  # @return [String]
433
434
  attr_accessor :glob
434
435
 
435
436
  # Required. The value to put in the HTTP location header of the response.
436
- # <br>The location can contain capture group values from the pattern using a
437
- # `":"` prefix to identify the segment and an optional `"*"` to capture the
437
+ # <br>The location can contain capture group values from the pattern using
438
+ # a `:` prefix to identify the segment and an optional `*` to capture the
438
439
  # rest of the URL.
439
440
  # For example:
440
441
  # <code>"glob": "/:capture*",
@@ -521,9 +522,10 @@ module Google
521
522
  end
522
523
  end
523
524
 
524
- # A `Rewrite` represents an internal content rewrite on the version. If the
525
- # pattern matches, the request will be handled as if it were to the
526
- # destination path specified in the configuration.
525
+ # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
526
+ # content rewrite on the version. If the pattern matches, the request will be
527
+ # handled as if it were to the destination path specified in the
528
+ # configuration.
527
529
  class Rewrite
528
530
  include Google::Apis::Core::Hashable
529
531
 
@@ -540,8 +542,8 @@ module Google
540
542
  attr_accessor :function
541
543
 
542
544
  # Required. The user-supplied
543
- # [glob pattern](/docs/hosting/full-config#section-glob) to match against
544
- # the request URL path.
545
+ # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
546
+ # against the request URL path.
545
547
  # Corresponds to the JSON property `glob`
546
548
  # @return [String]
547
549
  attr_accessor :glob
@@ -567,7 +569,7 @@ module Google
567
569
  # The configuration for how incoming requests to a site should be routed and
568
570
  # processed before serving content. The patterns are matched and applied
569
571
  # according to a specific
570
- # [priority order](/docs/hosting/url-redirects-rewrites#section-priorities).
572
+ # [priority order](/docs/hosting/full-config#hosting_priority_order).
571
573
  class ServingConfig
572
574
  include Google::Apis::Core::Hashable
573
575
 
@@ -620,6 +622,30 @@ module Google
620
622
  end
621
623
  end
622
624
 
625
+ # A `SiteConfig` contains metadata associated with a specific site that
626
+ # controls Firebase Hosting serving behavior
627
+ class SiteConfig
628
+ include Google::Apis::Core::Hashable
629
+
630
+ # The number of FINALIZED versions that will be held for a site before
631
+ # automatic deletion. When a new version is deployed, content for versions
632
+ # in storage in excess of this number will be deleted, and will no longer be
633
+ # billed for storage usage. Oldest versions will be deleted first; sites are
634
+ # created with an unlimited number of max_versions by default.
635
+ # Corresponds to the JSON property `maxVersions`
636
+ # @return [Fixnum]
637
+ attr_accessor :max_versions
638
+
639
+ def initialize(**args)
640
+ update!(**args)
641
+ end
642
+
643
+ # Update properties of this object
644
+ def update!(**args)
645
+ @max_versions = args[:max_versions] if args.key?(:max_versions)
646
+ end
647
+ end
648
+
623
649
  # A `Version` is the collection of configuration and
624
650
  # [static files](sites.versions.files) that determine how a site is displayed.
625
651
  class Version
@@ -628,7 +654,7 @@ module Google
628
654
  # The configuration for how incoming requests to a site should be routed and
629
655
  # processed before serving content. The patterns are matched and applied
630
656
  # according to a specific
631
- # [priority order](/docs/hosting/url-redirects-rewrites#section-priorities).
657
+ # [priority order](/docs/hosting/full-config#hosting_priority_order).
632
658
  # Corresponds to the JSON property `config`
633
659
  # @return [Google::Apis::FirebasehostingV1beta1::ServingConfig]
634
660
  attr_accessor :config
@@ -124,6 +124,12 @@ module Google
124
124
  include Google::Apis::Core::JsonObjectSupport
125
125
  end
126
126
 
127
+ class SiteConfig
128
+ class Representation < Google::Apis::Core::JsonRepresentation; end
129
+
130
+ include Google::Apis::Core::JsonObjectSupport
131
+ end
132
+
127
133
  class Version
128
134
  class Representation < Google::Apis::Core::JsonRepresentation; end
129
135
 
@@ -302,6 +308,13 @@ module Google
302
308
  end
303
309
  end
304
310
 
311
+ class SiteConfig
312
+ # @private
313
+ class Representation < Google::Apis::Core::JsonRepresentation
314
+ property :max_versions, :numeric_string => true, as: 'maxVersions'
315
+ end
316
+ end
317
+
305
318
  class Version
306
319
  # @private
307
320
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -22,7 +22,8 @@ module Google
22
22
  module FirebasehostingV1beta1
23
23
  # Firebase Hosting API
24
24
  #
25
- #
25
+ # The Firebase Hosting REST API enables programmatic custom deployment for
26
+ # releasing versions of your Firebase hosted content and configuration files.
26
27
  #
27
28
  # @example
28
29
  # require 'google/apis/firebasehosting_v1beta1'
@@ -47,6 +48,78 @@ module Google
47
48
  @batch_path = 'batch'
48
49
  end
49
50
 
51
+ # Gets the Hosting metadata for a specific site.
52
+ # @param [String] name
53
+ # Required. The site for which to get the SiteConfig, in the format:
54
+ # <code>sites/<var>site-name</var>/config</code>
55
+ # @param [String] fields
56
+ # Selector specifying which fields to include in a partial response.
57
+ # @param [String] quota_user
58
+ # Available to use for quota purposes for server-side applications. Can be any
59
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
60
+ # @param [Google::Apis::RequestOptions] options
61
+ # Request-specific options
62
+ #
63
+ # @yield [result, err] Result & error if block supplied
64
+ # @yieldparam result [Google::Apis::FirebasehostingV1beta1::SiteConfig] parsed result object
65
+ # @yieldparam err [StandardError] error object if request failed
66
+ #
67
+ # @return [Google::Apis::FirebasehostingV1beta1::SiteConfig]
68
+ #
69
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
70
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
71
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
72
+ def get_site_config(name, fields: nil, quota_user: nil, options: nil, &block)
73
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
74
+ command.response_representation = Google::Apis::FirebasehostingV1beta1::SiteConfig::Representation
75
+ command.response_class = Google::Apis::FirebasehostingV1beta1::SiteConfig
76
+ command.params['name'] = name unless name.nil?
77
+ command.query['fields'] = fields unless fields.nil?
78
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
79
+ execute_or_queue_command(command, &block)
80
+ end
81
+
82
+ # Sets the Hosting metadata for a specific site.
83
+ # @param [String] name
84
+ # Required. The site for which to update the SiteConfig, in the format:
85
+ # <code>sites/<var>site-name</var>/config</code>
86
+ # @param [Google::Apis::FirebasehostingV1beta1::SiteConfig] site_config_object
87
+ # @param [String] update_mask
88
+ # A set of field names from your [site configuration](../sites.SiteConfig)
89
+ # that you want to update.
90
+ # <br>A field will be overwritten if, and only if, it's in the mask.
91
+ # <br>If a mask is not provided then a default mask of only
92
+ # [`max_versions`](../sites.SiteConfig.max_versions) will be used.
93
+ # @param [String] fields
94
+ # Selector specifying which fields to include in a partial response.
95
+ # @param [String] quota_user
96
+ # Available to use for quota purposes for server-side applications. Can be any
97
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
98
+ # @param [Google::Apis::RequestOptions] options
99
+ # Request-specific options
100
+ #
101
+ # @yield [result, err] Result & error if block supplied
102
+ # @yieldparam result [Google::Apis::FirebasehostingV1beta1::SiteConfig] parsed result object
103
+ # @yieldparam err [StandardError] error object if request failed
104
+ #
105
+ # @return [Google::Apis::FirebasehostingV1beta1::SiteConfig]
106
+ #
107
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
108
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
109
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
110
+ def update_site_config(name, site_config_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
111
+ command = make_simple_command(:patch, 'v1beta1/{+name}', options)
112
+ command.request_representation = Google::Apis::FirebasehostingV1beta1::SiteConfig::Representation
113
+ command.request_object = site_config_object
114
+ command.response_representation = Google::Apis::FirebasehostingV1beta1::SiteConfig::Representation
115
+ command.response_class = Google::Apis::FirebasehostingV1beta1::SiteConfig
116
+ command.params['name'] = name unless name.nil?
117
+ command.query['updateMask'] = update_mask unless update_mask.nil?
118
+ command.query['fields'] = fields unless fields.nil?
119
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
120
+ execute_or_queue_command(command, &block)
121
+ end
122
+
50
123
  # Creates a domain mapping on the specified site.
51
124
  # @param [String] parent
52
125
  # Required. The parent to create the domain association for, in the format:
@@ -26,7 +26,7 @@ module Google
26
26
  # @see https://cloud.google.com/firestore
27
27
  module FirestoreV1
28
28
  VERSION = 'V1'
29
- REVISION = '20181020'
29
+ REVISION = '20181121'
30
30
 
31
31
  # View and manage your data across Google Cloud Platform services
32
32
  AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
@@ -22,69 +22,108 @@ module Google
22
22
  module Apis
23
23
  module FirestoreV1
24
24
 
25
- # A generic empty message that you can re-use to avoid defining duplicated
26
- # empty messages in your APIs. A typical example is to use it as the request
27
- # or the response type of an API method. For instance:
28
- # service Foo `
29
- # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
30
- # `
31
- # The JSON representation for `Empty` is empty JSON object ````.
32
- class Empty
25
+ # An array value.
26
+ class ArrayValue
33
27
  include Google::Apis::Core::Hashable
34
28
 
29
+ # Values in the array.
30
+ # Corresponds to the JSON property `values`
31
+ # @return [Array<Google::Apis::FirestoreV1::Value>]
32
+ attr_accessor :values
33
+
35
34
  def initialize(**args)
36
35
  update!(**args)
37
36
  end
38
37
 
39
38
  # Update properties of this object
40
39
  def update!(**args)
40
+ @values = args[:values] if args.key?(:values)
41
41
  end
42
42
  end
43
43
 
44
- # Metadata for google.longrunning.Operation results from
45
- # FirestoreAdmin.ExportDocuments.
46
- class GoogleFirestoreAdminV1ExportDocumentsMetadata
44
+ # The request for Firestore.BatchGetDocuments.
45
+ class BatchGetDocumentsRequest
47
46
  include Google::Apis::Core::Hashable
48
47
 
49
- # Which collection ids are being exported.
50
- # Corresponds to the JSON property `collectionIds`
48
+ # The names of the documents to retrieve. In the format:
49
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
50
+ # The request will fail if any of the document is not a child resource of the
51
+ # given `database`. Duplicate names will be elided.
52
+ # Corresponds to the JSON property `documents`
51
53
  # @return [Array<String>]
52
- attr_accessor :collection_ids
53
-
54
- # The time this operation completed. Will be unset if operation still in
55
- # progress.
56
- # Corresponds to the JSON property `endTime`
54
+ attr_accessor :documents
55
+
56
+ # A set of field paths on a document.
57
+ # Used to restrict a get or update operation on a document to a subset of its
58
+ # fields.
59
+ # This is different from standard field masks, as this is always scoped to a
60
+ # Document, and takes in account the dynamic nature of Value.
61
+ # Corresponds to the JSON property `mask`
62
+ # @return [Google::Apis::FirestoreV1::DocumentMask]
63
+ attr_accessor :mask
64
+
65
+ # Options for creating a new transaction.
66
+ # Corresponds to the JSON property `newTransaction`
67
+ # @return [Google::Apis::FirestoreV1::TransactionOptions]
68
+ attr_accessor :new_transaction
69
+
70
+ # Reads documents as they were at the given time.
71
+ # This may not be older than 60 seconds.
72
+ # Corresponds to the JSON property `readTime`
57
73
  # @return [String]
58
- attr_accessor :end_time
74
+ attr_accessor :read_time
59
75
 
60
- # The state of the export operation.
61
- # Corresponds to the JSON property `operationState`
76
+ # Reads documents in a transaction.
77
+ # Corresponds to the JSON property `transaction`
78
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
62
79
  # @return [String]
63
- attr_accessor :operation_state
80
+ attr_accessor :transaction
64
81
 
65
- # Where the entities are being exported to.
66
- # Corresponds to the JSON property `outputUriPrefix`
67
- # @return [String]
68
- attr_accessor :output_uri_prefix
82
+ def initialize(**args)
83
+ update!(**args)
84
+ end
69
85
 
70
- # Describes the progress of the operation.
71
- # Unit of work is generic and must be interpreted based on where Progress
72
- # is used.
73
- # Corresponds to the JSON property `progressBytes`
74
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
75
- attr_accessor :progress_bytes
86
+ # Update properties of this object
87
+ def update!(**args)
88
+ @documents = args[:documents] if args.key?(:documents)
89
+ @mask = args[:mask] if args.key?(:mask)
90
+ @new_transaction = args[:new_transaction] if args.key?(:new_transaction)
91
+ @read_time = args[:read_time] if args.key?(:read_time)
92
+ @transaction = args[:transaction] if args.key?(:transaction)
93
+ end
94
+ end
76
95
 
77
- # Describes the progress of the operation.
78
- # Unit of work is generic and must be interpreted based on where Progress
79
- # is used.
80
- # Corresponds to the JSON property `progressDocuments`
81
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
82
- attr_accessor :progress_documents
96
+ # The streamed response for Firestore.BatchGetDocuments.
97
+ class BatchGetDocumentsResponse
98
+ include Google::Apis::Core::Hashable
83
99
 
84
- # The time this operation started.
85
- # Corresponds to the JSON property `startTime`
100
+ # A Firestore document.
101
+ # Must not exceed 1 MiB - 4 bytes.
102
+ # Corresponds to the JSON property `found`
103
+ # @return [Google::Apis::FirestoreV1::Document]
104
+ attr_accessor :found
105
+
106
+ # A document name that was requested but does not exist. In the format:
107
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
108
+ # Corresponds to the JSON property `missing`
86
109
  # @return [String]
87
- attr_accessor :start_time
110
+ attr_accessor :missing
111
+
112
+ # The time at which the document was read.
113
+ # This may be monotically increasing, in this case the previous documents in
114
+ # the result stream are guaranteed not to have changed between their
115
+ # read_time and this one.
116
+ # Corresponds to the JSON property `readTime`
117
+ # @return [String]
118
+ attr_accessor :read_time
119
+
120
+ # The transaction that was started as part of this request.
121
+ # Will only be set in the first response, and only if
122
+ # BatchGetDocumentsRequest.new_transaction was set in the request.
123
+ # Corresponds to the JSON property `transaction`
124
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
125
+ # @return [String]
126
+ attr_accessor :transaction
88
127
 
89
128
  def initialize(**args)
90
129
  update!(**args)
@@ -92,36 +131,21 @@ module Google
92
131
 
93
132
  # Update properties of this object
94
133
  def update!(**args)
95
- @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
96
- @end_time = args[:end_time] if args.key?(:end_time)
97
- @operation_state = args[:operation_state] if args.key?(:operation_state)
98
- @output_uri_prefix = args[:output_uri_prefix] if args.key?(:output_uri_prefix)
99
- @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
100
- @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
101
- @start_time = args[:start_time] if args.key?(:start_time)
134
+ @found = args[:found] if args.key?(:found)
135
+ @missing = args[:missing] if args.key?(:missing)
136
+ @read_time = args[:read_time] if args.key?(:read_time)
137
+ @transaction = args[:transaction] if args.key?(:transaction)
102
138
  end
103
139
  end
104
140
 
105
- # The request for FirestoreAdmin.ExportDocuments.
106
- class GoogleFirestoreAdminV1ExportDocumentsRequest
141
+ # The request for Firestore.BeginTransaction.
142
+ class BeginTransactionRequest
107
143
  include Google::Apis::Core::Hashable
108
144
 
109
- # Which collection ids to export. Unspecified means all collections.
110
- # Corresponds to the JSON property `collectionIds`
111
- # @return [Array<String>]
112
- attr_accessor :collection_ids
113
-
114
- # The output URI. Currently only supports Google Cloud Storage URIs of the
115
- # form: `gs://BUCKET_NAME[/NAMESPACE_PATH]`, where `BUCKET_NAME` is the name
116
- # of the Google Cloud Storage bucket and `NAMESPACE_PATH` is an optional
117
- # Google Cloud Storage namespace path. When
118
- # choosing a name, be sure to consider Google Cloud Storage naming
119
- # guidelines: https://cloud.google.com/storage/docs/naming.
120
- # If the URI is a bucket (without a namespace path), a prefix will be
121
- # generated based on the start time.
122
- # Corresponds to the JSON property `outputUriPrefix`
123
- # @return [String]
124
- attr_accessor :output_uri_prefix
145
+ # Options for creating a new transaction.
146
+ # Corresponds to the JSON property `options`
147
+ # @return [Google::Apis::FirestoreV1::TransactionOptions]
148
+ attr_accessor :options
125
149
 
126
150
  def initialize(**args)
127
151
  update!(**args)
@@ -129,21 +153,19 @@ module Google
129
153
 
130
154
  # Update properties of this object
131
155
  def update!(**args)
132
- @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
133
- @output_uri_prefix = args[:output_uri_prefix] if args.key?(:output_uri_prefix)
156
+ @options = args[:options] if args.key?(:options)
134
157
  end
135
158
  end
136
159
 
137
- # Returned in the google.longrunning.Operation response field.
138
- class GoogleFirestoreAdminV1ExportDocumentsResponse
160
+ # The response for Firestore.BeginTransaction.
161
+ class BeginTransactionResponse
139
162
  include Google::Apis::Core::Hashable
140
163
 
141
- # Location of the output files. This can be used to begin an import
142
- # into Cloud Firestore (this project or another project) after the operation
143
- # completes successfully.
144
- # Corresponds to the JSON property `outputUriPrefix`
164
+ # The transaction that was started.
165
+ # Corresponds to the JSON property `transaction`
166
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
145
167
  # @return [String]
146
- attr_accessor :output_uri_prefix
168
+ attr_accessor :transaction
147
169
 
148
170
  def initialize(**args)
149
171
  update!(**args)
@@ -151,48 +173,27 @@ module Google
151
173
 
152
174
  # Update properties of this object
153
175
  def update!(**args)
154
- @output_uri_prefix = args[:output_uri_prefix] if args.key?(:output_uri_prefix)
176
+ @transaction = args[:transaction] if args.key?(:transaction)
155
177
  end
156
178
  end
157
179
 
158
- # Represents a single field in the database.
159
- # Fields are grouped by their "Collection Group", which represent all
160
- # collections in the database with the same id.
161
- class GoogleFirestoreAdminV1Field
180
+ # A selection of a collection, such as `messages as m1`.
181
+ class CollectionSelector
162
182
  include Google::Apis::Core::Hashable
163
183
 
164
- # The index configuration for this field.
165
- # Corresponds to the JSON property `indexConfig`
166
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1IndexConfig]
167
- attr_accessor :index_config
184
+ # When false, selects only collections that are immediate children of
185
+ # the `parent` specified in the containing `RunQueryRequest`.
186
+ # When true, selects all descendant collections.
187
+ # Corresponds to the JSON property `allDescendants`
188
+ # @return [Boolean]
189
+ attr_accessor :all_descendants
190
+ alias_method :all_descendants?, :all_descendants
168
191
 
169
- # A field name of the form
170
- # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
171
- # /fields/`field_path``
172
- # A field path may be a simple field name, e.g. `address` or a path to fields
173
- # within map_value , e.g. `address.city`,
174
- # or a special field path. The only valid special field is `*`, which
175
- # represents any field.
176
- # Field paths may be quoted using ` (backtick). The only character that needs
177
- # to be escaped within a quoted field path is the backtick character itself,
178
- # escaped using a backslash. Special characters in field paths that
179
- # must be quoted include: `*`, `.`,
180
- # ``` (backtick), `[`, `]`, as well as any ascii symbolic characters.
181
- # Examples:
182
- # (Note: Comments here are written in markdown syntax, so there is an
183
- # additional layer of backticks to represent a code block)
184
- # `\`address.city\`` represents a field named `address.city`, not the map key
185
- # `city` in the field `address`.
186
- # `\`*\`` represents a field named `*`, not any field.
187
- # A special `Field` contains the default indexing settings for all fields.
188
- # This field's resource name is:
189
- # `projects/`project_id`/databases/`database_id`/collectionGroups/__default__/
190
- # fields/*`
191
- # Indexes defined on this `Field` will be applied to all fields which do not
192
- # have their own `Field` index configuration.
193
- # Corresponds to the JSON property `name`
192
+ # The collection ID.
193
+ # When set, selects only collections with this ID.
194
+ # Corresponds to the JSON property `collectionId`
194
195
  # @return [String]
195
- attr_accessor :name
196
+ attr_accessor :collection_id
196
197
 
197
198
  def initialize(**args)
198
199
  update!(**args)
@@ -200,58 +201,53 @@ module Google
200
201
 
201
202
  # Update properties of this object
202
203
  def update!(**args)
203
- @index_config = args[:index_config] if args.key?(:index_config)
204
- @name = args[:name] if args.key?(:name)
204
+ @all_descendants = args[:all_descendants] if args.key?(:all_descendants)
205
+ @collection_id = args[:collection_id] if args.key?(:collection_id)
205
206
  end
206
207
  end
207
208
 
208
- # Metadata for google.longrunning.Operation results from
209
- # FirestoreAdmin.UpdateField.
210
- class GoogleFirestoreAdminV1FieldOperationMetadata
209
+ # The request for Firestore.Commit.
210
+ class CommitRequest
211
211
  include Google::Apis::Core::Hashable
212
212
 
213
- # The time this operation completed. Will be unset if operation still in
214
- # progress.
215
- # Corresponds to the JSON property `endTime`
213
+ # If set, applies all writes in this transaction, and commits it.
214
+ # Corresponds to the JSON property `transaction`
215
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
216
216
  # @return [String]
217
- attr_accessor :end_time
217
+ attr_accessor :transaction
218
218
 
219
- # The field resource that this operation is acting on. For example:
220
- # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
221
- # /fields/`field_path``
222
- # Corresponds to the JSON property `field`
223
- # @return [String]
224
- attr_accessor :field
219
+ # The writes to apply.
220
+ # Always executed atomically and in order.
221
+ # Corresponds to the JSON property `writes`
222
+ # @return [Array<Google::Apis::FirestoreV1::Write>]
223
+ attr_accessor :writes
225
224
 
226
- # A list of IndexConfigDelta, which describe the intent of this
227
- # operation.
228
- # Corresponds to the JSON property `indexConfigDeltas`
229
- # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1IndexConfigDelta>]
230
- attr_accessor :index_config_deltas
225
+ def initialize(**args)
226
+ update!(**args)
227
+ end
231
228
 
232
- # Describes the progress of the operation.
233
- # Unit of work is generic and must be interpreted based on where Progress
234
- # is used.
235
- # Corresponds to the JSON property `progressBytes`
236
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
237
- attr_accessor :progress_bytes
229
+ # Update properties of this object
230
+ def update!(**args)
231
+ @transaction = args[:transaction] if args.key?(:transaction)
232
+ @writes = args[:writes] if args.key?(:writes)
233
+ end
234
+ end
238
235
 
239
- # Describes the progress of the operation.
240
- # Unit of work is generic and must be interpreted based on where Progress
241
- # is used.
242
- # Corresponds to the JSON property `progressDocuments`
243
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
244
- attr_accessor :progress_documents
236
+ # The response for Firestore.Commit.
237
+ class CommitResponse
238
+ include Google::Apis::Core::Hashable
245
239
 
246
- # The time this operation started.
247
- # Corresponds to the JSON property `startTime`
240
+ # The time at which the commit occurred.
241
+ # Corresponds to the JSON property `commitTime`
248
242
  # @return [String]
249
- attr_accessor :start_time
243
+ attr_accessor :commit_time
250
244
 
251
- # The state of the operation.
252
- # Corresponds to the JSON property `state`
253
- # @return [String]
254
- attr_accessor :state
245
+ # The result of applying the writes.
246
+ # This i-th write result corresponds to the i-th write in the
247
+ # request.
248
+ # Corresponds to the JSON property `writeResults`
249
+ # @return [Array<Google::Apis::FirestoreV1::WriteResult>]
250
+ attr_accessor :write_results
255
251
 
256
252
  def initialize(**args)
257
253
  update!(**args)
@@ -259,60 +255,54 @@ module Google
259
255
 
260
256
  # Update properties of this object
261
257
  def update!(**args)
262
- @end_time = args[:end_time] if args.key?(:end_time)
263
- @field = args[:field] if args.key?(:field)
264
- @index_config_deltas = args[:index_config_deltas] if args.key?(:index_config_deltas)
265
- @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
266
- @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
267
- @start_time = args[:start_time] if args.key?(:start_time)
268
- @state = args[:state] if args.key?(:state)
258
+ @commit_time = args[:commit_time] if args.key?(:commit_time)
259
+ @write_results = args[:write_results] if args.key?(:write_results)
269
260
  end
270
261
  end
271
262
 
272
- # Metadata for google.longrunning.Operation results from
273
- # FirestoreAdmin.ImportDocuments.
274
- class GoogleFirestoreAdminV1ImportDocumentsMetadata
263
+ # A filter that merges multiple other filters using the given operator.
264
+ class CompositeFilter
275
265
  include Google::Apis::Core::Hashable
276
266
 
277
- # Which collection ids are being imported.
278
- # Corresponds to the JSON property `collectionIds`
279
- # @return [Array<String>]
280
- attr_accessor :collection_ids
267
+ # The list of filters to combine.
268
+ # Must contain at least one filter.
269
+ # Corresponds to the JSON property `filters`
270
+ # @return [Array<Google::Apis::FirestoreV1::Filter>]
271
+ attr_accessor :filters
281
272
 
282
- # The time this operation completed. Will be unset if operation still in
283
- # progress.
284
- # Corresponds to the JSON property `endTime`
273
+ # The operator for combining multiple filters.
274
+ # Corresponds to the JSON property `op`
285
275
  # @return [String]
286
- attr_accessor :end_time
276
+ attr_accessor :op
287
277
 
288
- # The location of the documents being imported.
289
- # Corresponds to the JSON property `inputUriPrefix`
290
- # @return [String]
291
- attr_accessor :input_uri_prefix
278
+ def initialize(**args)
279
+ update!(**args)
280
+ end
292
281
 
293
- # The state of the import operation.
294
- # Corresponds to the JSON property `operationState`
295
- # @return [String]
296
- attr_accessor :operation_state
282
+ # Update properties of this object
283
+ def update!(**args)
284
+ @filters = args[:filters] if args.key?(:filters)
285
+ @op = args[:op] if args.key?(:op)
286
+ end
287
+ end
297
288
 
298
- # Describes the progress of the operation.
299
- # Unit of work is generic and must be interpreted based on where Progress
300
- # is used.
301
- # Corresponds to the JSON property `progressBytes`
302
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
303
- attr_accessor :progress_bytes
289
+ # A position in a query result set.
290
+ class Cursor
291
+ include Google::Apis::Core::Hashable
304
292
 
305
- # Describes the progress of the operation.
306
- # Unit of work is generic and must be interpreted based on where Progress
307
- # is used.
308
- # Corresponds to the JSON property `progressDocuments`
309
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
310
- attr_accessor :progress_documents
293
+ # If the position is just before or just after the given values, relative
294
+ # to the sort order defined by the query.
295
+ # Corresponds to the JSON property `before`
296
+ # @return [Boolean]
297
+ attr_accessor :before
298
+ alias_method :before?, :before
311
299
 
312
- # The time this operation started.
313
- # Corresponds to the JSON property `startTime`
314
- # @return [String]
315
- attr_accessor :start_time
300
+ # The values that represent a position, in the order they appear in
301
+ # the order by clause of a query.
302
+ # Can contain fewer values than specified in the order by clause.
303
+ # Corresponds to the JSON property `values`
304
+ # @return [Array<Google::Apis::FirestoreV1::Value>]
305
+ attr_accessor :values
316
306
 
317
307
  def initialize(**args)
318
308
  update!(**args)
@@ -320,34 +310,60 @@ module Google
320
310
 
321
311
  # Update properties of this object
322
312
  def update!(**args)
323
- @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
324
- @end_time = args[:end_time] if args.key?(:end_time)
325
- @input_uri_prefix = args[:input_uri_prefix] if args.key?(:input_uri_prefix)
326
- @operation_state = args[:operation_state] if args.key?(:operation_state)
327
- @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
328
- @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
329
- @start_time = args[:start_time] if args.key?(:start_time)
313
+ @before = args[:before] if args.key?(:before)
314
+ @values = args[:values] if args.key?(:values)
330
315
  end
331
316
  end
332
317
 
333
- # The request for FirestoreAdmin.ImportDocuments.
334
- class GoogleFirestoreAdminV1ImportDocumentsRequest
318
+ # A Firestore document.
319
+ # Must not exceed 1 MiB - 4 bytes.
320
+ class Document
335
321
  include Google::Apis::Core::Hashable
336
322
 
337
- # Which collection ids to import. Unspecified means all collections included
338
- # in the import.
339
- # Corresponds to the JSON property `collectionIds`
340
- # @return [Array<String>]
341
- attr_accessor :collection_ids
323
+ # Output only. The time at which the document was created.
324
+ # This value increases monotonically when a document is deleted then
325
+ # recreated. It can also be compared to values from other documents and
326
+ # the `read_time` of a query.
327
+ # Corresponds to the JSON property `createTime`
328
+ # @return [String]
329
+ attr_accessor :create_time
330
+
331
+ # The document's fields.
332
+ # The map keys represent field names.
333
+ # A simple field name contains only characters `a` to `z`, `A` to `Z`,
334
+ # `0` to `9`, or `_`, and must not start with `0` to `9`. For example,
335
+ # `foo_bar_17`.
336
+ # Field names matching the regular expression `__.*__` are reserved. Reserved
337
+ # field names are forbidden except in certain documented contexts. The map
338
+ # keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be
339
+ # empty.
340
+ # Field paths may be used in other contexts to refer to structured fields
341
+ # defined here. For `map_value`, the field path is represented by the simple
342
+ # or quoted field names of the containing fields, delimited by `.`. For
343
+ # example, the structured field
344
+ # `"foo" : ` map_value: ` "x&y" : ` string_value: "hello" ```` would be
345
+ # represented by the field path `foo.x&y`.
346
+ # Within a field path, a quoted field name starts and ends with `` ` `` and
347
+ # may contain any character. Some characters, including `` ` ``, must be
348
+ # escaped using a `\`. For example, `` `x&y` `` represents `x&y` and
349
+ # `` `bak\`tik` `` represents `` bak`tik ``.
350
+ # Corresponds to the JSON property `fields`
351
+ # @return [Hash<String,Google::Apis::FirestoreV1::Value>]
352
+ attr_accessor :fields
342
353
 
343
- # Location of the exported files.
344
- # This must match the output_uri_prefix of an ExportDocumentsResponse from
345
- # an export that has completed successfully.
346
- # See:
347
- # google.firestore.admin.v1.ExportDocumentsResponse.output_uri_prefix.
348
- # Corresponds to the JSON property `inputUriPrefix`
354
+ # The resource name of the document, for example
355
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
356
+ # Corresponds to the JSON property `name`
349
357
  # @return [String]
350
- attr_accessor :input_uri_prefix
358
+ attr_accessor :name
359
+
360
+ # Output only. The time at which the document was last changed.
361
+ # This value is initially set to the `create_time` then increases
362
+ # monotonically with each change to the document. It can also be
363
+ # compared to values from other documents and the `read_time` of a query.
364
+ # Corresponds to the JSON property `updateTime`
365
+ # @return [String]
366
+ attr_accessor :update_time
351
367
 
352
368
  def initialize(**args)
353
369
  update!(**args)
@@ -355,54 +371,133 @@ module Google
355
371
 
356
372
  # Update properties of this object
357
373
  def update!(**args)
358
- @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
359
- @input_uri_prefix = args[:input_uri_prefix] if args.key?(:input_uri_prefix)
374
+ @create_time = args[:create_time] if args.key?(:create_time)
375
+ @fields = args[:fields] if args.key?(:fields)
376
+ @name = args[:name] if args.key?(:name)
377
+ @update_time = args[:update_time] if args.key?(:update_time)
360
378
  end
361
379
  end
362
380
 
363
- # Cloud Firestore indexes enable simple and complex queries against
364
- # documents in a database.
365
- class GoogleFirestoreAdminV1Index
381
+ # A Document has changed.
382
+ # May be the result of multiple writes, including deletes, that
383
+ # ultimately resulted in a new value for the Document.
384
+ # Multiple DocumentChange messages may be returned for the same logical
385
+ # change, if multiple targets are affected.
386
+ class DocumentChange
366
387
  include Google::Apis::Core::Hashable
367
388
 
368
- # The fields supported by this index.
369
- # For composite indexes, this is always 2 or more fields.
370
- # The last field entry is always for the field path `__name__`. If, on
371
- # creation, `__name__` was not specified as the last field, it will be added
372
- # automatically with the same direction as that of the last field defined. If
373
- # the final field in a composite index is not directional, the `__name__`
374
- # will be ordered ASCENDING (unless explicitly specified).
375
- # For single field indexes, this will always be exactly one entry with a
376
- # field path equal to the field path of the associated field.
377
- # Corresponds to the JSON property `fields`
378
- # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1IndexField>]
379
- attr_accessor :fields
389
+ # A Firestore document.
390
+ # Must not exceed 1 MiB - 4 bytes.
391
+ # Corresponds to the JSON property `document`
392
+ # @return [Google::Apis::FirestoreV1::Document]
393
+ attr_accessor :document
380
394
 
381
- # Output only.
382
- # A server defined name for this index.
383
- # The form of this name for composite indexes will be:
384
- # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
385
- # /indexes/`composite_index_id``
386
- # For single field indexes, this field will be empty.
387
- # Corresponds to the JSON property `name`
395
+ # A set of target IDs for targets that no longer match this document.
396
+ # Corresponds to the JSON property `removedTargetIds`
397
+ # @return [Array<Fixnum>]
398
+ attr_accessor :removed_target_ids
399
+
400
+ # A set of target IDs of targets that match this document.
401
+ # Corresponds to the JSON property `targetIds`
402
+ # @return [Array<Fixnum>]
403
+ attr_accessor :target_ids
404
+
405
+ def initialize(**args)
406
+ update!(**args)
407
+ end
408
+
409
+ # Update properties of this object
410
+ def update!(**args)
411
+ @document = args[:document] if args.key?(:document)
412
+ @removed_target_ids = args[:removed_target_ids] if args.key?(:removed_target_ids)
413
+ @target_ids = args[:target_ids] if args.key?(:target_ids)
414
+ end
415
+ end
416
+
417
+ # A Document has been deleted.
418
+ # May be the result of multiple writes, including updates, the
419
+ # last of which deleted the Document.
420
+ # Multiple DocumentDelete messages may be returned for the same logical
421
+ # delete, if multiple targets are affected.
422
+ class DocumentDelete
423
+ include Google::Apis::Core::Hashable
424
+
425
+ # The resource name of the Document that was deleted.
426
+ # Corresponds to the JSON property `document`
388
427
  # @return [String]
389
- attr_accessor :name
428
+ attr_accessor :document
390
429
 
391
- # Indexes with a collection query scope specified allow queries
392
- # against a collection that is the child of a specific document, specified at
393
- # query time, and that has the same collection id.
394
- # Indexes with a collection group query scope specified allow queries against
395
- # all collections descended from a specific document, specified at query
396
- # time, and that have the same collection id as this index.
397
- # Corresponds to the JSON property `queryScope`
430
+ # The read timestamp at which the delete was observed.
431
+ # Greater or equal to the `commit_time` of the delete.
432
+ # Corresponds to the JSON property `readTime`
398
433
  # @return [String]
399
- attr_accessor :query_scope
434
+ attr_accessor :read_time
400
435
 
401
- # Output only.
402
- # The serving state of the index.
403
- # Corresponds to the JSON property `state`
436
+ # A set of target IDs for targets that previously matched this entity.
437
+ # Corresponds to the JSON property `removedTargetIds`
438
+ # @return [Array<Fixnum>]
439
+ attr_accessor :removed_target_ids
440
+
441
+ def initialize(**args)
442
+ update!(**args)
443
+ end
444
+
445
+ # Update properties of this object
446
+ def update!(**args)
447
+ @document = args[:document] if args.key?(:document)
448
+ @read_time = args[:read_time] if args.key?(:read_time)
449
+ @removed_target_ids = args[:removed_target_ids] if args.key?(:removed_target_ids)
450
+ end
451
+ end
452
+
453
+ # A set of field paths on a document.
454
+ # Used to restrict a get or update operation on a document to a subset of its
455
+ # fields.
456
+ # This is different from standard field masks, as this is always scoped to a
457
+ # Document, and takes in account the dynamic nature of Value.
458
+ class DocumentMask
459
+ include Google::Apis::Core::Hashable
460
+
461
+ # The list of field paths in the mask. See Document.fields for a field
462
+ # path syntax reference.
463
+ # Corresponds to the JSON property `fieldPaths`
464
+ # @return [Array<String>]
465
+ attr_accessor :field_paths
466
+
467
+ def initialize(**args)
468
+ update!(**args)
469
+ end
470
+
471
+ # Update properties of this object
472
+ def update!(**args)
473
+ @field_paths = args[:field_paths] if args.key?(:field_paths)
474
+ end
475
+ end
476
+
477
+ # A Document has been removed from the view of the targets.
478
+ # Sent if the document is no longer relevant to a target and is out of view.
479
+ # Can be sent instead of a DocumentDelete or a DocumentChange if the server
480
+ # can not send the new value of the document.
481
+ # Multiple DocumentRemove messages may be returned for the same logical
482
+ # write or delete, if multiple targets are affected.
483
+ class DocumentRemove
484
+ include Google::Apis::Core::Hashable
485
+
486
+ # The resource name of the Document that has gone out of view.
487
+ # Corresponds to the JSON property `document`
404
488
  # @return [String]
405
- attr_accessor :state
489
+ attr_accessor :document
490
+
491
+ # The read timestamp at which the remove was observed.
492
+ # Greater or equal to the `commit_time` of the change/delete/remove.
493
+ # Corresponds to the JSON property `readTime`
494
+ # @return [String]
495
+ attr_accessor :read_time
496
+
497
+ # A set of target IDs for targets that previously matched this document.
498
+ # Corresponds to the JSON property `removedTargetIds`
499
+ # @return [Array<Fixnum>]
500
+ attr_accessor :removed_target_ids
406
501
 
407
502
  def initialize(**args)
408
503
  update!(**args)
@@ -410,49 +505,50 @@ module Google
410
505
 
411
506
  # Update properties of this object
412
507
  def update!(**args)
413
- @fields = args[:fields] if args.key?(:fields)
414
- @name = args[:name] if args.key?(:name)
415
- @query_scope = args[:query_scope] if args.key?(:query_scope)
416
- @state = args[:state] if args.key?(:state)
508
+ @document = args[:document] if args.key?(:document)
509
+ @read_time = args[:read_time] if args.key?(:read_time)
510
+ @removed_target_ids = args[:removed_target_ids] if args.key?(:removed_target_ids)
417
511
  end
418
512
  end
419
513
 
420
- # The index configuration for this field.
421
- class GoogleFirestoreAdminV1IndexConfig
514
+ # A transformation of a document.
515
+ class DocumentTransform
422
516
  include Google::Apis::Core::Hashable
423
517
 
424
- # Output only.
425
- # Specifies the resource name of the `Field` from which this field's
426
- # index configuration is set (when `uses_ancestor_config` is true),
427
- # or from which it *would* be set if this field had no index configuration
428
- # (when `uses_ancestor_config` is false).
429
- # Corresponds to the JSON property `ancestorField`
518
+ # The name of the document to transform.
519
+ # Corresponds to the JSON property `document`
430
520
  # @return [String]
431
- attr_accessor :ancestor_field
521
+ attr_accessor :document
432
522
 
433
- # The indexes supported for this field.
434
- # Corresponds to the JSON property `indexes`
435
- # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Index>]
436
- attr_accessor :indexes
523
+ # The list of transformations to apply to the fields of the document, in
524
+ # order.
525
+ # This must not be empty.
526
+ # Corresponds to the JSON property `fieldTransforms`
527
+ # @return [Array<Google::Apis::FirestoreV1::FieldTransform>]
528
+ attr_accessor :field_transforms
437
529
 
438
- # Output only
439
- # When true, the `Field`'s index configuration is in the process of being
440
- # reverted. Once complete, the index config will transition to the same
441
- # state as the field specified by `ancestor_field`, at which point
442
- # `uses_ancestor_config` will be `true` and `reverting` will be `false`.
443
- # Corresponds to the JSON property `reverting`
444
- # @return [Boolean]
445
- attr_accessor :reverting
446
- alias_method :reverting?, :reverting
530
+ def initialize(**args)
531
+ update!(**args)
532
+ end
447
533
 
448
- # Output only.
449
- # When true, the `Field`'s index configuration is set from the
450
- # configuration specified by the `ancestor_field`.
451
- # When false, the `Field`'s index configuration is defined explicitly.
452
- # Corresponds to the JSON property `usesAncestorConfig`
453
- # @return [Boolean]
454
- attr_accessor :uses_ancestor_config
455
- alias_method :uses_ancestor_config?, :uses_ancestor_config
534
+ # Update properties of this object
535
+ def update!(**args)
536
+ @document = args[:document] if args.key?(:document)
537
+ @field_transforms = args[:field_transforms] if args.key?(:field_transforms)
538
+ end
539
+ end
540
+
541
+ # A target specified by a set of documents names.
542
+ class DocumentsTarget
543
+ include Google::Apis::Core::Hashable
544
+
545
+ # The names of the documents to retrieve. In the format:
546
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
547
+ # The request will fail if any of the document is not a child resource of
548
+ # the given `database`. Duplicate names will be elided.
549
+ # Corresponds to the JSON property `documents`
550
+ # @return [Array<String>]
551
+ attr_accessor :documents
456
552
 
457
553
  def initialize(**args)
458
554
  update!(**args)
@@ -460,27 +556,74 @@ module Google
460
556
 
461
557
  # Update properties of this object
462
558
  def update!(**args)
463
- @ancestor_field = args[:ancestor_field] if args.key?(:ancestor_field)
464
- @indexes = args[:indexes] if args.key?(:indexes)
465
- @reverting = args[:reverting] if args.key?(:reverting)
466
- @uses_ancestor_config = args[:uses_ancestor_config] if args.key?(:uses_ancestor_config)
559
+ @documents = args[:documents] if args.key?(:documents)
467
560
  end
468
561
  end
469
562
 
470
- # Information about an index configuration change.
471
- class GoogleFirestoreAdminV1IndexConfigDelta
563
+ # A generic empty message that you can re-use to avoid defining duplicated
564
+ # empty messages in your APIs. A typical example is to use it as the request
565
+ # or the response type of an API method. For instance:
566
+ # service Foo `
567
+ # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
568
+ # `
569
+ # The JSON representation for `Empty` is empty JSON object ````.
570
+ class Empty
472
571
  include Google::Apis::Core::Hashable
473
572
 
474
- # Specifies how the index is changing.
475
- # Corresponds to the JSON property `changeType`
573
+ def initialize(**args)
574
+ update!(**args)
575
+ end
576
+
577
+ # Update properties of this object
578
+ def update!(**args)
579
+ end
580
+ end
581
+
582
+ # A digest of all the documents that match a given target.
583
+ class ExistenceFilter
584
+ include Google::Apis::Core::Hashable
585
+
586
+ # The total count of documents that match target_id.
587
+ # If different from the count of documents in the client that match, the
588
+ # client must manually determine which documents no longer match the target.
589
+ # Corresponds to the JSON property `count`
590
+ # @return [Fixnum]
591
+ attr_accessor :count
592
+
593
+ # The target ID to which this filter applies.
594
+ # Corresponds to the JSON property `targetId`
595
+ # @return [Fixnum]
596
+ attr_accessor :target_id
597
+
598
+ def initialize(**args)
599
+ update!(**args)
600
+ end
601
+
602
+ # Update properties of this object
603
+ def update!(**args)
604
+ @count = args[:count] if args.key?(:count)
605
+ @target_id = args[:target_id] if args.key?(:target_id)
606
+ end
607
+ end
608
+
609
+ # A filter on a specific field.
610
+ class FieldFilter
611
+ include Google::Apis::Core::Hashable
612
+
613
+ # A reference to a field, such as `max(messages.time) as max_time`.
614
+ # Corresponds to the JSON property `field`
615
+ # @return [Google::Apis::FirestoreV1::FieldReference]
616
+ attr_accessor :field
617
+
618
+ # The operator to filter by.
619
+ # Corresponds to the JSON property `op`
476
620
  # @return [String]
477
- attr_accessor :change_type
621
+ attr_accessor :op
478
622
 
479
- # Cloud Firestore indexes enable simple and complex queries against
480
- # documents in a database.
481
- # Corresponds to the JSON property `index`
482
- # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Index]
483
- attr_accessor :index
623
+ # A message that can hold any of the supported value types.
624
+ # Corresponds to the JSON property `value`
625
+ # @return [Google::Apis::FirestoreV1::Value]
626
+ attr_accessor :value
484
627
 
485
628
  def initialize(**args)
486
629
  update!(**args)
@@ -488,34 +631,55 @@ module Google
488
631
 
489
632
  # Update properties of this object
490
633
  def update!(**args)
491
- @change_type = args[:change_type] if args.key?(:change_type)
492
- @index = args[:index] if args.key?(:index)
634
+ @field = args[:field] if args.key?(:field)
635
+ @op = args[:op] if args.key?(:op)
636
+ @value = args[:value] if args.key?(:value)
493
637
  end
494
638
  end
495
639
 
496
- # A field in an index.
497
- # The field_path describes which field is indexed, the value_mode describes
498
- # how the field value is indexed.
499
- class GoogleFirestoreAdminV1IndexField
640
+ # A reference to a field, such as `max(messages.time) as max_time`.
641
+ class FieldReference
500
642
  include Google::Apis::Core::Hashable
501
643
 
502
- # Indicates that this field supports operations on `array_value`s.
503
- # Corresponds to the JSON property `arrayConfig`
644
+ #
645
+ # Corresponds to the JSON property `fieldPath`
504
646
  # @return [String]
505
- attr_accessor :array_config
647
+ attr_accessor :field_path
506
648
 
507
- # Can be __name__.
508
- # For single field indexes, this must match the name of the field or may
509
- # be omitted.
649
+ def initialize(**args)
650
+ update!(**args)
651
+ end
652
+
653
+ # Update properties of this object
654
+ def update!(**args)
655
+ @field_path = args[:field_path] if args.key?(:field_path)
656
+ end
657
+ end
658
+
659
+ # A transformation of a field of the document.
660
+ class FieldTransform
661
+ include Google::Apis::Core::Hashable
662
+
663
+ # An array value.
664
+ # Corresponds to the JSON property `appendMissingElements`
665
+ # @return [Google::Apis::FirestoreV1::ArrayValue]
666
+ attr_accessor :append_missing_elements
667
+
668
+ # The path of the field. See Document.fields for the field path syntax
669
+ # reference.
510
670
  # Corresponds to the JSON property `fieldPath`
511
671
  # @return [String]
512
672
  attr_accessor :field_path
513
673
 
514
- # Indicates that this field supports ordering by the specified order or
515
- # comparing using =, <, <=, >, >=.
516
- # Corresponds to the JSON property `order`
674
+ # An array value.
675
+ # Corresponds to the JSON property `removeAllFromArray`
676
+ # @return [Google::Apis::FirestoreV1::ArrayValue]
677
+ attr_accessor :remove_all_from_array
678
+
679
+ # Sets the field to the given server value.
680
+ # Corresponds to the JSON property `setToServerValue`
517
681
  # @return [String]
518
- attr_accessor :order
682
+ attr_accessor :set_to_server_value
519
683
 
520
684
  def initialize(**args)
521
685
  update!(**args)
@@ -523,29 +687,69 @@ module Google
523
687
 
524
688
  # Update properties of this object
525
689
  def update!(**args)
526
- @array_config = args[:array_config] if args.key?(:array_config)
690
+ @append_missing_elements = args[:append_missing_elements] if args.key?(:append_missing_elements)
527
691
  @field_path = args[:field_path] if args.key?(:field_path)
528
- @order = args[:order] if args.key?(:order)
692
+ @remove_all_from_array = args[:remove_all_from_array] if args.key?(:remove_all_from_array)
693
+ @set_to_server_value = args[:set_to_server_value] if args.key?(:set_to_server_value)
694
+ end
695
+ end
696
+
697
+ # A filter.
698
+ class Filter
699
+ include Google::Apis::Core::Hashable
700
+
701
+ # A filter that merges multiple other filters using the given operator.
702
+ # Corresponds to the JSON property `compositeFilter`
703
+ # @return [Google::Apis::FirestoreV1::CompositeFilter]
704
+ attr_accessor :composite_filter
705
+
706
+ # A filter on a specific field.
707
+ # Corresponds to the JSON property `fieldFilter`
708
+ # @return [Google::Apis::FirestoreV1::FieldFilter]
709
+ attr_accessor :field_filter
710
+
711
+ # A filter with a single operand.
712
+ # Corresponds to the JSON property `unaryFilter`
713
+ # @return [Google::Apis::FirestoreV1::UnaryFilter]
714
+ attr_accessor :unary_filter
715
+
716
+ def initialize(**args)
717
+ update!(**args)
718
+ end
719
+
720
+ # Update properties of this object
721
+ def update!(**args)
722
+ @composite_filter = args[:composite_filter] if args.key?(:composite_filter)
723
+ @field_filter = args[:field_filter] if args.key?(:field_filter)
724
+ @unary_filter = args[:unary_filter] if args.key?(:unary_filter)
529
725
  end
530
726
  end
531
727
 
532
728
  # Metadata for google.longrunning.Operation results from
533
- # FirestoreAdmin.CreateIndex.
534
- class GoogleFirestoreAdminV1IndexOperationMetadata
729
+ # FirestoreAdmin.ExportDocuments.
730
+ class GoogleFirestoreAdminV1ExportDocumentsMetadata
535
731
  include Google::Apis::Core::Hashable
536
732
 
733
+ # Which collection ids are being exported.
734
+ # Corresponds to the JSON property `collectionIds`
735
+ # @return [Array<String>]
736
+ attr_accessor :collection_ids
737
+
537
738
  # The time this operation completed. Will be unset if operation still in
538
739
  # progress.
539
740
  # Corresponds to the JSON property `endTime`
540
741
  # @return [String]
541
742
  attr_accessor :end_time
542
743
 
543
- # The index resource that this operation is acting on. For example:
544
- # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
545
- # /indexes/`index_id``
546
- # Corresponds to the JSON property `index`
744
+ # The state of the export operation.
745
+ # Corresponds to the JSON property `operationState`
547
746
  # @return [String]
548
- attr_accessor :index
747
+ attr_accessor :operation_state
748
+
749
+ # Where the entities are being exported to.
750
+ # Corresponds to the JSON property `outputUriPrefix`
751
+ # @return [String]
752
+ attr_accessor :output_uri_prefix
549
753
 
550
754
  # Describes the progress of the operation.
551
755
  # Unit of work is generic and must be interpreted based on where Progress
@@ -566,40 +770,1083 @@ module Google
566
770
  # @return [String]
567
771
  attr_accessor :start_time
568
772
 
569
- # The state of the operation.
570
- # Corresponds to the JSON property `state`
571
- # @return [String]
572
- attr_accessor :state
573
-
574
773
  def initialize(**args)
575
774
  update!(**args)
576
775
  end
577
776
 
578
777
  # Update properties of this object
579
778
  def update!(**args)
779
+ @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
580
780
  @end_time = args[:end_time] if args.key?(:end_time)
581
- @index = args[:index] if args.key?(:index)
781
+ @operation_state = args[:operation_state] if args.key?(:operation_state)
782
+ @output_uri_prefix = args[:output_uri_prefix] if args.key?(:output_uri_prefix)
582
783
  @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
583
784
  @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
584
785
  @start_time = args[:start_time] if args.key?(:start_time)
585
- @state = args[:state] if args.key?(:state)
586
786
  end
587
787
  end
588
788
 
589
- # The response for FirestoreAdmin.ListFields.
590
- class GoogleFirestoreAdminV1ListFieldsResponse
789
+ # The request for FirestoreAdmin.ExportDocuments.
790
+ class GoogleFirestoreAdminV1ExportDocumentsRequest
791
+ include Google::Apis::Core::Hashable
792
+
793
+ # Which collection ids to export. Unspecified means all collections.
794
+ # Corresponds to the JSON property `collectionIds`
795
+ # @return [Array<String>]
796
+ attr_accessor :collection_ids
797
+
798
+ # The output URI. Currently only supports Google Cloud Storage URIs of the
799
+ # form: `gs://BUCKET_NAME[/NAMESPACE_PATH]`, where `BUCKET_NAME` is the name
800
+ # of the Google Cloud Storage bucket and `NAMESPACE_PATH` is an optional
801
+ # Google Cloud Storage namespace path. When
802
+ # choosing a name, be sure to consider Google Cloud Storage naming
803
+ # guidelines: https://cloud.google.com/storage/docs/naming.
804
+ # If the URI is a bucket (without a namespace path), a prefix will be
805
+ # generated based on the start time.
806
+ # Corresponds to the JSON property `outputUriPrefix`
807
+ # @return [String]
808
+ attr_accessor :output_uri_prefix
809
+
810
+ def initialize(**args)
811
+ update!(**args)
812
+ end
813
+
814
+ # Update properties of this object
815
+ def update!(**args)
816
+ @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
817
+ @output_uri_prefix = args[:output_uri_prefix] if args.key?(:output_uri_prefix)
818
+ end
819
+ end
820
+
821
+ # Returned in the google.longrunning.Operation response field.
822
+ class GoogleFirestoreAdminV1ExportDocumentsResponse
823
+ include Google::Apis::Core::Hashable
824
+
825
+ # Location of the output files. This can be used to begin an import
826
+ # into Cloud Firestore (this project or another project) after the operation
827
+ # completes successfully.
828
+ # Corresponds to the JSON property `outputUriPrefix`
829
+ # @return [String]
830
+ attr_accessor :output_uri_prefix
831
+
832
+ def initialize(**args)
833
+ update!(**args)
834
+ end
835
+
836
+ # Update properties of this object
837
+ def update!(**args)
838
+ @output_uri_prefix = args[:output_uri_prefix] if args.key?(:output_uri_prefix)
839
+ end
840
+ end
841
+
842
+ # Represents a single field in the database.
843
+ # Fields are grouped by their "Collection Group", which represent all
844
+ # collections in the database with the same id.
845
+ class GoogleFirestoreAdminV1Field
846
+ include Google::Apis::Core::Hashable
847
+
848
+ # The index configuration for this field.
849
+ # Corresponds to the JSON property `indexConfig`
850
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1IndexConfig]
851
+ attr_accessor :index_config
852
+
853
+ # A field name of the form
854
+ # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
855
+ # /fields/`field_path``
856
+ # A field path may be a simple field name, e.g. `address` or a path to fields
857
+ # within map_value , e.g. `address.city`,
858
+ # or a special field path. The only valid special field is `*`, which
859
+ # represents any field.
860
+ # Field paths may be quoted using ` (backtick). The only character that needs
861
+ # to be escaped within a quoted field path is the backtick character itself,
862
+ # escaped using a backslash. Special characters in field paths that
863
+ # must be quoted include: `*`, `.`,
864
+ # ``` (backtick), `[`, `]`, as well as any ascii symbolic characters.
865
+ # Examples:
866
+ # (Note: Comments here are written in markdown syntax, so there is an
867
+ # additional layer of backticks to represent a code block)
868
+ # `\`address.city\`` represents a field named `address.city`, not the map key
869
+ # `city` in the field `address`.
870
+ # `\`*\`` represents a field named `*`, not any field.
871
+ # A special `Field` contains the default indexing settings for all fields.
872
+ # This field's resource name is:
873
+ # `projects/`project_id`/databases/`database_id`/collectionGroups/__default__/
874
+ # fields/*`
875
+ # Indexes defined on this `Field` will be applied to all fields which do not
876
+ # have their own `Field` index configuration.
877
+ # Corresponds to the JSON property `name`
878
+ # @return [String]
879
+ attr_accessor :name
880
+
881
+ def initialize(**args)
882
+ update!(**args)
883
+ end
884
+
885
+ # Update properties of this object
886
+ def update!(**args)
887
+ @index_config = args[:index_config] if args.key?(:index_config)
888
+ @name = args[:name] if args.key?(:name)
889
+ end
890
+ end
891
+
892
+ # Metadata for google.longrunning.Operation results from
893
+ # FirestoreAdmin.UpdateField.
894
+ class GoogleFirestoreAdminV1FieldOperationMetadata
895
+ include Google::Apis::Core::Hashable
896
+
897
+ # The time this operation completed. Will be unset if operation still in
898
+ # progress.
899
+ # Corresponds to the JSON property `endTime`
900
+ # @return [String]
901
+ attr_accessor :end_time
902
+
903
+ # The field resource that this operation is acting on. For example:
904
+ # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
905
+ # /fields/`field_path``
906
+ # Corresponds to the JSON property `field`
907
+ # @return [String]
908
+ attr_accessor :field
909
+
910
+ # A list of IndexConfigDelta, which describe the intent of this
911
+ # operation.
912
+ # Corresponds to the JSON property `indexConfigDeltas`
913
+ # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1IndexConfigDelta>]
914
+ attr_accessor :index_config_deltas
915
+
916
+ # Describes the progress of the operation.
917
+ # Unit of work is generic and must be interpreted based on where Progress
918
+ # is used.
919
+ # Corresponds to the JSON property `progressBytes`
920
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
921
+ attr_accessor :progress_bytes
922
+
923
+ # Describes the progress of the operation.
924
+ # Unit of work is generic and must be interpreted based on where Progress
925
+ # is used.
926
+ # Corresponds to the JSON property `progressDocuments`
927
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
928
+ attr_accessor :progress_documents
929
+
930
+ # The time this operation started.
931
+ # Corresponds to the JSON property `startTime`
932
+ # @return [String]
933
+ attr_accessor :start_time
934
+
935
+ # The state of the operation.
936
+ # Corresponds to the JSON property `state`
937
+ # @return [String]
938
+ attr_accessor :state
939
+
940
+ def initialize(**args)
941
+ update!(**args)
942
+ end
943
+
944
+ # Update properties of this object
945
+ def update!(**args)
946
+ @end_time = args[:end_time] if args.key?(:end_time)
947
+ @field = args[:field] if args.key?(:field)
948
+ @index_config_deltas = args[:index_config_deltas] if args.key?(:index_config_deltas)
949
+ @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
950
+ @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
951
+ @start_time = args[:start_time] if args.key?(:start_time)
952
+ @state = args[:state] if args.key?(:state)
953
+ end
954
+ end
955
+
956
+ # Metadata for google.longrunning.Operation results from
957
+ # FirestoreAdmin.ImportDocuments.
958
+ class GoogleFirestoreAdminV1ImportDocumentsMetadata
959
+ include Google::Apis::Core::Hashable
960
+
961
+ # Which collection ids are being imported.
962
+ # Corresponds to the JSON property `collectionIds`
963
+ # @return [Array<String>]
964
+ attr_accessor :collection_ids
965
+
966
+ # The time this operation completed. Will be unset if operation still in
967
+ # progress.
968
+ # Corresponds to the JSON property `endTime`
969
+ # @return [String]
970
+ attr_accessor :end_time
971
+
972
+ # The location of the documents being imported.
973
+ # Corresponds to the JSON property `inputUriPrefix`
974
+ # @return [String]
975
+ attr_accessor :input_uri_prefix
976
+
977
+ # The state of the import operation.
978
+ # Corresponds to the JSON property `operationState`
979
+ # @return [String]
980
+ attr_accessor :operation_state
981
+
982
+ # Describes the progress of the operation.
983
+ # Unit of work is generic and must be interpreted based on where Progress
984
+ # is used.
985
+ # Corresponds to the JSON property `progressBytes`
986
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
987
+ attr_accessor :progress_bytes
988
+
989
+ # Describes the progress of the operation.
990
+ # Unit of work is generic and must be interpreted based on where Progress
991
+ # is used.
992
+ # Corresponds to the JSON property `progressDocuments`
993
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
994
+ attr_accessor :progress_documents
995
+
996
+ # The time this operation started.
997
+ # Corresponds to the JSON property `startTime`
998
+ # @return [String]
999
+ attr_accessor :start_time
1000
+
1001
+ def initialize(**args)
1002
+ update!(**args)
1003
+ end
1004
+
1005
+ # Update properties of this object
1006
+ def update!(**args)
1007
+ @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
1008
+ @end_time = args[:end_time] if args.key?(:end_time)
1009
+ @input_uri_prefix = args[:input_uri_prefix] if args.key?(:input_uri_prefix)
1010
+ @operation_state = args[:operation_state] if args.key?(:operation_state)
1011
+ @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
1012
+ @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
1013
+ @start_time = args[:start_time] if args.key?(:start_time)
1014
+ end
1015
+ end
1016
+
1017
+ # The request for FirestoreAdmin.ImportDocuments.
1018
+ class GoogleFirestoreAdminV1ImportDocumentsRequest
1019
+ include Google::Apis::Core::Hashable
1020
+
1021
+ # Which collection ids to import. Unspecified means all collections included
1022
+ # in the import.
1023
+ # Corresponds to the JSON property `collectionIds`
1024
+ # @return [Array<String>]
1025
+ attr_accessor :collection_ids
1026
+
1027
+ # Location of the exported files.
1028
+ # This must match the output_uri_prefix of an ExportDocumentsResponse from
1029
+ # an export that has completed successfully.
1030
+ # See:
1031
+ # google.firestore.admin.v1.ExportDocumentsResponse.output_uri_prefix.
1032
+ # Corresponds to the JSON property `inputUriPrefix`
1033
+ # @return [String]
1034
+ attr_accessor :input_uri_prefix
1035
+
1036
+ def initialize(**args)
1037
+ update!(**args)
1038
+ end
1039
+
1040
+ # Update properties of this object
1041
+ def update!(**args)
1042
+ @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
1043
+ @input_uri_prefix = args[:input_uri_prefix] if args.key?(:input_uri_prefix)
1044
+ end
1045
+ end
1046
+
1047
+ # Cloud Firestore indexes enable simple and complex queries against
1048
+ # documents in a database.
1049
+ class GoogleFirestoreAdminV1Index
1050
+ include Google::Apis::Core::Hashable
1051
+
1052
+ # The fields supported by this index.
1053
+ # For composite indexes, this is always 2 or more fields.
1054
+ # The last field entry is always for the field path `__name__`. If, on
1055
+ # creation, `__name__` was not specified as the last field, it will be added
1056
+ # automatically with the same direction as that of the last field defined. If
1057
+ # the final field in a composite index is not directional, the `__name__`
1058
+ # will be ordered ASCENDING (unless explicitly specified).
1059
+ # For single field indexes, this will always be exactly one entry with a
1060
+ # field path equal to the field path of the associated field.
1061
+ # Corresponds to the JSON property `fields`
1062
+ # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1IndexField>]
1063
+ attr_accessor :fields
1064
+
1065
+ # Output only.
1066
+ # A server defined name for this index.
1067
+ # The form of this name for composite indexes will be:
1068
+ # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
1069
+ # /indexes/`composite_index_id``
1070
+ # For single field indexes, this field will be empty.
1071
+ # Corresponds to the JSON property `name`
1072
+ # @return [String]
1073
+ attr_accessor :name
1074
+
1075
+ # Indexes with a collection query scope specified allow queries
1076
+ # against a collection that is the child of a specific document, specified at
1077
+ # query time, and that has the same collection id.
1078
+ # Indexes with a collection group query scope specified allow queries against
1079
+ # all collections descended from a specific document, specified at query
1080
+ # time, and that have the same collection id as this index.
1081
+ # Corresponds to the JSON property `queryScope`
1082
+ # @return [String]
1083
+ attr_accessor :query_scope
1084
+
1085
+ # Output only.
1086
+ # The serving state of the index.
1087
+ # Corresponds to the JSON property `state`
1088
+ # @return [String]
1089
+ attr_accessor :state
1090
+
1091
+ def initialize(**args)
1092
+ update!(**args)
1093
+ end
1094
+
1095
+ # Update properties of this object
1096
+ def update!(**args)
1097
+ @fields = args[:fields] if args.key?(:fields)
1098
+ @name = args[:name] if args.key?(:name)
1099
+ @query_scope = args[:query_scope] if args.key?(:query_scope)
1100
+ @state = args[:state] if args.key?(:state)
1101
+ end
1102
+ end
1103
+
1104
+ # The index configuration for this field.
1105
+ class GoogleFirestoreAdminV1IndexConfig
1106
+ include Google::Apis::Core::Hashable
1107
+
1108
+ # Output only.
1109
+ # Specifies the resource name of the `Field` from which this field's
1110
+ # index configuration is set (when `uses_ancestor_config` is true),
1111
+ # or from which it *would* be set if this field had no index configuration
1112
+ # (when `uses_ancestor_config` is false).
1113
+ # Corresponds to the JSON property `ancestorField`
1114
+ # @return [String]
1115
+ attr_accessor :ancestor_field
1116
+
1117
+ # The indexes supported for this field.
1118
+ # Corresponds to the JSON property `indexes`
1119
+ # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Index>]
1120
+ attr_accessor :indexes
1121
+
1122
+ # Output only
1123
+ # When true, the `Field`'s index configuration is in the process of being
1124
+ # reverted. Once complete, the index config will transition to the same
1125
+ # state as the field specified by `ancestor_field`, at which point
1126
+ # `uses_ancestor_config` will be `true` and `reverting` will be `false`.
1127
+ # Corresponds to the JSON property `reverting`
1128
+ # @return [Boolean]
1129
+ attr_accessor :reverting
1130
+ alias_method :reverting?, :reverting
1131
+
1132
+ # Output only.
1133
+ # When true, the `Field`'s index configuration is set from the
1134
+ # configuration specified by the `ancestor_field`.
1135
+ # When false, the `Field`'s index configuration is defined explicitly.
1136
+ # Corresponds to the JSON property `usesAncestorConfig`
1137
+ # @return [Boolean]
1138
+ attr_accessor :uses_ancestor_config
1139
+ alias_method :uses_ancestor_config?, :uses_ancestor_config
1140
+
1141
+ def initialize(**args)
1142
+ update!(**args)
1143
+ end
1144
+
1145
+ # Update properties of this object
1146
+ def update!(**args)
1147
+ @ancestor_field = args[:ancestor_field] if args.key?(:ancestor_field)
1148
+ @indexes = args[:indexes] if args.key?(:indexes)
1149
+ @reverting = args[:reverting] if args.key?(:reverting)
1150
+ @uses_ancestor_config = args[:uses_ancestor_config] if args.key?(:uses_ancestor_config)
1151
+ end
1152
+ end
1153
+
1154
+ # Information about an index configuration change.
1155
+ class GoogleFirestoreAdminV1IndexConfigDelta
1156
+ include Google::Apis::Core::Hashable
1157
+
1158
+ # Specifies how the index is changing.
1159
+ # Corresponds to the JSON property `changeType`
1160
+ # @return [String]
1161
+ attr_accessor :change_type
1162
+
1163
+ # Cloud Firestore indexes enable simple and complex queries against
1164
+ # documents in a database.
1165
+ # Corresponds to the JSON property `index`
1166
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Index]
1167
+ attr_accessor :index
1168
+
1169
+ def initialize(**args)
1170
+ update!(**args)
1171
+ end
1172
+
1173
+ # Update properties of this object
1174
+ def update!(**args)
1175
+ @change_type = args[:change_type] if args.key?(:change_type)
1176
+ @index = args[:index] if args.key?(:index)
1177
+ end
1178
+ end
1179
+
1180
+ # A field in an index.
1181
+ # The field_path describes which field is indexed, the value_mode describes
1182
+ # how the field value is indexed.
1183
+ class GoogleFirestoreAdminV1IndexField
1184
+ include Google::Apis::Core::Hashable
1185
+
1186
+ # Indicates that this field supports operations on `array_value`s.
1187
+ # Corresponds to the JSON property `arrayConfig`
1188
+ # @return [String]
1189
+ attr_accessor :array_config
1190
+
1191
+ # Can be __name__.
1192
+ # For single field indexes, this must match the name of the field or may
1193
+ # be omitted.
1194
+ # Corresponds to the JSON property `fieldPath`
1195
+ # @return [String]
1196
+ attr_accessor :field_path
1197
+
1198
+ # Indicates that this field supports ordering by the specified order or
1199
+ # comparing using =, <, <=, >, >=.
1200
+ # Corresponds to the JSON property `order`
1201
+ # @return [String]
1202
+ attr_accessor :order
1203
+
1204
+ def initialize(**args)
1205
+ update!(**args)
1206
+ end
1207
+
1208
+ # Update properties of this object
1209
+ def update!(**args)
1210
+ @array_config = args[:array_config] if args.key?(:array_config)
1211
+ @field_path = args[:field_path] if args.key?(:field_path)
1212
+ @order = args[:order] if args.key?(:order)
1213
+ end
1214
+ end
1215
+
1216
+ # Metadata for google.longrunning.Operation results from
1217
+ # FirestoreAdmin.CreateIndex.
1218
+ class GoogleFirestoreAdminV1IndexOperationMetadata
1219
+ include Google::Apis::Core::Hashable
1220
+
1221
+ # The time this operation completed. Will be unset if operation still in
1222
+ # progress.
1223
+ # Corresponds to the JSON property `endTime`
1224
+ # @return [String]
1225
+ attr_accessor :end_time
1226
+
1227
+ # The index resource that this operation is acting on. For example:
1228
+ # `projects/`project_id`/databases/`database_id`/collectionGroups/`collection_id`
1229
+ # /indexes/`index_id``
1230
+ # Corresponds to the JSON property `index`
1231
+ # @return [String]
1232
+ attr_accessor :index
1233
+
1234
+ # Describes the progress of the operation.
1235
+ # Unit of work is generic and must be interpreted based on where Progress
1236
+ # is used.
1237
+ # Corresponds to the JSON property `progressBytes`
1238
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
1239
+ attr_accessor :progress_bytes
1240
+
1241
+ # Describes the progress of the operation.
1242
+ # Unit of work is generic and must be interpreted based on where Progress
1243
+ # is used.
1244
+ # Corresponds to the JSON property `progressDocuments`
1245
+ # @return [Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Progress]
1246
+ attr_accessor :progress_documents
1247
+
1248
+ # The time this operation started.
1249
+ # Corresponds to the JSON property `startTime`
1250
+ # @return [String]
1251
+ attr_accessor :start_time
1252
+
1253
+ # The state of the operation.
1254
+ # Corresponds to the JSON property `state`
1255
+ # @return [String]
1256
+ attr_accessor :state
1257
+
1258
+ def initialize(**args)
1259
+ update!(**args)
1260
+ end
1261
+
1262
+ # Update properties of this object
1263
+ def update!(**args)
1264
+ @end_time = args[:end_time] if args.key?(:end_time)
1265
+ @index = args[:index] if args.key?(:index)
1266
+ @progress_bytes = args[:progress_bytes] if args.key?(:progress_bytes)
1267
+ @progress_documents = args[:progress_documents] if args.key?(:progress_documents)
1268
+ @start_time = args[:start_time] if args.key?(:start_time)
1269
+ @state = args[:state] if args.key?(:state)
1270
+ end
1271
+ end
1272
+
1273
+ # The response for FirestoreAdmin.ListFields.
1274
+ class GoogleFirestoreAdminV1ListFieldsResponse
591
1275
  include Google::Apis::Core::Hashable
592
1276
 
593
1277
  # The requested fields.
594
1278
  # Corresponds to the JSON property `fields`
595
- # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Field>]
1279
+ # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Field>]
1280
+ attr_accessor :fields
1281
+
1282
+ # A page token that may be used to request another page of results. If blank,
1283
+ # this is the last page.
1284
+ # Corresponds to the JSON property `nextPageToken`
1285
+ # @return [String]
1286
+ attr_accessor :next_page_token
1287
+
1288
+ def initialize(**args)
1289
+ update!(**args)
1290
+ end
1291
+
1292
+ # Update properties of this object
1293
+ def update!(**args)
1294
+ @fields = args[:fields] if args.key?(:fields)
1295
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1296
+ end
1297
+ end
1298
+
1299
+ # The response for FirestoreAdmin.ListIndexes.
1300
+ class GoogleFirestoreAdminV1ListIndexesResponse
1301
+ include Google::Apis::Core::Hashable
1302
+
1303
+ # The requested indexes.
1304
+ # Corresponds to the JSON property `indexes`
1305
+ # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Index>]
1306
+ attr_accessor :indexes
1307
+
1308
+ # A page token that may be used to request another page of results. If blank,
1309
+ # this is the last page.
1310
+ # Corresponds to the JSON property `nextPageToken`
1311
+ # @return [String]
1312
+ attr_accessor :next_page_token
1313
+
1314
+ def initialize(**args)
1315
+ update!(**args)
1316
+ end
1317
+
1318
+ # Update properties of this object
1319
+ def update!(**args)
1320
+ @indexes = args[:indexes] if args.key?(:indexes)
1321
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1322
+ end
1323
+ end
1324
+
1325
+ # The metadata message for google.cloud.location.Location.metadata.
1326
+ class GoogleFirestoreAdminV1LocationMetadata
1327
+ include Google::Apis::Core::Hashable
1328
+
1329
+ def initialize(**args)
1330
+ update!(**args)
1331
+ end
1332
+
1333
+ # Update properties of this object
1334
+ def update!(**args)
1335
+ end
1336
+ end
1337
+
1338
+ # Describes the progress of the operation.
1339
+ # Unit of work is generic and must be interpreted based on where Progress
1340
+ # is used.
1341
+ class GoogleFirestoreAdminV1Progress
1342
+ include Google::Apis::Core::Hashable
1343
+
1344
+ # The amount of work completed.
1345
+ # Corresponds to the JSON property `completedWork`
1346
+ # @return [Fixnum]
1347
+ attr_accessor :completed_work
1348
+
1349
+ # The amount of work estimated.
1350
+ # Corresponds to the JSON property `estimatedWork`
1351
+ # @return [Fixnum]
1352
+ attr_accessor :estimated_work
1353
+
1354
+ def initialize(**args)
1355
+ update!(**args)
1356
+ end
1357
+
1358
+ # Update properties of this object
1359
+ def update!(**args)
1360
+ @completed_work = args[:completed_work] if args.key?(:completed_work)
1361
+ @estimated_work = args[:estimated_work] if args.key?(:estimated_work)
1362
+ end
1363
+ end
1364
+
1365
+ # The request message for Operations.CancelOperation.
1366
+ class GoogleLongrunningCancelOperationRequest
1367
+ include Google::Apis::Core::Hashable
1368
+
1369
+ def initialize(**args)
1370
+ update!(**args)
1371
+ end
1372
+
1373
+ # Update properties of this object
1374
+ def update!(**args)
1375
+ end
1376
+ end
1377
+
1378
+ # The response message for Operations.ListOperations.
1379
+ class GoogleLongrunningListOperationsResponse
1380
+ include Google::Apis::Core::Hashable
1381
+
1382
+ # The standard List next-page token.
1383
+ # Corresponds to the JSON property `nextPageToken`
1384
+ # @return [String]
1385
+ attr_accessor :next_page_token
1386
+
1387
+ # A list of operations that matches the specified filter in the request.
1388
+ # Corresponds to the JSON property `operations`
1389
+ # @return [Array<Google::Apis::FirestoreV1::GoogleLongrunningOperation>]
1390
+ attr_accessor :operations
1391
+
1392
+ def initialize(**args)
1393
+ update!(**args)
1394
+ end
1395
+
1396
+ # Update properties of this object
1397
+ def update!(**args)
1398
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1399
+ @operations = args[:operations] if args.key?(:operations)
1400
+ end
1401
+ end
1402
+
1403
+ # This resource represents a long-running operation that is the result of a
1404
+ # network API call.
1405
+ class GoogleLongrunningOperation
1406
+ include Google::Apis::Core::Hashable
1407
+
1408
+ # If the value is `false`, it means the operation is still in progress.
1409
+ # If `true`, the operation is completed, and either `error` or `response` is
1410
+ # available.
1411
+ # Corresponds to the JSON property `done`
1412
+ # @return [Boolean]
1413
+ attr_accessor :done
1414
+ alias_method :done?, :done
1415
+
1416
+ # The `Status` type defines a logical error model that is suitable for different
1417
+ # programming environments, including REST APIs and RPC APIs. It is used by
1418
+ # [gRPC](https://github.com/grpc). The error model is designed to be:
1419
+ # - Simple to use and understand for most users
1420
+ # - Flexible enough to meet unexpected needs
1421
+ # # Overview
1422
+ # The `Status` message contains three pieces of data: error code, error message,
1423
+ # and error details. The error code should be an enum value of
1424
+ # google.rpc.Code, but it may accept additional error codes if needed. The
1425
+ # error message should be a developer-facing English message that helps
1426
+ # developers *understand* and *resolve* the error. If a localized user-facing
1427
+ # error message is needed, put the localized message in the error details or
1428
+ # localize it in the client. The optional error details may contain arbitrary
1429
+ # information about the error. There is a predefined set of error detail types
1430
+ # in the package `google.rpc` that can be used for common error conditions.
1431
+ # # Language mapping
1432
+ # The `Status` message is the logical representation of the error model, but it
1433
+ # is not necessarily the actual wire format. When the `Status` message is
1434
+ # exposed in different client libraries and different wire protocols, it can be
1435
+ # mapped differently. For example, it will likely be mapped to some exceptions
1436
+ # in Java, but more likely mapped to some error codes in C.
1437
+ # # Other uses
1438
+ # The error model and the `Status` message can be used in a variety of
1439
+ # environments, either with or without APIs, to provide a
1440
+ # consistent developer experience across different environments.
1441
+ # Example uses of this error model include:
1442
+ # - Partial errors. If a service needs to return partial errors to the client,
1443
+ # it may embed the `Status` in the normal response to indicate the partial
1444
+ # errors.
1445
+ # - Workflow errors. A typical workflow has multiple steps. Each step may
1446
+ # have a `Status` message for error reporting.
1447
+ # - Batch operations. If a client uses batch request and batch response, the
1448
+ # `Status` message should be used directly inside batch response, one for
1449
+ # each error sub-response.
1450
+ # - Asynchronous operations. If an API call embeds asynchronous operation
1451
+ # results in its response, the status of those operations should be
1452
+ # represented directly using the `Status` message.
1453
+ # - Logging. If some API errors are stored in logs, the message `Status` could
1454
+ # be used directly after any stripping needed for security/privacy reasons.
1455
+ # Corresponds to the JSON property `error`
1456
+ # @return [Google::Apis::FirestoreV1::Status]
1457
+ attr_accessor :error
1458
+
1459
+ # Service-specific metadata associated with the operation. It typically
1460
+ # contains progress information and common metadata such as create time.
1461
+ # Some services might not provide such metadata. Any method that returns a
1462
+ # long-running operation should document the metadata type, if any.
1463
+ # Corresponds to the JSON property `metadata`
1464
+ # @return [Hash<String,Object>]
1465
+ attr_accessor :metadata
1466
+
1467
+ # The server-assigned name, which is only unique within the same service that
1468
+ # originally returns it. If you use the default HTTP mapping, the
1469
+ # `name` should have the format of `operations/some/unique/name`.
1470
+ # Corresponds to the JSON property `name`
1471
+ # @return [String]
1472
+ attr_accessor :name
1473
+
1474
+ # The normal response of the operation in case of success. If the original
1475
+ # method returns no data on success, such as `Delete`, the response is
1476
+ # `google.protobuf.Empty`. If the original method is standard
1477
+ # `Get`/`Create`/`Update`, the response should be the resource. For other
1478
+ # methods, the response should have the type `XxxResponse`, where `Xxx`
1479
+ # is the original method name. For example, if the original method name
1480
+ # is `TakeSnapshot()`, the inferred response type is
1481
+ # `TakeSnapshotResponse`.
1482
+ # Corresponds to the JSON property `response`
1483
+ # @return [Hash<String,Object>]
1484
+ attr_accessor :response
1485
+
1486
+ def initialize(**args)
1487
+ update!(**args)
1488
+ end
1489
+
1490
+ # Update properties of this object
1491
+ def update!(**args)
1492
+ @done = args[:done] if args.key?(:done)
1493
+ @error = args[:error] if args.key?(:error)
1494
+ @metadata = args[:metadata] if args.key?(:metadata)
1495
+ @name = args[:name] if args.key?(:name)
1496
+ @response = args[:response] if args.key?(:response)
1497
+ end
1498
+ end
1499
+
1500
+ # An object representing a latitude/longitude pair. This is expressed as a pair
1501
+ # of doubles representing degrees latitude and degrees longitude. Unless
1502
+ # specified otherwise, this must conform to the
1503
+ # <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84
1504
+ # standard</a>. Values must be within normalized ranges.
1505
+ class LatLng
1506
+ include Google::Apis::Core::Hashable
1507
+
1508
+ # The latitude in degrees. It must be in the range [-90.0, +90.0].
1509
+ # Corresponds to the JSON property `latitude`
1510
+ # @return [Float]
1511
+ attr_accessor :latitude
1512
+
1513
+ # The longitude in degrees. It must be in the range [-180.0, +180.0].
1514
+ # Corresponds to the JSON property `longitude`
1515
+ # @return [Float]
1516
+ attr_accessor :longitude
1517
+
1518
+ def initialize(**args)
1519
+ update!(**args)
1520
+ end
1521
+
1522
+ # Update properties of this object
1523
+ def update!(**args)
1524
+ @latitude = args[:latitude] if args.key?(:latitude)
1525
+ @longitude = args[:longitude] if args.key?(:longitude)
1526
+ end
1527
+ end
1528
+
1529
+ # The request for Firestore.ListCollectionIds.
1530
+ class ListCollectionIdsRequest
1531
+ include Google::Apis::Core::Hashable
1532
+
1533
+ # The maximum number of results to return.
1534
+ # Corresponds to the JSON property `pageSize`
1535
+ # @return [Fixnum]
1536
+ attr_accessor :page_size
1537
+
1538
+ # A page token. Must be a value from
1539
+ # ListCollectionIdsResponse.
1540
+ # Corresponds to the JSON property `pageToken`
1541
+ # @return [String]
1542
+ attr_accessor :page_token
1543
+
1544
+ def initialize(**args)
1545
+ update!(**args)
1546
+ end
1547
+
1548
+ # Update properties of this object
1549
+ def update!(**args)
1550
+ @page_size = args[:page_size] if args.key?(:page_size)
1551
+ @page_token = args[:page_token] if args.key?(:page_token)
1552
+ end
1553
+ end
1554
+
1555
+ # The response from Firestore.ListCollectionIds.
1556
+ class ListCollectionIdsResponse
1557
+ include Google::Apis::Core::Hashable
1558
+
1559
+ # The collection ids.
1560
+ # Corresponds to the JSON property `collectionIds`
1561
+ # @return [Array<String>]
1562
+ attr_accessor :collection_ids
1563
+
1564
+ # A page token that may be used to continue the list.
1565
+ # Corresponds to the JSON property `nextPageToken`
1566
+ # @return [String]
1567
+ attr_accessor :next_page_token
1568
+
1569
+ def initialize(**args)
1570
+ update!(**args)
1571
+ end
1572
+
1573
+ # Update properties of this object
1574
+ def update!(**args)
1575
+ @collection_ids = args[:collection_ids] if args.key?(:collection_ids)
1576
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1577
+ end
1578
+ end
1579
+
1580
+ # The response for Firestore.ListDocuments.
1581
+ class ListDocumentsResponse
1582
+ include Google::Apis::Core::Hashable
1583
+
1584
+ # The Documents found.
1585
+ # Corresponds to the JSON property `documents`
1586
+ # @return [Array<Google::Apis::FirestoreV1::Document>]
1587
+ attr_accessor :documents
1588
+
1589
+ # The next page token.
1590
+ # Corresponds to the JSON property `nextPageToken`
1591
+ # @return [String]
1592
+ attr_accessor :next_page_token
1593
+
1594
+ def initialize(**args)
1595
+ update!(**args)
1596
+ end
1597
+
1598
+ # Update properties of this object
1599
+ def update!(**args)
1600
+ @documents = args[:documents] if args.key?(:documents)
1601
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1602
+ end
1603
+ end
1604
+
1605
+ # The response message for Locations.ListLocations.
1606
+ class ListLocationsResponse
1607
+ include Google::Apis::Core::Hashable
1608
+
1609
+ # A list of locations that matches the specified filter in the request.
1610
+ # Corresponds to the JSON property `locations`
1611
+ # @return [Array<Google::Apis::FirestoreV1::Location>]
1612
+ attr_accessor :locations
1613
+
1614
+ # The standard List next-page token.
1615
+ # Corresponds to the JSON property `nextPageToken`
1616
+ # @return [String]
1617
+ attr_accessor :next_page_token
1618
+
1619
+ def initialize(**args)
1620
+ update!(**args)
1621
+ end
1622
+
1623
+ # Update properties of this object
1624
+ def update!(**args)
1625
+ @locations = args[:locations] if args.key?(:locations)
1626
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1627
+ end
1628
+ end
1629
+
1630
+ # A request for Firestore.Listen
1631
+ class ListenRequest
1632
+ include Google::Apis::Core::Hashable
1633
+
1634
+ # A specification of a set of documents to listen to.
1635
+ # Corresponds to the JSON property `addTarget`
1636
+ # @return [Google::Apis::FirestoreV1::Target]
1637
+ attr_accessor :add_target
1638
+
1639
+ # Labels associated with this target change.
1640
+ # Corresponds to the JSON property `labels`
1641
+ # @return [Hash<String,String>]
1642
+ attr_accessor :labels
1643
+
1644
+ # The ID of a target to remove from this stream.
1645
+ # Corresponds to the JSON property `removeTarget`
1646
+ # @return [Fixnum]
1647
+ attr_accessor :remove_target
1648
+
1649
+ def initialize(**args)
1650
+ update!(**args)
1651
+ end
1652
+
1653
+ # Update properties of this object
1654
+ def update!(**args)
1655
+ @add_target = args[:add_target] if args.key?(:add_target)
1656
+ @labels = args[:labels] if args.key?(:labels)
1657
+ @remove_target = args[:remove_target] if args.key?(:remove_target)
1658
+ end
1659
+ end
1660
+
1661
+ # The response for Firestore.Listen.
1662
+ class ListenResponse
1663
+ include Google::Apis::Core::Hashable
1664
+
1665
+ # A Document has changed.
1666
+ # May be the result of multiple writes, including deletes, that
1667
+ # ultimately resulted in a new value for the Document.
1668
+ # Multiple DocumentChange messages may be returned for the same logical
1669
+ # change, if multiple targets are affected.
1670
+ # Corresponds to the JSON property `documentChange`
1671
+ # @return [Google::Apis::FirestoreV1::DocumentChange]
1672
+ attr_accessor :document_change
1673
+
1674
+ # A Document has been deleted.
1675
+ # May be the result of multiple writes, including updates, the
1676
+ # last of which deleted the Document.
1677
+ # Multiple DocumentDelete messages may be returned for the same logical
1678
+ # delete, if multiple targets are affected.
1679
+ # Corresponds to the JSON property `documentDelete`
1680
+ # @return [Google::Apis::FirestoreV1::DocumentDelete]
1681
+ attr_accessor :document_delete
1682
+
1683
+ # A Document has been removed from the view of the targets.
1684
+ # Sent if the document is no longer relevant to a target and is out of view.
1685
+ # Can be sent instead of a DocumentDelete or a DocumentChange if the server
1686
+ # can not send the new value of the document.
1687
+ # Multiple DocumentRemove messages may be returned for the same logical
1688
+ # write or delete, if multiple targets are affected.
1689
+ # Corresponds to the JSON property `documentRemove`
1690
+ # @return [Google::Apis::FirestoreV1::DocumentRemove]
1691
+ attr_accessor :document_remove
1692
+
1693
+ # A digest of all the documents that match a given target.
1694
+ # Corresponds to the JSON property `filter`
1695
+ # @return [Google::Apis::FirestoreV1::ExistenceFilter]
1696
+ attr_accessor :filter
1697
+
1698
+ # Targets being watched have changed.
1699
+ # Corresponds to the JSON property `targetChange`
1700
+ # @return [Google::Apis::FirestoreV1::TargetChange]
1701
+ attr_accessor :target_change
1702
+
1703
+ def initialize(**args)
1704
+ update!(**args)
1705
+ end
1706
+
1707
+ # Update properties of this object
1708
+ def update!(**args)
1709
+ @document_change = args[:document_change] if args.key?(:document_change)
1710
+ @document_delete = args[:document_delete] if args.key?(:document_delete)
1711
+ @document_remove = args[:document_remove] if args.key?(:document_remove)
1712
+ @filter = args[:filter] if args.key?(:filter)
1713
+ @target_change = args[:target_change] if args.key?(:target_change)
1714
+ end
1715
+ end
1716
+
1717
+ # A resource that represents Google Cloud Platform location.
1718
+ class Location
1719
+ include Google::Apis::Core::Hashable
1720
+
1721
+ # The friendly name for this location, typically a nearby city name.
1722
+ # For example, "Tokyo".
1723
+ # Corresponds to the JSON property `displayName`
1724
+ # @return [String]
1725
+ attr_accessor :display_name
1726
+
1727
+ # Cross-service attributes for the location. For example
1728
+ # `"cloud.googleapis.com/region": "us-east1"`
1729
+ # Corresponds to the JSON property `labels`
1730
+ # @return [Hash<String,String>]
1731
+ attr_accessor :labels
1732
+
1733
+ # The canonical id for this location. For example: `"us-east1"`.
1734
+ # Corresponds to the JSON property `locationId`
1735
+ # @return [String]
1736
+ attr_accessor :location_id
1737
+
1738
+ # Service-specific metadata. For example the available capacity at the given
1739
+ # location.
1740
+ # Corresponds to the JSON property `metadata`
1741
+ # @return [Hash<String,Object>]
1742
+ attr_accessor :metadata
1743
+
1744
+ # Resource name for the location, which may vary between implementations.
1745
+ # For example: `"projects/example-project/locations/us-east1"`
1746
+ # Corresponds to the JSON property `name`
1747
+ # @return [String]
1748
+ attr_accessor :name
1749
+
1750
+ def initialize(**args)
1751
+ update!(**args)
1752
+ end
1753
+
1754
+ # Update properties of this object
1755
+ def update!(**args)
1756
+ @display_name = args[:display_name] if args.key?(:display_name)
1757
+ @labels = args[:labels] if args.key?(:labels)
1758
+ @location_id = args[:location_id] if args.key?(:location_id)
1759
+ @metadata = args[:metadata] if args.key?(:metadata)
1760
+ @name = args[:name] if args.key?(:name)
1761
+ end
1762
+ end
1763
+
1764
+ # A map value.
1765
+ class MapValue
1766
+ include Google::Apis::Core::Hashable
1767
+
1768
+ # The map's fields.
1769
+ # The map keys represent field names. Field names matching the regular
1770
+ # expression `__.*__` are reserved. Reserved field names are forbidden except
1771
+ # in certain documented contexts. The map keys, represented as UTF-8, must
1772
+ # not exceed 1,500 bytes and cannot be empty.
1773
+ # Corresponds to the JSON property `fields`
1774
+ # @return [Hash<String,Google::Apis::FirestoreV1::Value>]
596
1775
  attr_accessor :fields
597
1776
 
598
- # A page token that may be used to request another page of results. If blank,
599
- # this is the last page.
600
- # Corresponds to the JSON property `nextPageToken`
1777
+ def initialize(**args)
1778
+ update!(**args)
1779
+ end
1780
+
1781
+ # Update properties of this object
1782
+ def update!(**args)
1783
+ @fields = args[:fields] if args.key?(:fields)
1784
+ end
1785
+ end
1786
+
1787
+ # An order on a field.
1788
+ class Order
1789
+ include Google::Apis::Core::Hashable
1790
+
1791
+ # The direction to order by. Defaults to `ASCENDING`.
1792
+ # Corresponds to the JSON property `direction`
601
1793
  # @return [String]
602
- attr_accessor :next_page_token
1794
+ attr_accessor :direction
1795
+
1796
+ # A reference to a field, such as `max(messages.time) as max_time`.
1797
+ # Corresponds to the JSON property `field`
1798
+ # @return [Google::Apis::FirestoreV1::FieldReference]
1799
+ attr_accessor :field
1800
+
1801
+ def initialize(**args)
1802
+ update!(**args)
1803
+ end
1804
+
1805
+ # Update properties of this object
1806
+ def update!(**args)
1807
+ @direction = args[:direction] if args.key?(:direction)
1808
+ @field = args[:field] if args.key?(:field)
1809
+ end
1810
+ end
1811
+
1812
+ # A precondition on a document, used for conditional operations.
1813
+ class Precondition
1814
+ include Google::Apis::Core::Hashable
1815
+
1816
+ # When set to `true`, the target document must exist.
1817
+ # When set to `false`, the target document must not exist.
1818
+ # Corresponds to the JSON property `exists`
1819
+ # @return [Boolean]
1820
+ attr_accessor :exists
1821
+ alias_method :exists?, :exists
1822
+
1823
+ # When set, the target document must exist and have been last updated at
1824
+ # that time.
1825
+ # Corresponds to the JSON property `updateTime`
1826
+ # @return [String]
1827
+ attr_accessor :update_time
1828
+
1829
+ def initialize(**args)
1830
+ update!(**args)
1831
+ end
1832
+
1833
+ # Update properties of this object
1834
+ def update!(**args)
1835
+ @exists = args[:exists] if args.key?(:exists)
1836
+ @update_time = args[:update_time] if args.key?(:update_time)
1837
+ end
1838
+ end
1839
+
1840
+ # The projection of document's fields to return.
1841
+ class Projection
1842
+ include Google::Apis::Core::Hashable
1843
+
1844
+ # The fields to return.
1845
+ # If empty, all fields are returned. To only return the name
1846
+ # of the document, use `['__name__']`.
1847
+ # Corresponds to the JSON property `fields`
1848
+ # @return [Array<Google::Apis::FirestoreV1::FieldReference>]
1849
+ attr_accessor :fields
603
1850
 
604
1851
  def initialize(**args)
605
1852
  update!(**args)
@@ -608,24 +1855,48 @@ module Google
608
1855
  # Update properties of this object
609
1856
  def update!(**args)
610
1857
  @fields = args[:fields] if args.key?(:fields)
611
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
612
1858
  end
613
1859
  end
614
1860
 
615
- # The response for FirestoreAdmin.ListIndexes.
616
- class GoogleFirestoreAdminV1ListIndexesResponse
1861
+ # A target specified by a query.
1862
+ class QueryTarget
617
1863
  include Google::Apis::Core::Hashable
618
1864
 
619
- # The requested indexes.
620
- # Corresponds to the JSON property `indexes`
621
- # @return [Array<Google::Apis::FirestoreV1::GoogleFirestoreAdminV1Index>]
622
- attr_accessor :indexes
1865
+ # The parent resource name. In the format:
1866
+ # `projects/`project_id`/databases/`database_id`/documents` or
1867
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
1868
+ # For example:
1869
+ # `projects/my-project/databases/my-database/documents` or
1870
+ # `projects/my-project/databases/my-database/documents/chatrooms/my-chatroom`
1871
+ # Corresponds to the JSON property `parent`
1872
+ # @return [String]
1873
+ attr_accessor :parent
623
1874
 
624
- # A page token that may be used to request another page of results. If blank,
625
- # this is the last page.
626
- # Corresponds to the JSON property `nextPageToken`
1875
+ # A Firestore query.
1876
+ # Corresponds to the JSON property `structuredQuery`
1877
+ # @return [Google::Apis::FirestoreV1::StructuredQuery]
1878
+ attr_accessor :structured_query
1879
+
1880
+ def initialize(**args)
1881
+ update!(**args)
1882
+ end
1883
+
1884
+ # Update properties of this object
1885
+ def update!(**args)
1886
+ @parent = args[:parent] if args.key?(:parent)
1887
+ @structured_query = args[:structured_query] if args.key?(:structured_query)
1888
+ end
1889
+ end
1890
+
1891
+ # Options for a transaction that can only be used to read documents.
1892
+ class ReadOnly
1893
+ include Google::Apis::Core::Hashable
1894
+
1895
+ # Reads documents at the given time.
1896
+ # This may not be older than 60 seconds.
1897
+ # Corresponds to the JSON property `readTime`
627
1898
  # @return [String]
628
- attr_accessor :next_page_token
1899
+ attr_accessor :read_time
629
1900
 
630
1901
  def initialize(**args)
631
1902
  update!(**args)
@@ -633,14 +1904,196 @@ module Google
633
1904
 
634
1905
  # Update properties of this object
635
1906
  def update!(**args)
636
- @indexes = args[:indexes] if args.key?(:indexes)
637
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1907
+ @read_time = args[:read_time] if args.key?(:read_time)
1908
+ end
1909
+ end
1910
+
1911
+ # Options for a transaction that can be used to read and write documents.
1912
+ class ReadWrite
1913
+ include Google::Apis::Core::Hashable
1914
+
1915
+ # An optional transaction to retry.
1916
+ # Corresponds to the JSON property `retryTransaction`
1917
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
1918
+ # @return [String]
1919
+ attr_accessor :retry_transaction
1920
+
1921
+ def initialize(**args)
1922
+ update!(**args)
1923
+ end
1924
+
1925
+ # Update properties of this object
1926
+ def update!(**args)
1927
+ @retry_transaction = args[:retry_transaction] if args.key?(:retry_transaction)
1928
+ end
1929
+ end
1930
+
1931
+ # The request for Firestore.Rollback.
1932
+ class RollbackRequest
1933
+ include Google::Apis::Core::Hashable
1934
+
1935
+ # The transaction to roll back.
1936
+ # Corresponds to the JSON property `transaction`
1937
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
1938
+ # @return [String]
1939
+ attr_accessor :transaction
1940
+
1941
+ def initialize(**args)
1942
+ update!(**args)
1943
+ end
1944
+
1945
+ # Update properties of this object
1946
+ def update!(**args)
1947
+ @transaction = args[:transaction] if args.key?(:transaction)
1948
+ end
1949
+ end
1950
+
1951
+ # The request for Firestore.RunQuery.
1952
+ class RunQueryRequest
1953
+ include Google::Apis::Core::Hashable
1954
+
1955
+ # Options for creating a new transaction.
1956
+ # Corresponds to the JSON property `newTransaction`
1957
+ # @return [Google::Apis::FirestoreV1::TransactionOptions]
1958
+ attr_accessor :new_transaction
1959
+
1960
+ # Reads documents as they were at the given time.
1961
+ # This may not be older than 60 seconds.
1962
+ # Corresponds to the JSON property `readTime`
1963
+ # @return [String]
1964
+ attr_accessor :read_time
1965
+
1966
+ # A Firestore query.
1967
+ # Corresponds to the JSON property `structuredQuery`
1968
+ # @return [Google::Apis::FirestoreV1::StructuredQuery]
1969
+ attr_accessor :structured_query
1970
+
1971
+ # Reads documents in a transaction.
1972
+ # Corresponds to the JSON property `transaction`
1973
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
1974
+ # @return [String]
1975
+ attr_accessor :transaction
1976
+
1977
+ def initialize(**args)
1978
+ update!(**args)
1979
+ end
1980
+
1981
+ # Update properties of this object
1982
+ def update!(**args)
1983
+ @new_transaction = args[:new_transaction] if args.key?(:new_transaction)
1984
+ @read_time = args[:read_time] if args.key?(:read_time)
1985
+ @structured_query = args[:structured_query] if args.key?(:structured_query)
1986
+ @transaction = args[:transaction] if args.key?(:transaction)
1987
+ end
1988
+ end
1989
+
1990
+ # The response for Firestore.RunQuery.
1991
+ class RunQueryResponse
1992
+ include Google::Apis::Core::Hashable
1993
+
1994
+ # A Firestore document.
1995
+ # Must not exceed 1 MiB - 4 bytes.
1996
+ # Corresponds to the JSON property `document`
1997
+ # @return [Google::Apis::FirestoreV1::Document]
1998
+ attr_accessor :document
1999
+
2000
+ # The time at which the document was read. This may be monotonically
2001
+ # increasing; in this case, the previous documents in the result stream are
2002
+ # guaranteed not to have changed between their `read_time` and this one.
2003
+ # If the query returns no results, a response with `read_time` and no
2004
+ # `document` will be sent, and this represents the time at which the query
2005
+ # was run.
2006
+ # Corresponds to the JSON property `readTime`
2007
+ # @return [String]
2008
+ attr_accessor :read_time
2009
+
2010
+ # The number of results that have been skipped due to an offset between
2011
+ # the last response and the current response.
2012
+ # Corresponds to the JSON property `skippedResults`
2013
+ # @return [Fixnum]
2014
+ attr_accessor :skipped_results
2015
+
2016
+ # The transaction that was started as part of this request.
2017
+ # Can only be set in the first response, and only if
2018
+ # RunQueryRequest.new_transaction was set in the request.
2019
+ # If set, no other fields will be set in this response.
2020
+ # Corresponds to the JSON property `transaction`
2021
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
2022
+ # @return [String]
2023
+ attr_accessor :transaction
2024
+
2025
+ def initialize(**args)
2026
+ update!(**args)
2027
+ end
2028
+
2029
+ # Update properties of this object
2030
+ def update!(**args)
2031
+ @document = args[:document] if args.key?(:document)
2032
+ @read_time = args[:read_time] if args.key?(:read_time)
2033
+ @skipped_results = args[:skipped_results] if args.key?(:skipped_results)
2034
+ @transaction = args[:transaction] if args.key?(:transaction)
638
2035
  end
639
2036
  end
640
2037
 
641
- # The metadata message for google.cloud.location.Location.metadata.
642
- class GoogleFirestoreAdminV1LocationMetadata
643
- include Google::Apis::Core::Hashable
2038
+ # The `Status` type defines a logical error model that is suitable for different
2039
+ # programming environments, including REST APIs and RPC APIs. It is used by
2040
+ # [gRPC](https://github.com/grpc). The error model is designed to be:
2041
+ # - Simple to use and understand for most users
2042
+ # - Flexible enough to meet unexpected needs
2043
+ # # Overview
2044
+ # The `Status` message contains three pieces of data: error code, error message,
2045
+ # and error details. The error code should be an enum value of
2046
+ # google.rpc.Code, but it may accept additional error codes if needed. The
2047
+ # error message should be a developer-facing English message that helps
2048
+ # developers *understand* and *resolve* the error. If a localized user-facing
2049
+ # error message is needed, put the localized message in the error details or
2050
+ # localize it in the client. The optional error details may contain arbitrary
2051
+ # information about the error. There is a predefined set of error detail types
2052
+ # in the package `google.rpc` that can be used for common error conditions.
2053
+ # # Language mapping
2054
+ # The `Status` message is the logical representation of the error model, but it
2055
+ # is not necessarily the actual wire format. When the `Status` message is
2056
+ # exposed in different client libraries and different wire protocols, it can be
2057
+ # mapped differently. For example, it will likely be mapped to some exceptions
2058
+ # in Java, but more likely mapped to some error codes in C.
2059
+ # # Other uses
2060
+ # The error model and the `Status` message can be used in a variety of
2061
+ # environments, either with or without APIs, to provide a
2062
+ # consistent developer experience across different environments.
2063
+ # Example uses of this error model include:
2064
+ # - Partial errors. If a service needs to return partial errors to the client,
2065
+ # it may embed the `Status` in the normal response to indicate the partial
2066
+ # errors.
2067
+ # - Workflow errors. A typical workflow has multiple steps. Each step may
2068
+ # have a `Status` message for error reporting.
2069
+ # - Batch operations. If a client uses batch request and batch response, the
2070
+ # `Status` message should be used directly inside batch response, one for
2071
+ # each error sub-response.
2072
+ # - Asynchronous operations. If an API call embeds asynchronous operation
2073
+ # results in its response, the status of those operations should be
2074
+ # represented directly using the `Status` message.
2075
+ # - Logging. If some API errors are stored in logs, the message `Status` could
2076
+ # be used directly after any stripping needed for security/privacy reasons.
2077
+ class Status
2078
+ include Google::Apis::Core::Hashable
2079
+
2080
+ # The status code, which should be an enum value of google.rpc.Code.
2081
+ # Corresponds to the JSON property `code`
2082
+ # @return [Fixnum]
2083
+ attr_accessor :code
2084
+
2085
+ # A list of messages that carry the error details. There is a common set of
2086
+ # message types for APIs to use.
2087
+ # Corresponds to the JSON property `details`
2088
+ # @return [Array<Hash<String,Object>>]
2089
+ attr_accessor :details
2090
+
2091
+ # A developer-facing error message, which should be in English. Any
2092
+ # user-facing error message should be localized and sent in the
2093
+ # google.rpc.Status.details field, or localized by the client.
2094
+ # Corresponds to the JSON property `message`
2095
+ # @return [String]
2096
+ attr_accessor :message
644
2097
 
645
2098
  def initialize(**args)
646
2099
  update!(**args)
@@ -648,24 +2101,72 @@ module Google
648
2101
 
649
2102
  # Update properties of this object
650
2103
  def update!(**args)
2104
+ @code = args[:code] if args.key?(:code)
2105
+ @details = args[:details] if args.key?(:details)
2106
+ @message = args[:message] if args.key?(:message)
651
2107
  end
652
2108
  end
653
2109
 
654
- # Describes the progress of the operation.
655
- # Unit of work is generic and must be interpreted based on where Progress
656
- # is used.
657
- class GoogleFirestoreAdminV1Progress
2110
+ # A Firestore query.
2111
+ class StructuredQuery
658
2112
  include Google::Apis::Core::Hashable
659
2113
 
660
- # The amount of work completed.
661
- # Corresponds to the JSON property `completedWork`
2114
+ # A position in a query result set.
2115
+ # Corresponds to the JSON property `endAt`
2116
+ # @return [Google::Apis::FirestoreV1::Cursor]
2117
+ attr_accessor :end_at
2118
+
2119
+ # The collections to query.
2120
+ # Corresponds to the JSON property `from`
2121
+ # @return [Array<Google::Apis::FirestoreV1::CollectionSelector>]
2122
+ attr_accessor :from
2123
+
2124
+ # The maximum number of results to return.
2125
+ # Applies after all other constraints.
2126
+ # Must be >= 0 if specified.
2127
+ # Corresponds to the JSON property `limit`
662
2128
  # @return [Fixnum]
663
- attr_accessor :completed_work
2129
+ attr_accessor :limit
664
2130
 
665
- # The amount of work estimated.
666
- # Corresponds to the JSON property `estimatedWork`
2131
+ # The number of results to skip.
2132
+ # Applies before limit, but after all other constraints. Must be >= 0 if
2133
+ # specified.
2134
+ # Corresponds to the JSON property `offset`
667
2135
  # @return [Fixnum]
668
- attr_accessor :estimated_work
2136
+ attr_accessor :offset
2137
+
2138
+ # The order to apply to the query results.
2139
+ # Firestore guarantees a stable ordering through the following rules:
2140
+ # * Any field required to appear in `order_by`, that is not already
2141
+ # specified in `order_by`, is appended to the order in field name order
2142
+ # by default.
2143
+ # * If an order on `__name__` is not specified, it is appended by default.
2144
+ # Fields are appended with the same sort direction as the last order
2145
+ # specified, or 'ASCENDING' if no order was specified. For example:
2146
+ # * `SELECT * FROM Foo ORDER BY A` becomes
2147
+ # `SELECT * FROM Foo ORDER BY A, __name__`
2148
+ # * `SELECT * FROM Foo ORDER BY A DESC` becomes
2149
+ # `SELECT * FROM Foo ORDER BY A DESC, __name__ DESC`
2150
+ # * `SELECT * FROM Foo WHERE A > 1` becomes
2151
+ # `SELECT * FROM Foo WHERE A > 1 ORDER BY A, __name__`
2152
+ # Corresponds to the JSON property `orderBy`
2153
+ # @return [Array<Google::Apis::FirestoreV1::Order>]
2154
+ attr_accessor :order_by
2155
+
2156
+ # The projection of document's fields to return.
2157
+ # Corresponds to the JSON property `select`
2158
+ # @return [Google::Apis::FirestoreV1::Projection]
2159
+ attr_accessor :select
2160
+
2161
+ # A position in a query result set.
2162
+ # Corresponds to the JSON property `startAt`
2163
+ # @return [Google::Apis::FirestoreV1::Cursor]
2164
+ attr_accessor :start_at
2165
+
2166
+ # A filter.
2167
+ # Corresponds to the JSON property `where`
2168
+ # @return [Google::Apis::FirestoreV1::Filter]
2169
+ attr_accessor :where
669
2170
 
670
2171
  def initialize(**args)
671
2172
  update!(**args)
@@ -673,37 +2174,59 @@ module Google
673
2174
 
674
2175
  # Update properties of this object
675
2176
  def update!(**args)
676
- @completed_work = args[:completed_work] if args.key?(:completed_work)
677
- @estimated_work = args[:estimated_work] if args.key?(:estimated_work)
2177
+ @end_at = args[:end_at] if args.key?(:end_at)
2178
+ @from = args[:from] if args.key?(:from)
2179
+ @limit = args[:limit] if args.key?(:limit)
2180
+ @offset = args[:offset] if args.key?(:offset)
2181
+ @order_by = args[:order_by] if args.key?(:order_by)
2182
+ @select = args[:select] if args.key?(:select)
2183
+ @start_at = args[:start_at] if args.key?(:start_at)
2184
+ @where = args[:where] if args.key?(:where)
678
2185
  end
679
2186
  end
680
2187
 
681
- # The request message for Operations.CancelOperation.
682
- class GoogleLongrunningCancelOperationRequest
2188
+ # A specification of a set of documents to listen to.
2189
+ class Target
683
2190
  include Google::Apis::Core::Hashable
684
2191
 
685
- def initialize(**args)
686
- update!(**args)
687
- end
2192
+ # A target specified by a set of documents names.
2193
+ # Corresponds to the JSON property `documents`
2194
+ # @return [Google::Apis::FirestoreV1::DocumentsTarget]
2195
+ attr_accessor :documents
688
2196
 
689
- # Update properties of this object
690
- def update!(**args)
691
- end
692
- end
2197
+ # If the target should be removed once it is current and consistent.
2198
+ # Corresponds to the JSON property `once`
2199
+ # @return [Boolean]
2200
+ attr_accessor :once
2201
+ alias_method :once?, :once
693
2202
 
694
- # The response message for Operations.ListOperations.
695
- class GoogleLongrunningListOperationsResponse
696
- include Google::Apis::Core::Hashable
2203
+ # A target specified by a query.
2204
+ # Corresponds to the JSON property `query`
2205
+ # @return [Google::Apis::FirestoreV1::QueryTarget]
2206
+ attr_accessor :query
697
2207
 
698
- # The standard List next-page token.
699
- # Corresponds to the JSON property `nextPageToken`
2208
+ # Start listening after a specific `read_time`.
2209
+ # The client must know the state of matching documents at this time.
2210
+ # Corresponds to the JSON property `readTime`
700
2211
  # @return [String]
701
- attr_accessor :next_page_token
2212
+ attr_accessor :read_time
702
2213
 
703
- # A list of operations that matches the specified filter in the request.
704
- # Corresponds to the JSON property `operations`
705
- # @return [Array<Google::Apis::FirestoreV1::GoogleLongrunningOperation>]
706
- attr_accessor :operations
2214
+ # A resume token from a prior TargetChange for an identical target.
2215
+ # Using a resume token with a different target is unsupported and may fail.
2216
+ # Corresponds to the JSON property `resumeToken`
2217
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
2218
+ # @return [String]
2219
+ attr_accessor :resume_token
2220
+
2221
+ # A client provided target ID.
2222
+ # If not set, the server will assign an ID for the target.
2223
+ # Used for resuming a target without changing IDs. The IDs can either be
2224
+ # client-assigned or be server-assigned in a previous stream. All targets
2225
+ # with client provided IDs must be added before adding a target that needs
2226
+ # a server-assigned id.
2227
+ # Corresponds to the JSON property `targetId`
2228
+ # @return [Fixnum]
2229
+ attr_accessor :target_id
707
2230
 
708
2231
  def initialize(**args)
709
2232
  update!(**args)
@@ -711,24 +2234,19 @@ module Google
711
2234
 
712
2235
  # Update properties of this object
713
2236
  def update!(**args)
714
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
715
- @operations = args[:operations] if args.key?(:operations)
2237
+ @documents = args[:documents] if args.key?(:documents)
2238
+ @once = args[:once] if args.key?(:once)
2239
+ @query = args[:query] if args.key?(:query)
2240
+ @read_time = args[:read_time] if args.key?(:read_time)
2241
+ @resume_token = args[:resume_token] if args.key?(:resume_token)
2242
+ @target_id = args[:target_id] if args.key?(:target_id)
716
2243
  end
717
2244
  end
718
2245
 
719
- # This resource represents a long-running operation that is the result of a
720
- # network API call.
721
- class GoogleLongrunningOperation
2246
+ # Targets being watched have changed.
2247
+ class TargetChange
722
2248
  include Google::Apis::Core::Hashable
723
2249
 
724
- # If the value is `false`, it means the operation is still in progress.
725
- # If `true`, the operation is completed, and either `error` or `response` is
726
- # available.
727
- # Corresponds to the JSON property `done`
728
- # @return [Boolean]
729
- attr_accessor :done
730
- alias_method :done?, :done
731
-
732
2250
  # The `Status` type defines a logical error model that is suitable for different
733
2251
  # programming environments, including REST APIs and RPC APIs. It is used by
734
2252
  # [gRPC](https://github.com/grpc). The error model is designed to be:
@@ -768,36 +2286,72 @@ module Google
768
2286
  # represented directly using the `Status` message.
769
2287
  # - Logging. If some API errors are stored in logs, the message `Status` could
770
2288
  # be used directly after any stripping needed for security/privacy reasons.
771
- # Corresponds to the JSON property `error`
2289
+ # Corresponds to the JSON property `cause`
772
2290
  # @return [Google::Apis::FirestoreV1::Status]
773
- attr_accessor :error
2291
+ attr_accessor :cause
2292
+
2293
+ # The consistent `read_time` for the given `target_ids` (omitted when the
2294
+ # target_ids are not at a consistent snapshot).
2295
+ # The stream is guaranteed to send a `read_time` with `target_ids` empty
2296
+ # whenever the entire stream reaches a new consistent snapshot. ADD,
2297
+ # CURRENT, and RESET messages are guaranteed to (eventually) result in a
2298
+ # new consistent snapshot (while NO_CHANGE and REMOVE messages are not).
2299
+ # For a given stream, `read_time` is guaranteed to be monotonically
2300
+ # increasing.
2301
+ # Corresponds to the JSON property `readTime`
2302
+ # @return [String]
2303
+ attr_accessor :read_time
774
2304
 
775
- # Service-specific metadata associated with the operation. It typically
776
- # contains progress information and common metadata such as create time.
777
- # Some services might not provide such metadata. Any method that returns a
778
- # long-running operation should document the metadata type, if any.
779
- # Corresponds to the JSON property `metadata`
780
- # @return [Hash<String,Object>]
781
- attr_accessor :metadata
2305
+ # A token that can be used to resume the stream for the given `target_ids`,
2306
+ # or all targets if `target_ids` is empty.
2307
+ # Not set on every target change.
2308
+ # Corresponds to the JSON property `resumeToken`
2309
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
2310
+ # @return [String]
2311
+ attr_accessor :resume_token
782
2312
 
783
- # The server-assigned name, which is only unique within the same service that
784
- # originally returns it. If you use the default HTTP mapping, the
785
- # `name` should have the format of `operations/some/unique/name`.
786
- # Corresponds to the JSON property `name`
2313
+ # The type of change that occurred.
2314
+ # Corresponds to the JSON property `targetChangeType`
787
2315
  # @return [String]
788
- attr_accessor :name
2316
+ attr_accessor :target_change_type
2317
+
2318
+ # The target IDs of targets that have changed.
2319
+ # If empty, the change applies to all targets.
2320
+ # For `target_change_type=ADD`, the order of the target IDs matches the order
2321
+ # of the requests to add the targets. This allows clients to unambiguously
2322
+ # associate server-assigned target IDs with added targets.
2323
+ # For other states, the order of the target IDs is not defined.
2324
+ # Corresponds to the JSON property `targetIds`
2325
+ # @return [Array<Fixnum>]
2326
+ attr_accessor :target_ids
789
2327
 
790
- # The normal response of the operation in case of success. If the original
791
- # method returns no data on success, such as `Delete`, the response is
792
- # `google.protobuf.Empty`. If the original method is standard
793
- # `Get`/`Create`/`Update`, the response should be the resource. For other
794
- # methods, the response should have the type `XxxResponse`, where `Xxx`
795
- # is the original method name. For example, if the original method name
796
- # is `TakeSnapshot()`, the inferred response type is
797
- # `TakeSnapshotResponse`.
798
- # Corresponds to the JSON property `response`
799
- # @return [Hash<String,Object>]
800
- attr_accessor :response
2328
+ def initialize(**args)
2329
+ update!(**args)
2330
+ end
2331
+
2332
+ # Update properties of this object
2333
+ def update!(**args)
2334
+ @cause = args[:cause] if args.key?(:cause)
2335
+ @read_time = args[:read_time] if args.key?(:read_time)
2336
+ @resume_token = args[:resume_token] if args.key?(:resume_token)
2337
+ @target_change_type = args[:target_change_type] if args.key?(:target_change_type)
2338
+ @target_ids = args[:target_ids] if args.key?(:target_ids)
2339
+ end
2340
+ end
2341
+
2342
+ # Options for creating a new transaction.
2343
+ class TransactionOptions
2344
+ include Google::Apis::Core::Hashable
2345
+
2346
+ # Options for a transaction that can only be used to read documents.
2347
+ # Corresponds to the JSON property `readOnly`
2348
+ # @return [Google::Apis::FirestoreV1::ReadOnly]
2349
+ attr_accessor :read_only
2350
+
2351
+ # Options for a transaction that can be used to read and write documents.
2352
+ # Corresponds to the JSON property `readWrite`
2353
+ # @return [Google::Apis::FirestoreV1::ReadWrite]
2354
+ attr_accessor :read_write
801
2355
 
802
2356
  def initialize(**args)
803
2357
  update!(**args)
@@ -805,27 +2359,24 @@ module Google
805
2359
 
806
2360
  # Update properties of this object
807
2361
  def update!(**args)
808
- @done = args[:done] if args.key?(:done)
809
- @error = args[:error] if args.key?(:error)
810
- @metadata = args[:metadata] if args.key?(:metadata)
811
- @name = args[:name] if args.key?(:name)
812
- @response = args[:response] if args.key?(:response)
2362
+ @read_only = args[:read_only] if args.key?(:read_only)
2363
+ @read_write = args[:read_write] if args.key?(:read_write)
813
2364
  end
814
2365
  end
815
2366
 
816
- # The response message for Locations.ListLocations.
817
- class ListLocationsResponse
2367
+ # A filter with a single operand.
2368
+ class UnaryFilter
818
2369
  include Google::Apis::Core::Hashable
819
2370
 
820
- # A list of locations that matches the specified filter in the request.
821
- # Corresponds to the JSON property `locations`
822
- # @return [Array<Google::Apis::FirestoreV1::Location>]
823
- attr_accessor :locations
2371
+ # A reference to a field, such as `max(messages.time) as max_time`.
2372
+ # Corresponds to the JSON property `field`
2373
+ # @return [Google::Apis::FirestoreV1::FieldReference]
2374
+ attr_accessor :field
824
2375
 
825
- # The standard List next-page token.
826
- # Corresponds to the JSON property `nextPageToken`
2376
+ # The unary operator to apply.
2377
+ # Corresponds to the JSON property `op`
827
2378
  # @return [String]
828
- attr_accessor :next_page_token
2379
+ attr_accessor :op
829
2380
 
830
2381
  def initialize(**args)
831
2382
  update!(**args)
@@ -833,43 +2384,198 @@ module Google
833
2384
 
834
2385
  # Update properties of this object
835
2386
  def update!(**args)
836
- @locations = args[:locations] if args.key?(:locations)
837
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
2387
+ @field = args[:field] if args.key?(:field)
2388
+ @op = args[:op] if args.key?(:op)
838
2389
  end
839
2390
  end
840
2391
 
841
- # A resource that represents Google Cloud Platform location.
842
- class Location
2392
+ # A message that can hold any of the supported value types.
2393
+ class Value
843
2394
  include Google::Apis::Core::Hashable
844
2395
 
845
- # The friendly name for this location, typically a nearby city name.
846
- # For example, "Tokyo".
847
- # Corresponds to the JSON property `displayName`
2396
+ # An array value.
2397
+ # Corresponds to the JSON property `arrayValue`
2398
+ # @return [Google::Apis::FirestoreV1::ArrayValue]
2399
+ attr_accessor :array_value
2400
+
2401
+ # A boolean value.
2402
+ # Corresponds to the JSON property `booleanValue`
2403
+ # @return [Boolean]
2404
+ attr_accessor :boolean_value
2405
+ alias_method :boolean_value?, :boolean_value
2406
+
2407
+ # A bytes value.
2408
+ # Must not exceed 1 MiB - 89 bytes.
2409
+ # Only the first 1,500 bytes are considered by queries.
2410
+ # Corresponds to the JSON property `bytesValue`
2411
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
848
2412
  # @return [String]
849
- attr_accessor :display_name
2413
+ attr_accessor :bytes_value
2414
+
2415
+ # A double value.
2416
+ # Corresponds to the JSON property `doubleValue`
2417
+ # @return [Float]
2418
+ attr_accessor :double_value
2419
+
2420
+ # An object representing a latitude/longitude pair. This is expressed as a pair
2421
+ # of doubles representing degrees latitude and degrees longitude. Unless
2422
+ # specified otherwise, this must conform to the
2423
+ # <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84
2424
+ # standard</a>. Values must be within normalized ranges.
2425
+ # Corresponds to the JSON property `geoPointValue`
2426
+ # @return [Google::Apis::FirestoreV1::LatLng]
2427
+ attr_accessor :geo_point_value
2428
+
2429
+ # An integer value.
2430
+ # Corresponds to the JSON property `integerValue`
2431
+ # @return [Fixnum]
2432
+ attr_accessor :integer_value
850
2433
 
851
- # Cross-service attributes for the location. For example
852
- # `"cloud.googleapis.com/region": "us-east1"`
2434
+ # A map value.
2435
+ # Corresponds to the JSON property `mapValue`
2436
+ # @return [Google::Apis::FirestoreV1::MapValue]
2437
+ attr_accessor :map_value
2438
+
2439
+ # A null value.
2440
+ # Corresponds to the JSON property `nullValue`
2441
+ # @return [String]
2442
+ attr_accessor :null_value
2443
+
2444
+ # A reference to a document. For example:
2445
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
2446
+ # Corresponds to the JSON property `referenceValue`
2447
+ # @return [String]
2448
+ attr_accessor :reference_value
2449
+
2450
+ # A string value.
2451
+ # The string, represented as UTF-8, must not exceed 1 MiB - 89 bytes.
2452
+ # Only the first 1,500 bytes of the UTF-8 representation are considered by
2453
+ # queries.
2454
+ # Corresponds to the JSON property `stringValue`
2455
+ # @return [String]
2456
+ attr_accessor :string_value
2457
+
2458
+ # A timestamp value.
2459
+ # Precise only to microseconds. When stored, any additional precision is
2460
+ # rounded down.
2461
+ # Corresponds to the JSON property `timestampValue`
2462
+ # @return [String]
2463
+ attr_accessor :timestamp_value
2464
+
2465
+ def initialize(**args)
2466
+ update!(**args)
2467
+ end
2468
+
2469
+ # Update properties of this object
2470
+ def update!(**args)
2471
+ @array_value = args[:array_value] if args.key?(:array_value)
2472
+ @boolean_value = args[:boolean_value] if args.key?(:boolean_value)
2473
+ @bytes_value = args[:bytes_value] if args.key?(:bytes_value)
2474
+ @double_value = args[:double_value] if args.key?(:double_value)
2475
+ @geo_point_value = args[:geo_point_value] if args.key?(:geo_point_value)
2476
+ @integer_value = args[:integer_value] if args.key?(:integer_value)
2477
+ @map_value = args[:map_value] if args.key?(:map_value)
2478
+ @null_value = args[:null_value] if args.key?(:null_value)
2479
+ @reference_value = args[:reference_value] if args.key?(:reference_value)
2480
+ @string_value = args[:string_value] if args.key?(:string_value)
2481
+ @timestamp_value = args[:timestamp_value] if args.key?(:timestamp_value)
2482
+ end
2483
+ end
2484
+
2485
+ # A write on a document.
2486
+ class Write
2487
+ include Google::Apis::Core::Hashable
2488
+
2489
+ # A precondition on a document, used for conditional operations.
2490
+ # Corresponds to the JSON property `currentDocument`
2491
+ # @return [Google::Apis::FirestoreV1::Precondition]
2492
+ attr_accessor :current_document
2493
+
2494
+ # A document name to delete. In the format:
2495
+ # `projects/`project_id`/databases/`database_id`/documents/`document_path``.
2496
+ # Corresponds to the JSON property `delete`
2497
+ # @return [String]
2498
+ attr_accessor :delete
2499
+
2500
+ # A transformation of a document.
2501
+ # Corresponds to the JSON property `transform`
2502
+ # @return [Google::Apis::FirestoreV1::DocumentTransform]
2503
+ attr_accessor :transform
2504
+
2505
+ # A Firestore document.
2506
+ # Must not exceed 1 MiB - 4 bytes.
2507
+ # Corresponds to the JSON property `update`
2508
+ # @return [Google::Apis::FirestoreV1::Document]
2509
+ attr_accessor :update
2510
+
2511
+ # A set of field paths on a document.
2512
+ # Used to restrict a get or update operation on a document to a subset of its
2513
+ # fields.
2514
+ # This is different from standard field masks, as this is always scoped to a
2515
+ # Document, and takes in account the dynamic nature of Value.
2516
+ # Corresponds to the JSON property `updateMask`
2517
+ # @return [Google::Apis::FirestoreV1::DocumentMask]
2518
+ attr_accessor :update_mask
2519
+
2520
+ def initialize(**args)
2521
+ update!(**args)
2522
+ end
2523
+
2524
+ # Update properties of this object
2525
+ def update!(**args)
2526
+ @current_document = args[:current_document] if args.key?(:current_document)
2527
+ @delete = args[:delete] if args.key?(:delete)
2528
+ @transform = args[:transform] if args.key?(:transform)
2529
+ @update = args[:update] if args.key?(:update)
2530
+ @update_mask = args[:update_mask] if args.key?(:update_mask)
2531
+ end
2532
+ end
2533
+
2534
+ # The request for Firestore.Write.
2535
+ # The first request creates a stream, or resumes an existing one from a token.
2536
+ # When creating a new stream, the server replies with a response containing
2537
+ # only an ID and a token, to use in the next request.
2538
+ # When resuming a stream, the server first streams any responses later than the
2539
+ # given token, then a response containing only an up-to-date token, to use in
2540
+ # the next request.
2541
+ class WriteRequest
2542
+ include Google::Apis::Core::Hashable
2543
+
2544
+ # Labels associated with this write request.
853
2545
  # Corresponds to the JSON property `labels`
854
2546
  # @return [Hash<String,String>]
855
2547
  attr_accessor :labels
856
2548
 
857
- # The canonical id for this location. For example: `"us-east1"`.
858
- # Corresponds to the JSON property `locationId`
2549
+ # The ID of the write stream to resume.
2550
+ # This may only be set in the first message. When left empty, a new write
2551
+ # stream will be created.
2552
+ # Corresponds to the JSON property `streamId`
859
2553
  # @return [String]
860
- attr_accessor :location_id
861
-
862
- # Service-specific metadata. For example the available capacity at the given
863
- # location.
864
- # Corresponds to the JSON property `metadata`
865
- # @return [Hash<String,Object>]
866
- attr_accessor :metadata
867
-
868
- # Resource name for the location, which may vary between implementations.
869
- # For example: `"projects/example-project/locations/us-east1"`
870
- # Corresponds to the JSON property `name`
2554
+ attr_accessor :stream_id
2555
+
2556
+ # A stream token that was previously sent by the server.
2557
+ # The client should set this field to the token from the most recent
2558
+ # WriteResponse it has received. This acknowledges that the client has
2559
+ # received responses up to this token. After sending this token, earlier
2560
+ # tokens may not be used anymore.
2561
+ # The server may close the stream if there are too many unacknowledged
2562
+ # responses.
2563
+ # Leave this field unset when creating a new stream. To resume a stream at
2564
+ # a specific point, set this field and the `stream_id` field.
2565
+ # Leave this field unset when creating a new stream.
2566
+ # Corresponds to the JSON property `streamToken`
2567
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
871
2568
  # @return [String]
872
- attr_accessor :name
2569
+ attr_accessor :stream_token
2570
+
2571
+ # The writes to apply.
2572
+ # Always executed atomically and in order.
2573
+ # This must be empty on the first request.
2574
+ # This may be empty on the last request.
2575
+ # This must not be empty on all other requests.
2576
+ # Corresponds to the JSON property `writes`
2577
+ # @return [Array<Google::Apis::FirestoreV1::Write>]
2578
+ attr_accessor :writes
873
2579
 
874
2580
  def initialize(**args)
875
2581
  update!(**args)
@@ -877,73 +2583,42 @@ module Google
877
2583
 
878
2584
  # Update properties of this object
879
2585
  def update!(**args)
880
- @display_name = args[:display_name] if args.key?(:display_name)
881
2586
  @labels = args[:labels] if args.key?(:labels)
882
- @location_id = args[:location_id] if args.key?(:location_id)
883
- @metadata = args[:metadata] if args.key?(:metadata)
884
- @name = args[:name] if args.key?(:name)
2587
+ @stream_id = args[:stream_id] if args.key?(:stream_id)
2588
+ @stream_token = args[:stream_token] if args.key?(:stream_token)
2589
+ @writes = args[:writes] if args.key?(:writes)
885
2590
  end
886
2591
  end
887
2592
 
888
- # The `Status` type defines a logical error model that is suitable for different
889
- # programming environments, including REST APIs and RPC APIs. It is used by
890
- # [gRPC](https://github.com/grpc). The error model is designed to be:
891
- # - Simple to use and understand for most users
892
- # - Flexible enough to meet unexpected needs
893
- # # Overview
894
- # The `Status` message contains three pieces of data: error code, error message,
895
- # and error details. The error code should be an enum value of
896
- # google.rpc.Code, but it may accept additional error codes if needed. The
897
- # error message should be a developer-facing English message that helps
898
- # developers *understand* and *resolve* the error. If a localized user-facing
899
- # error message is needed, put the localized message in the error details or
900
- # localize it in the client. The optional error details may contain arbitrary
901
- # information about the error. There is a predefined set of error detail types
902
- # in the package `google.rpc` that can be used for common error conditions.
903
- # # Language mapping
904
- # The `Status` message is the logical representation of the error model, but it
905
- # is not necessarily the actual wire format. When the `Status` message is
906
- # exposed in different client libraries and different wire protocols, it can be
907
- # mapped differently. For example, it will likely be mapped to some exceptions
908
- # in Java, but more likely mapped to some error codes in C.
909
- # # Other uses
910
- # The error model and the `Status` message can be used in a variety of
911
- # environments, either with or without APIs, to provide a
912
- # consistent developer experience across different environments.
913
- # Example uses of this error model include:
914
- # - Partial errors. If a service needs to return partial errors to the client,
915
- # it may embed the `Status` in the normal response to indicate the partial
916
- # errors.
917
- # - Workflow errors. A typical workflow has multiple steps. Each step may
918
- # have a `Status` message for error reporting.
919
- # - Batch operations. If a client uses batch request and batch response, the
920
- # `Status` message should be used directly inside batch response, one for
921
- # each error sub-response.
922
- # - Asynchronous operations. If an API call embeds asynchronous operation
923
- # results in its response, the status of those operations should be
924
- # represented directly using the `Status` message.
925
- # - Logging. If some API errors are stored in logs, the message `Status` could
926
- # be used directly after any stripping needed for security/privacy reasons.
927
- class Status
2593
+ # The response for Firestore.Write.
2594
+ class WriteResponse
928
2595
  include Google::Apis::Core::Hashable
929
2596
 
930
- # The status code, which should be an enum value of google.rpc.Code.
931
- # Corresponds to the JSON property `code`
932
- # @return [Fixnum]
933
- attr_accessor :code
2597
+ # The time at which the commit occurred.
2598
+ # Corresponds to the JSON property `commitTime`
2599
+ # @return [String]
2600
+ attr_accessor :commit_time
934
2601
 
935
- # A list of messages that carry the error details. There is a common set of
936
- # message types for APIs to use.
937
- # Corresponds to the JSON property `details`
938
- # @return [Array<Hash<String,Object>>]
939
- attr_accessor :details
2602
+ # The ID of the stream.
2603
+ # Only set on the first message, when a new stream was created.
2604
+ # Corresponds to the JSON property `streamId`
2605
+ # @return [String]
2606
+ attr_accessor :stream_id
940
2607
 
941
- # A developer-facing error message, which should be in English. Any
942
- # user-facing error message should be localized and sent in the
943
- # google.rpc.Status.details field, or localized by the client.
944
- # Corresponds to the JSON property `message`
2608
+ # A token that represents the position of this response in the stream.
2609
+ # This can be used by a client to resume the stream at this point.
2610
+ # This field is always set.
2611
+ # Corresponds to the JSON property `streamToken`
2612
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
945
2613
  # @return [String]
946
- attr_accessor :message
2614
+ attr_accessor :stream_token
2615
+
2616
+ # The result of applying the writes.
2617
+ # This i-th write result corresponds to the i-th write in the
2618
+ # request.
2619
+ # Corresponds to the JSON property `writeResults`
2620
+ # @return [Array<Google::Apis::FirestoreV1::WriteResult>]
2621
+ attr_accessor :write_results
947
2622
 
948
2623
  def initialize(**args)
949
2624
  update!(**args)
@@ -951,9 +2626,39 @@ module Google
951
2626
 
952
2627
  # Update properties of this object
953
2628
  def update!(**args)
954
- @code = args[:code] if args.key?(:code)
955
- @details = args[:details] if args.key?(:details)
956
- @message = args[:message] if args.key?(:message)
2629
+ @commit_time = args[:commit_time] if args.key?(:commit_time)
2630
+ @stream_id = args[:stream_id] if args.key?(:stream_id)
2631
+ @stream_token = args[:stream_token] if args.key?(:stream_token)
2632
+ @write_results = args[:write_results] if args.key?(:write_results)
2633
+ end
2634
+ end
2635
+
2636
+ # The result of applying a write.
2637
+ class WriteResult
2638
+ include Google::Apis::Core::Hashable
2639
+
2640
+ # The results of applying each DocumentTransform.FieldTransform, in the
2641
+ # same order.
2642
+ # Corresponds to the JSON property `transformResults`
2643
+ # @return [Array<Google::Apis::FirestoreV1::Value>]
2644
+ attr_accessor :transform_results
2645
+
2646
+ # The last update time of the document after applying the write. Not set
2647
+ # after a `delete`.
2648
+ # If the write did not actually change the document, this will be the
2649
+ # previous update_time.
2650
+ # Corresponds to the JSON property `updateTime`
2651
+ # @return [String]
2652
+ attr_accessor :update_time
2653
+
2654
+ def initialize(**args)
2655
+ update!(**args)
2656
+ end
2657
+
2658
+ # Update properties of this object
2659
+ def update!(**args)
2660
+ @transform_results = args[:transform_results] if args.key?(:transform_results)
2661
+ @update_time = args[:update_time] if args.key?(:update_time)
957
2662
  end
958
2663
  end
959
2664
  end