Lists the tags that have been applied to the ACM certificate. Use the certificate's Amazon Resource Name (ARN) to specify the certificate. To add a tag to an ACM certificate, use the AddTagsToCertificate action. To delete a tag, use the RemoveTagsFromCertificate action.
This action applies only to the certificate resource type. For all other ACM resource types, use ListTagsForResource instead.
Parameters:
-
certificate_arn
(Arn)
–
String that contains the ARN of the ACM certificate for which you want to list the tags. This must have the following form:
arn:aws:acm:region:123456789012:certificate/12345678-1234-1234-1234-123456789012
For more information about ARNs, see Amazon Resource Names (ARNs).
Raises:
-
InvalidArnException
–
The requested Amazon Resource Name (ARN) does not refer to an existing resource.
-
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 list_tags_for_certificate(
self,
certificate_arn: "capo_acm.types.arn.Arn",
*,
config_overrides: Optional[AsyncACMClientConfig] = None,
) -> "capo_acm.types.list_tags_for_certificate_response.ListTagsForCertificateResponse":
"""<p>Lists the tags that have been applied to the ACM certificate. Use the certificate's Amazon Resource Name (ARN) to specify the certificate. To add a tag to an ACM certificate, use the <a>AddTagsToCertificate</a> action. To delete a tag, use the <a>RemoveTagsFromCertificate</a> action. </p> <note> <p>This action applies only to the <code>certificate</code> resource type. For all other ACM resource types, use <a>ListTagsForResource</a> instead.</p> </note>
Args:
certificate_arn: <p>String that contains the ARN of the ACM certificate for which you want to list the tags. This must have the following form:</p> <p> <code>arn:aws:acm:region:123456789012:certificate/12345678-1234-1234-1234-123456789012</code> </p> <p>For more information about ARNs, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs)</a>.</p>
Raises:
capo_acm.errors.invalid_arn_exception.InvalidArnException: <p>The requested Amazon Resource Name (ARN) does not refer to an existing resource.</p>
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.list_tags_for_certificate_request.ListTagsForCertificateRequest]",
) -> AsyncOperationResponse[
"capo_acm.types.list_tags_for_certificate_response.ListTagsForCertificateResponse"
]:
import capo_acm._operations.certificate_manager.list_tags_for_certificate
(
output,
http_response,
) = await capo_acm._operations.certificate_manager.list_tags_for_certificate.async_list_tags_for_certificate(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListTagsForCertificate")
)
input_: capo_acm.types.list_tags_for_certificate_request.ListTagsForCertificateRequest = {
"certificate_arn": certificate_arn
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|