google-apis-osconfig_v1 0.9.0 → 0.10.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -213,6 +213,242 @@ module Google
213
213
  execute_or_queue_command(command, &block)
214
214
  end
215
215
 
216
+ # Create an OS policy assignment. This method also creates the first revision of
217
+ # the OS policy assignment. This method returns a long running operation (LRO)
218
+ # that contains the rollout details. The rollout can be cancelled by cancelling
219
+ # the LRO. For more information, see [Method: projects.locations.
220
+ # osPolicyAssignments.operations.cancel](https://cloud.google.com/compute/docs/
221
+ # osconfig/rest/v1/projects.locations.osPolicyAssignments.operations/cancel).
222
+ # @param [String] parent
223
+ # Required. The parent resource name in the form: projects/`project`/locations/`
224
+ # location`
225
+ # @param [Google::Apis::OsconfigV1::OsPolicyAssignment] os_policy_assignment_object
226
+ # @param [String] os_policy_assignment_id
227
+ # Required. The logical name of the OS policy assignment in the project with the
228
+ # following restrictions: * Must contain only lowercase letters, numbers, and
229
+ # hyphens. * Must start with a letter. * Must be between 1-63 characters. * Must
230
+ # end with a number or a letter. * Must be unique within the project.
231
+ # @param [String] fields
232
+ # Selector specifying which fields to include in a partial response.
233
+ # @param [String] quota_user
234
+ # Available to use for quota purposes for server-side applications. Can be any
235
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
236
+ # @param [Google::Apis::RequestOptions] options
237
+ # Request-specific options
238
+ #
239
+ # @yield [result, err] Result & error if block supplied
240
+ # @yieldparam result [Google::Apis::OsconfigV1::Operation] parsed result object
241
+ # @yieldparam err [StandardError] error object if request failed
242
+ #
243
+ # @return [Google::Apis::OsconfigV1::Operation]
244
+ #
245
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
246
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
247
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
248
+ def create_project_location_os_policy_assignment(parent, os_policy_assignment_object = nil, os_policy_assignment_id: nil, fields: nil, quota_user: nil, options: nil, &block)
249
+ command = make_simple_command(:post, 'v1/{+parent}/osPolicyAssignments', options)
250
+ command.request_representation = Google::Apis::OsconfigV1::OsPolicyAssignment::Representation
251
+ command.request_object = os_policy_assignment_object
252
+ command.response_representation = Google::Apis::OsconfigV1::Operation::Representation
253
+ command.response_class = Google::Apis::OsconfigV1::Operation
254
+ command.params['parent'] = parent unless parent.nil?
255
+ command.query['osPolicyAssignmentId'] = os_policy_assignment_id unless os_policy_assignment_id.nil?
256
+ command.query['fields'] = fields unless fields.nil?
257
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
258
+ execute_or_queue_command(command, &block)
259
+ end
260
+
261
+ # Delete the OS policy assignment. This method creates a new revision of the OS
262
+ # policy assignment. This method returns a long running operation (LRO) that
263
+ # contains the rollout details. The rollout can be cancelled by cancelling the
264
+ # LRO. If the LRO completes and is not cancelled, all revisions associated with
265
+ # the OS policy assignment are deleted. For more information, see [Method:
266
+ # projects.locations.osPolicyAssignments.operations.cancel](https://cloud.google.
267
+ # com/compute/docs/osconfig/rest/v1/projects.locations.osPolicyAssignments.
268
+ # operations/cancel).
269
+ # @param [String] name
270
+ # Required. The name of the OS policy assignment to be deleted
271
+ # @param [String] fields
272
+ # Selector specifying which fields to include in a partial response.
273
+ # @param [String] quota_user
274
+ # Available to use for quota purposes for server-side applications. Can be any
275
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
276
+ # @param [Google::Apis::RequestOptions] options
277
+ # Request-specific options
278
+ #
279
+ # @yield [result, err] Result & error if block supplied
280
+ # @yieldparam result [Google::Apis::OsconfigV1::Operation] parsed result object
281
+ # @yieldparam err [StandardError] error object if request failed
282
+ #
283
+ # @return [Google::Apis::OsconfigV1::Operation]
284
+ #
285
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
286
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
287
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
288
+ def delete_project_location_os_policy_assignment(name, fields: nil, quota_user: nil, options: nil, &block)
289
+ command = make_simple_command(:delete, 'v1/{+name}', options)
290
+ command.response_representation = Google::Apis::OsconfigV1::Operation::Representation
291
+ command.response_class = Google::Apis::OsconfigV1::Operation
292
+ command.params['name'] = name unless name.nil?
293
+ command.query['fields'] = fields unless fields.nil?
294
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
295
+ execute_or_queue_command(command, &block)
296
+ end
297
+
298
+ # Retrieve an existing OS policy assignment. This method always returns the
299
+ # latest revision. In order to retrieve a previous revision of the assignment,
300
+ # also provide the revision ID in the `name` parameter.
301
+ # @param [String] name
302
+ # Required. The resource name of OS policy assignment. Format: `projects/`
303
+ # project`/locations/`location`/osPolicyAssignments/`os_policy_assignment`@`
304
+ # revisionId``
305
+ # @param [String] fields
306
+ # Selector specifying which fields to include in a partial response.
307
+ # @param [String] quota_user
308
+ # Available to use for quota purposes for server-side applications. Can be any
309
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
310
+ # @param [Google::Apis::RequestOptions] options
311
+ # Request-specific options
312
+ #
313
+ # @yield [result, err] Result & error if block supplied
314
+ # @yieldparam result [Google::Apis::OsconfigV1::OsPolicyAssignment] parsed result object
315
+ # @yieldparam err [StandardError] error object if request failed
316
+ #
317
+ # @return [Google::Apis::OsconfigV1::OsPolicyAssignment]
318
+ #
319
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
320
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
321
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
322
+ def get_project_location_os_policy_assignment(name, fields: nil, quota_user: nil, options: nil, &block)
323
+ command = make_simple_command(:get, 'v1/{+name}', options)
324
+ command.response_representation = Google::Apis::OsconfigV1::OsPolicyAssignment::Representation
325
+ command.response_class = Google::Apis::OsconfigV1::OsPolicyAssignment
326
+ command.params['name'] = name unless name.nil?
327
+ command.query['fields'] = fields unless fields.nil?
328
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
329
+ execute_or_queue_command(command, &block)
330
+ end
331
+
332
+ # List the OS policy assignments under the parent resource. For each OS policy
333
+ # assignment, the latest revision is returned.
334
+ # @param [String] parent
335
+ # Required. The parent resource name.
336
+ # @param [Fixnum] page_size
337
+ # The maximum number of assignments to return.
338
+ # @param [String] page_token
339
+ # A pagination token returned from a previous call to `ListOSPolicyAssignments`
340
+ # that indicates where this listing should continue from.
341
+ # @param [String] fields
342
+ # Selector specifying which fields to include in a partial response.
343
+ # @param [String] quota_user
344
+ # Available to use for quota purposes for server-side applications. Can be any
345
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
346
+ # @param [Google::Apis::RequestOptions] options
347
+ # Request-specific options
348
+ #
349
+ # @yield [result, err] Result & error if block supplied
350
+ # @yieldparam result [Google::Apis::OsconfigV1::ListOsPolicyAssignmentsResponse] parsed result object
351
+ # @yieldparam err [StandardError] error object if request failed
352
+ #
353
+ # @return [Google::Apis::OsconfigV1::ListOsPolicyAssignmentsResponse]
354
+ #
355
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
356
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
357
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
358
+ def list_project_location_os_policy_assignments(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
359
+ command = make_simple_command(:get, 'v1/{+parent}/osPolicyAssignments', options)
360
+ command.response_representation = Google::Apis::OsconfigV1::ListOsPolicyAssignmentsResponse::Representation
361
+ command.response_class = Google::Apis::OsconfigV1::ListOsPolicyAssignmentsResponse
362
+ command.params['parent'] = parent unless parent.nil?
363
+ command.query['pageSize'] = page_size unless page_size.nil?
364
+ command.query['pageToken'] = page_token unless page_token.nil?
365
+ command.query['fields'] = fields unless fields.nil?
366
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
367
+ execute_or_queue_command(command, &block)
368
+ end
369
+
370
+ # List the OS policy assignment revisions for a given OS policy assignment.
371
+ # @param [String] name
372
+ # Required. The name of the OS policy assignment to list revisions for.
373
+ # @param [Fixnum] page_size
374
+ # The maximum number of revisions to return.
375
+ # @param [String] page_token
376
+ # A pagination token returned from a previous call to `
377
+ # ListOSPolicyAssignmentRevisions` that indicates where this listing should
378
+ # continue from.
379
+ # @param [String] fields
380
+ # Selector specifying which fields to include in a partial response.
381
+ # @param [String] quota_user
382
+ # Available to use for quota purposes for server-side applications. Can be any
383
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
384
+ # @param [Google::Apis::RequestOptions] options
385
+ # Request-specific options
386
+ #
387
+ # @yield [result, err] Result & error if block supplied
388
+ # @yieldparam result [Google::Apis::OsconfigV1::ListOsPolicyAssignmentRevisionsResponse] parsed result object
389
+ # @yieldparam err [StandardError] error object if request failed
390
+ #
391
+ # @return [Google::Apis::OsconfigV1::ListOsPolicyAssignmentRevisionsResponse]
392
+ #
393
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
394
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
395
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
396
+ def list_project_location_os_policy_assignment_revisions(name, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
397
+ command = make_simple_command(:get, 'v1/{+name}:listRevisions', options)
398
+ command.response_representation = Google::Apis::OsconfigV1::ListOsPolicyAssignmentRevisionsResponse::Representation
399
+ command.response_class = Google::Apis::OsconfigV1::ListOsPolicyAssignmentRevisionsResponse
400
+ command.params['name'] = name unless name.nil?
401
+ command.query['pageSize'] = page_size unless page_size.nil?
402
+ command.query['pageToken'] = page_token unless page_token.nil?
403
+ command.query['fields'] = fields unless fields.nil?
404
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
405
+ execute_or_queue_command(command, &block)
406
+ end
407
+
408
+ # Update an existing OS policy assignment. This method creates a new revision of
409
+ # the OS policy assignment. This method returns a long running operation (LRO)
410
+ # that contains the rollout details. The rollout can be cancelled by cancelling
411
+ # the LRO. For more information, see [Method: projects.locations.
412
+ # osPolicyAssignments.operations.cancel](https://cloud.google.com/compute/docs/
413
+ # osconfig/rest/v1/projects.locations.osPolicyAssignments.operations/cancel).
414
+ # @param [String] name
415
+ # Resource name. Format: `projects/`project_number`/locations/`location`/
416
+ # osPolicyAssignments/`os_policy_assignment_id`` This field is ignored when you
417
+ # create an OS policy assignment.
418
+ # @param [Google::Apis::OsconfigV1::OsPolicyAssignment] os_policy_assignment_object
419
+ # @param [String] update_mask
420
+ # Optional. Field mask that controls which fields of the assignment should be
421
+ # updated.
422
+ # @param [String] fields
423
+ # Selector specifying which fields to include in a partial response.
424
+ # @param [String] quota_user
425
+ # Available to use for quota purposes for server-side applications. Can be any
426
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
427
+ # @param [Google::Apis::RequestOptions] options
428
+ # Request-specific options
429
+ #
430
+ # @yield [result, err] Result & error if block supplied
431
+ # @yieldparam result [Google::Apis::OsconfigV1::Operation] parsed result object
432
+ # @yieldparam err [StandardError] error object if request failed
433
+ #
434
+ # @return [Google::Apis::OsconfigV1::Operation]
435
+ #
436
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
437
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
438
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
439
+ def patch_project_location_os_policy_assignment(name, os_policy_assignment_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
440
+ command = make_simple_command(:patch, 'v1/{+name}', options)
441
+ command.request_representation = Google::Apis::OsconfigV1::OsPolicyAssignment::Representation
442
+ command.request_object = os_policy_assignment_object
443
+ command.response_representation = Google::Apis::OsconfigV1::Operation::Representation
444
+ command.response_class = Google::Apis::OsconfigV1::Operation
445
+ command.params['name'] = name unless name.nil?
446
+ command.query['updateMask'] = update_mask unless update_mask.nil?
447
+ command.query['fields'] = fields unless fields.nil?
448
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
449
+ execute_or_queue_command(command, &block)
450
+ end
451
+
216
452
  # Create an OS Config patch deployment.
217
453
  # @param [String] parent
218
454
  # Required. The project to apply this patch deployment to in the form `projects/*
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-osconfig_v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.0
4
+ version: 0.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-09-06 00:00:00.000000000 Z
11
+ date: 2021-09-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -58,7 +58,7 @@ licenses:
58
58
  metadata:
59
59
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
60
60
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/master/generated/google-apis-osconfig_v1/CHANGELOG.md
61
- documentation_uri: https://googleapis.dev/ruby/google-apis-osconfig_v1/v0.9.0
61
+ documentation_uri: https://googleapis.dev/ruby/google-apis-osconfig_v1/v0.10.0
62
62
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/master/generated/google-apis-osconfig_v1
63
63
  post_install_message:
64
64
  rdoc_options: []