Class: Google::Apis::CloudresourcemanagerV3::CloudResourceManagerService

Inherits:
Google::Apis::Core::BaseService
  • Object
show all
Defined in:
lib/google/apis/cloudresourcemanager_v3/service.rb

Overview

Cloud Resource Manager API

Creates, reads, and updates metadata for Google Cloud Platform resource containers.

Examples:

require 'google/apis/cloudresourcemanager_v3'

Cloudresourcemanager = Google::Apis::CloudresourcemanagerV3 # Alias the module
service = Cloudresourcemanager::CloudResourceManagerService.new

See Also:

Constant Summary collapse

DEFAULT_ENDPOINT_TEMPLATE =
"https://cloudresourcemanager.$UNIVERSE_DOMAIN$/"

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeCloudResourceManagerService

Returns a new instance of CloudResourceManagerService.



48
49
50
51
52
53
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 48

def initialize
  super(DEFAULT_ENDPOINT_TEMPLATE, '',
        client_name: 'google-apis-cloudresourcemanager_v3',
        client_version: Google::Apis::CloudresourcemanagerV3::GEM_VERSION)
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString

Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.

Returns:

  • (String)

    API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.



41
42
43
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 41

def key
  @key
end

#quota_userString

Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

Returns:

  • (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.



46
47
48
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 46

def quota_user
  @quota_user
end

Instance Method Details

#create_folder(folder_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Creates a folder in the resource hierarchy. Returns an Operation which can be used to track the progress of the folder creation workflow. Upon success, the Operation.response field will be populated with the created Folder. In order to succeed, the addition of this new folder must not violate the folder naming, height, or fanout constraints. + The folder's display_name must be distinct from all other folders that share its parent. + The addition of the folder must not cause the active folder hierarchy to exceed a height of 10. Note, the full active + deleted folder hierarchy is allowed to reach a height of 20; this provides additional headroom when moving folders that contain deleted folders. + The addition of the folder must not cause the total number of folders under its parent to exceed 300. If the operation fails due to a folder constraint violation, some errors may be returned by the CreateFolder request, with status code FAILED_PRECONDITION and an error description. Other folder constraint violations will be communicated in the Operation, with the specific PreconditionFailure returned in the details list in the Operation.error field. The caller must have resourcemanager.folders.create permission on the identified parent.

Parameters:

  • folder_object (Google::Apis::CloudresourcemanagerV3::Folder) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



131
132
133
134
135
136
137
138
139
140
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 131

def create_folder(folder_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/folders', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::Folder::Representation
  command.request_object = folder_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_lien(lien_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Lien

Create a Lien which applies to the resource denoted by the parent field. Callers of this method will require permission on the parent resource. For example, applying to projects/1234 requires permission resourcemanager. projects.updateLiens. NOTE: Some resources may limit the number of Liens which may be applied.

Parameters:

  • lien_object (Google::Apis::CloudresourcemanagerV3::Lien) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



661
662
663
664
665
666
667
668
669
670
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 661

def create_lien(lien_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/liens', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::Lien::Representation
  command.request_object = lien_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Lien::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Lien
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_project(project_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Request that a new project be created. The result is an Operation which can be used to track the creation process. This process usually takes a few seconds, but can sometimes take much longer. The tracking Operation is automatically deleted after a few hours, so there is no need to call DeleteOperation.

Parameters:

  • project_object (Google::Apis::CloudresourcemanagerV3::Project) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1143

def create_project(project_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/projects', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::Project::Representation
  command.request_object = project_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_tag_binding(tag_binding_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Creates a TagBinding between a TagValue and a Google Cloud resource.

Parameters:

  • tag_binding_object (Google::Apis::CloudresourcemanagerV3::TagBinding) (defaults to: nil)
  • validate_only (Boolean) (defaults to: nil)

    Optional. Set to true to perform the validations necessary for creating the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1616

def create_tag_binding(tag_binding_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/tagBindings', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagBinding::Representation
  command.request_object = tag_binding_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.query['validateOnly'] = validate_only unless validate_only.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_tag_key(tag_key_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Creates a new TagKey. If another request with the same parameters is sent while the original request is in process, the second request will receive an error. A maximum of 1000 TagKeys can exist under a parent at any given time.

Parameters:

  • tag_key_object (Google::Apis::CloudresourcemanagerV3::TagKey) (defaults to: nil)
  • validate_only (Boolean) (defaults to: nil)

    Optional. Set to true to perform validations necessary for creating the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1726

def create_tag_key(tag_key_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/tagKeys', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagKey::Representation
  command.request_object = tag_key_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.query['validateOnly'] = validate_only unless validate_only.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_tag_value(tag_value_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Creates a TagValue as a child of the specified TagKey. If a another request with the same parameters is sent while the original request is in process the second request will receive an error. A maximum of 1000 TagValues can exist under a TagKey at any given time.

Parameters:

  • tag_value_object (Google::Apis::CloudresourcemanagerV3::TagValue) (defaults to: nil)
  • validate_only (Boolean) (defaults to: nil)

    Optional. Set as true to perform the validations necessary for creating the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2065

def create_tag_value(tag_value_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/tagValues', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagValue::Representation
  command.request_object = tag_value_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.query['validateOnly'] = validate_only unless validate_only.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_tag_value_tag_hold(parent, tag_hold_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Creates a TagHold. Returns ALREADY_EXISTS if a TagHold with the same resource and origin exists under the same TagValue.

Parameters:

  • parent (String)

    Required. The resource name of the TagHold's parent TagValue. Must be of the form: tagValues/tag-value-id``.

  • tag_hold_object (Google::Apis::CloudresourcemanagerV3::TagHold) (defaults to: nil)
  • validate_only (Boolean) (defaults to: nil)

    Optional. Set to true to perform the validations necessary for creating the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2403

def create_tag_value_tag_hold(parent, tag_hold_object = nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+parent}/tagHolds', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagHold::Representation
  command.request_object = tag_hold_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.params['parent'] = parent unless parent.nil?
  command.query['validateOnly'] = validate_only unless validate_only.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_folder(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Requests deletion of a folder. The folder is moved into the DELETE_REQUESTED state immediately, and is deleted approximately 30 days later. This method may only be called on an empty folder, where a folder is empty if it doesn't contain any folders or projects in the ACTIVE state. If called on a folder in DELETE_REQUESTED state the operation will result in a no-op success. The caller must have resourcemanager.folders.delete permission on the identified folder.

Parameters:

  • name (String)

    Required. The resource name of the folder to be deleted. Must be of the form folders/folder_id``.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



169
170
171
172
173
174
175
176
177
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 169

def delete_folder(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_lien(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Empty

Delete a Lien by name. Callers of this method will require permission on the parent resource. For example, a Lien with a parent of projects/1234 requires permission resourcemanager.projects.updateLiens.

Parameters:

  • name (String)

    Required. The name/identifier of the Lien to delete.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



694
695
696
697
698
699
700
701
702
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 694

def delete_lien(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Empty::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Empty
  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_project(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Marks the project identified by the specified name (for example, projects/ 415104041262) for deletion. This method will only affect the project if it has a lifecycle state of ACTIVE. This method changes the Project's lifecycle state from ACTIVE to DELETE_REQUESTED. The deletion starts at an unspecified time, at which point the Project is no longer accessible. Until the deletion completes, you can check the lifecycle state checked by retrieving the project with GetProject, and the project remains visible to ListProjects. However, you cannot update the project. After the deletion completes, the project is not retrievable by the GetProject, ListProjects, and SearchProjects methods. The caller must have resourcemanager.projects.delete permissions for this project.

Parameters:

  • name (String)

    Required. The name of the Project (for example, projects/415104041262).

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1184
1185
1186
1187
1188
1189
1190
1191
1192
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1184

def delete_project(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_tag_binding(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Deletes a TagBinding.

Parameters:

  • name (String)

    Required. The name of the TagBinding. This is a String of the form: tagBindings/id`(e.g.tagBindings/%2F%2Fcloudresourcemanager.googleapis.com% 2Fprojects%2F123/tagValues/456`).

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1650
1651
1652
1653
1654
1655
1656
1657
1658
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1650

def delete_tag_binding(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_tag_key(name, etag: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Deletes a TagKey. The TagKey cannot be deleted if it has any child TagValues.

Parameters:

  • name (String)

    Required. The resource name of a TagKey to be deleted in the format tagKeys/ 123. The TagKey cannot be a parent of any existing TagValues or it will not be deleted successfully.

  • etag (String) (defaults to: nil)

    Optional. The etag known to the client for the expected state of the TagKey. This is to be used for optimistic concurrency.

  • validate_only (Boolean) (defaults to: nil)

    Optional. Set as true to perform validations necessary for deletion, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1766

def delete_tag_key(name, etag: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.params['name'] = name unless name.nil?
  command.query['etag'] = etag unless etag.nil?
  command.query['validateOnly'] = validate_only unless validate_only.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_tag_value(name, etag: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Deletes a TagValue. The TagValue cannot have any bindings when it is deleted.

Parameters:

  • name (String)

    Required. Resource name for TagValue to be deleted in the format tagValues/456.

  • etag (String) (defaults to: nil)

    Optional. The etag known to the client for the expected state of the TagValue. This is to be used for optimistic concurrency.

  • validate_only (Boolean) (defaults to: nil)

    Optional. Set as true to perform the validations necessary for deletion, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2103

def delete_tag_value(name, etag: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.params['name'] = name unless name.nil?
  command.query['etag'] = etag unless etag.nil?
  command.query['validateOnly'] = validate_only unless validate_only.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_tag_value_tag_hold(name, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Deletes a TagHold.

Parameters:

  • name (String)

    Required. The resource name of the TagHold to delete. Must be of the form: tagValues/tag-value-id/tagHolds/tag-hold-id``.

  • validate_only (Boolean) (defaults to: nil)

    Optional. Set to true to perform the validations necessary for deleting the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2440

def delete_tag_value_tag_hold(name, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:delete, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.params['name'] = name unless name.nil?
  command.query['validateOnly'] = validate_only unless validate_only.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_folder(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Folder

Retrieves a folder identified by the supplied resource name. Valid folder resource names have the format folders/folder_id`(for example,folders/ 1234). The caller must haveresourcemanager.folders.get` permission on the identified folder.

Parameters:

  • name (String)

    Required. The resource name of the folder to retrieve. Must be of the form folders/folder_id``.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



203
204
205
206
207
208
209
210
211
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 203

def get_folder(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Folder::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Folder
  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_folder_capability(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Capability

Retrieves the Capability identified by the supplied resource name.

Parameters:

  • name (String)

    Required. The name of the capability to get. For example, folders/123/ capabilities/app-management

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



589
590
591
592
593
594
595
596
597
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 589

def get_folder_capability(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Capability::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Capability
  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_folder_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Gets the access control policy for a folder. The returned policy may be empty if no such policy or resource exists. The resource field should be the folder's resource name, for example: "folders/1234". The caller must have resourcemanager.folders.getIamPolicy permission on the identified folder.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being requested. See Resource names for the appropriate value for this field.

  • get_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



239
240
241
242
243
244
245
246
247
248
249
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 239

def get_folder_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:getIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest::Representation
  command.request_object = get_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.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_lien(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Lien

Retrieve a Lien by name. Callers of this method will require permission on the parent resource. For example, a Lien with a parent of projects/1234 requires permission resourcemanager.projects.get

Parameters:

  • name (String)

    Required. The name/identifier of the Lien.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



726
727
728
729
730
731
732
733
734
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 726

def get_lien(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Lien::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Lien
  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_location_effective_tag_binding_collection(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::EffectiveTagBindingCollection

Returns effective tag bindings on a GCP resource.

Parameters:

  • name (String)

    Required. The full name of the EffectiveTagBindingCollection in format: locations/location/effectiveTagBindingCollections/encoded-full-resource- name`` where the encoded-full-resource-name is the UTF-8 encoded name of the resource the TagBindings are bound to. E.g. "locations/global/ effectiveTagBindingCollections/%2f%2fcloudresourcemanager.googleapis.com% 2fprojects%2f123"

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



804
805
806
807
808
809
810
811
812
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 804

def get_location_effective_tag_binding_collection(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::EffectiveTagBindingCollection::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::EffectiveTagBindingCollection
  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_location_tag_binding_collection(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TagBindingCollection

Returns tag bindings directly attached to a GCP resource.

Parameters:

  • name (String)

    Required. The full name of the TagBindingCollection in format: locations/ location/tagBindingCollections/encoded-full-resource-name`` where the enoded- full-resource-name is the UTF-8 encoded name of the resource the TagBindings are bound to. E.g. "locations/global/tagBindingCollections/%2f% 2fcloudresourcemanager.googleapis.com%2fprojects%2f123"

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



838
839
840
841
842
843
844
845
846
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 838

def get_location_tag_binding_collection(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TagBindingCollection::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TagBindingCollection
  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::CloudresourcemanagerV3::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.

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



910
911
912
913
914
915
916
917
918
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 910

def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_organization(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Organization

Fetches an organization resource identified by the specified resource name.

Parameters:

  • name (String)

    Required. The resource name of the Organization to fetch. This is the organization's relative path in the API, formatted as "organizations/[ organizationId]". For example, "organizations/1234".

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



942
943
944
945
946
947
948
949
950
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 942

def get_organization(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Organization::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Organization
  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_organization_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Gets the access control policy for an organization resource. The policy may be empty if no such policy or resource exists. The resource field should be the organization's resource name, for example: "organizations/123". Authorization requires the IAM permission resourcemanager.organizations.getIamPolicy on the specified organization.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being requested. See Resource names for the appropriate value for this field.

  • get_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



979
980
981
982
983
984
985
986
987
988
989
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 979

def get_organization_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:getIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest::Representation
  command.request_object = get_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.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_project(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Project

Retrieves the project identified by the specified name (for example, projects/415104041262). The caller must have resourcemanager.projects.get permission for this project.

Parameters:

  • name (String)

    Required. The name of the project (for example, projects/415104041262).

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1216
1217
1218
1219
1220
1221
1222
1223
1224
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1216

def get_project(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Project::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Project
  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_project_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Returns the IAM access control policy for the specified project, in the format projects/ProjectIdOrNumber`` e.g. projects/123. Permission is denied if the policy or the resource do not exist.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being requested. See Resource names for the appropriate value for this field.

  • get_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1251

def get_project_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:getIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest::Representation
  command.request_object = get_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.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_tag_key(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TagKey

Retrieves a TagKey. This method will return PERMISSION_DENIED if the key does not exist or the user does not have permission to view it.

Parameters:

  • name (String)

    Required. A resource name in the format tagKeys/id`, such astagKeys/123`.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1799
1800
1801
1802
1803
1804
1805
1806
1807
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1799

def get_tag_key(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TagKey::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TagKey
  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_tag_key_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Gets the access control policy for a TagKey. The returned policy may be empty if no such policy or resource exists. The resource field should be the TagKey's resource name. For example, "tagKeys/1234". The caller must have cloudresourcemanager.googleapis.com/tagKeys.getIamPolicy permission on the specified TagKey.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being requested. See Resource names for the appropriate value for this field.

  • get_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1836

def get_tag_key_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:getIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest::Representation
  command.request_object = get_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.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_tag_key_namespaced(name: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TagKey

Retrieves a TagKey by its namespaced name. This method will return PERMISSION_DENIED if the key does not exist or the user does not have permission to view it.

Parameters:

  • name (String) (defaults to: nil)

    Required. A namespaced tag key name in the format parentId`/`tagKeyShort, such as 42/foo for a key with short name "foo" under the organization with ID 42 or r2-d2/bar for a key with short name "bar" under the project r2-d2.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1872
1873
1874
1875
1876
1877
1878
1879
1880
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1872

def get_tag_key_namespaced(name: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/tagKeys/namespaced', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TagKey::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TagKey
  command.query['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_tag_value(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TagValue

Retrieves a TagValue. This method will return PERMISSION_DENIED if the value does not exist or the user does not have permission to view it.

Parameters:

  • name (String)

    Required. Resource name for TagValue to be fetched in the format tagValues/ 456.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2137
2138
2139
2140
2141
2142
2143
2144
2145
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2137

def get_tag_value(name, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+name}', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TagValue::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TagValue
  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_tag_value_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Gets the access control policy for a TagValue. The returned policy may be empty if no such policy or resource exists. The resource field should be the TagValue's resource name. For example: tagValues/1234. The caller must have the cloudresourcemanager.googleapis.com/tagValues.getIamPolicy permission on the identified TagValue to get the access control policy.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being requested. See Resource names for the appropriate value for this field.

  • get_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2174

def get_tag_value_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:getIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::GetIamPolicyRequest::Representation
  command.request_object = get_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.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_tag_value_namespaced(name: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TagValue

Retrieves a TagValue by its namespaced name. This method will return PERMISSION_DENIED if the value does not exist or the user does not have permission to view it.

Parameters:

  • name (String) (defaults to: nil)

    Required. A namespaced tag value name in the following format: parentId`/` tagKeyShort`/`tagValueShort Examples: - 42/foo/abc for a value with short name "abc" under the key with short name "foo" under the organization with ID 42 - r2-d2/bar/xyz for a value with short name "xyz" under the key with short name "bar" under the project with ID "r2-d2"

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2212
2213
2214
2215
2216
2217
2218
2219
2220
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2212

def get_tag_value_namespaced(name: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/tagValues/namespaced', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TagValue::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TagValue
  command.query['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_effective_tags(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListEffectiveTagsResponse

Return a list of effective tags for the given Google Cloud resource, as specified in parent.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of effective tags to return in the response. The server allows a maximum of 300 effective tags to return in a single page. If unspecified, the server will use 100 as the default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListEffectiveTags that indicates from where this listing should continue.

  • parent (String) (defaults to: nil)

    Required. The full resource name of a resource for which you want to list the effective tags. E.g. "//cloudresourcemanager.googleapis.com/projects/123"

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



84
85
86
87
88
89
90
91
92
93
94
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 84

def list_effective_tags(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/effectiveTags', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListEffectiveTagsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListEffectiveTagsResponse
  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_folders(page_size: nil, page_token: nil, parent: nil, show_deleted: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListFoldersResponse

Lists the folders that are direct descendants of supplied parent resource. list() provides a strongly consistent view of the folders underneath the specified parent resource. list() returns folders sorted based upon the ( ascending) lexical ordering of their display_name. The caller must have resourcemanager.folders.list permission on the identified parent.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of folders to return in the response. The server can return fewer folders than requested. If unspecified, server picks an appropriate default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListFolders that indicates where this listing should continue from.

  • parent (String) (defaults to: nil)

    Required. The name of the parent resource whose folders are being listed. Only children of this parent resource are listed; descendants are not listed. If the parent is a folder, use the value folders/folder_id. If the parent is an organization, use the value `organizations/`org_id. Access to this method is controlled by checking the resourcemanager.folders.list permission on the parent.

  • show_deleted (Boolean) (defaults to: nil)

    Optional. Controls whether folders in the DELETE_REQUESTED state should be returned. Defaults to false.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



290
291
292
293
294
295
296
297
298
299
300
301
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 290

def list_folders(page_size: nil, page_token: nil, parent: nil, show_deleted: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/folders', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListFoldersResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListFoldersResponse
  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['showDeleted'] = show_deleted unless show_deleted.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_liens(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListLiensResponse

List all Liens applied to the parent resource. Callers of this method will require permission on the parent resource. For example, a Lien with a parent of projects/1234 requires permission resourcemanager.projects.get.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of items to return. This is a suggestion for the server. The server can return fewer liens than requested. If unspecified, server picks an appropriate default.

  • page_token (String) (defaults to: nil)

    The next_page_token value returned from a previous List request, if any.

  • parent (String) (defaults to: nil)

    Required. The name of the resource to list all attached Liens. For example, projects/1234. (google.api.field_policy).resource_type annotation is not set since the parent depends on the meta api implementation. This field could be a project or other sub project resources.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



767
768
769
770
771
772
773
774
775
776
777
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 767

def list_liens(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/liens', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListLiensResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListLiensResponse
  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_projects(page_size: nil, page_token: nil, parent: nil, show_deleted: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListProjectsResponse

Lists projects that are direct children of the specified folder or organization resource. list() provides a strongly consistent view of the projects underneath the specified parent resource. list() returns projects sorted based upon the (ascending) lexical ordering of their display_name. The caller must have resourcemanager.projects.list permission on the identified parent.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of projects to return in the response. The server can return fewer projects than requested. If unspecified, server picks an appropriate default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListProjects that indicates from where listing should continue.

  • parent (String) (defaults to: nil)

    Required. The name of the parent resource whose projects are being listed. Only children of this parent resource are listed; descendants are not listed. If the parent is a folder, use the value folders/folder_id. If the parent is an organization, use the value `organizations/`org_id.

  • show_deleted (Boolean) (defaults to: nil)

    Optional. Indicate that projects in the DELETE_REQUESTED state should also be returned. Normally only ACTIVE projects are returned.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1301

def list_projects(page_size: nil, page_token: nil, parent: nil, show_deleted: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/projects', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListProjectsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListProjectsResponse
  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['showDeleted'] = show_deleted unless show_deleted.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_tag_bindings(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListTagBindingsResponse

Lists the TagBindings for the given Google Cloud resource, as specified with parent. NOTE: The parent field is expected to be a full resource name: https://cloud.google.com/apis/design/resource_names#full_resource_name

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of TagBindings to return in the response. The server allows a maximum of 300 TagBindings to return. If unspecified, the server will use 100 as the default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListTagBindings that indicates where this listing should continue from.

  • parent (String) (defaults to: nil)

    Required. The full resource name of a resource for which you want to list existing TagBindings. E.g. "//cloudresourcemanager.googleapis.com/projects/123"

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1690

def list_tag_bindings(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/tagBindings', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListTagBindingsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListTagBindingsResponse
  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_tag_keys(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListTagKeysResponse

Lists all TagKeys for a parent resource.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of TagKeys to return in the response. The server allows a maximum of 300 TagKeys to return. If unspecified, the server will use 100 as the default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListTagKey that indicates where this listing should continue from.

  • parent (String) (defaults to: nil)

    Required. The resource name of the TagKey's parent. Must be of the form organizations/org_idor `projects/`project_id or projects/ project_number``

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1911

def list_tag_keys(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/tagKeys', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListTagKeysResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListTagKeysResponse
  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_tag_value_tag_holds(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListTagHoldsResponse

Lists TagHolds under a TagValue.

Parameters:

  • parent (String)

    Required. The resource name of the parent TagValue. Must be of the form: tagValues/tag-value-id``.

  • filter (String) (defaults to: nil)

    Optional. Criteria used to select a subset of TagHolds parented by the TagValue to return. This field follows the syntax defined by aip.dev/160; the holder and origin fields are supported for filtering. Currently only AND syntax is supported. Some example queries are: * holder = //compute. googleapis.com/compute/projects/myproject/regions/us-east-1/ instanceGroupManagers/instance-group * origin = 35678234 * holder = // compute.googleapis.com/compute/projects/myproject/regions/us-east-1/ instanceGroupManagers/instance-group AND origin = 35678234

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of TagHolds to return in the response. The server allows a maximum of 300 TagHolds to return. If unspecified, the server will use 100 as the default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListTagHolds that indicates where this listing should continue from.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2488

def list_tag_value_tag_holds(parent, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/{+parent}/tagHolds', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListTagHoldsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListTagHoldsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['filter'] = filter unless filter.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_tag_values(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::ListTagValuesResponse

Lists all TagValues for a specific TagKey.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of TagValues to return in the response. The server allows a maximum of 300 TagValues to return. If unspecified, the server will use 100 as the default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListTagValues that indicates where this listing should continue from.

  • parent (String) (defaults to: nil)

    Required. Resource name for the parent of the TagValues to be listed, in the format tagKeys/123 or tagValues/123.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2250

def list_tag_values(page_size: nil, page_token: nil, parent: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/tagValues', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::ListTagValuesResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::ListTagValuesResponse
  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

#move_folder(name, move_folder_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Moves a folder under a new resource parent. Returns an Operation which can be used to track the progress of the folder move workflow. Upon success, the Operation.response field will be populated with the moved folder. Upon failure, a FolderOperationError categorizing the failure cause will be returned - if the failure occurs synchronously then the FolderOperationError will be returned in the Status.details field. If it occurs asynchronously, then the FolderOperation will be returned in the Operation.error field. In addition, the Operation.metadata field will be populated with a FolderOperation message as an aid to stateless clients. Folder moves will be rejected if they violate either the naming, height, or fanout constraints described in the CreateFolder documentation. The caller must have resourcemanager.folders.move permission on the folder's current and proposed new parent.

Parameters:

  • name (String)

    Required. The resource name of the Folder to move. Must be of the form folders/ folder_id

  • move_folder_request_object (Google::Apis::CloudresourcemanagerV3::MoveFolderRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



337
338
339
340
341
342
343
344
345
346
347
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 337

def move_folder(name, move_folder_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+name}:move', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::MoveFolderRequest::Representation
  command.request_object = move_folder_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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

#move_project(name, move_project_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Move a project to another place in your resource hierarchy, under a new resource parent. Returns an operation which can be used to track the process of the project move workflow. Upon success, the Operation.response field will be populated with the moved project. The caller must have resourcemanager.projects.move permission on the project, on the project's current and proposed new parent. If project has no current parent, or it currently does not have an associated organization resource, you will also need the resourcemanager.projects.setIamPolicy permission in the project.

Parameters:

  • name (String)

    Required. The name of the project to move.

  • move_project_request_object (Google::Apis::CloudresourcemanagerV3::MoveProjectRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1342

def move_project(name, move_project_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+name}:move', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::MoveProjectRequest::Representation
  command.request_object = move_project_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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

#patch_folder(name, folder_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Updates a folder, changing its display_name. Changes to the folder display_name will be rejected if they violate either the display_name formatting rules or the naming constraints described in the CreateFolder documentation. The folder's display_name must start and end with a letter or digit, may contain letters, digits, spaces, hyphens and underscores and can be between 3 and 30 characters. This is captured by the regular expression: \pL \pN`1,28[\pL\pN]. The caller must haveresourcemanager.folders.update permission on the identified folder. If the update fails due to the unique name constraint then aPreconditionFailure` explaining this violation will be returned in the Status.details field.

Parameters:

  • name (String)

    Identifier. The resource name of the folder. Its format is folders/folder_id , for example: "folders/1234".

  • folder_object (Google::Apis::CloudresourcemanagerV3::Folder) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Required. Fields to be updated. Only the display_name can be updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



382
383
384
385
386
387
388
389
390
391
392
393
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 382

def patch_folder(name, folder_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v3/{+name}', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::Folder::Representation
  command.request_object = folder_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_folder_capability(name, capability_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Updates the Capability.

Parameters:

  • name (String)

    Immutable. Identifier. The resource name of the capability. Must be in the following form: * folders/folder_id/capabilities/capability_name`For example,folders/123/capabilities/app-managementFollowing are the allowed capability_namevalues: *app-management`

  • capability_object (Google::Apis::CloudresourcemanagerV3::Capability) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. The list of fields to update. Only [Capability.value] can be updated.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



625
626
627
628
629
630
631
632
633
634
635
636
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 625

def patch_folder_capability(name, capability_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v3/{+name}', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::Capability::Representation
  command.request_object = capability_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_location_tag_binding_collection(name, tag_binding_collection_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Updates tag bindings directly attached to a GCP resource. Update_mask can be kept empty or "*".

Parameters:

  • name (String)

    Identifier. The name of the TagBindingCollection, following the convention: locations/location/tagBindingCollections/encoded-full-resource-name`` where the encoded-full-resource-name is the UTF-8 encoded name of the GCP resource the TagBindings are bound to. "locations/global/tagBindingCollections/%2f% 2fcloudresourcemanager.googleapis.com%2fprojects%2f123"

  • tag_binding_collection_object (Google::Apis::CloudresourcemanagerV3::TagBindingCollection) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. An update mask to selectively update fields.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



876
877
878
879
880
881
882
883
884
885
886
887
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 876

def patch_location_tag_binding_collection(name, tag_binding_collection_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v3/{+name}', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagBindingCollection::Representation
  command.request_object = tag_binding_collection_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_project(name, project_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Updates the display_name and labels of the project identified by the specified name (for example, projects/415104041262). Deleting all labels requires an update mask for labels field. The caller must have resourcemanager.projects.update permission for this project.

Parameters:

  • name (String)

    Output only. The unique resource name of the project. It is an int64 generated number prefixed by "projects/". Example: projects/415104041262

  • project_object (Google::Apis::CloudresourcemanagerV3::Project) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. An update mask to selectively update fields.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1381

def patch_project(name, project_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v3/{+name}', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::Project::Representation
  command.request_object = project_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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_tag_key(name, tag_key_object = nil, update_mask: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Updates the attributes of the TagKey resource.

Parameters:

  • name (String)

    Immutable. The resource name for a TagKey. Must be in the format tagKeys/ tag_key_id`, wheretag_key_id` is the generated numeric id for the TagKey.

  • tag_key_object (Google::Apis::CloudresourcemanagerV3::TagKey) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Fields to be updated. The mask may only contain description or etag. If omitted entirely, both description and etag are assumed to be significant.

  • validate_only (Boolean) (defaults to: nil)

    Set as true to perform validations necessary for updating the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1951

def patch_tag_key(name, tag_key_object = nil, update_mask: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v3/{+name}', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagKey::Representation
  command.request_object = tag_key_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['validateOnly'] = validate_only unless validate_only.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_tag_value(name, tag_value_object = nil, update_mask: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Updates the attributes of the TagValue resource.

Parameters:

  • name (String)

    Immutable. Resource name for TagValue in the format tagValues/456.

  • tag_value_object (Google::Apis::CloudresourcemanagerV3::TagValue) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Optional. Fields to be updated.

  • validate_only (Boolean) (defaults to: nil)

    Optional. True to perform validations necessary for updating the resource, but not actually perform the action.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2288

def patch_tag_value(name, tag_value_object = nil, update_mask: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v3/{+name}', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TagValue::Representation
  command.request_object = tag_value_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Operation
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['validateOnly'] = validate_only unless validate_only.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#search_folders(page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::SearchFoldersResponse

Search for folders that match specific filter criteria. search() provides an eventually consistent view of the folders a user has access to which meet the specified filter criteria. This will only return folders on which the caller has the permission resourcemanager.folders.get.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of folders to return in the response. The server can return fewer folders than requested. If unspecified, server picks an appropriate default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to SearchFolders that indicates from where search should continue.

  • query (String) (defaults to: nil)

    Optional. Search criteria used to select the folders to return. If no search criteria is specified then all accessible folders will be returned. Query expressions can be used to restrict results based upon displayName, state and parent, where the operators = (:) NOT, AND and OR can be used along with the suffix wildcard symbol *. The displayName field in a query expression should use escaped quotes for values that include whitespace to prevent unexpected behavior. | Field | Description | |--------------------- ----|----------------------------------------| | displayName | Filters by displayName. | | parent | Filters by parent (for example: folders/123). | | state, lifecycleState | Filters by state. | Some example queries are: * Query displayName=Test* returns Folder resources whose display name starts with "Test". * Query state=ACTIVE returns Folder resources with state set to ACTIVE. * Query parent=folders/123 returns Folder resources that have folders/123 as a parent resource. * Query parent=folders/123 AND state= ACTIVE returns active Folder resources that have folders/123 as a parent resource. * Query displayName=\\"Test String\\" returns Folder resources with display names that include both "Test" and "String".

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



441
442
443
444
445
446
447
448
449
450
451
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 441

def search_folders(page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/folders:search', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::SearchFoldersResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::SearchFoldersResponse
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['query'] = query unless query.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#search_organizations(page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::SearchOrganizationsResponse

Searches organization resources that are visible to the user and satisfy the specified filter. This method returns organizations in an unspecified order. New organizations do not necessarily appear at the end of the results, and may take a small amount of time to appear. Search will only return organizations on which the user has the permission resourcemanager.organizations.get or has super admin privileges.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of organizations to return in the response. The server can return fewer organizations than requested. If unspecified, server picks an appropriate default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to SearchOrganizations that indicates from where listing should continue.

  • query (String) (defaults to: nil)

    Optional. An optional query string used to filter the Organizations to return in the response. Query rules are case-insensitive. | Field | Description | |------------------|--------------------------------------------| | directoryCustomerId, owner.directoryCustomerId | Filters by directory customer id. | | domain | Filters by domain. | Organizations may be queried by directoryCustomerId or by domain, where the domain is a G Suite domain, for example: * Query directorycustomerid:123456789 returns Organization resources with owner.directory_customer_id equal to 123456789. * Query domain:google.com returns Organization resources corresponding to the domain google.com.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1032

def search_organizations(page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/organizations:search', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::SearchOrganizationsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::SearchOrganizationsResponse
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['query'] = query unless query.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#search_projects(page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::SearchProjectsResponse

Search for projects that the caller has the resourcemanager.projects.get permission on, and also satisfy the specified query. This method returns projects in an unspecified order. This method is eventually consistent with project mutations; this means that a newly created project may not appear in the results or recent updates to an existing project may not be reflected in the results. To retrieve the latest state of a project, use the GetProject method.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    Optional. The maximum number of projects to return in the response. The server can return fewer projects than requested. If unspecified, server picks an appropriate default.

  • page_token (String) (defaults to: nil)

    Optional. A pagination token returned from a previous call to ListProjects that indicates from where listing should continue.

  • query (String) (defaults to: nil)

    Optional. A query string for searching for projects that the caller has resourcemanager.projects.get permission to. If multiple fields are included in the query, then it will return results that match any of the fields. Some eligible fields are: | Field | Description | |-------------------------|--- -------------------------------------------| | displayName, name | Filters by displayName. | | parent | Project's parent (for example: folders/123, organizations/*). Prefer parent field over parent.type and parent.id.| | parent.type | Parent's type: `folder` or `organization`. | | parent.id | Parent's id number (for example: 123) | | id, projectId | Filters by projectId. | | state, lifecycleState | Filters by state. | | labels | Filters by label name or value. | | labels.\ (where *key* is the name of a label) | Filters by label name.| Search expressions are case insensitive. Some examples queries: | Query | Description | |------------------|---------------------- -------------------------------| | name:how* | The project's name starts with " how". | | name:Howl | The project's name is `Howl` or `howl`. | | name:HOWL | Equivalent to above. | | NAME:howl | Equivalent to above. | | labels.color:* | The project has the label `color`. | | labels.color:red | The project's label ` color` has the value `red`. | | labels.color:red labels.size:big | The project' s label `color` has the value `red` or its label `size` has the value `big`. | If no query is specified, the call will return projects for which the user has the resourcemanager.projects.get permission.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1447

def search_projects(page_size: nil, page_token: nil, query: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v3/projects:search', options)
  command.response_representation = Google::Apis::CloudresourcemanagerV3::SearchProjectsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::SearchProjectsResponse
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['query'] = query unless query.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#set_folder_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Sets the access control policy on a folder, replacing any existing policy. The resource field should be the folder's resource name, for example: "folders/ 1234". The caller must have resourcemanager.folders.setIamPolicy permission on the identified folder.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being specified. See Resource names for the appropriate value for this field.

  • set_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



479
480
481
482
483
484
485
486
487
488
489
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 479

def set_folder_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:setIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest::Representation
  command.request_object = set_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#set_organization_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Sets the access control policy on an organization resource. Replaces any existing policy. The resource field should be the organization's resource name, for example: "organizations/123". Authorization requires the IAM permission resourcemanager.organizations.setIamPolicy on the specified organization.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being specified. See Resource names for the appropriate value for this field.

  • set_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1071

def set_organization_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:setIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest::Representation
  command.request_object = set_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#set_project_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Sets the IAM access control policy for the specified project, in the format projects/ProjectIdOrNumber`e.g. projects/123. CAUTION: This method will replace the existing policy, and cannot be used to append additional IAM settings. Note: Removing service accounts from policies or changing their roles can render services completely inoperable. It is important to understand how the service account is being used before removing or updating its roles. The following constraints apply when usingsetIamPolicy(): + Project does not supportallUsersandallAuthenticatedUsersasmembersin aBinding of aPolicy. + The owner role can be granted to auser,serviceAccount, or a group that is part of an organization. For example, group@ myownpersonaldomain.com could be added as an owner to a project in the myownpersonaldomain.com organization, but not the examplepetstore.com organization. + Service accounts can be made owners of a project directly without any restrictions. However, to be added as an owner, a user must be invited using the Cloud Platform console and must accept the invitation. + A user cannot be granted the owner role usingsetIamPolicy(). The user must be granted the owner role using the Cloud Platform Console and must explicitly accept the invitation. + Invitations to grant the owner role cannot be sent usingsetIamPolicy(); they must be sent only using the Cloud Platform Console. + If the project is not part of an organization, there must be at least one owner who has accepted the Terms of Service (ToS) agreement in the policy. CallingsetIamPolicy()` to remove the last ToS-accepted owner from the policy will fail. This restriction also applies to legacy projects that no longer have owners who have accepted the ToS. Edits to IAM policies will be rejected until the lack of a ToS-accepting owner is rectified. If the project is part of an organization, you can remove all owners, potentially making the organization inaccessible.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being specified. See Resource names for the appropriate value for this field.

  • set_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1508

def set_project_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:setIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest::Representation
  command.request_object = set_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#set_tag_key_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Sets the access control policy on a TagKey, replacing any existing policy. The resource field should be the TagKey's resource name. For example, "tagKeys/ 1234". The caller must have resourcemanager.tagKeys.setIamPolicy permission on the identified tagValue.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being specified. See Resource names for the appropriate value for this field.

  • set_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1991

def set_tag_key_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:setIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest::Representation
  command.request_object = set_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#set_tag_value_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Policy

Sets the access control policy on a TagValue, replacing any existing policy. The resource field should be the TagValue's resource name. For example: tagValues/1234. The caller must have resourcemanager.tagValues.setIamPolicy permission on the identified tagValue.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy is being specified. See Resource names for the appropriate value for this field.

  • set_iam_policy_request_object (Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2328

def set_tag_value_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:setIamPolicy', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::SetIamPolicyRequest::Representation
  command.request_object = set_iam_policy_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Policy::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::Policy
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#test_folder_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse

Returns permissions that a caller has on the specified folder. The resource field should be the folder's resource name, for example: "folders/1234". There are no permissions required for making this API call.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy detail is being requested. See Resource names for the appropriate value for this field.

  • test_iam_permissions_request_object (Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



516
517
518
519
520
521
522
523
524
525
526
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 516

def test_folder_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:testIamPermissions', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest::Representation
  command.request_object = test_iam_permissions_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#test_organization_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse

Returns the permissions that a caller has on the specified organization. The resource field should be the organization's resource name, for example: " organizations/123". There are no permissions required for making this API call.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy detail is being requested. See Resource names for the appropriate value for this field.

  • test_iam_permissions_request_object (Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1108

def test_organization_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:testIamPermissions', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest::Representation
  command.request_object = test_iam_permissions_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#test_project_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse

Returns permissions that a caller has on the specified project, in the format projects/ProjectIdOrNumber`` e.g. projects/123..

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy detail is being requested. See Resource names for the appropriate value for this field.

  • test_iam_permissions_request_object (Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1544

def test_project_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:testIamPermissions', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest::Representation
  command.request_object = test_iam_permissions_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#test_tag_key_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse

Returns permissions that a caller has on the specified TagKey. The resource field should be the TagKey's resource name. For example, "tagKeys/1234". There are no permissions required for making this API call.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy detail is being requested. See Resource names for the appropriate value for this field.

  • test_iam_permissions_request_object (Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2028

def test_tag_key_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:testIamPermissions', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest::Representation
  command.request_object = test_iam_permissions_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#test_tag_value_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse

Returns permissions that a caller has on the specified TagValue. The resource field should be the TagValue's resource name. For example: tagValues/1234. There are no permissions required for making this API call.

Parameters:

  • resource (String)

    REQUIRED: The resource for which the policy detail is being requested. See Resource names for the appropriate value for this field.

  • test_iam_permissions_request_object (Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 2365

def test_tag_value_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+resource}:testIamPermissions', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsRequest::Representation
  command.request_object = test_iam_permissions_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::TestIamPermissionsResponse
  command.params['resource'] = resource unless resource.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#undelete_folder(name, undelete_folder_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Cancels the deletion request for a folder. This method may be called on a folder in any state. If the folder is in the ACTIVE state the result will be a no-op success. In order to succeed, the folder's parent must be in the ACTIVE state. In addition, reintroducing the folder into the tree must not violate folder naming, height, and fanout constraints described in the CreateFolder documentation. The caller must have resourcemanager.folders.undelete permission on the identified folder.

Parameters:

  • name (String)

    Required. The resource name of the folder to undelete. Must be of the form folders/folder_id``.

  • undelete_folder_request_object (Google::Apis::CloudresourcemanagerV3::UndeleteFolderRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



556
557
558
559
560
561
562
563
564
565
566
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 556

def undelete_folder(name, undelete_folder_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+name}:undelete', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::UndeleteFolderRequest::Representation
  command.request_object = undelete_folder_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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

#undelete_project(name, undelete_project_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudresourcemanagerV3::Operation

Restores the project identified by the specified name (for example, projects/415104041262). You can only use this method for a project that has a lifecycle state of DELETE_REQUESTED. After deletion starts, the project cannot be restored. The caller must have resourcemanager.projects.undelete permission for this project.

Parameters:

  • name (String)

    Required. The name of the project (for example, projects/415104041262). Required.

  • undelete_project_request_object (Google::Apis::CloudresourcemanagerV3::UndeleteProjectRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
# File 'lib/google/apis/cloudresourcemanager_v3/service.rb', line 1582

def undelete_project(name, undelete_project_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v3/{+name}:undelete', options)
  command.request_representation = Google::Apis::CloudresourcemanagerV3::UndeleteProjectRequest::Representation
  command.request_object = undelete_project_request_object
  command.response_representation = Google::Apis::CloudresourcemanagerV3::Operation::Representation
  command.response_class = Google::Apis::CloudresourcemanagerV3::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