Deletes the specified certificate.
Parameters:
-
certificate_arn
(String)
–
The Amazon Resource Name (ARN) of the certificate.
Raises:
Examples:
Delete Certificate
Deletes the specified certificate.
>>> await client.delete_certificate(certificate_arn='arn:aws:dms:us-east-1:123456789012:rep:6UTDJGBOUSM457DE6XFJCJQ')
Source code in docs_src/capo_database_migration_service/_services/async_database_migration_service.py
| async def delete_certificate(
self,
certificate_arn: "capo_database_migration_service.types.string.String",
*,
config_overrides: Optional[AsyncDatabaseMigrationServiceClientConfig] = None,
) -> "capo_database_migration_service.types.delete_certificate_response.DeleteCertificateResponse":
"""<p>Deletes the specified certificate. </p>
Args:
certificate_arn: <p>The Amazon Resource Name (ARN) of the certificate.</p>
Raises:
capo_database_migration_service.errors.invalid_resource_state_fault.InvalidResourceStateFault: <p>The resource is in a state that prevents it from being used for database migration.</p>
capo_database_migration_service.errors.resource_not_found_fault.ResourceNotFoundFault: <p>The resource could not be found.</p>
capo_database_migration_service.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
Delete Certificate
Deletes the specified certificate.
>>> await client.delete_certificate(certificate_arn='arn:aws:dms:us-east-1:123456789012:rep:6UTDJGBOUSM457DE6XFJCJQ')
"""
async def _handler(
req: "AsyncOperationRequest[capo_database_migration_service.types.delete_certificate_message.DeleteCertificateMessage]",
) -> AsyncOperationResponse[
"capo_database_migration_service.types.delete_certificate_response.DeleteCertificateResponse"
]:
import capo_database_migration_service._operations.amazon_dm_sv20160101.delete_certificate
(
output,
http_response,
) = await capo_database_migration_service._operations.amazon_dm_sv20160101.delete_certificate.async_delete_certificate(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteCertificate")
)
input_: capo_database_migration_service.types.delete_certificate_message.DeleteCertificateMessage = {
"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
|