Initiates the process of retrieving an existing preview that shows the effects that running a specified Automation runbook would have on the targeted resources.
Parameters:
Raises:
Source code in docs_src/capo_ssm/_services/ssm.py
| def get_execution_preview(
self,
execution_preview_id: "capo_ssm.types.execution_preview_id.ExecutionPreviewId",
*,
config_overrides: Optional[SSMClientConfig] = None,
) -> "capo_ssm.types.get_execution_preview_response.GetExecutionPreviewResponse":
"""<p>Initiates the process of retrieving an existing preview that shows the effects that running a specified Automation runbook would have on the targeted resources.</p>
Args:
execution_preview_id: <p>The ID of the existing execution preview.</p>
Raises:
capo_ssm.errors.internal_server_error.InternalServerError: <p>An error occurred on the server side.</p>
capo_ssm.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified parameter to be shared could not be found.</p>
capo_ssm.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_ssm.types.get_execution_preview_request.GetExecutionPreviewRequest]",
) -> OperationResponse[
"capo_ssm.types.get_execution_preview_response.GetExecutionPreviewResponse"
]:
import capo_ssm._operations.amazon_ssm.get_execution_preview
output, http_response = (
capo_ssm._operations.amazon_ssm.get_execution_preview.get_execution_preview(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("GetExecutionPreview")
)
input_: capo_ssm.types.get_execution_preview_request.GetExecutionPreviewRequest = {
"execution_preview_id": execution_preview_id
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|