The connection to be deleted.
Parameters:
-
connection_arn
(ConnectionArn)
–
The Amazon Resource Name (ARN) of the connection to be deleted.
The ARN is never reused if the connection is deleted.
Raises:
Source code in docs_src/capo_codeconnections/_services/code_connections.py
| def delete_connection(
self,
connection_arn: "capo_codeconnections.types.connection_arn.ConnectionArn",
*,
config_overrides: Optional[CodeConnectionsClientConfig] = None,
) -> "capo_codeconnections.types.delete_connection_output.DeleteConnectionOutput":
"""<p>The connection to be deleted.</p>
Args:
connection_arn: <p>The Amazon Resource Name (ARN) of the connection to be deleted.</p> <note> <p>The ARN is never reused if the connection is deleted.</p> </note>
Raises:
capo_codeconnections.errors.resource_not_found_exception.ResourceNotFoundException: <p>Resource not found. Verify the connection resource ARN and try again.</p>
capo_codeconnections.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_codeconnections.types.delete_connection_input.DeleteConnectionInput]",
) -> OperationResponse[
"capo_codeconnections.types.delete_connection_output.DeleteConnectionOutput"
]:
import capo_codeconnections._operations.code_connections_20231201.delete_connection
output, http_response = (
capo_codeconnections._operations.code_connections_20231201.delete_connection.delete_connection(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteConnection")
)
input_: capo_codeconnections.types.delete_connection_input.DeleteConnectionInput = {
"connection_arn": connection_arn
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|