Skip to main content

aws_sdk_continuum/client/
create_code_scan.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`CreateCodeScan`](crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`environment_id(impl Into<String>)`](crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder::environment_id) / [`set_environment_id(Option<String>)`](crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder::set_environment_id):<br>required: **true**<br>Environment to scan.<br>
7    ///   - [`client_token(impl Into<String>)`](crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder::client_token) / [`set_client_token(Option<String>)`](crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder::set_client_token):<br>required: **false**<br>An optional token identifying one scan request for this environment. SDKs generate a token when omitted. If a request reaches the service without a token, the service generates one for that request, so each request without a token starts a new scan. To retry a request after a lost response, supply the same token on the same environment; once a request with that token has succeeded, a retry returns the original scan. Concurrent requests with the same token, or a retry after a request that failed partway through, can leave an additional scan, which may end FAILED as superseded. A token is bound to its scan for as long as the service retains the scan's build record, with no shorter expiry. Deleting the environment makes the binding inaccessible: a later request with the token returns ResourceNotFoundException.<br>
8    /// - On success, responds with [`CreateCodeScanOutput`](crate::operation::create_code_scan::CreateCodeScanOutput) with field(s):
9    ///   - [`scan(Option<CodeScanSummary>)`](crate::operation::create_code_scan::CreateCodeScanOutput::scan): The scan run this request created, or the scan run a previous request with the same clientToken already accepted.
10    /// - On failure, responds with [`SdkError<CreateCodeScanError>`](crate::operation::create_code_scan::CreateCodeScanError)
11    pub fn create_code_scan(&self) -> crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder {
12        crate::operation::create_code_scan::builders::CreateCodeScanFluentBuilder::new(self.handle.clone())
13    }
14}