google-apis-baremetalsolution_v2 0.2.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -123,7 +123,7 @@ module Google
123
123
  execute_or_queue_command(command, &block)
124
124
  end
125
125
 
126
- # Gets details of a single Instance.
126
+ # Get details about a single server.
127
127
  # @param [String] name
128
128
  # Required. Name of the resource.
129
129
  # @param [String] fields
@@ -153,19 +153,122 @@ module Google
153
153
  execute_or_queue_command(command, &block)
154
154
  end
155
155
 
156
- # Gets the access control policy for a resource. Returns an empty policy if the
157
- # resource exists and does not have a policy set.
158
- # @param [String] resource
159
- # REQUIRED: The resource for which the policy is being requested. See the
160
- # operation documentation for the appropriate value for this field.
161
- # @param [Fixnum] options_requested_policy_version
162
- # Optional. The policy format version to be returned. Valid values are 0, 1, and
163
- # 3. Requests specifying an invalid value will be rejected. Requests for
164
- # policies with any conditional bindings must specify version 3. Policies
165
- # without any conditional bindings may specify any valid value or leave the
166
- # field unset. To learn which resources support conditions in their IAM policies,
167
- # see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
168
- # resource-policies).
156
+ # List servers in a given project and location.
157
+ # @param [String] parent
158
+ # Required. Parent value for ListInstancesRequest.
159
+ # @param [String] filter
160
+ # List filter.
161
+ # @param [Fixnum] page_size
162
+ # Requested page size. Server may return fewer items than requested. If
163
+ # unspecified, the server will pick an appropriate default.
164
+ # @param [String] page_token
165
+ # A token identifying a page of results from the server.
166
+ # @param [String] fields
167
+ # Selector specifying which fields to include in a partial response.
168
+ # @param [String] quota_user
169
+ # Available to use for quota purposes for server-side applications. Can be any
170
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
171
+ # @param [Google::Apis::RequestOptions] options
172
+ # Request-specific options
173
+ #
174
+ # @yield [result, err] Result & error if block supplied
175
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::ListInstancesResponse] parsed result object
176
+ # @yieldparam err [StandardError] error object if request failed
177
+ #
178
+ # @return [Google::Apis::BaremetalsolutionV2::ListInstancesResponse]
179
+ #
180
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
181
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
182
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
183
+ def list_project_location_instances(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
184
+ command = make_simple_command(:get, 'v2/{+parent}/instances', options)
185
+ command.response_representation = Google::Apis::BaremetalsolutionV2::ListInstancesResponse::Representation
186
+ command.response_class = Google::Apis::BaremetalsolutionV2::ListInstancesResponse
187
+ command.params['parent'] = parent unless parent.nil?
188
+ command.query['filter'] = filter unless filter.nil?
189
+ command.query['pageSize'] = page_size unless page_size.nil?
190
+ command.query['pageToken'] = page_token unless page_token.nil?
191
+ command.query['fields'] = fields unless fields.nil?
192
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
193
+ execute_or_queue_command(command, &block)
194
+ end
195
+
196
+ # Update details of a single server.
197
+ # @param [String] name
198
+ # Output only. The resource name of this `Instance`. Resource names are
199
+ # schemeless URIs that follow the conventions in https://cloud.google.com/apis/
200
+ # design/resource_names. Format: `projects/`project`/locations/`location`/
201
+ # instances/`instance``
202
+ # @param [Google::Apis::BaremetalsolutionV2::Instance] instance_object
203
+ # @param [String] update_mask
204
+ # The list of fields to update. The only currently supported fields are: `labels`
205
+ # @param [String] fields
206
+ # Selector specifying which fields to include in a partial response.
207
+ # @param [String] quota_user
208
+ # Available to use for quota purposes for server-side applications. Can be any
209
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
210
+ # @param [Google::Apis::RequestOptions] options
211
+ # Request-specific options
212
+ #
213
+ # @yield [result, err] Result & error if block supplied
214
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Operation] parsed result object
215
+ # @yieldparam err [StandardError] error object if request failed
216
+ #
217
+ # @return [Google::Apis::BaremetalsolutionV2::Operation]
218
+ #
219
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
220
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
221
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
222
+ def patch_project_location_instance(name, instance_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
223
+ command = make_simple_command(:patch, 'v2/{+name}', options)
224
+ command.request_representation = Google::Apis::BaremetalsolutionV2::Instance::Representation
225
+ command.request_object = instance_object
226
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Operation::Representation
227
+ command.response_class = Google::Apis::BaremetalsolutionV2::Operation
228
+ command.params['name'] = name unless name.nil?
229
+ command.query['updateMask'] = update_mask unless update_mask.nil?
230
+ command.query['fields'] = fields unless fields.nil?
231
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
232
+ execute_or_queue_command(command, &block)
233
+ end
234
+
235
+ # Perform an ungraceful, hard reset on a server. Equivalent to shutting the
236
+ # power off and then turning it back on.
237
+ # @param [String] name
238
+ # Required. Name of the resource.
239
+ # @param [Google::Apis::BaremetalsolutionV2::ResetInstanceRequest] reset_instance_request_object
240
+ # @param [String] fields
241
+ # Selector specifying which fields to include in a partial response.
242
+ # @param [String] quota_user
243
+ # Available to use for quota purposes for server-side applications. Can be any
244
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
245
+ # @param [Google::Apis::RequestOptions] options
246
+ # Request-specific options
247
+ #
248
+ # @yield [result, err] Result & error if block supplied
249
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Operation] parsed result object
250
+ # @yieldparam err [StandardError] error object if request failed
251
+ #
252
+ # @return [Google::Apis::BaremetalsolutionV2::Operation]
253
+ #
254
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
255
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
256
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
257
+ def reset_instance(name, reset_instance_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
258
+ command = make_simple_command(:post, 'v2/{+name}:reset', options)
259
+ command.request_representation = Google::Apis::BaremetalsolutionV2::ResetInstanceRequest::Representation
260
+ command.request_object = reset_instance_request_object
261
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Operation::Representation
262
+ command.response_class = Google::Apis::BaremetalsolutionV2::Operation
263
+ command.params['name'] = name unless name.nil?
264
+ command.query['fields'] = fields unless fields.nil?
265
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
266
+ execute_or_queue_command(command, &block)
267
+ end
268
+
269
+ # Get details of a single network.
270
+ # @param [String] name
271
+ # Required. Name of the resource.
169
272
  # @param [String] fields
170
273
  # Selector specifying which fields to include in a partial response.
171
274
  # @param [String] quota_user
@@ -175,37 +278,34 @@ module Google
175
278
  # Request-specific options
176
279
  #
177
280
  # @yield [result, err] Result & error if block supplied
178
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::Policy] parsed result object
281
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Network] parsed result object
179
282
  # @yieldparam err [StandardError] error object if request failed
180
283
  #
181
- # @return [Google::Apis::BaremetalsolutionV2::Policy]
284
+ # @return [Google::Apis::BaremetalsolutionV2::Network]
182
285
  #
183
286
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
184
287
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
185
288
  # @raise [Google::Apis::AuthorizationError] Authorization is required
186
- def get_project_location_instance_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil, &block)
187
- command = make_simple_command(:get, 'v2/{+resource}:getIamPolicy', options)
188
- command.response_representation = Google::Apis::BaremetalsolutionV2::Policy::Representation
189
- command.response_class = Google::Apis::BaremetalsolutionV2::Policy
190
- command.params['resource'] = resource unless resource.nil?
191
- command.query['options.requestedPolicyVersion'] = options_requested_policy_version unless options_requested_policy_version.nil?
289
+ def get_project_location_network(name, fields: nil, quota_user: nil, options: nil, &block)
290
+ command = make_simple_command(:get, 'v2/{+name}', options)
291
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Network::Representation
292
+ command.response_class = Google::Apis::BaremetalsolutionV2::Network
293
+ command.params['name'] = name unless name.nil?
192
294
  command.query['fields'] = fields unless fields.nil?
193
295
  command.query['quotaUser'] = quota_user unless quota_user.nil?
194
296
  execute_or_queue_command(command, &block)
195
297
  end
196
298
 
197
- # Lists Instances in a given project and location.
299
+ # List network in a given project and location.
198
300
  # @param [String] parent
199
- # Required. Parent value for ListInstancesRequest.
301
+ # Required. Parent value for ListNetworksRequest.
200
302
  # @param [String] filter
201
- # Filtering results.
202
- # @param [String] order_by
203
- # Hint for how to order the results.
303
+ # List filter.
204
304
  # @param [Fixnum] page_size
205
- # Requested page size. Server may return fewer items than requested. If
305
+ # Requested page size. The server might return fewer items than requested. If
206
306
  # unspecified, server will pick an appropriate default.
207
307
  # @param [String] page_token
208
- # A token identifying a page of results the server should return.
308
+ # A token identifying a page of results from the server.
209
309
  # @param [String] fields
210
310
  # Selector specifying which fields to include in a partial response.
211
311
  # @param [String] quota_user
@@ -215,21 +315,20 @@ module Google
215
315
  # Request-specific options
216
316
  #
217
317
  # @yield [result, err] Result & error if block supplied
218
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::ListInstancesResponse] parsed result object
318
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::ListNetworksResponse] parsed result object
219
319
  # @yieldparam err [StandardError] error object if request failed
220
320
  #
221
- # @return [Google::Apis::BaremetalsolutionV2::ListInstancesResponse]
321
+ # @return [Google::Apis::BaremetalsolutionV2::ListNetworksResponse]
222
322
  #
223
323
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
224
324
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
225
325
  # @raise [Google::Apis::AuthorizationError] Authorization is required
226
- def list_project_location_instances(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
227
- command = make_simple_command(:get, 'v2/{+parent}/instances', options)
228
- command.response_representation = Google::Apis::BaremetalsolutionV2::ListInstancesResponse::Representation
229
- command.response_class = Google::Apis::BaremetalsolutionV2::ListInstancesResponse
326
+ def list_project_location_networks(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
327
+ command = make_simple_command(:get, 'v2/{+parent}/networks', options)
328
+ command.response_representation = Google::Apis::BaremetalsolutionV2::ListNetworksResponse::Representation
329
+ command.response_class = Google::Apis::BaremetalsolutionV2::ListNetworksResponse
230
330
  command.params['parent'] = parent unless parent.nil?
231
331
  command.query['filter'] = filter unless filter.nil?
232
- command.query['orderBy'] = order_by unless order_by.nil?
233
332
  command.query['pageSize'] = page_size unless page_size.nil?
234
333
  command.query['pageToken'] = page_token unless page_token.nil?
235
334
  command.query['fields'] = fields unless fields.nil?
@@ -237,13 +336,15 @@ module Google
237
336
  execute_or_queue_command(command, &block)
238
337
  end
239
338
 
240
- # Sets the access control policy on the specified resource. Replaces any
241
- # existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `
242
- # PERMISSION_DENIED` errors.
243
- # @param [String] resource
244
- # REQUIRED: The resource for which the policy is being specified. See the
245
- # operation documentation for the appropriate value for this field.
246
- # @param [Google::Apis::BaremetalsolutionV2::SetIamPolicyRequest] set_iam_policy_request_object
339
+ # Update details of a single network.
340
+ # @param [String] name
341
+ # Output only. The resource name of this `Network`. Resource names are
342
+ # schemeless URIs that follow the conventions in https://cloud.google.com/apis/
343
+ # design/resource_names. Format: `projects/`project`/locations/`location`/
344
+ # networks/`network``
345
+ # @param [Google::Apis::BaremetalsolutionV2::Network] network_object
346
+ # @param [String] update_mask
347
+ # The list of fields to update. The only currently supported fields are: `labels`
247
348
  # @param [String] fields
248
349
  # Selector specifying which fields to include in a partial response.
249
350
  # @param [String] quota_user
@@ -253,35 +354,34 @@ module Google
253
354
  # Request-specific options
254
355
  #
255
356
  # @yield [result, err] Result & error if block supplied
256
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::Policy] parsed result object
357
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Operation] parsed result object
257
358
  # @yieldparam err [StandardError] error object if request failed
258
359
  #
259
- # @return [Google::Apis::BaremetalsolutionV2::Policy]
360
+ # @return [Google::Apis::BaremetalsolutionV2::Operation]
260
361
  #
261
362
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
262
363
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
263
364
  # @raise [Google::Apis::AuthorizationError] Authorization is required
264
- def set_instance_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
265
- command = make_simple_command(:post, 'v2/{+resource}:setIamPolicy', options)
266
- command.request_representation = Google::Apis::BaremetalsolutionV2::SetIamPolicyRequest::Representation
267
- command.request_object = set_iam_policy_request_object
268
- command.response_representation = Google::Apis::BaremetalsolutionV2::Policy::Representation
269
- command.response_class = Google::Apis::BaremetalsolutionV2::Policy
270
- command.params['resource'] = resource unless resource.nil?
365
+ def patch_project_location_network(name, network_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
366
+ command = make_simple_command(:patch, 'v2/{+name}', options)
367
+ command.request_representation = Google::Apis::BaremetalsolutionV2::Network::Representation
368
+ command.request_object = network_object
369
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Operation::Representation
370
+ command.response_class = Google::Apis::BaremetalsolutionV2::Operation
371
+ command.params['name'] = name unless name.nil?
372
+ command.query['updateMask'] = update_mask unless update_mask.nil?
271
373
  command.query['fields'] = fields unless fields.nil?
272
374
  command.query['quotaUser'] = quota_user unless quota_user.nil?
273
375
  execute_or_queue_command(command, &block)
274
376
  end
275
377
 
276
- # Returns permissions that a caller has on the specified resource. If the
277
- # resource does not exist, this will return an empty set of permissions, not a `
278
- # NOT_FOUND` error. Note: This operation is designed to be used for building
279
- # permission-aware UIs and command-line tools, not for authorization checking.
280
- # This operation may "fail open" without warning.
281
- # @param [String] resource
282
- # REQUIRED: The resource for which the policy detail is being requested. See the
283
- # operation documentation for the appropriate value for this field.
284
- # @param [Google::Apis::BaremetalsolutionV2::TestIamPermissionsRequest] test_iam_permissions_request_object
378
+ # Create a snapshot schedule policy in the specified project.
379
+ # @param [String] parent
380
+ # Required. The parent project and location containing the
381
+ # SnapshotSchedulePolicy.
382
+ # @param [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy] snapshot_schedule_policy_object
383
+ # @param [String] snapshot_schedule_policy_id
384
+ # Required. Snapshot policy ID
285
385
  # @param [String] fields
286
386
  # Selector specifying which fields to include in a partial response.
287
387
  # @param [String] quota_user
@@ -291,37 +391,30 @@ module Google
291
391
  # Request-specific options
292
392
  #
293
393
  # @yield [result, err] Result & error if block supplied
294
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::TestIamPermissionsResponse] parsed result object
394
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy] parsed result object
295
395
  # @yieldparam err [StandardError] error object if request failed
296
396
  #
297
- # @return [Google::Apis::BaremetalsolutionV2::TestIamPermissionsResponse]
397
+ # @return [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy]
298
398
  #
299
399
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
300
400
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
301
401
  # @raise [Google::Apis::AuthorizationError] Authorization is required
302
- def test_instance_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
303
- command = make_simple_command(:post, 'v2/{+resource}:testIamPermissions', options)
304
- command.request_representation = Google::Apis::BaremetalsolutionV2::TestIamPermissionsRequest::Representation
305
- command.request_object = test_iam_permissions_request_object
306
- command.response_representation = Google::Apis::BaremetalsolutionV2::TestIamPermissionsResponse::Representation
307
- command.response_class = Google::Apis::BaremetalsolutionV2::TestIamPermissionsResponse
308
- command.params['resource'] = resource unless resource.nil?
402
+ def create_project_location_snapshot_schedule_policy(parent, snapshot_schedule_policy_object = nil, snapshot_schedule_policy_id: nil, fields: nil, quota_user: nil, options: nil, &block)
403
+ command = make_simple_command(:post, 'v2/{+parent}/snapshotSchedulePolicies', options)
404
+ command.request_representation = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy::Representation
405
+ command.request_object = snapshot_schedule_policy_object
406
+ command.response_representation = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy::Representation
407
+ command.response_class = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy
408
+ command.params['parent'] = parent unless parent.nil?
409
+ command.query['snapshotSchedulePolicyId'] = snapshot_schedule_policy_id unless snapshot_schedule_policy_id.nil?
309
410
  command.query['fields'] = fields unless fields.nil?
310
411
  command.query['quotaUser'] = quota_user unless quota_user.nil?
311
412
  execute_or_queue_command(command, &block)
312
413
  end
313
414
 
314
- # Starts asynchronous cancellation on a long-running operation. The server makes
315
- # a best effort to cancel the operation, but success is not guaranteed. If the
316
- # server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
317
- # Clients can use Operations.GetOperation or other methods to check whether the
318
- # cancellation succeeded or whether the operation completed despite cancellation.
319
- # On successful cancellation, the operation is not deleted; instead, it becomes
320
- # an operation with an Operation.error value with a google.rpc.Status.code of 1,
321
- # corresponding to `Code.CANCELLED`.
415
+ # Delete a named snapshot schedule policy.
322
416
  # @param [String] name
323
- # The name of the operation resource to be cancelled.
324
- # @param [Google::Apis::BaremetalsolutionV2::CancelOperationRequest] cancel_operation_request_object
417
+ # Required. The name of the snapshot schedule policy to delete.
325
418
  # @param [String] fields
326
419
  # Selector specifying which fields to include in a partial response.
327
420
  # @param [String] quota_user
@@ -339,10 +432,8 @@ module Google
339
432
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
340
433
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
341
434
  # @raise [Google::Apis::AuthorizationError] Authorization is required
342
- def cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
343
- command = make_simple_command(:post, 'v2/{+name}:cancel', options)
344
- command.request_representation = Google::Apis::BaremetalsolutionV2::CancelOperationRequest::Representation
345
- command.request_object = cancel_operation_request_object
435
+ def delete_project_location_snapshot_schedule_policy(name, fields: nil, quota_user: nil, options: nil, &block)
436
+ command = make_simple_command(:delete, 'v2/{+name}', options)
346
437
  command.response_representation = Google::Apis::BaremetalsolutionV2::Empty::Representation
347
438
  command.response_class = Google::Apis::BaremetalsolutionV2::Empty
348
439
  command.params['name'] = name unless name.nil?
@@ -351,12 +442,9 @@ module Google
351
442
  execute_or_queue_command(command, &block)
352
443
  end
353
444
 
354
- # Deletes a long-running operation. This method indicates that the client is no
355
- # longer interested in the operation result. It does not cancel the operation.
356
- # If the server doesn't support this method, it returns `google.rpc.Code.
357
- # UNIMPLEMENTED`.
445
+ # Get details of a single snapshot schedule policy.
358
446
  # @param [String] name
359
- # The name of the operation resource to be deleted.
447
+ # Required. Name of the resource.
360
448
  # @param [String] fields
361
449
  # Selector specifying which fields to include in a partial response.
362
450
  # @param [String] quota_user
@@ -366,28 +454,33 @@ module Google
366
454
  # Request-specific options
367
455
  #
368
456
  # @yield [result, err] Result & error if block supplied
369
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::Empty] parsed result object
457
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy] parsed result object
370
458
  # @yieldparam err [StandardError] error object if request failed
371
459
  #
372
- # @return [Google::Apis::BaremetalsolutionV2::Empty]
460
+ # @return [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy]
373
461
  #
374
462
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
375
463
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
376
464
  # @raise [Google::Apis::AuthorizationError] Authorization is required
377
- def delete_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
378
- command = make_simple_command(:delete, 'v2/{+name}', options)
379
- command.response_representation = Google::Apis::BaremetalsolutionV2::Empty::Representation
380
- command.response_class = Google::Apis::BaremetalsolutionV2::Empty
465
+ def get_project_location_snapshot_schedule_policy(name, fields: nil, quota_user: nil, options: nil, &block)
466
+ command = make_simple_command(:get, 'v2/{+name}', options)
467
+ command.response_representation = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy::Representation
468
+ command.response_class = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy
381
469
  command.params['name'] = name unless name.nil?
382
470
  command.query['fields'] = fields unless fields.nil?
383
471
  command.query['quotaUser'] = quota_user unless quota_user.nil?
384
472
  execute_or_queue_command(command, &block)
385
473
  end
386
474
 
387
- # Gets the latest state of a long-running operation. Clients can use this method
388
- # to poll the operation result at intervals as recommended by the API service.
389
- # @param [String] name
390
- # The name of the operation resource.
475
+ # List snapshot schedule policies in a given project and location.
476
+ # @param [String] parent
477
+ # Required. The parent project containing the Snapshot Schedule Policies.
478
+ # @param [String] filter
479
+ # List filter.
480
+ # @param [Fixnum] page_size
481
+ # The maximum number of items to return.
482
+ # @param [String] page_token
483
+ # The next_page_token value returned from a previous List request, if any.
391
484
  # @param [String] fields
392
485
  # Selector specifying which fields to include in a partial response.
393
486
  # @param [String] quota_user
@@ -397,40 +490,33 @@ module Google
397
490
  # Request-specific options
398
491
  #
399
492
  # @yield [result, err] Result & error if block supplied
400
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::Operation] parsed result object
493
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::ListSnapshotSchedulePoliciesResponse] parsed result object
401
494
  # @yieldparam err [StandardError] error object if request failed
402
495
  #
403
- # @return [Google::Apis::BaremetalsolutionV2::Operation]
496
+ # @return [Google::Apis::BaremetalsolutionV2::ListSnapshotSchedulePoliciesResponse]
404
497
  #
405
498
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
406
499
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
407
500
  # @raise [Google::Apis::AuthorizationError] Authorization is required
408
- def get_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
409
- command = make_simple_command(:get, 'v2/{+name}', options)
410
- command.response_representation = Google::Apis::BaremetalsolutionV2::Operation::Representation
411
- command.response_class = Google::Apis::BaremetalsolutionV2::Operation
412
- command.params['name'] = name unless name.nil?
501
+ def list_project_location_snapshot_schedule_policies(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
502
+ command = make_simple_command(:get, 'v2/{+parent}/snapshotSchedulePolicies', options)
503
+ command.response_representation = Google::Apis::BaremetalsolutionV2::ListSnapshotSchedulePoliciesResponse::Representation
504
+ command.response_class = Google::Apis::BaremetalsolutionV2::ListSnapshotSchedulePoliciesResponse
505
+ command.params['parent'] = parent unless parent.nil?
506
+ command.query['filter'] = filter unless filter.nil?
507
+ command.query['pageSize'] = page_size unless page_size.nil?
508
+ command.query['pageToken'] = page_token unless page_token.nil?
413
509
  command.query['fields'] = fields unless fields.nil?
414
510
  command.query['quotaUser'] = quota_user unless quota_user.nil?
415
511
  execute_or_queue_command(command, &block)
416
512
  end
417
513
 
418
- # Lists operations that match the specified filter in the request. If the server
419
- # doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name`
420
- # binding allows API services to override the binding to use different resource
421
- # name schemes, such as `users/*/operations`. To override the binding, API
422
- # services can add a binding such as `"/v1/`name=users/*`/operations"` to their
423
- # service configuration. For backwards compatibility, the default name includes
424
- # the operations collection id, however overriding users must ensure the name
425
- # binding is the parent resource, without the operations collection id.
514
+ # Update a snapshot schedule policy in the specified project.
426
515
  # @param [String] name
427
- # The name of the operation's parent resource.
428
- # @param [String] filter
429
- # The standard list filter.
430
- # @param [Fixnum] page_size
431
- # The standard list page size.
432
- # @param [String] page_token
433
- # The standard list page token.
516
+ # Output only. The name of the snapshot schedule policy.
517
+ # @param [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy] snapshot_schedule_policy_object
518
+ # @param [String] update_mask
519
+ # Required. The list of fields to update.
434
520
  # @param [String] fields
435
521
  # Selector specifying which fields to include in a partial response.
436
522
  # @param [String] quota_user
@@ -440,28 +526,28 @@ module Google
440
526
  # Request-specific options
441
527
  #
442
528
  # @yield [result, err] Result & error if block supplied
443
- # @yieldparam result [Google::Apis::BaremetalsolutionV2::ListOperationsResponse] parsed result object
529
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy] parsed result object
444
530
  # @yieldparam err [StandardError] error object if request failed
445
531
  #
446
- # @return [Google::Apis::BaremetalsolutionV2::ListOperationsResponse]
532
+ # @return [Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy]
447
533
  #
448
534
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
449
535
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
450
536
  # @raise [Google::Apis::AuthorizationError] Authorization is required
451
- def list_project_location_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
452
- command = make_simple_command(:get, 'v2/{+name}/operations', options)
453
- command.response_representation = Google::Apis::BaremetalsolutionV2::ListOperationsResponse::Representation
454
- command.response_class = Google::Apis::BaremetalsolutionV2::ListOperationsResponse
537
+ def patch_project_location_snapshot_schedule_policy(name, snapshot_schedule_policy_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
538
+ command = make_simple_command(:patch, 'v2/{+name}', options)
539
+ command.request_representation = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy::Representation
540
+ command.request_object = snapshot_schedule_policy_object
541
+ command.response_representation = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy::Representation
542
+ command.response_class = Google::Apis::BaremetalsolutionV2::SnapshotSchedulePolicy
455
543
  command.params['name'] = name unless name.nil?
456
- command.query['filter'] = filter unless filter.nil?
457
- command.query['pageSize'] = page_size unless page_size.nil?
458
- command.query['pageToken'] = page_token unless page_token.nil?
544
+ command.query['updateMask'] = update_mask unless update_mask.nil?
459
545
  command.query['fields'] = fields unless fields.nil?
460
546
  command.query['quotaUser'] = quota_user unless quota_user.nil?
461
547
  execute_or_queue_command(command, &block)
462
548
  end
463
549
 
464
- # Gets details of a single Volume.
550
+ # Get details of a single storage volume.
465
551
  # @param [String] name
466
552
  # Required. Name of the resource.
467
553
  # @param [String] fields
@@ -491,18 +577,16 @@ module Google
491
577
  execute_or_queue_command(command, &block)
492
578
  end
493
579
 
494
- # Lists Volumes in a given project and location.
580
+ # List storage volumes in a given project and location.
495
581
  # @param [String] parent
496
582
  # Required. Parent value for ListVolumesRequest.
497
583
  # @param [String] filter
498
- # Filtering results.
499
- # @param [String] order_by
500
- # Hint for how to order the results.
584
+ # List filter.
501
585
  # @param [Fixnum] page_size
502
- # Requested page size. Server may return fewer items than requested. If
586
+ # Requested page size. The server might return fewer items than requested. If
503
587
  # unspecified, server will pick an appropriate default.
504
588
  # @param [String] page_token
505
- # A token identifying a page of results the server should return.
589
+ # A token identifying a page of results from the server.
506
590
  # @param [String] fields
507
591
  # Selector specifying which fields to include in a partial response.
508
592
  # @param [String] quota_user
@@ -520,19 +604,288 @@ module Google
520
604
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
521
605
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
522
606
  # @raise [Google::Apis::AuthorizationError] Authorization is required
523
- def list_project_location_volumes(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
607
+ def list_project_location_volumes(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
524
608
  command = make_simple_command(:get, 'v2/{+parent}/volumes', options)
525
609
  command.response_representation = Google::Apis::BaremetalsolutionV2::ListVolumesResponse::Representation
526
610
  command.response_class = Google::Apis::BaremetalsolutionV2::ListVolumesResponse
527
611
  command.params['parent'] = parent unless parent.nil?
528
612
  command.query['filter'] = filter unless filter.nil?
529
- command.query['orderBy'] = order_by unless order_by.nil?
530
613
  command.query['pageSize'] = page_size unless page_size.nil?
531
614
  command.query['pageToken'] = page_token unless page_token.nil?
532
615
  command.query['fields'] = fields unless fields.nil?
533
616
  command.query['quotaUser'] = quota_user unless quota_user.nil?
534
617
  execute_or_queue_command(command, &block)
535
618
  end
619
+
620
+ # Update details of a single storage volume.
621
+ # @param [String] name
622
+ # Output only. The resource name of this `Volume`. Resource names are schemeless
623
+ # URIs that follow the conventions in https://cloud.google.com/apis/design/
624
+ # resource_names. Format: `projects/`project`/locations/`location`/volumes/`
625
+ # volume``
626
+ # @param [Google::Apis::BaremetalsolutionV2::Volume] volume_object
627
+ # @param [String] update_mask
628
+ # The list of fields to update. The only currently supported fields are: `
629
+ # snapshot_auto_delete_behavior` `snapshot_schedule_policy_name` 'labels'
630
+ # @param [String] fields
631
+ # Selector specifying which fields to include in a partial response.
632
+ # @param [String] quota_user
633
+ # Available to use for quota purposes for server-side applications. Can be any
634
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
635
+ # @param [Google::Apis::RequestOptions] options
636
+ # Request-specific options
637
+ #
638
+ # @yield [result, err] Result & error if block supplied
639
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Operation] parsed result object
640
+ # @yieldparam err [StandardError] error object if request failed
641
+ #
642
+ # @return [Google::Apis::BaremetalsolutionV2::Operation]
643
+ #
644
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
645
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
646
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
647
+ def patch_project_location_volume(name, volume_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
648
+ command = make_simple_command(:patch, 'v2/{+name}', options)
649
+ command.request_representation = Google::Apis::BaremetalsolutionV2::Volume::Representation
650
+ command.request_object = volume_object
651
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Operation::Representation
652
+ command.response_class = Google::Apis::BaremetalsolutionV2::Operation
653
+ command.params['name'] = name unless name.nil?
654
+ command.query['updateMask'] = update_mask unless update_mask.nil?
655
+ command.query['fields'] = fields unless fields.nil?
656
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
657
+ execute_or_queue_command(command, &block)
658
+ end
659
+
660
+ # Get details of a single storage logical unit number(LUN).
661
+ # @param [String] name
662
+ # Required. Name of the resource.
663
+ # @param [String] fields
664
+ # Selector specifying which fields to include in a partial response.
665
+ # @param [String] quota_user
666
+ # Available to use for quota purposes for server-side applications. Can be any
667
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
668
+ # @param [Google::Apis::RequestOptions] options
669
+ # Request-specific options
670
+ #
671
+ # @yield [result, err] Result & error if block supplied
672
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Lun] parsed result object
673
+ # @yieldparam err [StandardError] error object if request failed
674
+ #
675
+ # @return [Google::Apis::BaremetalsolutionV2::Lun]
676
+ #
677
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
678
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
679
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
680
+ def get_project_location_volume_lun(name, fields: nil, quota_user: nil, options: nil, &block)
681
+ command = make_simple_command(:get, 'v2/{+name}', options)
682
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Lun::Representation
683
+ command.response_class = Google::Apis::BaremetalsolutionV2::Lun
684
+ command.params['name'] = name unless name.nil?
685
+ command.query['fields'] = fields unless fields.nil?
686
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
687
+ execute_or_queue_command(command, &block)
688
+ end
689
+
690
+ # List storage volume luns for given storage volume.
691
+ # @param [String] parent
692
+ # Required. Parent value for ListLunsRequest.
693
+ # @param [Fixnum] page_size
694
+ # Requested page size. The server might return fewer items than requested. If
695
+ # unspecified, server will pick an appropriate default.
696
+ # @param [String] page_token
697
+ # A token identifying a page of results from the server.
698
+ # @param [String] fields
699
+ # Selector specifying which fields to include in a partial response.
700
+ # @param [String] quota_user
701
+ # Available to use for quota purposes for server-side applications. Can be any
702
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
703
+ # @param [Google::Apis::RequestOptions] options
704
+ # Request-specific options
705
+ #
706
+ # @yield [result, err] Result & error if block supplied
707
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::ListLunsResponse] parsed result object
708
+ # @yieldparam err [StandardError] error object if request failed
709
+ #
710
+ # @return [Google::Apis::BaremetalsolutionV2::ListLunsResponse]
711
+ #
712
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
713
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
714
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
715
+ def list_project_location_volume_luns(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
716
+ command = make_simple_command(:get, 'v2/{+parent}/luns', options)
717
+ command.response_representation = Google::Apis::BaremetalsolutionV2::ListLunsResponse::Representation
718
+ command.response_class = Google::Apis::BaremetalsolutionV2::ListLunsResponse
719
+ command.params['parent'] = parent unless parent.nil?
720
+ command.query['pageSize'] = page_size unless page_size.nil?
721
+ command.query['pageToken'] = page_token unless page_token.nil?
722
+ command.query['fields'] = fields unless fields.nil?
723
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
724
+ execute_or_queue_command(command, &block)
725
+ end
726
+
727
+ # Create a storage volume snapshot in a containing volume.
728
+ # @param [String] parent
729
+ # Required. The volume to snapshot.
730
+ # @param [Google::Apis::BaremetalsolutionV2::VolumeSnapshot] volume_snapshot_object
731
+ # @param [String] fields
732
+ # Selector specifying which fields to include in a partial response.
733
+ # @param [String] quota_user
734
+ # Available to use for quota purposes for server-side applications. Can be any
735
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
736
+ # @param [Google::Apis::RequestOptions] options
737
+ # Request-specific options
738
+ #
739
+ # @yield [result, err] Result & error if block supplied
740
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::VolumeSnapshot] parsed result object
741
+ # @yieldparam err [StandardError] error object if request failed
742
+ #
743
+ # @return [Google::Apis::BaremetalsolutionV2::VolumeSnapshot]
744
+ #
745
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
746
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
747
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
748
+ def create_project_location_volume_snapshot(parent, volume_snapshot_object = nil, fields: nil, quota_user: nil, options: nil, &block)
749
+ command = make_simple_command(:post, 'v2/{+parent}/snapshots', options)
750
+ command.request_representation = Google::Apis::BaremetalsolutionV2::VolumeSnapshot::Representation
751
+ command.request_object = volume_snapshot_object
752
+ command.response_representation = Google::Apis::BaremetalsolutionV2::VolumeSnapshot::Representation
753
+ command.response_class = Google::Apis::BaremetalsolutionV2::VolumeSnapshot
754
+ command.params['parent'] = parent unless parent.nil?
755
+ command.query['fields'] = fields unless fields.nil?
756
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
757
+ execute_or_queue_command(command, &block)
758
+ end
759
+
760
+ # Deletes a storage volume snapshot for a given volume.
761
+ # @param [String] name
762
+ # Required. The name of the snapshot to delete.
763
+ # @param [String] fields
764
+ # Selector specifying which fields to include in a partial response.
765
+ # @param [String] quota_user
766
+ # Available to use for quota purposes for server-side applications. Can be any
767
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
768
+ # @param [Google::Apis::RequestOptions] options
769
+ # Request-specific options
770
+ #
771
+ # @yield [result, err] Result & error if block supplied
772
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Empty] parsed result object
773
+ # @yieldparam err [StandardError] error object if request failed
774
+ #
775
+ # @return [Google::Apis::BaremetalsolutionV2::Empty]
776
+ #
777
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
778
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
779
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
780
+ def delete_project_location_volume_snapshot(name, fields: nil, quota_user: nil, options: nil, &block)
781
+ command = make_simple_command(:delete, 'v2/{+name}', options)
782
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Empty::Representation
783
+ command.response_class = Google::Apis::BaremetalsolutionV2::Empty
784
+ command.params['name'] = name unless name.nil?
785
+ command.query['fields'] = fields unless fields.nil?
786
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
787
+ execute_or_queue_command(command, &block)
788
+ end
789
+
790
+ # Get details of a single storage volume snapshot.
791
+ # @param [String] name
792
+ # Required. Name of the resource.
793
+ # @param [String] fields
794
+ # Selector specifying which fields to include in a partial response.
795
+ # @param [String] quota_user
796
+ # Available to use for quota purposes for server-side applications. Can be any
797
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
798
+ # @param [Google::Apis::RequestOptions] options
799
+ # Request-specific options
800
+ #
801
+ # @yield [result, err] Result & error if block supplied
802
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::VolumeSnapshot] parsed result object
803
+ # @yieldparam err [StandardError] error object if request failed
804
+ #
805
+ # @return [Google::Apis::BaremetalsolutionV2::VolumeSnapshot]
806
+ #
807
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
808
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
809
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
810
+ def get_project_location_volume_snapshot(name, fields: nil, quota_user: nil, options: nil, &block)
811
+ command = make_simple_command(:get, 'v2/{+name}', options)
812
+ command.response_representation = Google::Apis::BaremetalsolutionV2::VolumeSnapshot::Representation
813
+ command.response_class = Google::Apis::BaremetalsolutionV2::VolumeSnapshot
814
+ command.params['name'] = name unless name.nil?
815
+ command.query['fields'] = fields unless fields.nil?
816
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
817
+ execute_or_queue_command(command, &block)
818
+ end
819
+
820
+ # List storage volume snapshots for given storage volume.
821
+ # @param [String] parent
822
+ # Required. Parent value for ListVolumesRequest.
823
+ # @param [Fixnum] page_size
824
+ # Requested page size. The server might return fewer items than requested. If
825
+ # unspecified, server will pick an appropriate default.
826
+ # @param [String] page_token
827
+ # A token identifying a page of results from the server.
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::BaremetalsolutionV2::ListVolumeSnapshotsResponse] parsed result object
838
+ # @yieldparam err [StandardError] error object if request failed
839
+ #
840
+ # @return [Google::Apis::BaremetalsolutionV2::ListVolumeSnapshotsResponse]
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_volume_snapshots(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
846
+ command = make_simple_command(:get, 'v2/{+parent}/snapshots', options)
847
+ command.response_representation = Google::Apis::BaremetalsolutionV2::ListVolumeSnapshotsResponse::Representation
848
+ command.response_class = Google::Apis::BaremetalsolutionV2::ListVolumeSnapshotsResponse
849
+ command.params['parent'] = parent unless parent.nil?
850
+ command.query['pageSize'] = page_size unless page_size.nil?
851
+ command.query['pageToken'] = page_token unless page_token.nil?
852
+ command.query['fields'] = fields unless fields.nil?
853
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
854
+ execute_or_queue_command(command, &block)
855
+ end
856
+
857
+ # Restore a storage volume snapshot to its containing volume.
858
+ # @param [String] volume_snapshot
859
+ # Required. Name of the resource.
860
+ # @param [Google::Apis::BaremetalsolutionV2::RestoreVolumeSnapshotRequest] restore_volume_snapshot_request_object
861
+ # @param [String] fields
862
+ # Selector specifying which fields to include in a partial response.
863
+ # @param [String] quota_user
864
+ # Available to use for quota purposes for server-side applications. Can be any
865
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
866
+ # @param [Google::Apis::RequestOptions] options
867
+ # Request-specific options
868
+ #
869
+ # @yield [result, err] Result & error if block supplied
870
+ # @yieldparam result [Google::Apis::BaremetalsolutionV2::Operation] parsed result object
871
+ # @yieldparam err [StandardError] error object if request failed
872
+ #
873
+ # @return [Google::Apis::BaremetalsolutionV2::Operation]
874
+ #
875
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
876
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
877
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
878
+ def restore_volume_snapshot(volume_snapshot, restore_volume_snapshot_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
879
+ command = make_simple_command(:post, 'v2/{+volumeSnapshot}:restoreVolumeSnapshot', options)
880
+ command.request_representation = Google::Apis::BaremetalsolutionV2::RestoreVolumeSnapshotRequest::Representation
881
+ command.request_object = restore_volume_snapshot_request_object
882
+ command.response_representation = Google::Apis::BaremetalsolutionV2::Operation::Representation
883
+ command.response_class = Google::Apis::BaremetalsolutionV2::Operation
884
+ command.params['volumeSnapshot'] = volume_snapshot unless volume_snapshot.nil?
885
+ command.query['fields'] = fields unless fields.nil?
886
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
887
+ execute_or_queue_command(command, &block)
888
+ end
536
889
 
537
890
  protected
538
891