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/async_mgn.py
| async 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[AsyncmgnClientConfig] = 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.
"""
async def _handler(
req: "AsyncOperationRequest[capo_mgn.types.remove_template_action_request.RemoveTemplateActionRequest]",
) -> AsyncOperationResponse[
"capo_mgn.types.remove_template_action_response.RemoveTemplateActionResponse"
]:
import capo_mgn._operations.application_migration_service.remove_template_action
(
output,
http_response,
) = await capo_mgn._operations.application_migration_service.remove_template_action.async_remove_template_action(
req.options, req.input
)
return AsyncOperationResponse(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 = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|