Remove template post migration custom action.
Parameters:
-
launch_configuration_template_id
(LaunchConfigurationTemplateID)
–
Launch configuration template ID of the post migration custom action to remove.
-
action_id
(ActionID)
–
Template post migration custom action ID to remove.
Raises:
Source code in docs_src/capo_mgn/_services/mgn.py
| def remove_template_action(
self,
launch_configuration_template_id: "capo_mgn.types.launch_configuration_template_id.LaunchConfigurationTemplateID",
action_id: "capo_mgn.types.action_id.ActionID",
*,
config_overrides: Optional[mgnClientConfig] = None,
) -> "capo_mgn.types.remove_template_action_response.RemoveTemplateActionResponse":
"""<p>Remove template post migration custom action.</p>
Args:
launch_configuration_template_id: <p>Launch configuration template ID of the post migration custom action to remove.</p>
action_id: <p>Template post migration custom action ID to remove.</p>
Raises:
capo_mgn.errors.resource_not_found_exception.ResourceNotFoundException: <p>Resource not found exception.</p>
capo_mgn.errors.uninitialized_account_exception.UninitializedAccountException: <p>Uninitialized account exception.</p>
capo_mgn.errors.validation_exception.ValidationException: <p>Validate exception.</p>
capo_mgn.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_mgn.types.remove_template_action_request.RemoveTemplateActionRequest]",
) -> OperationResponse[
"capo_mgn.types.remove_template_action_response.RemoveTemplateActionResponse"
]:
import capo_mgn._operations.application_migration_service.remove_template_action
output, http_response = (
capo_mgn._operations.application_migration_service.remove_template_action.remove_template_action(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("RemoveTemplateAction")
)
input_: capo_mgn.types.remove_template_action_request.RemoveTemplateActionRequest = {
"launch_configuration_template_id": launch_configuration_template_id,
"action_id": action_id,
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|