google-apis-agentregistry_v1 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,1091 @@
1
+ # Copyright 2020 Google LLC
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 AgentregistryV1
23
+ # Agent Registry API
24
+ #
25
+ # Agent Registry is a centralized, unified catalog that lets you store, discover,
26
+ # and govern Model Context Protocol (MCP) servers, tools, and AI agents within
27
+ # Google Cloud.
28
+ #
29
+ # @example
30
+ # require 'google/apis/agentregistry_v1'
31
+ #
32
+ # Agentregistry = Google::Apis::AgentregistryV1 # Alias the module
33
+ # service = Agentregistry::AgentRegistryService.new
34
+ #
35
+ # @see https://docs.cloud.google.com/agent-registry/overview
36
+ class AgentRegistryService < Google::Apis::Core::BaseService
37
+ DEFAULT_ENDPOINT_TEMPLATE = "https://agentregistry.$UNIVERSE_DOMAIN$/"
38
+
39
+ # @return [String]
40
+ # API key. Your API key identifies your project and provides you with API access,
41
+ # quota, and reports. Required unless you provide an OAuth 2.0 token.
42
+ attr_accessor :key
43
+
44
+ # @return [String]
45
+ # Available to use for quota purposes for server-side applications. Can be any
46
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
47
+ attr_accessor :quota_user
48
+
49
+ def initialize
50
+ super(DEFAULT_ENDPOINT_TEMPLATE, '',
51
+ client_name: 'google-apis-agentregistry_v1',
52
+ client_version: Google::Apis::AgentregistryV1::GEM_VERSION)
53
+ @batch_path = 'batch'
54
+ end
55
+
56
+ # Gets information about a location.
57
+ # @param [String] name
58
+ # Resource name for the location.
59
+ # @param [String] fields
60
+ # Selector specifying which fields to include in a partial response.
61
+ # @param [String] quota_user
62
+ # Available to use for quota purposes for server-side applications. Can be any
63
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
64
+ # @param [Google::Apis::RequestOptions] options
65
+ # Request-specific options
66
+ #
67
+ # @yield [result, err] Result & error if block supplied
68
+ # @yieldparam result [Google::Apis::AgentregistryV1::Location] parsed result object
69
+ # @yieldparam err [StandardError] error object if request failed
70
+ #
71
+ # @return [Google::Apis::AgentregistryV1::Location]
72
+ #
73
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
74
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
75
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
76
+ def get_project_location(name, fields: nil, quota_user: nil, options: nil, &block)
77
+ command = make_simple_command(:get, 'v1/{+name}', options)
78
+ command.response_representation = Google::Apis::AgentregistryV1::Location::Representation
79
+ command.response_class = Google::Apis::AgentregistryV1::Location
80
+ command.params['name'] = name unless name.nil?
81
+ command.query['fields'] = fields unless fields.nil?
82
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
83
+ execute_or_queue_command(command, &block)
84
+ end
85
+
86
+ # Lists information about the supported locations for this service. This method
87
+ # lists locations based on the resource scope provided in the
88
+ # ListLocationsRequest.name field: * **Global locations**: If `name` is empty,
89
+ # the method lists the public locations available to all projects. * **Project-
90
+ # specific locations**: If `name` follows the format `projects/`project``, the
91
+ # method lists locations visible to that specific project. This includes public,
92
+ # private, or other project-specific locations enabled for the project. For gRPC
93
+ # and client library implementations, the resource name is passed as the `name`
94
+ # field. For direct service calls, the resource name is incorporated into the
95
+ # request path based on the specific service implementation and version.
96
+ # @param [String] name
97
+ # The resource that owns the locations collection, if applicable.
98
+ # @param [Array<String>, String] extra_location_types
99
+ # Optional. Do not use this field unless explicitly documented otherwise. This
100
+ # is primarily for internal usage.
101
+ # @param [String] filter
102
+ # A filter to narrow down results to a preferred subset. The filtering language
103
+ # accepts strings like `"displayName=tokyo"`, and is documented in more detail
104
+ # in [AIP-160](https://google.aip.dev/160).
105
+ # @param [Fixnum] page_size
106
+ # The maximum number of results to return. If not set, the service selects a
107
+ # default.
108
+ # @param [String] page_token
109
+ # A page token received from the `next_page_token` field in the response. Send
110
+ # that page token to receive the subsequent page.
111
+ # @param [String] fields
112
+ # Selector specifying which fields to include in a partial response.
113
+ # @param [String] quota_user
114
+ # Available to use for quota purposes for server-side applications. Can be any
115
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
116
+ # @param [Google::Apis::RequestOptions] options
117
+ # Request-specific options
118
+ #
119
+ # @yield [result, err] Result & error if block supplied
120
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListLocationsResponse] parsed result object
121
+ # @yieldparam err [StandardError] error object if request failed
122
+ #
123
+ # @return [Google::Apis::AgentregistryV1::ListLocationsResponse]
124
+ #
125
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
126
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
127
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
128
+ def list_project_locations(name, extra_location_types: nil, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
129
+ command = make_simple_command(:get, 'v1/{+name}/locations', options)
130
+ command.response_representation = Google::Apis::AgentregistryV1::ListLocationsResponse::Representation
131
+ command.response_class = Google::Apis::AgentregistryV1::ListLocationsResponse
132
+ command.params['name'] = name unless name.nil?
133
+ command.query['extraLocationTypes'] = extra_location_types unless extra_location_types.nil?
134
+ command.query['filter'] = filter unless filter.nil?
135
+ command.query['pageSize'] = page_size unless page_size.nil?
136
+ command.query['pageToken'] = page_token unless page_token.nil?
137
+ command.query['fields'] = fields unless fields.nil?
138
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
139
+ execute_or_queue_command(command, &block)
140
+ end
141
+
142
+ # Gets details of a single Agent.
143
+ # @param [String] name
144
+ # Required. Name of the resource
145
+ # @param [String] fields
146
+ # Selector specifying which fields to include in a partial response.
147
+ # @param [String] quota_user
148
+ # Available to use for quota purposes for server-side applications. Can be any
149
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
150
+ # @param [Google::Apis::RequestOptions] options
151
+ # Request-specific options
152
+ #
153
+ # @yield [result, err] Result & error if block supplied
154
+ # @yieldparam result [Google::Apis::AgentregistryV1::Agent] parsed result object
155
+ # @yieldparam err [StandardError] error object if request failed
156
+ #
157
+ # @return [Google::Apis::AgentregistryV1::Agent]
158
+ #
159
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
160
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
161
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
162
+ def get_project_location_agent(name, fields: nil, quota_user: nil, options: nil, &block)
163
+ command = make_simple_command(:get, 'v1/{+name}', options)
164
+ command.response_representation = Google::Apis::AgentregistryV1::Agent::Representation
165
+ command.response_class = Google::Apis::AgentregistryV1::Agent
166
+ command.params['name'] = name unless name.nil?
167
+ command.query['fields'] = fields unless fields.nil?
168
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
169
+ execute_or_queue_command(command, &block)
170
+ end
171
+
172
+ # Lists Agents in a given project and location.
173
+ # @param [String] parent
174
+ # Required. Parent value for ListAgentsRequest
175
+ # @param [String] filter
176
+ # Optional. Filtering results
177
+ # @param [String] order_by
178
+ # Optional. Hint for how to order the results
179
+ # @param [Fixnum] page_size
180
+ # Optional. Requested page size. Server may return fewer items than requested.
181
+ # If unspecified, server will pick an appropriate default.
182
+ # @param [String] page_token
183
+ # Optional. A token identifying a page of results the server should return.
184
+ # @param [String] fields
185
+ # Selector specifying which fields to include in a partial response.
186
+ # @param [String] quota_user
187
+ # Available to use for quota purposes for server-side applications. Can be any
188
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
189
+ # @param [Google::Apis::RequestOptions] options
190
+ # Request-specific options
191
+ #
192
+ # @yield [result, err] Result & error if block supplied
193
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListAgentsResponse] parsed result object
194
+ # @yieldparam err [StandardError] error object if request failed
195
+ #
196
+ # @return [Google::Apis::AgentregistryV1::ListAgentsResponse]
197
+ #
198
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
199
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
200
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
201
+ def list_project_location_agents(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
202
+ command = make_simple_command(:get, 'v1/{+parent}/agents', options)
203
+ command.response_representation = Google::Apis::AgentregistryV1::ListAgentsResponse::Representation
204
+ command.response_class = Google::Apis::AgentregistryV1::ListAgentsResponse
205
+ command.params['parent'] = parent unless parent.nil?
206
+ command.query['filter'] = filter unless filter.nil?
207
+ command.query['orderBy'] = order_by unless order_by.nil?
208
+ command.query['pageSize'] = page_size unless page_size.nil?
209
+ command.query['pageToken'] = page_token unless page_token.nil?
210
+ command.query['fields'] = fields unless fields.nil?
211
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
212
+ execute_or_queue_command(command, &block)
213
+ end
214
+
215
+ # Searches Agents in a given project and location.
216
+ # @param [String] parent
217
+ # Required. Parent value for SearchAgentsRequest. Format: `projects/`project`/
218
+ # locations/`location``.
219
+ # @param [Google::Apis::AgentregistryV1::SearchAgentsRequest] search_agents_request_object
220
+ # @param [String] fields
221
+ # Selector specifying which fields to include in a partial response.
222
+ # @param [String] quota_user
223
+ # Available to use for quota purposes for server-side applications. Can be any
224
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
225
+ # @param [Google::Apis::RequestOptions] options
226
+ # Request-specific options
227
+ #
228
+ # @yield [result, err] Result & error if block supplied
229
+ # @yieldparam result [Google::Apis::AgentregistryV1::SearchAgentsResponse] parsed result object
230
+ # @yieldparam err [StandardError] error object if request failed
231
+ #
232
+ # @return [Google::Apis::AgentregistryV1::SearchAgentsResponse]
233
+ #
234
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
235
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
236
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
237
+ def search_agents(parent, search_agents_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
238
+ command = make_simple_command(:post, 'v1/{+parent}/agents:search', options)
239
+ command.request_representation = Google::Apis::AgentregistryV1::SearchAgentsRequest::Representation
240
+ command.request_object = search_agents_request_object
241
+ command.response_representation = Google::Apis::AgentregistryV1::SearchAgentsResponse::Representation
242
+ command.response_class = Google::Apis::AgentregistryV1::SearchAgentsResponse
243
+ command.params['parent'] = parent unless parent.nil?
244
+ command.query['fields'] = fields unless fields.nil?
245
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
246
+ execute_or_queue_command(command, &block)
247
+ end
248
+
249
+ # Creates a new Binding in a given project and location.
250
+ # @param [String] parent
251
+ # Required. The project and location to create the Binding in. Expected format: `
252
+ # projects/`project`/locations/`location``.
253
+ # @param [Google::Apis::AgentregistryV1::Binding] binding_object
254
+ # @param [String] binding_id
255
+ # Required. The ID to use for the binding, which will become the final component
256
+ # of the binding's resource name. This value should be 4-63 characters, and must
257
+ # conform to RFC-1034. Specifically, it must match the regular expression `^[a-z]
258
+ # ([a-z0-9-]`0,61`[a-z0-9])?$`.
259
+ # @param [String] request_id
260
+ # Optional. An optional request ID to identify requests. Specify a unique
261
+ # request ID so that if you must retry your request, the server will know to
262
+ # ignore the request if it has already been completed. The server will guarantee
263
+ # that for at least 60 minutes since the first request. For example, consider a
264
+ # situation where you make an initial request and the request times out. If you
265
+ # make the request again with the same request ID, the server can check if
266
+ # original operation with the same request ID was received, and if so, will
267
+ # ignore the second request. This prevents clients from accidentally creating
268
+ # duplicate commitments. The request ID must be a valid UUID with the exception
269
+ # that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
270
+ # @param [String] fields
271
+ # Selector specifying which fields to include in a partial response.
272
+ # @param [String] quota_user
273
+ # Available to use for quota purposes for server-side applications. Can be any
274
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
275
+ # @param [Google::Apis::RequestOptions] options
276
+ # Request-specific options
277
+ #
278
+ # @yield [result, err] Result & error if block supplied
279
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
280
+ # @yieldparam err [StandardError] error object if request failed
281
+ #
282
+ # @return [Google::Apis::AgentregistryV1::Operation]
283
+ #
284
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
285
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
286
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
287
+ def create_project_location_binding(parent, binding_object = nil, binding_id: nil, request_id: nil, fields: nil, quota_user: nil, options: nil, &block)
288
+ command = make_simple_command(:post, 'v1/{+parent}/bindings', options)
289
+ command.request_representation = Google::Apis::AgentregistryV1::Binding::Representation
290
+ command.request_object = binding_object
291
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
292
+ command.response_class = Google::Apis::AgentregistryV1::Operation
293
+ command.params['parent'] = parent unless parent.nil?
294
+ command.query['bindingId'] = binding_id unless binding_id.nil?
295
+ command.query['requestId'] = request_id unless request_id.nil?
296
+ command.query['fields'] = fields unless fields.nil?
297
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
298
+ execute_or_queue_command(command, &block)
299
+ end
300
+
301
+ # Deletes a single Binding.
302
+ # @param [String] name
303
+ # Required. The name of the Binding. Format: `projects/`project`/locations/`
304
+ # location`/bindings/`binding``.
305
+ # @param [String] request_id
306
+ # Optional. An optional request ID to identify requests. Specify a unique
307
+ # request ID so that if you must retry your request, the server will know to
308
+ # ignore the request if it has already been completed. The server will guarantee
309
+ # that for at least 60 minutes after the first request. For example, consider a
310
+ # situation where you make an initial request and the request times out. If you
311
+ # make the request again with the same request ID, the server can check if
312
+ # original operation with the same request ID was received, and if so, will
313
+ # ignore the second request. This prevents clients from accidentally creating
314
+ # duplicate commitments. The request ID must be a valid UUID with the exception
315
+ # that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
316
+ # @param [String] fields
317
+ # Selector specifying which fields to include in a partial response.
318
+ # @param [String] quota_user
319
+ # Available to use for quota purposes for server-side applications. Can be any
320
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
321
+ # @param [Google::Apis::RequestOptions] options
322
+ # Request-specific options
323
+ #
324
+ # @yield [result, err] Result & error if block supplied
325
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
326
+ # @yieldparam err [StandardError] error object if request failed
327
+ #
328
+ # @return [Google::Apis::AgentregistryV1::Operation]
329
+ #
330
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
331
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
332
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
333
+ def delete_project_location_binding(name, request_id: nil, fields: nil, quota_user: nil, options: nil, &block)
334
+ command = make_simple_command(:delete, 'v1/{+name}', options)
335
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
336
+ command.response_class = Google::Apis::AgentregistryV1::Operation
337
+ command.params['name'] = name unless name.nil?
338
+ command.query['requestId'] = request_id unless request_id.nil?
339
+ command.query['fields'] = fields unless fields.nil?
340
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
341
+ execute_or_queue_command(command, &block)
342
+ end
343
+
344
+ # Fetches available Bindings.
345
+ # @param [String] parent
346
+ # Required. The parent, in the format `projects/`project`/locations/`location``.
347
+ # @param [Fixnum] page_size
348
+ # Optional. Requested page size. Server may return fewer items than requested.
349
+ # Page size is 500 if unspecified and is capped at `500` even if a larger value
350
+ # is given.
351
+ # @param [String] page_token
352
+ # Optional. A token identifying a page of results the server should return.
353
+ # @param [String] source_identifier
354
+ # The identifier of the source Agent. Format: * `urn:agent:`publisher`:`
355
+ # namespace`:`name``
356
+ # @param [String] target_identifier
357
+ # Optional. The identifier of the target Agent, MCP Server, or Endpoint. Format:
358
+ # * `urn:agent:`publisher`:`namespace`:`name`` * `urn:mcp:`publisher`:`namespace`
359
+ # :`name`` * `urn:endpoint:`publisher`:`namespace`:`name``
360
+ # @param [String] fields
361
+ # Selector specifying which fields to include in a partial response.
362
+ # @param [String] quota_user
363
+ # Available to use for quota purposes for server-side applications. Can be any
364
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
365
+ # @param [Google::Apis::RequestOptions] options
366
+ # Request-specific options
367
+ #
368
+ # @yield [result, err] Result & error if block supplied
369
+ # @yieldparam result [Google::Apis::AgentregistryV1::FetchAvailableBindingsResponse] parsed result object
370
+ # @yieldparam err [StandardError] error object if request failed
371
+ #
372
+ # @return [Google::Apis::AgentregistryV1::FetchAvailableBindingsResponse]
373
+ #
374
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
375
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
376
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
377
+ def fetch_project_location_binding_available(parent, page_size: nil, page_token: nil, source_identifier: nil, target_identifier: nil, fields: nil, quota_user: nil, options: nil, &block)
378
+ command = make_simple_command(:get, 'v1/{+parent}/bindings:fetchAvailable', options)
379
+ command.response_representation = Google::Apis::AgentregistryV1::FetchAvailableBindingsResponse::Representation
380
+ command.response_class = Google::Apis::AgentregistryV1::FetchAvailableBindingsResponse
381
+ command.params['parent'] = parent unless parent.nil?
382
+ command.query['pageSize'] = page_size unless page_size.nil?
383
+ command.query['pageToken'] = page_token unless page_token.nil?
384
+ command.query['sourceIdentifier'] = source_identifier unless source_identifier.nil?
385
+ command.query['targetIdentifier'] = target_identifier unless target_identifier.nil?
386
+ command.query['fields'] = fields unless fields.nil?
387
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
388
+ execute_or_queue_command(command, &block)
389
+ end
390
+
391
+ # Gets details of a single Binding.
392
+ # @param [String] name
393
+ # Required. The name of the Binding. Format: `projects/`project`/locations/`
394
+ # location`/bindings/`binding``.
395
+ # @param [String] fields
396
+ # Selector specifying which fields to include in a partial response.
397
+ # @param [String] quota_user
398
+ # Available to use for quota purposes for server-side applications. Can be any
399
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
400
+ # @param [Google::Apis::RequestOptions] options
401
+ # Request-specific options
402
+ #
403
+ # @yield [result, err] Result & error if block supplied
404
+ # @yieldparam result [Google::Apis::AgentregistryV1::Binding] parsed result object
405
+ # @yieldparam err [StandardError] error object if request failed
406
+ #
407
+ # @return [Google::Apis::AgentregistryV1::Binding]
408
+ #
409
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
410
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
411
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
412
+ def get_project_location_binding(name, fields: nil, quota_user: nil, options: nil, &block)
413
+ command = make_simple_command(:get, 'v1/{+name}', options)
414
+ command.response_representation = Google::Apis::AgentregistryV1::Binding::Representation
415
+ command.response_class = Google::Apis::AgentregistryV1::Binding
416
+ command.params['name'] = name unless name.nil?
417
+ command.query['fields'] = fields unless fields.nil?
418
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
419
+ execute_or_queue_command(command, &block)
420
+ end
421
+
422
+ # Lists Bindings in a given project and location.
423
+ # @param [String] parent
424
+ # Required. The project and location to list bindings in. Expected format: `
425
+ # projects/`project`/locations/`location``.
426
+ # @param [String] filter
427
+ # Optional. A query string used to filter the list of bindings returned. The
428
+ # filter expression must follow AIP-160 syntax.
429
+ # @param [String] order_by
430
+ # Optional. Hint for how to order the results
431
+ # @param [Fixnum] page_size
432
+ # Optional. Requested page size. Server may return fewer items than requested.
433
+ # Page size is 500 if unspecified and is capped at `500` even if a larger value
434
+ # is given.
435
+ # @param [String] page_token
436
+ # Optional. A token identifying a page of results the server should return.
437
+ # @param [String] fields
438
+ # Selector specifying which fields to include in a partial response.
439
+ # @param [String] quota_user
440
+ # Available to use for quota purposes for server-side applications. Can be any
441
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
442
+ # @param [Google::Apis::RequestOptions] options
443
+ # Request-specific options
444
+ #
445
+ # @yield [result, err] Result & error if block supplied
446
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListBindingsResponse] parsed result object
447
+ # @yieldparam err [StandardError] error object if request failed
448
+ #
449
+ # @return [Google::Apis::AgentregistryV1::ListBindingsResponse]
450
+ #
451
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
452
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
453
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
454
+ def list_project_location_bindings(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
455
+ command = make_simple_command(:get, 'v1/{+parent}/bindings', options)
456
+ command.response_representation = Google::Apis::AgentregistryV1::ListBindingsResponse::Representation
457
+ command.response_class = Google::Apis::AgentregistryV1::ListBindingsResponse
458
+ command.params['parent'] = parent unless parent.nil?
459
+ command.query['filter'] = filter unless filter.nil?
460
+ command.query['orderBy'] = order_by unless order_by.nil?
461
+ command.query['pageSize'] = page_size unless page_size.nil?
462
+ command.query['pageToken'] = page_token unless page_token.nil?
463
+ command.query['fields'] = fields unless fields.nil?
464
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
465
+ execute_or_queue_command(command, &block)
466
+ end
467
+
468
+ # Updates the parameters of a single Binding.
469
+ # @param [String] name
470
+ # Required. Identifier. The resource name of the Binding. Format: `projects/`
471
+ # project`/locations/`location`/bindings/`binding``.
472
+ # @param [Google::Apis::AgentregistryV1::Binding] binding_object
473
+ # @param [String] request_id
474
+ # Optional. An optional request ID to identify requests. Specify a unique
475
+ # request ID so that if you must retry your request, the server will know to
476
+ # ignore the request if it has already been completed. The server will guarantee
477
+ # that for at least 60 minutes since the first request. For example, consider a
478
+ # situation where you make an initial request and the request times out. If you
479
+ # make the request again with the same request ID, the server can check if
480
+ # original operation with the same request ID was received, and if so, will
481
+ # ignore the second request. This prevents clients from accidentally creating
482
+ # duplicate commitments. The request ID must be a valid UUID with the exception
483
+ # that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
484
+ # @param [String] update_mask
485
+ # Optional. Field mask is used to specify the fields to be overwritten in the
486
+ # Binding resource by the update. The fields specified in the update_mask are
487
+ # relative to the resource, not the full request. A field will be overwritten if
488
+ # it is in the mask. If the user does not provide a mask then all fields present
489
+ # in the request will be overwritten.
490
+ # @param [String] fields
491
+ # Selector specifying which fields to include in a partial response.
492
+ # @param [String] quota_user
493
+ # Available to use for quota purposes for server-side applications. Can be any
494
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
495
+ # @param [Google::Apis::RequestOptions] options
496
+ # Request-specific options
497
+ #
498
+ # @yield [result, err] Result & error if block supplied
499
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
500
+ # @yieldparam err [StandardError] error object if request failed
501
+ #
502
+ # @return [Google::Apis::AgentregistryV1::Operation]
503
+ #
504
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
505
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
506
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
507
+ def patch_project_location_binding(name, binding_object = nil, request_id: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
508
+ command = make_simple_command(:patch, 'v1/{+name}', options)
509
+ command.request_representation = Google::Apis::AgentregistryV1::Binding::Representation
510
+ command.request_object = binding_object
511
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
512
+ command.response_class = Google::Apis::AgentregistryV1::Operation
513
+ command.params['name'] = name unless name.nil?
514
+ command.query['requestId'] = request_id unless request_id.nil?
515
+ command.query['updateMask'] = update_mask unless update_mask.nil?
516
+ command.query['fields'] = fields unless fields.nil?
517
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
518
+ execute_or_queue_command(command, &block)
519
+ end
520
+
521
+ # Gets details of a single Endpoint.
522
+ # @param [String] name
523
+ # Required. The name of the endpoint to retrieve. Format: `projects/`project`/
524
+ # locations/`location`/endpoints/`endpoint``
525
+ # @param [String] fields
526
+ # Selector specifying which fields to include in a partial response.
527
+ # @param [String] quota_user
528
+ # Available to use for quota purposes for server-side applications. Can be any
529
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
530
+ # @param [Google::Apis::RequestOptions] options
531
+ # Request-specific options
532
+ #
533
+ # @yield [result, err] Result & error if block supplied
534
+ # @yieldparam result [Google::Apis::AgentregistryV1::Endpoint] parsed result object
535
+ # @yieldparam err [StandardError] error object if request failed
536
+ #
537
+ # @return [Google::Apis::AgentregistryV1::Endpoint]
538
+ #
539
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
540
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
541
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
542
+ def get_project_location_endpoint(name, fields: nil, quota_user: nil, options: nil, &block)
543
+ command = make_simple_command(:get, 'v1/{+name}', options)
544
+ command.response_representation = Google::Apis::AgentregistryV1::Endpoint::Representation
545
+ command.response_class = Google::Apis::AgentregistryV1::Endpoint
546
+ command.params['name'] = name unless name.nil?
547
+ command.query['fields'] = fields unless fields.nil?
548
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
549
+ execute_or_queue_command(command, &block)
550
+ end
551
+
552
+ # Lists Endpoints in a given project and location.
553
+ # @param [String] parent
554
+ # Required. The project and location to list endpoints in. Expected format: `
555
+ # projects/`project`/locations/`location``.
556
+ # @param [String] filter
557
+ # Optional. A query string used to filter the list of endpoints returned. The
558
+ # filter expression must follow AIP-160 syntax. Filtering is supported on the `
559
+ # name`, `display_name`, `description`, `version`, and `interfaces` fields. Some
560
+ # examples: * `name = "projects/p1/locations/l1/endpoints/e1"` * `display_name =
561
+ # "my-endpoint"` * `description = "my-endpoint-description"` * `version = "v1"` *
562
+ # `interfaces.transport = "HTTP_JSON"`
563
+ # @param [Fixnum] page_size
564
+ # Optional. Requested page size. Server may return fewer items than requested.
565
+ # If unspecified, server will pick an appropriate default.
566
+ # @param [String] page_token
567
+ # Optional. A token identifying a page of results the server should return.
568
+ # @param [String] fields
569
+ # Selector specifying which fields to include in a partial response.
570
+ # @param [String] quota_user
571
+ # Available to use for quota purposes for server-side applications. Can be any
572
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
573
+ # @param [Google::Apis::RequestOptions] options
574
+ # Request-specific options
575
+ #
576
+ # @yield [result, err] Result & error if block supplied
577
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListEndpointsResponse] parsed result object
578
+ # @yieldparam err [StandardError] error object if request failed
579
+ #
580
+ # @return [Google::Apis::AgentregistryV1::ListEndpointsResponse]
581
+ #
582
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
583
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
584
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
585
+ def list_project_location_endpoints(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
586
+ command = make_simple_command(:get, 'v1/{+parent}/endpoints', options)
587
+ command.response_representation = Google::Apis::AgentregistryV1::ListEndpointsResponse::Representation
588
+ command.response_class = Google::Apis::AgentregistryV1::ListEndpointsResponse
589
+ command.params['parent'] = parent unless parent.nil?
590
+ command.query['filter'] = filter unless filter.nil?
591
+ command.query['pageSize'] = page_size unless page_size.nil?
592
+ command.query['pageToken'] = page_token unless page_token.nil?
593
+ command.query['fields'] = fields unless fields.nil?
594
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
595
+ execute_or_queue_command(command, &block)
596
+ end
597
+
598
+ # Gets details of a single McpServer.
599
+ # @param [String] name
600
+ # Required. Name of the resource
601
+ # @param [String] fields
602
+ # Selector specifying which fields to include in a partial response.
603
+ # @param [String] quota_user
604
+ # Available to use for quota purposes for server-side applications. Can be any
605
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
606
+ # @param [Google::Apis::RequestOptions] options
607
+ # Request-specific options
608
+ #
609
+ # @yield [result, err] Result & error if block supplied
610
+ # @yieldparam result [Google::Apis::AgentregistryV1::McpServer] parsed result object
611
+ # @yieldparam err [StandardError] error object if request failed
612
+ #
613
+ # @return [Google::Apis::AgentregistryV1::McpServer]
614
+ #
615
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
616
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
617
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
618
+ def get_project_location_mcp_server(name, fields: nil, quota_user: nil, options: nil, &block)
619
+ command = make_simple_command(:get, 'v1/{+name}', options)
620
+ command.response_representation = Google::Apis::AgentregistryV1::McpServer::Representation
621
+ command.response_class = Google::Apis::AgentregistryV1::McpServer
622
+ command.params['name'] = name unless name.nil?
623
+ command.query['fields'] = fields unless fields.nil?
624
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
625
+ execute_or_queue_command(command, &block)
626
+ end
627
+
628
+ # Lists McpServers in a given project and location.
629
+ # @param [String] parent
630
+ # Required. Parent value for ListMcpServersRequest. Format: `projects/`project`/
631
+ # locations/`location``.
632
+ # @param [String] filter
633
+ # Optional. Filtering results
634
+ # @param [String] order_by
635
+ # Optional. Hint for how to order the results
636
+ # @param [Fixnum] page_size
637
+ # Optional. Requested page size. Server may return fewer items than requested.
638
+ # If unspecified, server will pick an appropriate default.
639
+ # @param [String] page_token
640
+ # Optional. A token identifying a page of results the server should return.
641
+ # @param [String] fields
642
+ # Selector specifying which fields to include in a partial response.
643
+ # @param [String] quota_user
644
+ # Available to use for quota purposes for server-side applications. Can be any
645
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
646
+ # @param [Google::Apis::RequestOptions] options
647
+ # Request-specific options
648
+ #
649
+ # @yield [result, err] Result & error if block supplied
650
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListMcpServersResponse] parsed result object
651
+ # @yieldparam err [StandardError] error object if request failed
652
+ #
653
+ # @return [Google::Apis::AgentregistryV1::ListMcpServersResponse]
654
+ #
655
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
656
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
657
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
658
+ def list_project_location_mcp_servers(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
659
+ command = make_simple_command(:get, 'v1/{+parent}/mcpServers', options)
660
+ command.response_representation = Google::Apis::AgentregistryV1::ListMcpServersResponse::Representation
661
+ command.response_class = Google::Apis::AgentregistryV1::ListMcpServersResponse
662
+ command.params['parent'] = parent unless parent.nil?
663
+ command.query['filter'] = filter unless filter.nil?
664
+ command.query['orderBy'] = order_by unless order_by.nil?
665
+ command.query['pageSize'] = page_size unless page_size.nil?
666
+ command.query['pageToken'] = page_token unless page_token.nil?
667
+ command.query['fields'] = fields unless fields.nil?
668
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
669
+ execute_or_queue_command(command, &block)
670
+ end
671
+
672
+ # Searches McpServers in a given project and location.
673
+ # @param [String] parent
674
+ # Required. Parent value for SearchMcpServersRequest. Format: `projects/`project`
675
+ # /locations/`location``.
676
+ # @param [Google::Apis::AgentregistryV1::SearchMcpServersRequest] search_mcp_servers_request_object
677
+ # @param [String] fields
678
+ # Selector specifying which fields to include in a partial response.
679
+ # @param [String] quota_user
680
+ # Available to use for quota purposes for server-side applications. Can be any
681
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
682
+ # @param [Google::Apis::RequestOptions] options
683
+ # Request-specific options
684
+ #
685
+ # @yield [result, err] Result & error if block supplied
686
+ # @yieldparam result [Google::Apis::AgentregistryV1::SearchMcpServersResponse] parsed result object
687
+ # @yieldparam err [StandardError] error object if request failed
688
+ #
689
+ # @return [Google::Apis::AgentregistryV1::SearchMcpServersResponse]
690
+ #
691
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
692
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
693
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
694
+ def search_mcp_servers(parent, search_mcp_servers_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
695
+ command = make_simple_command(:post, 'v1/{+parent}/mcpServers:search', options)
696
+ command.request_representation = Google::Apis::AgentregistryV1::SearchMcpServersRequest::Representation
697
+ command.request_object = search_mcp_servers_request_object
698
+ command.response_representation = Google::Apis::AgentregistryV1::SearchMcpServersResponse::Representation
699
+ command.response_class = Google::Apis::AgentregistryV1::SearchMcpServersResponse
700
+ command.params['parent'] = parent unless parent.nil?
701
+ command.query['fields'] = fields unless fields.nil?
702
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
703
+ execute_or_queue_command(command, &block)
704
+ end
705
+
706
+ # Starts asynchronous cancellation on a long-running operation. The server makes
707
+ # a best effort to cancel the operation, but success is not guaranteed. If the
708
+ # server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
709
+ # Clients can use Operations.GetOperation or other methods to check whether the
710
+ # cancellation succeeded or whether the operation completed despite cancellation.
711
+ # On successful cancellation, the operation is not deleted; instead, it becomes
712
+ # an operation with an Operation.error value with a google.rpc.Status.code of `1`
713
+ # , corresponding to `Code.CANCELLED`.
714
+ # @param [String] name
715
+ # The name of the operation resource to be cancelled.
716
+ # @param [Google::Apis::AgentregistryV1::CancelOperationRequest] cancel_operation_request_object
717
+ # @param [String] fields
718
+ # Selector specifying which fields to include in a partial response.
719
+ # @param [String] quota_user
720
+ # Available to use for quota purposes for server-side applications. Can be any
721
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
722
+ # @param [Google::Apis::RequestOptions] options
723
+ # Request-specific options
724
+ #
725
+ # @yield [result, err] Result & error if block supplied
726
+ # @yieldparam result [Google::Apis::AgentregistryV1::Empty] parsed result object
727
+ # @yieldparam err [StandardError] error object if request failed
728
+ #
729
+ # @return [Google::Apis::AgentregistryV1::Empty]
730
+ #
731
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
732
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
733
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
734
+ def cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
735
+ command = make_simple_command(:post, 'v1/{+name}:cancel', options)
736
+ command.request_representation = Google::Apis::AgentregistryV1::CancelOperationRequest::Representation
737
+ command.request_object = cancel_operation_request_object
738
+ command.response_representation = Google::Apis::AgentregistryV1::Empty::Representation
739
+ command.response_class = Google::Apis::AgentregistryV1::Empty
740
+ command.params['name'] = name unless name.nil?
741
+ command.query['fields'] = fields unless fields.nil?
742
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
743
+ execute_or_queue_command(command, &block)
744
+ end
745
+
746
+ # Deletes a long-running operation. This method indicates that the client is no
747
+ # longer interested in the operation result. It does not cancel the operation.
748
+ # If the server doesn't support this method, it returns `google.rpc.Code.
749
+ # UNIMPLEMENTED`.
750
+ # @param [String] name
751
+ # The name of the operation resource to be deleted.
752
+ # @param [String] fields
753
+ # Selector specifying which fields to include in a partial response.
754
+ # @param [String] quota_user
755
+ # Available to use for quota purposes for server-side applications. Can be any
756
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
757
+ # @param [Google::Apis::RequestOptions] options
758
+ # Request-specific options
759
+ #
760
+ # @yield [result, err] Result & error if block supplied
761
+ # @yieldparam result [Google::Apis::AgentregistryV1::Empty] parsed result object
762
+ # @yieldparam err [StandardError] error object if request failed
763
+ #
764
+ # @return [Google::Apis::AgentregistryV1::Empty]
765
+ #
766
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
767
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
768
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
769
+ def delete_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
770
+ command = make_simple_command(:delete, 'v1/{+name}', options)
771
+ command.response_representation = Google::Apis::AgentregistryV1::Empty::Representation
772
+ command.response_class = Google::Apis::AgentregistryV1::Empty
773
+ command.params['name'] = name unless name.nil?
774
+ command.query['fields'] = fields unless fields.nil?
775
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
776
+ execute_or_queue_command(command, &block)
777
+ end
778
+
779
+ # Gets the latest state of a long-running operation. Clients can use this method
780
+ # to poll the operation result at intervals as recommended by the API service.
781
+ # @param [String] name
782
+ # The name of the operation resource.
783
+ # @param [String] fields
784
+ # Selector specifying which fields to include in a partial response.
785
+ # @param [String] quota_user
786
+ # Available to use for quota purposes for server-side applications. Can be any
787
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
788
+ # @param [Google::Apis::RequestOptions] options
789
+ # Request-specific options
790
+ #
791
+ # @yield [result, err] Result & error if block supplied
792
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
793
+ # @yieldparam err [StandardError] error object if request failed
794
+ #
795
+ # @return [Google::Apis::AgentregistryV1::Operation]
796
+ #
797
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
798
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
799
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
800
+ def get_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
801
+ command = make_simple_command(:get, 'v1/{+name}', options)
802
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
803
+ command.response_class = Google::Apis::AgentregistryV1::Operation
804
+ command.params['name'] = name unless name.nil?
805
+ command.query['fields'] = fields unless fields.nil?
806
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
807
+ execute_or_queue_command(command, &block)
808
+ end
809
+
810
+ # Lists operations that match the specified filter in the request. If the server
811
+ # doesn't support this method, it returns `UNIMPLEMENTED`.
812
+ # @param [String] name
813
+ # The name of the operation's parent resource.
814
+ # @param [String] filter
815
+ # The standard list filter.
816
+ # @param [Fixnum] page_size
817
+ # The standard list page size.
818
+ # @param [String] page_token
819
+ # The standard list page token.
820
+ # @param [Boolean] return_partial_success
821
+ # When set to `true`, operations that are reachable are returned as normal, and
822
+ # those that are unreachable are returned in the ListOperationsResponse.
823
+ # unreachable field. This can only be `true` when reading across collections.
824
+ # For example, when `parent` is set to `"projects/example/locations/-"`. This
825
+ # field is not supported by default and will result in an `UNIMPLEMENTED` error
826
+ # if set unless explicitly documented otherwise in service or product specific
827
+ # documentation.
828
+ # @param [String] fields
829
+ # Selector specifying which fields to include in a partial response.
830
+ # @param [String] quota_user
831
+ # Available to use for quota purposes for server-side applications. Can be any
832
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
833
+ # @param [Google::Apis::RequestOptions] options
834
+ # Request-specific options
835
+ #
836
+ # @yield [result, err] Result & error if block supplied
837
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListOperationsResponse] parsed result object
838
+ # @yieldparam err [StandardError] error object if request failed
839
+ #
840
+ # @return [Google::Apis::AgentregistryV1::ListOperationsResponse]
841
+ #
842
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
843
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
844
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
845
+ def list_project_location_operations(name, filter: nil, page_size: nil, page_token: nil, return_partial_success: nil, fields: nil, quota_user: nil, options: nil, &block)
846
+ command = make_simple_command(:get, 'v1/{+name}/operations', options)
847
+ command.response_representation = Google::Apis::AgentregistryV1::ListOperationsResponse::Representation
848
+ command.response_class = Google::Apis::AgentregistryV1::ListOperationsResponse
849
+ command.params['name'] = name unless name.nil?
850
+ command.query['filter'] = filter unless filter.nil?
851
+ command.query['pageSize'] = page_size unless page_size.nil?
852
+ command.query['pageToken'] = page_token unless page_token.nil?
853
+ command.query['returnPartialSuccess'] = return_partial_success unless return_partial_success.nil?
854
+ command.query['fields'] = fields unless fields.nil?
855
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
856
+ execute_or_queue_command(command, &block)
857
+ end
858
+
859
+ # Creates a new Service in a given project and location.
860
+ # @param [String] parent
861
+ # Required. The project and location to create the Service in. Expected format: `
862
+ # projects/`project`/locations/`location``.
863
+ # @param [Google::Apis::AgentregistryV1::Service] service_object
864
+ # @param [String] request_id
865
+ # Optional. An optional request ID to identify requests. Specify a unique
866
+ # request ID so that if you must retry your request, the server will know to
867
+ # ignore the request if it has already been completed. The server will guarantee
868
+ # that for at least 60 minutes since the first request. For example, consider a
869
+ # situation where you make an initial request and the request times out. If you
870
+ # make the request again with the same request ID, the server can check if
871
+ # original operation with the same request ID was received, and if so, will
872
+ # ignore the second request. This prevents clients from accidentally creating
873
+ # duplicate commitments. The request ID must be a valid UUID with the exception
874
+ # that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
875
+ # @param [String] service_id
876
+ # Required. The ID to use for the service, which will become the final component
877
+ # of the service's resource name. This value should be 4-63 characters, and
878
+ # valid characters are `/a-z-/`.
879
+ # @param [String] fields
880
+ # Selector specifying which fields to include in a partial response.
881
+ # @param [String] quota_user
882
+ # Available to use for quota purposes for server-side applications. Can be any
883
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
884
+ # @param [Google::Apis::RequestOptions] options
885
+ # Request-specific options
886
+ #
887
+ # @yield [result, err] Result & error if block supplied
888
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
889
+ # @yieldparam err [StandardError] error object if request failed
890
+ #
891
+ # @return [Google::Apis::AgentregistryV1::Operation]
892
+ #
893
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
894
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
895
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
896
+ def create_project_location_service(parent, service_object = nil, request_id: nil, service_id: nil, fields: nil, quota_user: nil, options: nil, &block)
897
+ command = make_simple_command(:post, 'v1/{+parent}/services', options)
898
+ command.request_representation = Google::Apis::AgentregistryV1::Service::Representation
899
+ command.request_object = service_object
900
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
901
+ command.response_class = Google::Apis::AgentregistryV1::Operation
902
+ command.params['parent'] = parent unless parent.nil?
903
+ command.query['requestId'] = request_id unless request_id.nil?
904
+ command.query['serviceId'] = service_id unless service_id.nil?
905
+ command.query['fields'] = fields unless fields.nil?
906
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
907
+ execute_or_queue_command(command, &block)
908
+ end
909
+
910
+ # Deletes a single Service.
911
+ # @param [String] name
912
+ # Required. The name of the Service. Format: `projects/`project`/locations/`
913
+ # location`/services/`service``.
914
+ # @param [String] request_id
915
+ # Optional. An optional request ID to identify requests. Specify a unique
916
+ # request ID so that if you must retry your request, the server will know to
917
+ # ignore the request if it has already been completed. The server will guarantee
918
+ # that for at least 60 minutes after the first request. For example, consider a
919
+ # situation where you make an initial request and the request times out. If you
920
+ # make the request again with the same request ID, the server can check if
921
+ # original operation with the same request ID was received, and if so, will
922
+ # ignore the second request. This prevents clients from accidentally creating
923
+ # duplicate commitments. The request ID must be a valid UUID with the exception
924
+ # that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
925
+ # @param [String] fields
926
+ # Selector specifying which fields to include in a partial response.
927
+ # @param [String] quota_user
928
+ # Available to use for quota purposes for server-side applications. Can be any
929
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
930
+ # @param [Google::Apis::RequestOptions] options
931
+ # Request-specific options
932
+ #
933
+ # @yield [result, err] Result & error if block supplied
934
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
935
+ # @yieldparam err [StandardError] error object if request failed
936
+ #
937
+ # @return [Google::Apis::AgentregistryV1::Operation]
938
+ #
939
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
940
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
941
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
942
+ def delete_project_location_service(name, request_id: nil, fields: nil, quota_user: nil, options: nil, &block)
943
+ command = make_simple_command(:delete, 'v1/{+name}', options)
944
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
945
+ command.response_class = Google::Apis::AgentregistryV1::Operation
946
+ command.params['name'] = name unless name.nil?
947
+ command.query['requestId'] = request_id unless request_id.nil?
948
+ command.query['fields'] = fields unless fields.nil?
949
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
950
+ execute_or_queue_command(command, &block)
951
+ end
952
+
953
+ # Gets details of a single Service.
954
+ # @param [String] name
955
+ # Required. The name of the Service. Format: `projects/`project`/locations/`
956
+ # location`/services/`service``.
957
+ # @param [String] fields
958
+ # Selector specifying which fields to include in a partial response.
959
+ # @param [String] quota_user
960
+ # Available to use for quota purposes for server-side applications. Can be any
961
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
962
+ # @param [Google::Apis::RequestOptions] options
963
+ # Request-specific options
964
+ #
965
+ # @yield [result, err] Result & error if block supplied
966
+ # @yieldparam result [Google::Apis::AgentregistryV1::Service] parsed result object
967
+ # @yieldparam err [StandardError] error object if request failed
968
+ #
969
+ # @return [Google::Apis::AgentregistryV1::Service]
970
+ #
971
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
972
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
973
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
974
+ def get_project_location_service(name, fields: nil, quota_user: nil, options: nil, &block)
975
+ command = make_simple_command(:get, 'v1/{+name}', options)
976
+ command.response_representation = Google::Apis::AgentregistryV1::Service::Representation
977
+ command.response_class = Google::Apis::AgentregistryV1::Service
978
+ command.params['name'] = name unless name.nil?
979
+ command.query['fields'] = fields unless fields.nil?
980
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
981
+ execute_or_queue_command(command, &block)
982
+ end
983
+
984
+ # Lists Services in a given project and location.
985
+ # @param [String] parent
986
+ # Required. The project and location to list services in. Expected format: `
987
+ # projects/`project`/locations/`location``.
988
+ # @param [String] filter
989
+ # Optional. A query string used to filter the list of services returned. The
990
+ # filter expression must follow AIP-160 syntax. Filtering is supported on the `
991
+ # name`, `display_name`, `description`, and `labels` fields. Some examples: * `
992
+ # name = "projects/p1/locations/l1/services/s1"` * `display_name = "my-service"`
993
+ # * `description : "myservice description"` * `labels.env = "prod"`
994
+ # @param [Fixnum] page_size
995
+ # Optional. Requested page size. Server may return fewer items than requested.
996
+ # If unspecified, server will pick an appropriate default.
997
+ # @param [String] page_token
998
+ # Optional. A token identifying a page of results the server should return.
999
+ # @param [String] fields
1000
+ # Selector specifying which fields to include in a partial response.
1001
+ # @param [String] quota_user
1002
+ # Available to use for quota purposes for server-side applications. Can be any
1003
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1004
+ # @param [Google::Apis::RequestOptions] options
1005
+ # Request-specific options
1006
+ #
1007
+ # @yield [result, err] Result & error if block supplied
1008
+ # @yieldparam result [Google::Apis::AgentregistryV1::ListServicesResponse] parsed result object
1009
+ # @yieldparam err [StandardError] error object if request failed
1010
+ #
1011
+ # @return [Google::Apis::AgentregistryV1::ListServicesResponse]
1012
+ #
1013
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1014
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1015
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1016
+ def list_project_location_services(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
1017
+ command = make_simple_command(:get, 'v1/{+parent}/services', options)
1018
+ command.response_representation = Google::Apis::AgentregistryV1::ListServicesResponse::Representation
1019
+ command.response_class = Google::Apis::AgentregistryV1::ListServicesResponse
1020
+ command.params['parent'] = parent unless parent.nil?
1021
+ command.query['filter'] = filter unless filter.nil?
1022
+ command.query['pageSize'] = page_size unless page_size.nil?
1023
+ command.query['pageToken'] = page_token unless page_token.nil?
1024
+ command.query['fields'] = fields unless fields.nil?
1025
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1026
+ execute_or_queue_command(command, &block)
1027
+ end
1028
+
1029
+ # Updates the parameters of a single Service.
1030
+ # @param [String] name
1031
+ # Identifier. The resource name of the Service. Format: `projects/`project`/
1032
+ # locations/`location`/services/`service``.
1033
+ # @param [Google::Apis::AgentregistryV1::Service] service_object
1034
+ # @param [String] request_id
1035
+ # Optional. An optional request ID to identify requests. Specify a unique
1036
+ # request ID so that if you must retry your request, the server will know to
1037
+ # ignore the request if it has already been completed. The server will guarantee
1038
+ # that for at least 60 minutes since the first request. For example, consider a
1039
+ # situation where you make an initial request and the request times out. If you
1040
+ # make the request again with the same request ID, the server can check if
1041
+ # original operation with the same request ID was received, and if so, will
1042
+ # ignore the second request. This prevents clients from accidentally creating
1043
+ # duplicate commitments. The request ID must be a valid UUID with the exception
1044
+ # that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
1045
+ # @param [String] update_mask
1046
+ # Optional. Field mask is used to specify the fields to be overwritten in the
1047
+ # Service resource by the update. The fields specified in the update_mask are
1048
+ # relative to the resource, not the full request. A field will be overwritten if
1049
+ # it is in the mask. If the user does not provide a mask then all fields present
1050
+ # in the request will be overwritten.
1051
+ # @param [String] fields
1052
+ # Selector specifying which fields to include in a partial response.
1053
+ # @param [String] quota_user
1054
+ # Available to use for quota purposes for server-side applications. Can be any
1055
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1056
+ # @param [Google::Apis::RequestOptions] options
1057
+ # Request-specific options
1058
+ #
1059
+ # @yield [result, err] Result & error if block supplied
1060
+ # @yieldparam result [Google::Apis::AgentregistryV1::Operation] parsed result object
1061
+ # @yieldparam err [StandardError] error object if request failed
1062
+ #
1063
+ # @return [Google::Apis::AgentregistryV1::Operation]
1064
+ #
1065
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1066
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1067
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1068
+ def patch_project_location_service(name, service_object = nil, request_id: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
1069
+ command = make_simple_command(:patch, 'v1/{+name}', options)
1070
+ command.request_representation = Google::Apis::AgentregistryV1::Service::Representation
1071
+ command.request_object = service_object
1072
+ command.response_representation = Google::Apis::AgentregistryV1::Operation::Representation
1073
+ command.response_class = Google::Apis::AgentregistryV1::Operation
1074
+ command.params['name'] = name unless name.nil?
1075
+ command.query['requestId'] = request_id unless request_id.nil?
1076
+ command.query['updateMask'] = update_mask unless update_mask.nil?
1077
+ command.query['fields'] = fields unless fields.nil?
1078
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1079
+ execute_or_queue_command(command, &block)
1080
+ end
1081
+
1082
+ protected
1083
+
1084
+ def apply_command_defaults(command)
1085
+ command.query['key'] = key unless key.nil?
1086
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1087
+ end
1088
+ end
1089
+ end
1090
+ end
1091
+ end