untag_resource(
resource_arn: Arn,
tag_keys: TagKeyList,
*,
config_overrides: Optional[AsyncACMClientConfig] = None,
) -> None
Removes one or more tags from an ACM resource.
Use this action for all ACM resource types except the certificate resource type. For certificate resources, use RemoveTagsFromCertificate instead.
To add one or more tags, use the TagResource action. To view all of the tags that have been applied to a resource, use the ListTagsForResource action.
Parameters:
-
resource_arn
(Arn)
–
The ARN of the ACM resource from which the tag is to be removed.
-
tag_keys
(TagKeyList)
–
The key of each tag to remove.
Raises:
-
ResourceNotFoundException
–
The specified certificate cannot be found in the caller's account or the caller's account cannot be found.
-
ValidationException
–
The supplied input failed to satisfy constraints of an Amazon Web Services service.
-
UnknownServiceError
–
The service returned an error code this client does not model.
Source code in docs_src/capo_acm/_services/async_acm.py
| async def untag_resource(
self,
resource_arn: "capo_acm.types.arn.Arn",
tag_keys: "capo_acm.types.tag_key_list.TagKeyList",
*,
config_overrides: Optional[AsyncACMClientConfig] = None,
) -> None:
"""<p>Removes one or more tags from an ACM resource.</p> <note> <p>Use this action for all ACM resource types except the <code>certificate</code> resource type. For certificate resources, use <a>RemoveTagsFromCertificate</a> instead.</p> </note> <p>To add one or more tags, use the <a>TagResource</a> action. To view all of the tags that have been applied to a resource, use the <a>ListTagsForResource</a> action.</p>
Args:
resource_arn: <p>The ARN of the ACM resource from which the tag is to be removed.</p>
tag_keys: <p>The key of each tag to remove.</p>
Raises:
capo_acm.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified certificate cannot be found in the caller's account or the caller's account cannot be found.</p>
capo_acm.errors.validation_exception.ValidationException: <p>The supplied input failed to satisfy constraints of an Amazon Web Services service.</p>
capo_acm.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_acm.types.untag_resource_request.UntagResourceRequest]",
) -> AsyncOperationResponse[None]:
import capo_acm._operations.certificate_manager.untag_resource
(
output,
http_response,
) = await capo_acm._operations.certificate_manager.untag_resource.async_untag_resource(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("UntagResource")
)
input_: capo_acm.types.untag_resource_request.UntagResourceRequest = {
"resource_arn": resource_arn,
"tag_keys": tag_keys,
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|