Removes a specific tag associated with an Amazon Translate resource. For more information, see Tagging your resources.
Parameters:
-
resource_arn
(ResourceArn)
–
The Amazon Resource Name (ARN) of the given Amazon Translate resource from which you want to remove the tags.
-
tag_keys
(TagKeyList)
–
The initial part of a key-value pair that forms a tag being removed from a given resource. Keys must be unique and cannot be duplicated for a particular resource.
Raises:
-
ConcurrentModificationException
–
Another modification is being made. That modification must complete before you can make your change.
-
InternalServerException
–
An internal server error occurred. Retry your request.
-
InvalidParameterValueException
–
The value of the parameter is not valid. Review the value of the parameter you are using to correct it, and then retry your operation.
-
ResourceNotFoundException
–
The resource you are looking for has not been found. Review the resource you're looking for and see if a different resource will accomplish your needs before retrying the revised request.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Source code in docs_src/capo_translate/_services/translate.py
| def untag_resource(
self,
resource_arn: "capo_translate.types.resource_arn.ResourceArn",
tag_keys: "capo_translate.types.tag_key_list.TagKeyList",
*,
config_overrides: Optional[TranslateClientConfig] = None,
) -> "capo_translate.types.untag_resource_response.UntagResourceResponse":
"""<p>Removes a specific tag associated with an Amazon Translate resource. For more information, see <a href="https://docs.aws.amazon.com/translate/latest/dg/tagging.html"> Tagging your resources</a>.</p>
Args:
resource_arn: <p> The Amazon Resource Name (ARN) of the given Amazon Translate resource from which you want to remove the tags. </p>
tag_keys: <p>The initial part of a key-value pair that forms a tag being removed from a given resource. Keys must be unique and cannot be duplicated for a particular resource. </p>
Raises:
capo_translate.errors.concurrent_modification_exception.ConcurrentModificationException: <p>Another modification is being made. That modification must complete before you can make your change.</p>
capo_translate.errors.internal_server_exception.InternalServerException: <p>An internal server error occurred. Retry your request.</p>
capo_translate.errors.invalid_parameter_value_exception.InvalidParameterValueException: <p>The value of the parameter is not valid. Review the value of the parameter you are using to correct it, and then retry your operation.</p>
capo_translate.errors.resource_not_found_exception.ResourceNotFoundException: <p>The resource you are looking for has not been found. Review the resource you're looking for and see if a different resource will accomplish your needs before retrying the revised request.</p>
capo_translate.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_translate.types.untag_resource_request.UntagResourceRequest]",
) -> OperationResponse[
"capo_translate.types.untag_resource_response.UntagResourceResponse"
]:
import capo_translate._operations.aws_shine_frontend_service_20170701.untag_resource
output, http_response = (
capo_translate._operations.aws_shine_frontend_service_20170701.untag_resource.untag_resource(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("UntagResource")
)
input_: capo_translate.types.untag_resource_request.UntagResourceRequest = {
"resource_arn": resource_arn,
"tag_keys": tag_keys,
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|