Class: Google::Apis::AccesscontextmanagerV1beta::AccessContextManagerService

Inherits:
Core::BaseService
  • Object
show all
Defined in:
generated/google/apis/accesscontextmanager_v1beta/service.rb

Overview

Access Context Manager API

An API for setting attribute based access control to requests to GCP services.

Examples:

require 'google/apis/accesscontextmanager_v1beta'

Accesscontextmanager = Google::Apis::AccesscontextmanagerV1beta # Alias the module
service = Accesscontextmanager::AccessContextManagerService.new

See Also:

Instance Attribute Summary collapse

Attributes inherited from Core::BaseService

#authorization, #base_path, #batch_path, #client, #client_options, #request_options, #root_url, #upload_path

Instance Method Summary collapse

Methods inherited from Core::BaseService

#batch, #batch_upload, #fetch_all, #http

Methods included from Core::Logging

#logger

Constructor Details

#initializeAccessContextManagerService


45
46
47
48
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 45

def initialize
  super('https://accesscontextmanager.googleapis.com/', '')
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString


38
39
40
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 38

def key
  @key
end

#quota_userString


43
44
45
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 43

def quota_user
  @quota_user
end

Instance Method Details

#create_access_policy(access_policy_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Create an AccessPolicy. Fails if this organization already has a AccessPolicy. The longrunning Operation will have a successful status once the AccessPolicy has propagated to long-lasting storage. Syntactic and basic semantic errors will be returned in metadata as a BadRequest proto.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


73
74
75
76
77
78
79
80
81
82
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 73

def create_access_policy(access_policy_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1beta/accessPolicies', options)
  command.request_representation = Google::Apis::AccesscontextmanagerV1beta::AccessPolicy::Representation
  command.request_object = access_policy_object
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_access_policy_access_level(parent, access_level_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Create an Access Level. The longrunning operation from this RPC will have a successful status once the Access Level has propagated to long-lasting storage. Access Levels containing errors will result in an error response for the first error encountered.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


258
259
260
261
262
263
264
265
266
267
268
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 258

def create_access_policy_access_level(parent, access_level_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1beta/{+parent}/accessLevels', options)
  command.request_representation = Google::Apis::AccesscontextmanagerV1beta::AccessLevel::Representation
  command.request_object = access_level_object
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_access_policy_service_perimeter(parent, service_perimeter_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Create an Service Perimeter. The longrunning operation from this RPC will have a successful status once the Service Perimeter has propagated to long-lasting storage. Service Perimeters containing errors will result in an error response for the first error encountered.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


462
463
464
465
466
467
468
469
470
471
472
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 462

def create_access_policy_service_perimeter(parent, service_perimeter_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1beta/{+parent}/servicePerimeters', options)
  command.request_representation = Google::Apis::AccesscontextmanagerV1beta::ServicePerimeter::Representation
  command.request_object = service_perimeter_object
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_access_policy(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Delete an AccessPolicy by resource name. The longrunning Operation will have a successful status once the AccessPolicy has been removed from long-lasting storage.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


108
109
110
111
112
113
114
115
116
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 108

def delete_access_policy(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_access_policy_access_level(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Delete an Access Level by resource name. The longrunning operation from this RPC will have a successful status once the Access Level has been removed from long-lasting storage.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


295
296
297
298
299
300
301
302
303
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 295

def delete_access_policy_access_level(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_access_policy_service_perimeter(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Delete an Service Perimeter by resource name. The longrunning operation from this RPC will have a successful status once the Service Perimeter has been removed from long-lasting storage.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


499
500
501
502
503
504
505
506
507
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 499

def delete_access_policy_service_perimeter(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_access_policy(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::AccessPolicy

Get an AccessPolicy by name.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


139
140
141
142
143
144
145
146
147
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 139

def get_access_policy(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::AccessPolicy::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::AccessPolicy
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_access_policy_access_level(name, access_level_format: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::AccessLevel

Get an Access Level by resource name.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


336
337
338
339
340
341
342
343
344
345
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 336

def get_access_policy_access_level(name, access_level_format: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::AccessLevel::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::AccessLevel
  command.params['name'] = name unless name.nil?
  command.query['accessLevelFormat'] = access_level_format unless access_level_format.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_access_policy_service_perimeter(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::ServicePerimeter

Get an Service Perimeter by resource name.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


532
533
534
535
536
537
538
539
540
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 532

def get_access_policy_service_perimeter(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::ServicePerimeter::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::ServicePerimeter
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


647
648
649
650
651
652
653
654
655
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 647

def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/{+name}', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_access_policies(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::ListAccessPoliciesResponse

List all AccessPolicies under a container.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


178
179
180
181
182
183
184
185
186
187
188
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 178

def list_access_policies(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/accessPolicies', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::ListAccessPoliciesResponse::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::ListAccessPoliciesResponse
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_access_policy_access_levels(parent, access_level_format: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::ListAccessLevelsResponse

List all Access Levels for an access policy.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


380
381
382
383
384
385
386
387
388
389
390
391
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 380

def list_access_policy_access_levels(parent, access_level_format: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/{+parent}/accessLevels', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::ListAccessLevelsResponse::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::ListAccessLevelsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['accessLevelFormat'] = access_level_format unless access_level_format.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_access_policy_service_perimeters(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::ListServicePerimetersResponse

List all Service Perimeters for an access policy.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


571
572
573
574
575
576
577
578
579
580
581
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 571

def list_access_policy_service_perimeters(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1beta/{+parent}/servicePerimeters', options)
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::ListServicePerimetersResponse::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::ListServicePerimetersResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_access_policy(name, access_policy_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Update an AccessPolicy. The longrunning Operation from this RPC will have a successful status once the changes to the AccessPolicy have propagated to long-lasting storage. Syntactic and basic semantic errors will be returned in metadata as a BadRequest proto.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


218
219
220
221
222
223
224
225
226
227
228
229
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 218

def patch_access_policy(name, access_policy_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:patch, 'v1beta/{+name}', options)
  command.request_representation = Google::Apis::AccesscontextmanagerV1beta::AccessPolicy::Representation
  command.request_object = access_policy_object
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_access_policy_access_level(name, access_level_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Update an Access Level. The longrunning operation from this RPC will have a successful status once the changes to the Access Level have propagated to long-lasting storage. Access Levels containing errors will result in an error response for the first error encountered.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


422
423
424
425
426
427
428
429
430
431
432
433
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 422

def patch_access_policy_access_level(name, access_level_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:patch, 'v1beta/{+name}', options)
  command.request_representation = Google::Apis::AccesscontextmanagerV1beta::AccessLevel::Representation
  command.request_object = access_level_object
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_access_policy_service_perimeter(name, service_perimeter_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AccesscontextmanagerV1beta::Operation

Update an Service Perimeter. The longrunning operation from this RPC will have a successful status once the changes to the Service Perimeter have propagated to long-lasting storage. Service Perimeter containing errors will result in an error response for the first error encountered.

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Raises:


612
613
614
615
616
617
618
619
620
621
622
623
# File 'generated/google/apis/accesscontextmanager_v1beta/service.rb', line 612

def patch_access_policy_service_perimeter(name, service_perimeter_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:patch, 'v1beta/{+name}', options)
  command.request_representation = Google::Apis::AccesscontextmanagerV1beta::ServicePerimeter::Representation
  command.request_object = service_perimeter_object
  command.response_representation = Google::Apis::AccesscontextmanagerV1beta::Operation::Representation
  command.response_class = Google::Apis::AccesscontextmanagerV1beta::Operation
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end