google-cloud-ai_platform-v1 0.61.0 → 0.63.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (196) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/lib/google/cloud/ai_platform/v1/bindings_override.rb +24 -0
  4. data/lib/google/cloud/ai_platform/v1/dataset_service/client.rb +11 -0
  5. data/lib/google/cloud/ai_platform/v1/dataset_service/operations.rb +7 -0
  6. data/lib/google/cloud/ai_platform/v1/dataset_service/rest/client.rb +11 -0
  7. data/lib/google/cloud/ai_platform/v1/dataset_service/rest/operations.rb +70 -0
  8. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/client.rb +7 -0
  9. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/operations.rb +7 -0
  10. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/rest/client.rb +7 -0
  11. data/lib/google/cloud/ai_platform/v1/deployment_resource_pool_service/rest/operations.rb +70 -0
  12. data/lib/google/cloud/ai_platform/v1/endpoint_service/client.rb +7 -0
  13. data/lib/google/cloud/ai_platform/v1/endpoint_service/operations.rb +7 -0
  14. data/lib/google/cloud/ai_platform/v1/endpoint_service/rest/client.rb +7 -0
  15. data/lib/google/cloud/ai_platform/v1/endpoint_service/rest/operations.rb +70 -0
  16. data/lib/google/cloud/ai_platform/v1/evaluation_service/client.rb +57 -0
  17. data/lib/google/cloud/ai_platform/v1/evaluation_service/rest/client.rb +57 -0
  18. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/client.rb +7 -0
  19. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/operations.rb +7 -0
  20. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/rest/client.rb +7 -0
  21. data/lib/google/cloud/ai_platform/v1/feature_online_store_admin_service/rest/operations.rb +70 -0
  22. data/lib/google/cloud/ai_platform/v1/feature_online_store_service/client.rb +7 -0
  23. data/lib/google/cloud/ai_platform/v1/feature_online_store_service/rest/client.rb +7 -0
  24. data/lib/google/cloud/ai_platform/v1/feature_registry_service/client.rb +7 -0
  25. data/lib/google/cloud/ai_platform/v1/feature_registry_service/operations.rb +7 -0
  26. data/lib/google/cloud/ai_platform/v1/feature_registry_service/rest/client.rb +7 -0
  27. data/lib/google/cloud/ai_platform/v1/feature_registry_service/rest/operations.rb +70 -0
  28. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service/client.rb +7 -0
  29. data/lib/google/cloud/ai_platform/v1/featurestore_online_serving_service/rest/client.rb +7 -0
  30. data/lib/google/cloud/ai_platform/v1/featurestore_service/client.rb +26 -0
  31. data/lib/google/cloud/ai_platform/v1/featurestore_service/operations.rb +7 -0
  32. data/lib/google/cloud/ai_platform/v1/featurestore_service/rest/client.rb +26 -0
  33. data/lib/google/cloud/ai_platform/v1/featurestore_service/rest/operations.rb +70 -0
  34. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service/client.rb +879 -0
  35. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service/credentials.rb +47 -0
  36. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service/paths.rb +88 -0
  37. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service/rest/client.rb +827 -0
  38. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service/rest/service_stub.rb +388 -0
  39. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service/rest.rb +53 -0
  40. data/lib/google/cloud/ai_platform/v1/gen_ai_cache_service.rb +55 -0
  41. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/client.rb +7 -0
  42. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/operations.rb +7 -0
  43. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/rest/client.rb +7 -0
  44. data/lib/google/cloud/ai_platform/v1/gen_ai_tuning_service/rest/operations.rb +70 -0
  45. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/client.rb +7 -0
  46. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/operations.rb +7 -0
  47. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/rest/client.rb +7 -0
  48. data/lib/google/cloud/ai_platform/v1/index_endpoint_service/rest/operations.rb +70 -0
  49. data/lib/google/cloud/ai_platform/v1/index_service/client.rb +7 -0
  50. data/lib/google/cloud/ai_platform/v1/index_service/operations.rb +7 -0
  51. data/lib/google/cloud/ai_platform/v1/index_service/rest/client.rb +7 -0
  52. data/lib/google/cloud/ai_platform/v1/index_service/rest/operations.rb +70 -0
  53. data/lib/google/cloud/ai_platform/v1/job_service/client.rb +7 -0
  54. data/lib/google/cloud/ai_platform/v1/job_service/operations.rb +7 -0
  55. data/lib/google/cloud/ai_platform/v1/job_service/rest/client.rb +7 -0
  56. data/lib/google/cloud/ai_platform/v1/job_service/rest/operations.rb +70 -0
  57. data/lib/google/cloud/ai_platform/v1/llm_utility_service/client.rb +7 -0
  58. data/lib/google/cloud/ai_platform/v1/llm_utility_service/rest/client.rb +7 -0
  59. data/lib/google/cloud/ai_platform/v1/match_service/client.rb +7 -0
  60. data/lib/google/cloud/ai_platform/v1/match_service/rest/client.rb +7 -0
  61. data/lib/google/cloud/ai_platform/v1/metadata_service/client.rb +7 -0
  62. data/lib/google/cloud/ai_platform/v1/metadata_service/operations.rb +7 -0
  63. data/lib/google/cloud/ai_platform/v1/metadata_service/rest/client.rb +7 -0
  64. data/lib/google/cloud/ai_platform/v1/metadata_service/rest/operations.rb +70 -0
  65. data/lib/google/cloud/ai_platform/v1/migration_service/client.rb +7 -0
  66. data/lib/google/cloud/ai_platform/v1/migration_service/operations.rb +7 -0
  67. data/lib/google/cloud/ai_platform/v1/migration_service/rest/client.rb +7 -0
  68. data/lib/google/cloud/ai_platform/v1/migration_service/rest/operations.rb +70 -0
  69. data/lib/google/cloud/ai_platform/v1/model_garden_service/client.rb +7 -0
  70. data/lib/google/cloud/ai_platform/v1/model_garden_service/rest/client.rb +7 -0
  71. data/lib/google/cloud/ai_platform/v1/model_service/client.rb +124 -0
  72. data/lib/google/cloud/ai_platform/v1/model_service/operations.rb +7 -0
  73. data/lib/google/cloud/ai_platform/v1/model_service/rest/client.rb +117 -0
  74. data/lib/google/cloud/ai_platform/v1/model_service/rest/operations.rb +70 -0
  75. data/lib/google/cloud/ai_platform/v1/model_service/rest/service_stub.rb +61 -0
  76. data/lib/google/cloud/ai_platform/v1/notebook_service/client.rb +7 -0
  77. data/lib/google/cloud/ai_platform/v1/notebook_service/operations.rb +7 -0
  78. data/lib/google/cloud/ai_platform/v1/notebook_service/rest/client.rb +7 -0
  79. data/lib/google/cloud/ai_platform/v1/notebook_service/rest/operations.rb +70 -0
  80. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/client.rb +7 -0
  81. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/operations.rb +7 -0
  82. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/rest/client.rb +7 -0
  83. data/lib/google/cloud/ai_platform/v1/persistent_resource_service/rest/operations.rb +70 -0
  84. data/lib/google/cloud/ai_platform/v1/pipeline_service/client.rb +7 -0
  85. data/lib/google/cloud/ai_platform/v1/pipeline_service/operations.rb +7 -0
  86. data/lib/google/cloud/ai_platform/v1/pipeline_service/rest/client.rb +7 -0
  87. data/lib/google/cloud/ai_platform/v1/pipeline_service/rest/operations.rb +70 -0
  88. data/lib/google/cloud/ai_platform/v1/prediction_service/client.rb +21 -2
  89. data/lib/google/cloud/ai_platform/v1/prediction_service/paths.rb +19 -0
  90. data/lib/google/cloud/ai_platform/v1/prediction_service/rest/client.rb +21 -2
  91. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service/client.rb +600 -0
  92. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service/credentials.rb +47 -0
  93. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service/paths.rb +52 -0
  94. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service/rest/client.rb +571 -0
  95. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service/rest/service_stub.rb +199 -0
  96. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service/rest.rb +53 -0
  97. data/lib/google/cloud/ai_platform/v1/reasoning_engine_execution_service.rb +55 -0
  98. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/client.rb +921 -0
  99. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/credentials.rb +47 -0
  100. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/operations.rb +821 -0
  101. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/paths.rb +69 -0
  102. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/rest/client.rb +869 -0
  103. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/rest/operations.rb +4328 -0
  104. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/rest/service_stub.rb +388 -0
  105. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service/rest.rb +54 -0
  106. data/lib/google/cloud/ai_platform/v1/reasoning_engine_service.rb +56 -0
  107. data/lib/google/cloud/ai_platform/v1/rest.rb +3 -0
  108. data/lib/google/cloud/ai_platform/v1/schedule_service/client.rb +7 -0
  109. data/lib/google/cloud/ai_platform/v1/schedule_service/operations.rb +7 -0
  110. data/lib/google/cloud/ai_platform/v1/schedule_service/rest/client.rb +7 -0
  111. data/lib/google/cloud/ai_platform/v1/schedule_service/rest/operations.rb +70 -0
  112. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/client.rb +7 -0
  113. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/operations.rb +7 -0
  114. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/rest/client.rb +7 -0
  115. data/lib/google/cloud/ai_platform/v1/specialist_pool_service/rest/operations.rb +70 -0
  116. data/lib/google/cloud/ai_platform/v1/tensorboard_service/client.rb +7 -0
  117. data/lib/google/cloud/ai_platform/v1/tensorboard_service/operations.rb +7 -0
  118. data/lib/google/cloud/ai_platform/v1/tensorboard_service/rest/client.rb +7 -0
  119. data/lib/google/cloud/ai_platform/v1/tensorboard_service/rest/operations.rb +70 -0
  120. data/lib/google/cloud/ai_platform/v1/version.rb +1 -1
  121. data/lib/google/cloud/ai_platform/v1/vertex_rag_data_service/client.rb +7 -0
  122. data/lib/google/cloud/ai_platform/v1/vertex_rag_data_service/operations.rb +7 -0
  123. data/lib/google/cloud/ai_platform/v1/vertex_rag_data_service/rest/client.rb +7 -0
  124. data/lib/google/cloud/ai_platform/v1/vertex_rag_data_service/rest/operations.rb +70 -0
  125. data/lib/google/cloud/ai_platform/v1/vertex_rag_service/client.rb +7 -0
  126. data/lib/google/cloud/ai_platform/v1/vertex_rag_service/rest/client.rb +7 -0
  127. data/lib/google/cloud/ai_platform/v1/vizier_service/client.rb +7 -0
  128. data/lib/google/cloud/ai_platform/v1/vizier_service/operations.rb +7 -0
  129. data/lib/google/cloud/ai_platform/v1/vizier_service/rest/client.rb +7 -0
  130. data/lib/google/cloud/ai_platform/v1/vizier_service/rest/operations.rb +70 -0
  131. data/lib/google/cloud/ai_platform/v1.rb +3 -0
  132. data/lib/google/cloud/aiplatform/v1/cached_content_pb.rb +54 -0
  133. data/lib/google/cloud/aiplatform/v1/content_pb.rb +3 -1
  134. data/lib/google/cloud/aiplatform/v1/endpoint_pb.rb +5 -2
  135. data/lib/google/cloud/aiplatform/v1/feature_view_pb.rb +2 -1
  136. data/lib/google/cloud/aiplatform/v1/gen_ai_cache_service_pb.rb +57 -0
  137. data/lib/google/cloud/aiplatform/v1/gen_ai_cache_service_services_pb.rb +54 -0
  138. data/lib/google/cloud/aiplatform/v1/model_pb.rb +1 -1
  139. data/lib/google/cloud/aiplatform/v1/model_service_pb.rb +4 -1
  140. data/lib/google/cloud/aiplatform/v1/model_service_services_pb.rb +2 -0
  141. data/lib/google/cloud/aiplatform/v1/notebook_runtime_pb.rb +1 -1
  142. data/lib/google/cloud/aiplatform/v1/prediction_service_pb.rb +1 -1
  143. data/lib/google/cloud/aiplatform/v1/reasoning_engine_execution_service_pb.rb +52 -0
  144. data/lib/google/cloud/aiplatform/v1/reasoning_engine_execution_service_services_pb.rb +47 -0
  145. data/lib/google/cloud/aiplatform/v1/reasoning_engine_pb.rb +51 -0
  146. data/lib/google/cloud/aiplatform/v1/reasoning_engine_service_pb.rb +62 -0
  147. data/lib/google/cloud/aiplatform/v1/reasoning_engine_service_services_pb.rb +53 -0
  148. data/lib/google/cloud/aiplatform/v1/tool_pb.rb +9 -1
  149. data/proto_docs/google/cloud/aiplatform/v1/batch_prediction_job.rb +12 -0
  150. data/proto_docs/google/cloud/aiplatform/v1/cached_content.rb +105 -0
  151. data/proto_docs/google/cloud/aiplatform/v1/content.rb +61 -0
  152. data/proto_docs/google/cloud/aiplatform/v1/custom_job.rb +4 -0
  153. data/proto_docs/google/cloud/aiplatform/v1/data_labeling_job.rb +4 -0
  154. data/proto_docs/google/cloud/aiplatform/v1/dataset.rb +4 -0
  155. data/proto_docs/google/cloud/aiplatform/v1/dataset_service.rb +4 -0
  156. data/proto_docs/google/cloud/aiplatform/v1/endpoint.rb +57 -5
  157. data/proto_docs/google/cloud/aiplatform/v1/evaluation_service.rb +100 -0
  158. data/proto_docs/google/cloud/aiplatform/v1/explanation.rb +16 -0
  159. data/proto_docs/google/cloud/aiplatform/v1/explanation_metadata.rb +4 -0
  160. data/proto_docs/google/cloud/aiplatform/v1/feature_online_store.rb +4 -0
  161. data/proto_docs/google/cloud/aiplatform/v1/feature_online_store_service.rb +18 -0
  162. data/proto_docs/google/cloud/aiplatform/v1/feature_view.rb +39 -0
  163. data/proto_docs/google/cloud/aiplatform/v1/featurestore_online_service.rb +24 -0
  164. data/proto_docs/google/cloud/aiplatform/v1/featurestore_service.rb +29 -0
  165. data/proto_docs/google/cloud/aiplatform/v1/gen_ai_cache_service.rb +108 -0
  166. data/proto_docs/google/cloud/aiplatform/v1/index.rb +6 -0
  167. data/proto_docs/google/cloud/aiplatform/v1/io.rb +8 -0
  168. data/proto_docs/google/cloud/aiplatform/v1/migratable_resource.rb +8 -0
  169. data/proto_docs/google/cloud/aiplatform/v1/migration_service.rb +18 -0
  170. data/proto_docs/google/cloud/aiplatform/v1/model.rb +7 -0
  171. data/proto_docs/google/cloud/aiplatform/v1/model_evaluation_slice.rb +10 -0
  172. data/proto_docs/google/cloud/aiplatform/v1/model_monitoring.rb +10 -0
  173. data/proto_docs/google/cloud/aiplatform/v1/model_service.rb +63 -0
  174. data/proto_docs/google/cloud/aiplatform/v1/notebook_execution_job.rb +14 -0
  175. data/proto_docs/google/cloud/aiplatform/v1/notebook_runtime.rb +42 -2
  176. data/proto_docs/google/cloud/aiplatform/v1/pipeline_job.rb +4 -0
  177. data/proto_docs/google/cloud/aiplatform/v1/prediction_service.rb +24 -0
  178. data/proto_docs/google/cloud/aiplatform/v1/publisher_model.rb +14 -0
  179. data/proto_docs/google/cloud/aiplatform/v1/reasoning_engine.rb +87 -0
  180. data/proto_docs/google/cloud/aiplatform/v1/reasoning_engine_execution_service.rb +73 -0
  181. data/proto_docs/google/cloud/aiplatform/v1/reasoning_engine_service.rb +136 -0
  182. data/proto_docs/google/cloud/aiplatform/v1/schedule.rb +4 -0
  183. data/proto_docs/google/cloud/aiplatform/v1/schema/trainingjob/definition/automl_tables.rb +12 -0
  184. data/proto_docs/google/cloud/aiplatform/v1/study.rb +24 -0
  185. data/proto_docs/google/cloud/aiplatform/v1/tensorboard_data.rb +6 -0
  186. data/proto_docs/google/cloud/aiplatform/v1/tool.rb +95 -0
  187. data/proto_docs/google/cloud/aiplatform/v1/training_pipeline.rb +14 -0
  188. data/proto_docs/google/cloud/aiplatform/v1/tuning_job.rb +6 -0
  189. data/proto_docs/google/cloud/aiplatform/v1/user_action_reference.rb +4 -0
  190. data/proto_docs/google/cloud/aiplatform/v1/value.rb +6 -0
  191. data/proto_docs/google/cloud/aiplatform/v1/vertex_rag_data.rb +32 -0
  192. data/proto_docs/google/cloud/aiplatform/v1/vertex_rag_data_service.rb +8 -0
  193. data/proto_docs/google/longrunning/operations.rb +4 -0
  194. data/proto_docs/google/protobuf/struct.rb +12 -0
  195. data/proto_docs/google/type/latlng.rb +38 -0
  196. metadata +43 -9
@@ -0,0 +1,869 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2025 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "google/cloud/errors"
20
+ require "google/cloud/aiplatform/v1/reasoning_engine_service_pb"
21
+ require "google/cloud/ai_platform/v1/reasoning_engine_service/rest/service_stub"
22
+ require "google/cloud/location/rest"
23
+ require "google/iam/v1/rest"
24
+
25
+ module Google
26
+ module Cloud
27
+ module AIPlatform
28
+ module V1
29
+ module ReasoningEngineService
30
+ module Rest
31
+ ##
32
+ # REST client for the ReasoningEngineService service.
33
+ #
34
+ # A service for managing Vertex AI's Reasoning Engines.
35
+ #
36
+ class Client
37
+ # @private
38
+ API_VERSION = ""
39
+
40
+ # @private
41
+ DEFAULT_ENDPOINT_TEMPLATE = "aiplatform.$UNIVERSE_DOMAIN$"
42
+
43
+ include Paths
44
+
45
+ # @private
46
+ attr_reader :reasoning_engine_service_stub
47
+
48
+ ##
49
+ # Configure the ReasoningEngineService Client class.
50
+ #
51
+ # See {::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client::Configuration}
52
+ # for a description of the configuration fields.
53
+ #
54
+ # @example
55
+ #
56
+ # # Modify the configuration for all ReasoningEngineService clients
57
+ # ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.configure do |config|
58
+ # config.timeout = 10.0
59
+ # end
60
+ #
61
+ # @yield [config] Configure the Client client.
62
+ # @yieldparam config [Client::Configuration]
63
+ #
64
+ # @return [Client::Configuration]
65
+ #
66
+ def self.configure
67
+ @configure ||= begin
68
+ namespace = ["Google", "Cloud", "AIPlatform", "V1"]
69
+ parent_config = while namespace.any?
70
+ parent_name = namespace.join "::"
71
+ parent_const = const_get parent_name
72
+ break parent_const.configure if parent_const.respond_to? :configure
73
+ namespace.pop
74
+ end
75
+ default_config = Client::Configuration.new parent_config
76
+
77
+ default_config
78
+ end
79
+ yield @configure if block_given?
80
+ @configure
81
+ end
82
+
83
+ ##
84
+ # Configure the ReasoningEngineService Client instance.
85
+ #
86
+ # The configuration is set to the derived mode, meaning that values can be changed,
87
+ # but structural changes (adding new fields, etc.) are not allowed. Structural changes
88
+ # should be made on {Client.configure}.
89
+ #
90
+ # See {::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client::Configuration}
91
+ # for a description of the configuration fields.
92
+ #
93
+ # @yield [config] Configure the Client client.
94
+ # @yieldparam config [Client::Configuration]
95
+ #
96
+ # @return [Client::Configuration]
97
+ #
98
+ def configure
99
+ yield @config if block_given?
100
+ @config
101
+ end
102
+
103
+ ##
104
+ # The effective universe domain
105
+ #
106
+ # @return [String]
107
+ #
108
+ def universe_domain
109
+ @reasoning_engine_service_stub.universe_domain
110
+ end
111
+
112
+ ##
113
+ # Create a new ReasoningEngineService REST client object.
114
+ #
115
+ # @example
116
+ #
117
+ # # Create a client using the default configuration
118
+ # client = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new
119
+ #
120
+ # # Create a client using a custom configuration
121
+ # client = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new do |config|
122
+ # config.timeout = 10.0
123
+ # end
124
+ #
125
+ # @yield [config] Configure the ReasoningEngineService client.
126
+ # @yieldparam config [Client::Configuration]
127
+ #
128
+ def initialize
129
+ # Create the configuration object
130
+ @config = Configuration.new Client.configure
131
+
132
+ # Yield the configuration if needed
133
+ yield @config if block_given?
134
+
135
+ # Create credentials
136
+ credentials = @config.credentials
137
+ # Use self-signed JWT if the endpoint is unchanged from default,
138
+ # but only if the default endpoint does not have a region prefix.
139
+ enable_self_signed_jwt = @config.endpoint.nil? ||
140
+ (@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
141
+ !@config.endpoint.split(".").first.include?("-"))
142
+ credentials ||= Credentials.default scope: @config.scope,
143
+ enable_self_signed_jwt: enable_self_signed_jwt
144
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
145
+ credentials = Credentials.new credentials, scope: @config.scope
146
+ end
147
+
148
+ @quota_project_id = @config.quota_project
149
+ @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
150
+
151
+ @operations_client = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Operations.new do |config|
152
+ config.credentials = credentials
153
+ config.quota_project = @quota_project_id
154
+ config.endpoint = @config.endpoint
155
+ config.universe_domain = @config.universe_domain
156
+ end
157
+
158
+ @reasoning_engine_service_stub = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::ServiceStub.new(
159
+ endpoint: @config.endpoint,
160
+ endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
161
+ universe_domain: @config.universe_domain,
162
+ credentials: credentials,
163
+ logger: @config.logger
164
+ )
165
+
166
+ @reasoning_engine_service_stub.logger(stub: true)&.info do |entry|
167
+ entry.set_system_name
168
+ entry.set_service
169
+ entry.message = "Created client for #{entry.service}"
170
+ entry.set_credentials_fields credentials
171
+ entry.set "customEndpoint", @config.endpoint if @config.endpoint
172
+ entry.set "defaultTimeout", @config.timeout if @config.timeout
173
+ entry.set "quotaProject", @quota_project_id if @quota_project_id
174
+ end
175
+
176
+ @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config|
177
+ config.credentials = credentials
178
+ config.quota_project = @quota_project_id
179
+ config.endpoint = @reasoning_engine_service_stub.endpoint
180
+ config.universe_domain = @reasoning_engine_service_stub.universe_domain
181
+ config.bindings_override = @config.bindings_override
182
+ config.logger = @reasoning_engine_service_stub.logger if config.respond_to? :logger=
183
+ end
184
+
185
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
186
+ config.credentials = credentials
187
+ config.quota_project = @quota_project_id
188
+ config.endpoint = @reasoning_engine_service_stub.endpoint
189
+ config.universe_domain = @reasoning_engine_service_stub.universe_domain
190
+ config.bindings_override = @config.bindings_override
191
+ config.logger = @reasoning_engine_service_stub.logger if config.respond_to? :logger=
192
+ end
193
+ end
194
+
195
+ ##
196
+ # Get the associated client for long-running operations.
197
+ #
198
+ # @return [::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Operations]
199
+ #
200
+ attr_reader :operations_client
201
+
202
+ ##
203
+ # Get the associated client for mix-in of the Locations.
204
+ #
205
+ # @return [Google::Cloud::Location::Locations::Rest::Client]
206
+ #
207
+ attr_reader :location_client
208
+
209
+ ##
210
+ # Get the associated client for mix-in of the IAMPolicy.
211
+ #
212
+ # @return [Google::Iam::V1::IAMPolicy::Rest::Client]
213
+ #
214
+ attr_reader :iam_policy_client
215
+
216
+ ##
217
+ # The logger used for request/response debug logging.
218
+ #
219
+ # @return [Logger]
220
+ #
221
+ def logger
222
+ @reasoning_engine_service_stub.logger
223
+ end
224
+
225
+ # Service calls
226
+
227
+ ##
228
+ # Creates a reasoning engine.
229
+ #
230
+ # @overload create_reasoning_engine(request, options = nil)
231
+ # Pass arguments to `create_reasoning_engine` via a request object, either of type
232
+ # {::Google::Cloud::AIPlatform::V1::CreateReasoningEngineRequest} or an equivalent Hash.
233
+ #
234
+ # @param request [::Google::Cloud::AIPlatform::V1::CreateReasoningEngineRequest, ::Hash]
235
+ # A request object representing the call parameters. Required. To specify no
236
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
237
+ # @param options [::Gapic::CallOptions, ::Hash]
238
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
239
+ #
240
+ # @overload create_reasoning_engine(parent: nil, reasoning_engine: nil)
241
+ # Pass arguments to `create_reasoning_engine` via keyword arguments. Note that at
242
+ # least one keyword argument is required. To specify no parameters, or to keep all
243
+ # the default parameter values, pass an empty Hash as a request object (see above).
244
+ #
245
+ # @param parent [::String]
246
+ # Required. The resource name of the Location to create the ReasoningEngine
247
+ # in. Format: `projects/{project}/locations/{location}`
248
+ # @param reasoning_engine [::Google::Cloud::AIPlatform::V1::ReasoningEngine, ::Hash]
249
+ # Required. The ReasoningEngine to create.
250
+ # @yield [result, operation] Access the result along with the TransportOperation object
251
+ # @yieldparam result [::Gapic::Operation]
252
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
253
+ #
254
+ # @return [::Gapic::Operation]
255
+ #
256
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
257
+ #
258
+ # @example Basic example
259
+ # require "google/cloud/ai_platform/v1"
260
+ #
261
+ # # Create a client object. The client can be reused for multiple calls.
262
+ # client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new
263
+ #
264
+ # # Create a request. To set request fields, pass in keyword arguments.
265
+ # request = Google::Cloud::AIPlatform::V1::CreateReasoningEngineRequest.new
266
+ #
267
+ # # Call the create_reasoning_engine method.
268
+ # result = client.create_reasoning_engine request
269
+ #
270
+ # # The returned object is of type Gapic::Operation. You can use it to
271
+ # # check the status of an operation, cancel it, or wait for results.
272
+ # # Here is how to wait for a response.
273
+ # result.wait_until_done! timeout: 60
274
+ # if result.response?
275
+ # p result.response
276
+ # else
277
+ # puts "No response received."
278
+ # end
279
+ #
280
+ def create_reasoning_engine request, options = nil
281
+ raise ::ArgumentError, "request must be provided" if request.nil?
282
+
283
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::CreateReasoningEngineRequest
284
+
285
+ # Converts hash and nil to an options object
286
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
287
+
288
+ # Customize the options with defaults
289
+ call_metadata = @config.rpcs.create_reasoning_engine.metadata.to_h
290
+
291
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
292
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
293
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
294
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION,
295
+ transports_version_send: [:rest]
296
+
297
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
298
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
299
+
300
+ options.apply_defaults timeout: @config.rpcs.create_reasoning_engine.timeout,
301
+ metadata: call_metadata,
302
+ retry_policy: @config.rpcs.create_reasoning_engine.retry_policy
303
+
304
+ options.apply_defaults timeout: @config.timeout,
305
+ metadata: @config.metadata,
306
+ retry_policy: @config.retry_policy
307
+
308
+ @reasoning_engine_service_stub.create_reasoning_engine request, options do |result, operation|
309
+ result = ::Gapic::Operation.new result, @operations_client, options: options
310
+ yield result, operation if block_given?
311
+ throw :response, result
312
+ end
313
+ rescue ::Gapic::Rest::Error => e
314
+ raise ::Google::Cloud::Error.from_error(e)
315
+ end
316
+
317
+ ##
318
+ # Gets a reasoning engine.
319
+ #
320
+ # @overload get_reasoning_engine(request, options = nil)
321
+ # Pass arguments to `get_reasoning_engine` via a request object, either of type
322
+ # {::Google::Cloud::AIPlatform::V1::GetReasoningEngineRequest} or an equivalent Hash.
323
+ #
324
+ # @param request [::Google::Cloud::AIPlatform::V1::GetReasoningEngineRequest, ::Hash]
325
+ # A request object representing the call parameters. Required. To specify no
326
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
327
+ # @param options [::Gapic::CallOptions, ::Hash]
328
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
329
+ #
330
+ # @overload get_reasoning_engine(name: nil)
331
+ # Pass arguments to `get_reasoning_engine` via keyword arguments. Note that at
332
+ # least one keyword argument is required. To specify no parameters, or to keep all
333
+ # the default parameter values, pass an empty Hash as a request object (see above).
334
+ #
335
+ # @param name [::String]
336
+ # Required. The name of the ReasoningEngine resource.
337
+ # Format:
338
+ # `projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
339
+ # @yield [result, operation] Access the result along with the TransportOperation object
340
+ # @yieldparam result [::Google::Cloud::AIPlatform::V1::ReasoningEngine]
341
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
342
+ #
343
+ # @return [::Google::Cloud::AIPlatform::V1::ReasoningEngine]
344
+ #
345
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
346
+ #
347
+ # @example Basic example
348
+ # require "google/cloud/ai_platform/v1"
349
+ #
350
+ # # Create a client object. The client can be reused for multiple calls.
351
+ # client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new
352
+ #
353
+ # # Create a request. To set request fields, pass in keyword arguments.
354
+ # request = Google::Cloud::AIPlatform::V1::GetReasoningEngineRequest.new
355
+ #
356
+ # # Call the get_reasoning_engine method.
357
+ # result = client.get_reasoning_engine request
358
+ #
359
+ # # The returned object is of type Google::Cloud::AIPlatform::V1::ReasoningEngine.
360
+ # p result
361
+ #
362
+ def get_reasoning_engine request, options = nil
363
+ raise ::ArgumentError, "request must be provided" if request.nil?
364
+
365
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::GetReasoningEngineRequest
366
+
367
+ # Converts hash and nil to an options object
368
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
369
+
370
+ # Customize the options with defaults
371
+ call_metadata = @config.rpcs.get_reasoning_engine.metadata.to_h
372
+
373
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
374
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
375
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
376
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION,
377
+ transports_version_send: [:rest]
378
+
379
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
380
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
381
+
382
+ options.apply_defaults timeout: @config.rpcs.get_reasoning_engine.timeout,
383
+ metadata: call_metadata,
384
+ retry_policy: @config.rpcs.get_reasoning_engine.retry_policy
385
+
386
+ options.apply_defaults timeout: @config.timeout,
387
+ metadata: @config.metadata,
388
+ retry_policy: @config.retry_policy
389
+
390
+ @reasoning_engine_service_stub.get_reasoning_engine request, options do |result, operation|
391
+ yield result, operation if block_given?
392
+ end
393
+ rescue ::Gapic::Rest::Error => e
394
+ raise ::Google::Cloud::Error.from_error(e)
395
+ end
396
+
397
+ ##
398
+ # Lists reasoning engines in a location.
399
+ #
400
+ # @overload list_reasoning_engines(request, options = nil)
401
+ # Pass arguments to `list_reasoning_engines` via a request object, either of type
402
+ # {::Google::Cloud::AIPlatform::V1::ListReasoningEnginesRequest} or an equivalent Hash.
403
+ #
404
+ # @param request [::Google::Cloud::AIPlatform::V1::ListReasoningEnginesRequest, ::Hash]
405
+ # A request object representing the call parameters. Required. To specify no
406
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
407
+ # @param options [::Gapic::CallOptions, ::Hash]
408
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
409
+ #
410
+ # @overload list_reasoning_engines(parent: nil, filter: nil, page_size: nil, page_token: nil)
411
+ # Pass arguments to `list_reasoning_engines` via keyword arguments. Note that at
412
+ # least one keyword argument is required. To specify no parameters, or to keep all
413
+ # the default parameter values, pass an empty Hash as a request object (see above).
414
+ #
415
+ # @param parent [::String]
416
+ # Required. The resource name of the Location to list the ReasoningEngines
417
+ # from. Format: `projects/{project}/locations/{location}`
418
+ # @param filter [::String]
419
+ # Optional. The standard list filter.
420
+ # More detail in [AIP-160](https://google.aip.dev/160).
421
+ # @param page_size [::Integer]
422
+ # Optional. The standard list page size.
423
+ # @param page_token [::String]
424
+ # Optional. The standard list page token.
425
+ # @yield [result, operation] Access the result along with the TransportOperation object
426
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::ReasoningEngine>]
427
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
428
+ #
429
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::AIPlatform::V1::ReasoningEngine>]
430
+ #
431
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
432
+ #
433
+ # @example Basic example
434
+ # require "google/cloud/ai_platform/v1"
435
+ #
436
+ # # Create a client object. The client can be reused for multiple calls.
437
+ # client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new
438
+ #
439
+ # # Create a request. To set request fields, pass in keyword arguments.
440
+ # request = Google::Cloud::AIPlatform::V1::ListReasoningEnginesRequest.new
441
+ #
442
+ # # Call the list_reasoning_engines method.
443
+ # result = client.list_reasoning_engines request
444
+ #
445
+ # # The returned object is of type Gapic::PagedEnumerable. You can iterate
446
+ # # over elements, and API calls will be issued to fetch pages as needed.
447
+ # result.each do |item|
448
+ # # Each element is of type ::Google::Cloud::AIPlatform::V1::ReasoningEngine.
449
+ # p item
450
+ # end
451
+ #
452
+ def list_reasoning_engines request, options = nil
453
+ raise ::ArgumentError, "request must be provided" if request.nil?
454
+
455
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::ListReasoningEnginesRequest
456
+
457
+ # Converts hash and nil to an options object
458
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
459
+
460
+ # Customize the options with defaults
461
+ call_metadata = @config.rpcs.list_reasoning_engines.metadata.to_h
462
+
463
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
464
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
465
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
466
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION,
467
+ transports_version_send: [:rest]
468
+
469
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
470
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
471
+
472
+ options.apply_defaults timeout: @config.rpcs.list_reasoning_engines.timeout,
473
+ metadata: call_metadata,
474
+ retry_policy: @config.rpcs.list_reasoning_engines.retry_policy
475
+
476
+ options.apply_defaults timeout: @config.timeout,
477
+ metadata: @config.metadata,
478
+ retry_policy: @config.retry_policy
479
+
480
+ @reasoning_engine_service_stub.list_reasoning_engines request, options do |result, operation|
481
+ result = ::Gapic::Rest::PagedEnumerable.new @reasoning_engine_service_stub, :list_reasoning_engines, "reasoning_engines", request, result, options
482
+ yield result, operation if block_given?
483
+ throw :response, result
484
+ end
485
+ rescue ::Gapic::Rest::Error => e
486
+ raise ::Google::Cloud::Error.from_error(e)
487
+ end
488
+
489
+ ##
490
+ # Updates a reasoning engine.
491
+ #
492
+ # @overload update_reasoning_engine(request, options = nil)
493
+ # Pass arguments to `update_reasoning_engine` via a request object, either of type
494
+ # {::Google::Cloud::AIPlatform::V1::UpdateReasoningEngineRequest} or an equivalent Hash.
495
+ #
496
+ # @param request [::Google::Cloud::AIPlatform::V1::UpdateReasoningEngineRequest, ::Hash]
497
+ # A request object representing the call parameters. Required. To specify no
498
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
499
+ # @param options [::Gapic::CallOptions, ::Hash]
500
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
501
+ #
502
+ # @overload update_reasoning_engine(reasoning_engine: nil, update_mask: nil)
503
+ # Pass arguments to `update_reasoning_engine` via keyword arguments. Note that at
504
+ # least one keyword argument is required. To specify no parameters, or to keep all
505
+ # the default parameter values, pass an empty Hash as a request object (see above).
506
+ #
507
+ # @param reasoning_engine [::Google::Cloud::AIPlatform::V1::ReasoningEngine, ::Hash]
508
+ # Required. The ReasoningEngine which replaces the resource on the server.
509
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
510
+ # Optional. Mask specifying which fields to update.
511
+ # @yield [result, operation] Access the result along with the TransportOperation object
512
+ # @yieldparam result [::Gapic::Operation]
513
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
514
+ #
515
+ # @return [::Gapic::Operation]
516
+ #
517
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
518
+ #
519
+ # @example Basic example
520
+ # require "google/cloud/ai_platform/v1"
521
+ #
522
+ # # Create a client object. The client can be reused for multiple calls.
523
+ # client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new
524
+ #
525
+ # # Create a request. To set request fields, pass in keyword arguments.
526
+ # request = Google::Cloud::AIPlatform::V1::UpdateReasoningEngineRequest.new
527
+ #
528
+ # # Call the update_reasoning_engine method.
529
+ # result = client.update_reasoning_engine request
530
+ #
531
+ # # The returned object is of type Gapic::Operation. You can use it to
532
+ # # check the status of an operation, cancel it, or wait for results.
533
+ # # Here is how to wait for a response.
534
+ # result.wait_until_done! timeout: 60
535
+ # if result.response?
536
+ # p result.response
537
+ # else
538
+ # puts "No response received."
539
+ # end
540
+ #
541
+ def update_reasoning_engine request, options = nil
542
+ raise ::ArgumentError, "request must be provided" if request.nil?
543
+
544
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::UpdateReasoningEngineRequest
545
+
546
+ # Converts hash and nil to an options object
547
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
548
+
549
+ # Customize the options with defaults
550
+ call_metadata = @config.rpcs.update_reasoning_engine.metadata.to_h
551
+
552
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
553
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
554
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
555
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION,
556
+ transports_version_send: [:rest]
557
+
558
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
559
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
560
+
561
+ options.apply_defaults timeout: @config.rpcs.update_reasoning_engine.timeout,
562
+ metadata: call_metadata,
563
+ retry_policy: @config.rpcs.update_reasoning_engine.retry_policy
564
+
565
+ options.apply_defaults timeout: @config.timeout,
566
+ metadata: @config.metadata,
567
+ retry_policy: @config.retry_policy
568
+
569
+ @reasoning_engine_service_stub.update_reasoning_engine request, options do |result, operation|
570
+ result = ::Gapic::Operation.new result, @operations_client, options: options
571
+ yield result, operation if block_given?
572
+ throw :response, result
573
+ end
574
+ rescue ::Gapic::Rest::Error => e
575
+ raise ::Google::Cloud::Error.from_error(e)
576
+ end
577
+
578
+ ##
579
+ # Deletes a reasoning engine.
580
+ #
581
+ # @overload delete_reasoning_engine(request, options = nil)
582
+ # Pass arguments to `delete_reasoning_engine` via a request object, either of type
583
+ # {::Google::Cloud::AIPlatform::V1::DeleteReasoningEngineRequest} or an equivalent Hash.
584
+ #
585
+ # @param request [::Google::Cloud::AIPlatform::V1::DeleteReasoningEngineRequest, ::Hash]
586
+ # A request object representing the call parameters. Required. To specify no
587
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
588
+ # @param options [::Gapic::CallOptions, ::Hash]
589
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
590
+ #
591
+ # @overload delete_reasoning_engine(name: nil)
592
+ # Pass arguments to `delete_reasoning_engine` via keyword arguments. Note that at
593
+ # least one keyword argument is required. To specify no parameters, or to keep all
594
+ # the default parameter values, pass an empty Hash as a request object (see above).
595
+ #
596
+ # @param name [::String]
597
+ # Required. The name of the ReasoningEngine resource to be deleted.
598
+ # Format:
599
+ # `projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}`
600
+ # @yield [result, operation] Access the result along with the TransportOperation object
601
+ # @yieldparam result [::Gapic::Operation]
602
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
603
+ #
604
+ # @return [::Gapic::Operation]
605
+ #
606
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
607
+ #
608
+ # @example Basic example
609
+ # require "google/cloud/ai_platform/v1"
610
+ #
611
+ # # Create a client object. The client can be reused for multiple calls.
612
+ # client = Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new
613
+ #
614
+ # # Create a request. To set request fields, pass in keyword arguments.
615
+ # request = Google::Cloud::AIPlatform::V1::DeleteReasoningEngineRequest.new
616
+ #
617
+ # # Call the delete_reasoning_engine method.
618
+ # result = client.delete_reasoning_engine request
619
+ #
620
+ # # The returned object is of type Gapic::Operation. You can use it to
621
+ # # check the status of an operation, cancel it, or wait for results.
622
+ # # Here is how to wait for a response.
623
+ # result.wait_until_done! timeout: 60
624
+ # if result.response?
625
+ # p result.response
626
+ # else
627
+ # puts "No response received."
628
+ # end
629
+ #
630
+ def delete_reasoning_engine request, options = nil
631
+ raise ::ArgumentError, "request must be provided" if request.nil?
632
+
633
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AIPlatform::V1::DeleteReasoningEngineRequest
634
+
635
+ # Converts hash and nil to an options object
636
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
637
+
638
+ # Customize the options with defaults
639
+ call_metadata = @config.rpcs.delete_reasoning_engine.metadata.to_h
640
+
641
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
642
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
643
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
644
+ gapic_version: ::Google::Cloud::AIPlatform::V1::VERSION,
645
+ transports_version_send: [:rest]
646
+
647
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
648
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
649
+
650
+ options.apply_defaults timeout: @config.rpcs.delete_reasoning_engine.timeout,
651
+ metadata: call_metadata,
652
+ retry_policy: @config.rpcs.delete_reasoning_engine.retry_policy
653
+
654
+ options.apply_defaults timeout: @config.timeout,
655
+ metadata: @config.metadata,
656
+ retry_policy: @config.retry_policy
657
+
658
+ @reasoning_engine_service_stub.delete_reasoning_engine request, options do |result, operation|
659
+ result = ::Gapic::Operation.new result, @operations_client, options: options
660
+ yield result, operation if block_given?
661
+ throw :response, result
662
+ end
663
+ rescue ::Gapic::Rest::Error => e
664
+ raise ::Google::Cloud::Error.from_error(e)
665
+ end
666
+
667
+ ##
668
+ # Configuration class for the ReasoningEngineService REST API.
669
+ #
670
+ # This class represents the configuration for ReasoningEngineService REST,
671
+ # providing control over timeouts, retry behavior, logging, transport
672
+ # parameters, and other low-level controls. Certain parameters can also be
673
+ # applied individually to specific RPCs. See
674
+ # {::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client::Configuration::Rpcs}
675
+ # for a list of RPCs that can be configured independently.
676
+ #
677
+ # Configuration can be applied globally to all clients, or to a single client
678
+ # on construction.
679
+ #
680
+ # @example
681
+ #
682
+ # # Modify the global config, setting the timeout for
683
+ # # create_reasoning_engine to 20 seconds,
684
+ # # and all remaining timeouts to 10 seconds.
685
+ # ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.configure do |config|
686
+ # config.timeout = 10.0
687
+ # config.rpcs.create_reasoning_engine.timeout = 20.0
688
+ # end
689
+ #
690
+ # # Apply the above configuration only to a new client.
691
+ # client = ::Google::Cloud::AIPlatform::V1::ReasoningEngineService::Rest::Client.new do |config|
692
+ # config.timeout = 10.0
693
+ # config.rpcs.create_reasoning_engine.timeout = 20.0
694
+ # end
695
+ #
696
+ # @!attribute [rw] endpoint
697
+ # A custom service endpoint, as a hostname or hostname:port. The default is
698
+ # nil, indicating to use the default endpoint in the current universe domain.
699
+ # @return [::String,nil]
700
+ # @!attribute [rw] credentials
701
+ # Credentials to send with calls. You may provide any of the following types:
702
+ # * (`String`) The path to a service account key file in JSON format
703
+ # * (`Hash`) A service account key as a Hash
704
+ # * (`Google::Auth::Credentials`) A googleauth credentials object
705
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
706
+ # * (`Signet::OAuth2::Client`) A signet oauth2 client object
707
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
708
+ # * (`nil`) indicating no credentials
709
+ #
710
+ # Warning: If you accept a credential configuration (JSON file or Hash) from an
711
+ # external source for authentication to Google Cloud, you must validate it before
712
+ # providing it to a Google API client library. Providing an unvalidated credential
713
+ # configuration to Google APIs can compromise the security of your systems and data.
714
+ # For more information, refer to [Validate credential configurations from external
715
+ # sources](https://cloud.google.com/docs/authentication/external/externally-sourced-credentials).
716
+ # @return [::Object]
717
+ # @!attribute [rw] scope
718
+ # The OAuth scopes
719
+ # @return [::Array<::String>]
720
+ # @!attribute [rw] lib_name
721
+ # The library name as recorded in instrumentation and logging
722
+ # @return [::String]
723
+ # @!attribute [rw] lib_version
724
+ # The library version as recorded in instrumentation and logging
725
+ # @return [::String]
726
+ # @!attribute [rw] timeout
727
+ # The call timeout in seconds.
728
+ # @return [::Numeric]
729
+ # @!attribute [rw] metadata
730
+ # Additional headers to be sent with the call.
731
+ # @return [::Hash{::Symbol=>::String}]
732
+ # @!attribute [rw] retry_policy
733
+ # The retry policy. The value is a hash with the following keys:
734
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
735
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
736
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
737
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
738
+ # trigger a retry.
739
+ # @return [::Hash]
740
+ # @!attribute [rw] quota_project
741
+ # A separate project against which to charge quota.
742
+ # @return [::String]
743
+ # @!attribute [rw] universe_domain
744
+ # The universe domain within which to make requests. This determines the
745
+ # default endpoint URL. The default value of nil uses the environment
746
+ # universe (usually the default "googleapis.com" universe).
747
+ # @return [::String,nil]
748
+ # @!attribute [rw] logger
749
+ # A custom logger to use for request/response debug logging, or the value
750
+ # `:default` (the default) to construct a default logger, or `nil` to
751
+ # explicitly disable logging.
752
+ # @return [::Logger,:default,nil]
753
+ #
754
+ class Configuration
755
+ extend ::Gapic::Config
756
+
757
+ # @private
758
+ # The endpoint specific to the default "googleapis.com" universe. Deprecated.
759
+ DEFAULT_ENDPOINT = "aiplatform.googleapis.com"
760
+
761
+ config_attr :endpoint, nil, ::String, nil
762
+ config_attr :credentials, nil do |value|
763
+ allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
764
+ allowed.any? { |klass| klass === value }
765
+ end
766
+ config_attr :scope, nil, ::String, ::Array, nil
767
+ config_attr :lib_name, nil, ::String, nil
768
+ config_attr :lib_version, nil, ::String, nil
769
+ config_attr :timeout, nil, ::Numeric, nil
770
+ config_attr :metadata, nil, ::Hash, nil
771
+ config_attr :retry_policy, nil, ::Hash, ::Proc, nil
772
+ config_attr :quota_project, nil, ::String, nil
773
+ config_attr :universe_domain, nil, ::String, nil
774
+
775
+ # @private
776
+ # Overrides for http bindings for the RPCs of this service
777
+ # are only used when this service is used as mixin, and only
778
+ # by the host service.
779
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
780
+ config_attr :bindings_override, {}, ::Hash, nil
781
+ config_attr :logger, :default, ::Logger, nil, :default
782
+
783
+ # @private
784
+ def initialize parent_config = nil
785
+ @parent_config = parent_config unless parent_config.nil?
786
+
787
+ yield self if block_given?
788
+ end
789
+
790
+ ##
791
+ # Configurations for individual RPCs
792
+ # @return [Rpcs]
793
+ #
794
+ def rpcs
795
+ @rpcs ||= begin
796
+ parent_rpcs = nil
797
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
798
+ Rpcs.new parent_rpcs
799
+ end
800
+ end
801
+
802
+ ##
803
+ # Configuration RPC class for the ReasoningEngineService API.
804
+ #
805
+ # Includes fields providing the configuration for each RPC in this service.
806
+ # Each configuration object is of type `Gapic::Config::Method` and includes
807
+ # the following configuration fields:
808
+ #
809
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
810
+ # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers
811
+ # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
812
+ # include the following keys:
813
+ # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
814
+ # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
815
+ # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
816
+ # * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
817
+ # trigger a retry.
818
+ #
819
+ class Rpcs
820
+ ##
821
+ # RPC-specific configuration for `create_reasoning_engine`
822
+ # @return [::Gapic::Config::Method]
823
+ #
824
+ attr_reader :create_reasoning_engine
825
+ ##
826
+ # RPC-specific configuration for `get_reasoning_engine`
827
+ # @return [::Gapic::Config::Method]
828
+ #
829
+ attr_reader :get_reasoning_engine
830
+ ##
831
+ # RPC-specific configuration for `list_reasoning_engines`
832
+ # @return [::Gapic::Config::Method]
833
+ #
834
+ attr_reader :list_reasoning_engines
835
+ ##
836
+ # RPC-specific configuration for `update_reasoning_engine`
837
+ # @return [::Gapic::Config::Method]
838
+ #
839
+ attr_reader :update_reasoning_engine
840
+ ##
841
+ # RPC-specific configuration for `delete_reasoning_engine`
842
+ # @return [::Gapic::Config::Method]
843
+ #
844
+ attr_reader :delete_reasoning_engine
845
+
846
+ # @private
847
+ def initialize parent_rpcs = nil
848
+ create_reasoning_engine_config = parent_rpcs.create_reasoning_engine if parent_rpcs.respond_to? :create_reasoning_engine
849
+ @create_reasoning_engine = ::Gapic::Config::Method.new create_reasoning_engine_config
850
+ get_reasoning_engine_config = parent_rpcs.get_reasoning_engine if parent_rpcs.respond_to? :get_reasoning_engine
851
+ @get_reasoning_engine = ::Gapic::Config::Method.new get_reasoning_engine_config
852
+ list_reasoning_engines_config = parent_rpcs.list_reasoning_engines if parent_rpcs.respond_to? :list_reasoning_engines
853
+ @list_reasoning_engines = ::Gapic::Config::Method.new list_reasoning_engines_config
854
+ update_reasoning_engine_config = parent_rpcs.update_reasoning_engine if parent_rpcs.respond_to? :update_reasoning_engine
855
+ @update_reasoning_engine = ::Gapic::Config::Method.new update_reasoning_engine_config
856
+ delete_reasoning_engine_config = parent_rpcs.delete_reasoning_engine if parent_rpcs.respond_to? :delete_reasoning_engine
857
+ @delete_reasoning_engine = ::Gapic::Config::Method.new delete_reasoning_engine_config
858
+
859
+ yield self if block_given?
860
+ end
861
+ end
862
+ end
863
+ end
864
+ end
865
+ end
866
+ end
867
+ end
868
+ end
869
+ end