tag_resource
async
¶
tag_resource(
resource_arn: Arn,
tags: Tags,
*,
config_overrides: Optional[AsyncOpenSearchServerlessClientConfig] = None,
) -> TagResourceResponse
Associates tags with an OpenSearch Serverless resource. For more information, see Tagging Amazon OpenSearch Serverless collections.
Parameters:
-
resource_arn(Arn) –The Amazon Resource Name (ARN) of the resource. The resource must be active (not in the
DELETINGstate), and must be owned by the account ID included in the request. -
tags(Tags) –A list of tags (key-value pairs) to add to the resource. All tag keys in the request must be unique.
Raises:
-
ConflictException–When creating a resource, thrown when a resource with the same name already exists or is being created. When deleting a resource, thrown when the resource is not in the ACTIVE, FAILED, or UPDATE_FAILED state.
-
InternalServerException–Thrown when an error internal to the service occurs while processing a request.
-
ResourceNotFoundException–Thrown when accessing or deleting a resource that does not exist.
-
ServiceQuotaExceededException–Thrown when you attempt to create more resources than the service allows based on service quotas.
-
ValidationException–Thrown when the HTTP request contains invalid input or is missing required input.
-
UnknownServiceError–The service returned an error code this client does not model.