1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl super::Client {
    /// Constructs a fluent builder for the [`ImportSourceCredentials`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder) operation.
    ///
    /// - The fluent builder is configurable:
    ///   - [`username(impl Into<String>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::username) / [`set_username(Option<String>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::set_username):<br>required: **false**<br><p>The Bitbucket username when the <code>authType</code> is BASIC_AUTH. This parameter is not valid for other types of source providers or connections.</p><br>
    ///   - [`token(impl Into<String>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::token) / [`set_token(Option<String>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::set_token):<br>required: **true**<br><p>For GitHub or GitHub Enterprise, this is the personal access token. For Bitbucket, this is either the access token or the app password. For the <code>authType</code> CODECONNECTIONS, this is the <code>connectionArn</code>.</p><br>
    ///   - [`server_type(ServerType)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::server_type) / [`set_server_type(Option<ServerType>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::set_server_type):<br>required: **true**<br><p>The source provider used for this project.</p><br>
    ///   - [`auth_type(AuthType)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::auth_type) / [`set_auth_type(Option<AuthType>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::set_auth_type):<br>required: **true**<br><p>The type of authentication used to connect to a GitHub, GitHub Enterprise, GitLab, GitLab Self Managed, or Bitbucket repository. An OAUTH connection is not supported by the API and must be created using the CodeBuild console. Note that CODECONNECTIONS is only valid for GitLab and GitLab Self Managed.</p><br>
    ///   - [`should_overwrite(bool)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::should_overwrite) / [`set_should_overwrite(Option<bool>)`](crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::set_should_overwrite):<br>required: **false**<br><p>Set to <code>false</code> to prevent overwriting the repository source credentials. Set to <code>true</code> to overwrite the repository source credentials. The default value is <code>true</code>.</p><br>
    /// - On success, responds with [`ImportSourceCredentialsOutput`](crate::operation::import_source_credentials::ImportSourceCredentialsOutput) with field(s):
    ///   - [`arn(Option<String>)`](crate::operation::import_source_credentials::ImportSourceCredentialsOutput::arn): <p>The Amazon Resource Name (ARN) of the token.</p>
    /// - On failure, responds with [`SdkError<ImportSourceCredentialsError>`](crate::operation::import_source_credentials::ImportSourceCredentialsError)
    pub fn import_source_credentials(&self) -> crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder {
        crate::operation::import_source_credentials::builders::ImportSourceCredentialsFluentBuilder::new(self.handle.clone())
    }
}