Class TagBindingsAsyncClient

Allow users to create and manage TagBindings between TagValues and different cloud resources throughout the GCP resource hierarchy.

Inheritance

builtins.object > TagBindingsAsyncClient

Properties

transport

Returns the transport used by the client instance.

Returns
TypeDescription
TagBindingsTransportThe transport used by the client instance.

Methods

common_billing_account_path

common_billing_account_path(billing_account: str)

Returns a fully-qualified billing_account string.

Parameter
NameDescription
billing_account str

common_folder_path

common_folder_path(folder: str)

Returns a fully-qualified folder string.

Parameter
NameDescription
folder str

common_location_path

common_location_path(project: str, location: str)

Returns a fully-qualified location string.

Parameters
NameDescription
project str
location str

common_organization_path

common_organization_path(organization: str)

Returns a fully-qualified organization string.

Parameter
NameDescription
organization str

common_project_path

common_project_path(project: str)

Returns a fully-qualified project string.

Parameter
NameDescription
project str

create_tag_binding

create_tag_binding(request: Optional[Union[google.cloud.resourcemanager_v3.types.tag_bindings.CreateTagBindingRequest, dict]] = None, *, tag_binding: Optional[google.cloud.resourcemanager_v3.types.tag_bindings.TagBinding] = None, retry: Union[google.api_core.retry.Retry, google.api_core.gapic_v1.method._MethodDefault] = <_MethodDefault._DEFAULT_VALUE: <object object>>, timeout: Optional[float] = None, metadata: Sequence[Tuple[str, str]] = ())

Creates a TagBinding between a TagValue and a cloud resource (currently project, folder, or organization).

Parameters
NameDescription
request Union[google.cloud.resourcemanager_v3.types.CreateTagBindingRequest, dict]

The request object. The request message to create a TagBinding.

tag_binding TagBinding

Required. The TagBinding to be created. This corresponds to the tag_binding field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry.Retry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be TagBinding A TagBinding represents a connection between a TagValue and a cloud resource (currently project, folder, or organization). Once a TagBinding is created, the TagValue is applied to all the descendants of the cloud resource.

delete_tag_binding

delete_tag_binding(request: Optional[Union[google.cloud.resourcemanager_v3.types.tag_bindings.DeleteTagBindingRequest, dict]] = None, *, name: Optional[str] = None, retry: Union[google.api_core.retry.Retry, google.api_core.gapic_v1.method._MethodDefault] = <_MethodDefault._DEFAULT_VALUE: <object object>>, timeout: Optional[float] = None, metadata: Sequence[Tuple[str, str]] = ())

Deletes a TagBinding.

Parameters
NameDescription
request Union[google.cloud.resourcemanager_v3.types.DeleteTagBindingRequest, dict]

The request object. The request message to delete a TagBinding.

name `str`

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). This corresponds to the name field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry.Retry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.api_core.operation_async.AsyncOperationAn object representing a long-running operation. The result type for the operation will be `google.protobuf.empty_pb2.Empty` A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for Empty is empty JSON object {}.

from_service_account_file

from_service_account_file(filename: str, *args, **kwargs)

Creates an instance of this client using the provided credentials file.

Parameters
NameDescription
filename str

The path to the service account private key json file.

args

Additional arguments to pass to the constructor.

kwargs

Additional arguments to pass to the constructor.

Returns
TypeDescription
TagBindingsAsyncClientThe constructed client.

from_service_account_info

from_service_account_info(info: dict, *args, **kwargs)

Creates an instance of this client using the provided credentials info.

Parameters
NameDescription
info dict

The service account private key info.

args

Additional arguments to pass to the constructor.

kwargs

Additional arguments to pass to the constructor.

Returns
TypeDescription
TagBindingsAsyncClientThe constructed client.

from_service_account_json

from_service_account_json(filename: str, *args, **kwargs)

Creates an instance of this client using the provided credentials file.

Parameters
NameDescription
filename str

The path to the service account private key json file.

args

Additional arguments to pass to the constructor.

kwargs

Additional arguments to pass to the constructor.

Returns
TypeDescription
TagBindingsAsyncClientThe constructed client.

get_transport_class

get_transport_class()

partial(func, *args, **keywords) - new function with partial application of the given arguments and keywords.

Parameter
NameDescription
label str

list_tag_bindings

list_tag_bindings(request: Optional[Union[google.cloud.resourcemanager_v3.types.tag_bindings.ListTagBindingsRequest, dict]] = None, *, parent: Optional[str] = None, retry: Union[google.api_core.retry.Retry, google.api_core.gapic_v1.method._MethodDefault] = <_MethodDefault._DEFAULT_VALUE: <object object>>, timeout: Optional[float] = None, metadata: Sequence[Tuple[str, str]] = ())

Lists the TagBindings for the given 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
NameDescription
request Union[google.cloud.resourcemanager_v3.types.ListTagBindingsRequest, dict]

The request object. The request message to list all TagBindings for a parent.

parent `str`

Required. The full resource name of a resource for which you want to list existing TagBindings. E.g. "//cloudresourcemanager.googleapis.com/projects/123" This corresponds to the parent field on the request instance; if request is provided, this should not be set.

retry google.api_core.retry.Retry

Designation of what errors, if any, should be retried.

timeout float

The timeout for this request.

metadata Sequence[Tuple[str, str]]

Strings which should be sent along with the request as metadata.

Returns
TypeDescription
google.cloud.resourcemanager_v3.services.tag_bindings.pagers.ListTagBindingsAsyncPagerThe ListTagBindings response. Iterating over this object will yield results and resolve additional pages automatically.

parse_common_billing_account_path

parse_common_billing_account_path(path: str)

Parse a billing_account path into its component segments.

Parameter
NameDescription
path str

parse_common_folder_path

parse_common_folder_path(path: str)

Parse a folder path into its component segments.

Parameter
NameDescription
path str

parse_common_location_path

parse_common_location_path(path: str)

Parse a location path into its component segments.

Parameter
NameDescription
path str

parse_common_organization_path

parse_common_organization_path(path: str)

Parse a organization path into its component segments.

Parameter
NameDescription
path str

parse_common_project_path

parse_common_project_path(path: str)

Parse a project path into its component segments.

Parameter
NameDescription
path str

parse_tag_binding_path

parse_tag_binding_path(path: str)

Parses a tag_binding path into its component segments.

Parameter
NameDescription
path str

tag_binding_path

tag_binding_path(tag_binding: str)

Returns a fully-qualified tag_binding string.

Parameter
NameDescription
tag_binding str