AWS SDK

AWS SDK

rev. e063993ca0ab793f44c575dbe707d50a5e3e2406

Files changed:

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_invalid_request_exception.rs

@@ -1,0 +35,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_invalid_request_exception_json_err(
    3         -
    _value: &[u8],
    4         -
    mut builder: crate::types::error::builders::InvalidRequestExceptionBuilder,
    5         -
) -> ::std::result::Result<crate::types::error::builders::InvalidRequestExceptionBuilder, ::aws_smithy_json::deserialize::error::DeserializeError> {
    6         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
    7         -
    let tokens = &mut tokens_owned;
    8         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
    9         -
    loop {
   10         -
        match tokens.next().transpose()? {
   11         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   12         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   13         -
                "message" => {
   14         -
                    builder = builder.set_message(
   15         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   16         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   17         -
                            .transpose()?,
   18         -
                    );
   19         -
                }
   20         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   21         -
            },
   22         -
            other => {
   23         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   24         -
                    "expected object key or end object, found: {other:?}"
   25         -
                )))
   26         -
            }
   27         -
        }
   28         -
    }
   29         -
    if tokens.next().is_some() {
   30         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   31         -
            "found more JSON tokens after completing parsing",
   32         -
        ));
   33         -
    }
   34         -
    Ok(builder)
   35         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_list_account_roles.rs

@@ -1,0 +157,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_list_account_roles_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<crate::operation::list_account_roles::ListAccountRolesOutput, crate::operation::list_account_roles::ListAccountRolesError> {
    8         -
    #[allow(unused_mut)]
    9         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   10         -
        .map_err(crate::operation::list_account_roles::ListAccountRolesError::unhandled)?;
   11         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   12         -
    let generic = generic_builder.build();
   13         -
    let error_code = match generic.code() {
   14         -
        Some(code) => code,
   15         -
        None => return Err(crate::operation::list_account_roles::ListAccountRolesError::unhandled(generic)),
   16         -
    };
   17         -
   18         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   19         -
    Err(match error_code {
   20         -
        "InvalidRequestException" => crate::operation::list_account_roles::ListAccountRolesError::InvalidRequestException({
   21         -
            #[allow(unused_mut)]
   22         -
            let mut tmp = {
   23         -
                #[allow(unused_mut)]
   24         -
                let mut output = crate::types::error::builders::InvalidRequestExceptionBuilder::default();
   25         -
                output = crate::protocol_serde::shape_invalid_request_exception::de_invalid_request_exception_json_err(_response_body, output)
   26         -
                    .map_err(crate::operation::list_account_roles::ListAccountRolesError::unhandled)?;
   27         -
                let output = output.meta(generic);
   28         -
                output.build()
   29         -
            };
   30         -
            if tmp.message.is_none() {
   31         -
                tmp.message = _error_message;
   32         -
            }
   33         -
            tmp
   34         -
        }),
   35         -
        "ResourceNotFoundException" => crate::operation::list_account_roles::ListAccountRolesError::ResourceNotFoundException({
   36         -
            #[allow(unused_mut)]
   37         -
            let mut tmp = {
   38         -
                #[allow(unused_mut)]
   39         -
                let mut output = crate::types::error::builders::ResourceNotFoundExceptionBuilder::default();
   40         -
                output = crate::protocol_serde::shape_resource_not_found_exception::de_resource_not_found_exception_json_err(_response_body, output)
   41         -
                    .map_err(crate::operation::list_account_roles::ListAccountRolesError::unhandled)?;
   42         -
                let output = output.meta(generic);
   43         -
                output.build()
   44         -
            };
   45         -
            if tmp.message.is_none() {
   46         -
                tmp.message = _error_message;
   47         -
            }
   48         -
            tmp
   49         -
        }),
   50         -
        "TooManyRequestsException" => crate::operation::list_account_roles::ListAccountRolesError::TooManyRequestsException({
   51         -
            #[allow(unused_mut)]
   52         -
            let mut tmp = {
   53         -
                #[allow(unused_mut)]
   54         -
                let mut output = crate::types::error::builders::TooManyRequestsExceptionBuilder::default();
   55         -
                output = crate::protocol_serde::shape_too_many_requests_exception::de_too_many_requests_exception_json_err(_response_body, output)
   56         -
                    .map_err(crate::operation::list_account_roles::ListAccountRolesError::unhandled)?;
   57         -
                let output = output.meta(generic);
   58         -
                output.build()
   59         -
            };
   60         -
            if tmp.message.is_none() {
   61         -
                tmp.message = _error_message;
   62         -
            }
   63         -
            tmp
   64         -
        }),
   65         -
        "UnauthorizedException" => crate::operation::list_account_roles::ListAccountRolesError::UnauthorizedException({
   66         -
            #[allow(unused_mut)]
   67         -
            let mut tmp = {
   68         -
                #[allow(unused_mut)]
   69         -
                let mut output = crate::types::error::builders::UnauthorizedExceptionBuilder::default();
   70         -
                output = crate::protocol_serde::shape_unauthorized_exception::de_unauthorized_exception_json_err(_response_body, output)
   71         -
                    .map_err(crate::operation::list_account_roles::ListAccountRolesError::unhandled)?;
   72         -
                let output = output.meta(generic);
   73         -
                output.build()
   74         -
            };
   75         -
            if tmp.message.is_none() {
   76         -
                tmp.message = _error_message;
   77         -
            }
   78         -
            tmp
   79         -
        }),
   80         -
        _ => crate::operation::list_account_roles::ListAccountRolesError::generic(generic),
   81         -
    })
   82         -
}
   83         -
   84         -
#[allow(clippy::unnecessary_wraps)]
   85         -
pub fn de_list_account_roles_http_response(
   86         -
    _response_status: u16,
   87         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   88         -
    _response_body: &[u8],
   89         -
) -> std::result::Result<crate::operation::list_account_roles::ListAccountRolesOutput, crate::operation::list_account_roles::ListAccountRolesError> {
   90         -
    Ok({
   91         -
        #[allow(unused_mut)]
   92         -
        let mut output = crate::operation::list_account_roles::builders::ListAccountRolesOutputBuilder::default();
   93         -
        output = crate::protocol_serde::shape_list_account_roles::de_list_account_roles(_response_body, output)
   94         -
            .map_err(crate::operation::list_account_roles::ListAccountRolesError::unhandled)?;
   95         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
   96         -
        output.build()
   97         -
    })
   98         -
}
   99         -
  100         -
pub fn ser_list_account_roles_headers(
  101         -
    input: &crate::operation::list_account_roles::ListAccountRolesInput,
  102         -
    mut builder: ::http_1x::request::Builder,
  103         -
) -> std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  104         -
    if let ::std::option::Option::Some(inner_1) = &input.access_token {
  105         -
        let formatted_2 = inner_1.as_str();
  106         -
        let header_value = formatted_2;
  107         -
        let header_value: ::http_1x::HeaderValue = header_value.parse().map_err(|err| {
  108         -
            ::aws_smithy_types::error::operation::BuildError::invalid_field(
  109         -
                "access_token",
  110         -
                format!("`{}` cannot be used as a header value: {}", &"*** Sensitive Data Redacted ***", err),
  111         -
            )
  112         -
        })?;
  113         -
        builder = builder.header("x-amz-sso_bearer_token", header_value);
  114         -
    }
  115         -
    Ok(builder)
  116         -
}
  117         -
  118         -
pub(crate) fn de_list_account_roles(
  119         -
    _value: &[u8],
  120         -
    mut builder: crate::operation::list_account_roles::builders::ListAccountRolesOutputBuilder,
  121         -
) -> ::std::result::Result<
  122         -
    crate::operation::list_account_roles::builders::ListAccountRolesOutputBuilder,
  123         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
  124         -
> {
  125         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  126         -
    let tokens = &mut tokens_owned;
  127         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  128         -
    loop {
  129         -
        match tokens.next().transpose()? {
  130         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  131         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  132         -
                "nextToken" => {
  133         -
                    builder = builder.set_next_token(
  134         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  135         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  136         -
                            .transpose()?,
  137         -
                    );
  138         -
                }
  139         -
                "roleList" => {
  140         -
                    builder = builder.set_role_list(crate::protocol_serde::shape_role_list_type::de_role_list_type(tokens, _value)?);
  141         -
                }
  142         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  143         -
            },
  144         -
            other => {
  145         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  146         -
                    "expected object key or end object, found: {other:?}"
  147         -
                )))
  148         -
            }
  149         -
        }
  150         -
    }
  151         -
    if tokens.next().is_some() {
  152         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  153         -
            "found more JSON tokens after completing parsing",
  154         -
        ));
  155         -
    }
  156         -
    Ok(builder)
  157         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_list_accounts.rs

@@ -1,0 +157,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_list_accounts_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<crate::operation::list_accounts::ListAccountsOutput, crate::operation::list_accounts::ListAccountsError> {
    8         -
    #[allow(unused_mut)]
    9         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   10         -
        .map_err(crate::operation::list_accounts::ListAccountsError::unhandled)?;
   11         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   12         -
    let generic = generic_builder.build();
   13         -
    let error_code = match generic.code() {
   14         -
        Some(code) => code,
   15         -
        None => return Err(crate::operation::list_accounts::ListAccountsError::unhandled(generic)),
   16         -
    };
   17         -
   18         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   19         -
    Err(match error_code {
   20         -
        "InvalidRequestException" => crate::operation::list_accounts::ListAccountsError::InvalidRequestException({
   21         -
            #[allow(unused_mut)]
   22         -
            let mut tmp = {
   23         -
                #[allow(unused_mut)]
   24         -
                let mut output = crate::types::error::builders::InvalidRequestExceptionBuilder::default();
   25         -
                output = crate::protocol_serde::shape_invalid_request_exception::de_invalid_request_exception_json_err(_response_body, output)
   26         -
                    .map_err(crate::operation::list_accounts::ListAccountsError::unhandled)?;
   27         -
                let output = output.meta(generic);
   28         -
                output.build()
   29         -
            };
   30         -
            if tmp.message.is_none() {
   31         -
                tmp.message = _error_message;
   32         -
            }
   33         -
            tmp
   34         -
        }),
   35         -
        "ResourceNotFoundException" => crate::operation::list_accounts::ListAccountsError::ResourceNotFoundException({
   36         -
            #[allow(unused_mut)]
   37         -
            let mut tmp = {
   38         -
                #[allow(unused_mut)]
   39         -
                let mut output = crate::types::error::builders::ResourceNotFoundExceptionBuilder::default();
   40         -
                output = crate::protocol_serde::shape_resource_not_found_exception::de_resource_not_found_exception_json_err(_response_body, output)
   41         -
                    .map_err(crate::operation::list_accounts::ListAccountsError::unhandled)?;
   42         -
                let output = output.meta(generic);
   43         -
                output.build()
   44         -
            };
   45         -
            if tmp.message.is_none() {
   46         -
                tmp.message = _error_message;
   47         -
            }
   48         -
            tmp
   49         -
        }),
   50         -
        "TooManyRequestsException" => crate::operation::list_accounts::ListAccountsError::TooManyRequestsException({
   51         -
            #[allow(unused_mut)]
   52         -
            let mut tmp = {
   53         -
                #[allow(unused_mut)]
   54         -
                let mut output = crate::types::error::builders::TooManyRequestsExceptionBuilder::default();
   55         -
                output = crate::protocol_serde::shape_too_many_requests_exception::de_too_many_requests_exception_json_err(_response_body, output)
   56         -
                    .map_err(crate::operation::list_accounts::ListAccountsError::unhandled)?;
   57         -
                let output = output.meta(generic);
   58         -
                output.build()
   59         -
            };
   60         -
            if tmp.message.is_none() {
   61         -
                tmp.message = _error_message;
   62         -
            }
   63         -
            tmp
   64         -
        }),
   65         -
        "UnauthorizedException" => crate::operation::list_accounts::ListAccountsError::UnauthorizedException({
   66         -
            #[allow(unused_mut)]
   67         -
            let mut tmp = {
   68         -
                #[allow(unused_mut)]
   69         -
                let mut output = crate::types::error::builders::UnauthorizedExceptionBuilder::default();
   70         -
                output = crate::protocol_serde::shape_unauthorized_exception::de_unauthorized_exception_json_err(_response_body, output)
   71         -
                    .map_err(crate::operation::list_accounts::ListAccountsError::unhandled)?;
   72         -
                let output = output.meta(generic);
   73         -
                output.build()
   74         -
            };
   75         -
            if tmp.message.is_none() {
   76         -
                tmp.message = _error_message;
   77         -
            }
   78         -
            tmp
   79         -
        }),
   80         -
        _ => crate::operation::list_accounts::ListAccountsError::generic(generic),
   81         -
    })
   82         -
}
   83         -
   84         -
#[allow(clippy::unnecessary_wraps)]
   85         -
pub fn de_list_accounts_http_response(
   86         -
    _response_status: u16,
   87         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   88         -
    _response_body: &[u8],
   89         -
) -> std::result::Result<crate::operation::list_accounts::ListAccountsOutput, crate::operation::list_accounts::ListAccountsError> {
   90         -
    Ok({
   91         -
        #[allow(unused_mut)]
   92         -
        let mut output = crate::operation::list_accounts::builders::ListAccountsOutputBuilder::default();
   93         -
        output = crate::protocol_serde::shape_list_accounts::de_list_accounts(_response_body, output)
   94         -
            .map_err(crate::operation::list_accounts::ListAccountsError::unhandled)?;
   95         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
   96         -
        output.build()
   97         -
    })
   98         -
}
   99         -
  100         -
pub fn ser_list_accounts_headers(
  101         -
    input: &crate::operation::list_accounts::ListAccountsInput,
  102         -
    mut builder: ::http_1x::request::Builder,
  103         -
) -> std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  104         -
    if let ::std::option::Option::Some(inner_1) = &input.access_token {
  105         -
        let formatted_2 = inner_1.as_str();
  106         -
        let header_value = formatted_2;
  107         -
        let header_value: ::http_1x::HeaderValue = header_value.parse().map_err(|err| {
  108         -
            ::aws_smithy_types::error::operation::BuildError::invalid_field(
  109         -
                "access_token",
  110         -
                format!("`{}` cannot be used as a header value: {}", &"*** Sensitive Data Redacted ***", err),
  111         -
            )
  112         -
        })?;
  113         -
        builder = builder.header("x-amz-sso_bearer_token", header_value);
  114         -
    }
  115         -
    Ok(builder)
  116         -
}
  117         -
  118         -
pub(crate) fn de_list_accounts(
  119         -
    _value: &[u8],
  120         -
    mut builder: crate::operation::list_accounts::builders::ListAccountsOutputBuilder,
  121         -
) -> ::std::result::Result<
  122         -
    crate::operation::list_accounts::builders::ListAccountsOutputBuilder,
  123         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
  124         -
> {
  125         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  126         -
    let tokens = &mut tokens_owned;
  127         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  128         -
    loop {
  129         -
        match tokens.next().transpose()? {
  130         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  131         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  132         -
                "accountList" => {
  133         -
                    builder = builder.set_account_list(crate::protocol_serde::shape_account_list_type::de_account_list_type(tokens, _value)?);
  134         -
                }
  135         -
                "nextToken" => {
  136         -
                    builder = builder.set_next_token(
  137         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  138         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  139         -
                            .transpose()?,
  140         -
                    );
  141         -
                }
  142         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  143         -
            },
  144         -
            other => {
  145         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  146         -
                    "expected object key or end object, found: {other:?}"
  147         -
                )))
  148         -
            }
  149         -
        }
  150         -
    }
  151         -
    if tokens.next().is_some() {
  152         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  153         -
            "found more JSON tokens after completing parsing",
  154         -
        ));
  155         -
    }
  156         -
    Ok(builder)
  157         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_logout.rs

@@ -1,0 +99,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_logout_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<crate::operation::logout::LogoutOutput, crate::operation::logout::LogoutError> {
    8         -
    #[allow(unused_mut)]
    9         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   10         -
        .map_err(crate::operation::logout::LogoutError::unhandled)?;
   11         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   12         -
    let generic = generic_builder.build();
   13         -
    let error_code = match generic.code() {
   14         -
        Some(code) => code,
   15         -
        None => return Err(crate::operation::logout::LogoutError::unhandled(generic)),
   16         -
    };
   17         -
   18         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   19         -
    Err(match error_code {
   20         -
        "InvalidRequestException" => crate::operation::logout::LogoutError::InvalidRequestException({
   21         -
            #[allow(unused_mut)]
   22         -
            let mut tmp = {
   23         -
                #[allow(unused_mut)]
   24         -
                let mut output = crate::types::error::builders::InvalidRequestExceptionBuilder::default();
   25         -
                output = crate::protocol_serde::shape_invalid_request_exception::de_invalid_request_exception_json_err(_response_body, output)
   26         -
                    .map_err(crate::operation::logout::LogoutError::unhandled)?;
   27         -
                let output = output.meta(generic);
   28         -
                output.build()
   29         -
            };
   30         -
            if tmp.message.is_none() {
   31         -
                tmp.message = _error_message;
   32         -
            }
   33         -
            tmp
   34         -
        }),
   35         -
        "TooManyRequestsException" => crate::operation::logout::LogoutError::TooManyRequestsException({
   36         -
            #[allow(unused_mut)]
   37         -
            let mut tmp = {
   38         -
                #[allow(unused_mut)]
   39         -
                let mut output = crate::types::error::builders::TooManyRequestsExceptionBuilder::default();
   40         -
                output = crate::protocol_serde::shape_too_many_requests_exception::de_too_many_requests_exception_json_err(_response_body, output)
   41         -
                    .map_err(crate::operation::logout::LogoutError::unhandled)?;
   42         -
                let output = output.meta(generic);
   43         -
                output.build()
   44         -
            };
   45         -
            if tmp.message.is_none() {
   46         -
                tmp.message = _error_message;
   47         -
            }
   48         -
            tmp
   49         -
        }),
   50         -
        "UnauthorizedException" => crate::operation::logout::LogoutError::UnauthorizedException({
   51         -
            #[allow(unused_mut)]
   52         -
            let mut tmp = {
   53         -
                #[allow(unused_mut)]
   54         -
                let mut output = crate::types::error::builders::UnauthorizedExceptionBuilder::default();
   55         -
                output = crate::protocol_serde::shape_unauthorized_exception::de_unauthorized_exception_json_err(_response_body, output)
   56         -
                    .map_err(crate::operation::logout::LogoutError::unhandled)?;
   57         -
                let output = output.meta(generic);
   58         -
                output.build()
   59         -
            };
   60         -
            if tmp.message.is_none() {
   61         -
                tmp.message = _error_message;
   62         -
            }
   63         -
            tmp
   64         -
        }),
   65         -
        _ => crate::operation::logout::LogoutError::generic(generic),
   66         -
    })
   67         -
}
   68         -
   69         -
#[allow(clippy::unnecessary_wraps)]
   70         -
pub fn de_logout_http_response(
   71         -
    _response_status: u16,
   72         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   73         -
    _response_body: &[u8],
   74         -
) -> std::result::Result<crate::operation::logout::LogoutOutput, crate::operation::logout::LogoutError> {
   75         -
    Ok({
   76         -
        #[allow(unused_mut)]
   77         -
        let mut output = crate::operation::logout::builders::LogoutOutputBuilder::default();
   78         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
   79         -
        output.build()
   80         -
    })
   81         -
}
   82         -
   83         -
pub fn ser_logout_headers(
   84         -
    input: &crate::operation::logout::LogoutInput,
   85         -
    mut builder: ::http_1x::request::Builder,
   86         -
) -> std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
   87         -
    if let ::std::option::Option::Some(inner_1) = &input.access_token {
   88         -
        let formatted_2 = inner_1.as_str();
   89         -
        let header_value = formatted_2;
   90         -
        let header_value: ::http_1x::HeaderValue = header_value.parse().map_err(|err| {
   91         -
            ::aws_smithy_types::error::operation::BuildError::invalid_field(
   92         -
                "access_token",
   93         -
                format!("`{}` cannot be used as a header value: {}", &"*** Sensitive Data Redacted ***", err),
   94         -
            )
   95         -
        })?;
   96         -
        builder = builder.header("x-amz-sso_bearer_token", header_value);
   97         -
    }
   98         -
    Ok(builder)
   99         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_resource_not_found_exception.rs

@@ -1,0 +35,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_resource_not_found_exception_json_err(
    3         -
    _value: &[u8],
    4         -
    mut builder: crate::types::error::builders::ResourceNotFoundExceptionBuilder,
    5         -
) -> ::std::result::Result<crate::types::error::builders::ResourceNotFoundExceptionBuilder, ::aws_smithy_json::deserialize::error::DeserializeError> {
    6         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
    7         -
    let tokens = &mut tokens_owned;
    8         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
    9         -
    loop {
   10         -
        match tokens.next().transpose()? {
   11         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   12         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   13         -
                "message" => {
   14         -
                    builder = builder.set_message(
   15         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   16         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   17         -
                            .transpose()?,
   18         -
                    );
   19         -
                }
   20         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   21         -
            },
   22         -
            other => {
   23         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   24         -
                    "expected object key or end object, found: {other:?}"
   25         -
                )))
   26         -
            }
   27         -
        }
   28         -
    }
   29         -
    if tokens.next().is_some() {
   30         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   31         -
            "found more JSON tokens after completing parsing",
   32         -
        ));
   33         -
    }
   34         -
    Ok(builder)
   35         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_role_credentials.rs

@@ -1,0 +61,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_role_credentials<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::RoleCredentials>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::RoleCredentialsBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "accessKeyId" => {
   19         -
                            builder = builder.set_access_key_id(
   20         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                                    .transpose()?,
   23         -
                            );
   24         -
                        }
   25         -
                        "secretAccessKey" => {
   26         -
                            builder = builder.set_secret_access_key(
   27         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   28         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   29         -
                                    .transpose()?,
   30         -
                            );
   31         -
                        }
   32         -
                        "sessionToken" => {
   33         -
                            builder = builder.set_session_token(
   34         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   35         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   36         -
                                    .transpose()?,
   37         -
                            );
   38         -
                        }
   39         -
                        "expiration" => {
   40         -
                            builder = builder.set_expiration(
   41         -
                                ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
   42         -
                                    .map(i64::try_from)
   43         -
                                    .transpose()?,
   44         -
                            );
   45         -
                        }
   46         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   47         -
                    },
   48         -
                    other => {
   49         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   50         -
                            "expected object key or end object, found: {other:?}"
   51         -
                        )))
   52         -
                    }
   53         -
                }
   54         -
            }
   55         -
            Ok(Some(builder.build()))
   56         -
        }
   57         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   58         -
            "expected start object or null",
   59         -
        )),
   60         -
    }
   61         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_role_info.rs

@@ -1,0 +47,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_role_info<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::RoleInfo>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::RoleInfoBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "roleName" => {
   19         -
                            builder = builder.set_role_name(
   20         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                                    .transpose()?,
   23         -
                            );
   24         -
                        }
   25         -
                        "accountId" => {
   26         -
                            builder = builder.set_account_id(
   27         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   28         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   29         -
                                    .transpose()?,
   30         -
                            );
   31         -
                        }
   32         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   33         -
                    },
   34         -
                    other => {
   35         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   36         -
                            "expected object key or end object, found: {other:?}"
   37         -
                        )))
   38         -
                    }
   39         -
                }
   40         -
            }
   41         -
            Ok(Some(builder.build()))
   42         -
        }
   43         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   44         -
            "expected start object or null",
   45         -
        )),
   46         -
    }
   47         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_role_list_type.rs

@@ -1,0 +37,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_role_list_type<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<::std::vec::Vec<crate::types::RoleInfo>>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   12         -
            let mut items = Vec::new();
   13         -
            loop {
   14         -
                match tokens.peek() {
   15         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   16         -
                        tokens.next().transpose().unwrap();
   17         -
                        break;
   18         -
                    }
   19         -
                    _ => {
   20         -
                        let value = crate::protocol_serde::shape_role_info::de_role_info(tokens, _value)?;
   21         -
                        if let Some(value) = value {
   22         -
                            items.push(value);
   23         -
                        } else {
   24         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   25         -
                                "dense list cannot contain null values",
   26         -
                            ));
   27         -
                        }
   28         -
                    }
   29         -
                }
   30         -
            }
   31         -
            Ok(Some(items))
   32         -
        }
   33         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   34         -
            "expected start array or null",
   35         -
        )),
   36         -
    }
   37         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_too_many_requests_exception.rs

@@ -1,0 +35,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_too_many_requests_exception_json_err(
    3         -
    _value: &[u8],
    4         -
    mut builder: crate::types::error::builders::TooManyRequestsExceptionBuilder,
    5         -
) -> ::std::result::Result<crate::types::error::builders::TooManyRequestsExceptionBuilder, ::aws_smithy_json::deserialize::error::DeserializeError> {
    6         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
    7         -
    let tokens = &mut tokens_owned;
    8         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
    9         -
    loop {
   10         -
        match tokens.next().transpose()? {
   11         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   12         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   13         -
                "message" => {
   14         -
                    builder = builder.set_message(
   15         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   16         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   17         -
                            .transpose()?,
   18         -
                    );
   19         -
                }
   20         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   21         -
            },
   22         -
            other => {
   23         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   24         -
                    "expected object key or end object, found: {other:?}"
   25         -
                )))
   26         -
            }
   27         -
        }
   28         -
    }
   29         -
    if tokens.next().is_some() {
   30         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   31         -
            "found more JSON tokens after completing parsing",
   32         -
        ));
   33         -
    }
   34         -
    Ok(builder)
   35         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/protocol_serde/shape_unauthorized_exception.rs

@@ -1,0 +35,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_unauthorized_exception_json_err(
    3         -
    _value: &[u8],
    4         -
    mut builder: crate::types::error::builders::UnauthorizedExceptionBuilder,
    5         -
) -> ::std::result::Result<crate::types::error::builders::UnauthorizedExceptionBuilder, ::aws_smithy_json::deserialize::error::DeserializeError> {
    6         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
    7         -
    let tokens = &mut tokens_owned;
    8         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
    9         -
    loop {
   10         -
        match tokens.next().transpose()? {
   11         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   12         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   13         -
                "message" => {
   14         -
                    builder = builder.set_message(
   15         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   16         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   17         -
                            .transpose()?,
   18         -
                    );
   19         -
                }
   20         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   21         -
            },
   22         -
            other => {
   23         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   24         -
                    "expected object key or end object, found: {other:?}"
   25         -
                )))
   26         -
            }
   27         -
        }
   28         -
    }
   29         -
    if tokens.next().is_some() {
   30         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   31         -
            "found more JSON tokens after completing parsing",
   32         -
        ));
   33         -
    }
   34         -
    Ok(builder)
   35         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/serialization_settings.rs

@@ -1,0 +89,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
/*
    3         -
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
    4         -
 * SPDX-License-Identifier: Apache-2.0
    5         -
 */
    6         -
    7         -
#![allow(dead_code)]
    8         -
    9         -
use aws_smithy_http::header::set_request_header_if_absent;
   10         -
use aws_smithy_types::config_bag::{Storable, StoreReplace};
   11         -
use http_1x::header::{HeaderName, CONTENT_LENGTH, CONTENT_TYPE};
   12         -
   13         -
/// Configuration for how default protocol headers are serialized
   14         -
#[derive(Clone, Debug, Default)]
   15         -
pub(crate) struct HeaderSerializationSettings {
   16         -
    omit_default_content_length: bool,
   17         -
    omit_default_content_type: bool,
   18         -
}
   19         -
   20         -
impl HeaderSerializationSettings {
   21         -
    /// Creates new [`HeaderSerializationSettings`]
   22         -
    pub(crate) fn new() -> Self {
   23         -
        Default::default()
   24         -
    }
   25         -
   26         -
    /// Omit the default `Content-Length` header during serialization
   27         -
    pub(crate) fn omit_default_content_length(self) -> Self {
   28         -
        Self {
   29         -
            omit_default_content_length: true,
   30         -
            ..self
   31         -
        }
   32         -
    }
   33         -
   34         -
    /// Omit the default `Content-Type` header during serialization
   35         -
    pub(crate) fn omit_default_content_type(self) -> Self {
   36         -
        Self {
   37         -
            omit_default_content_type: true,
   38         -
            ..self
   39         -
        }
   40         -
    }
   41         -
   42         -
    /// Returns true if the given default header name should be serialized
   43         -
    fn include_header(&self, header: &HeaderName) -> bool {
   44         -
        (!self.omit_default_content_length || header != CONTENT_LENGTH) && (!self.omit_default_content_type || header != CONTENT_TYPE)
   45         -
    }
   46         -
   47         -
    /// Sets a default header on the given request builder if it should be serialized
   48         -
    pub(crate) fn set_default_header(
   49         -
        &self,
   50         -
        mut request: http_1x::request::Builder,
   51         -
        header_name: HeaderName,
   52         -
        value: &str,
   53         -
    ) -> http_1x::request::Builder {
   54         -
        if self.include_header(&header_name) {
   55         -
            request = set_request_header_if_absent(request, header_name, value);
   56         -
        }
   57         -
        request
   58         -
    }
   59         -
}
   60         -
   61         -
impl Storable for HeaderSerializationSettings {
   62         -
    type Storer = StoreReplace<Self>;
   63         -
}
   64         -
   65         -
#[cfg(test)]
   66         -
mod tests {
   67         -
    use super::*;
   68         -
   69         -
    #[test]
   70         -
    fn test_include_header() {
   71         -
        let settings = HeaderSerializationSettings::default();
   72         -
        assert!(settings.include_header(&CONTENT_LENGTH));
   73         -
        assert!(settings.include_header(&CONTENT_TYPE));
   74         -
   75         -
        let settings = HeaderSerializationSettings::default().omit_default_content_length();
   76         -
        assert!(!settings.include_header(&CONTENT_LENGTH));
   77         -
        assert!(settings.include_header(&CONTENT_TYPE));
   78         -
   79         -
        let settings = HeaderSerializationSettings::default().omit_default_content_type();
   80         -
        assert!(settings.include_header(&CONTENT_LENGTH));
   81         -
        assert!(!settings.include_header(&CONTENT_TYPE));
   82         -
   83         -
        let settings = HeaderSerializationSettings::default()
   84         -
            .omit_default_content_type()
   85         -
            .omit_default_content_length();
   86         -
        assert!(!settings.include_header(&CONTENT_LENGTH));
   87         -
        assert!(!settings.include_header(&CONTENT_TYPE));
   88         -
    }
   89         -
}

tmp-codegen-diff/aws-sdk/sdk/sso/src/types/_account_info.rs

@@ -3,3 +140,151 @@
   23     23   
    /// <p>The email address of the AWS account that is assigned to the user.</p>
   24     24   
    pub fn email_address(&self) -> ::std::option::Option<&str> {
   25     25   
        self.email_address.as_deref()
   26     26   
    }
   27     27   
}
   28     28   
static ACCOUNTINFO_SCHEMA_ID: ::aws_smithy_schema::ShapeId =
   29     29   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#AccountInfo", "com.amazonaws.sso", "AccountInfo");
   30     30   
static ACCOUNTINFO_MEMBER_ACCOUNT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   31     31   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#AccountInfo$accountId", "com.amazonaws.sso", "AccountInfo"),
   32     32   
    ::aws_smithy_schema::ShapeType::String,
   33         -
    "account_id",
          33  +
    "accountId",
   34     34   
    0,
   35     35   
);
   36     36   
static ACCOUNTINFO_MEMBER_ACCOUNT_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   37     37   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#AccountInfo$accountName", "com.amazonaws.sso", "AccountInfo"),
   38     38   
    ::aws_smithy_schema::ShapeType::String,
   39         -
    "account_name",
          39  +
    "accountName",
   40     40   
    1,
   41     41   
);
   42     42   
static ACCOUNTINFO_MEMBER_EMAIL_ADDRESS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   43     43   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#AccountInfo$emailAddress", "com.amazonaws.sso", "AccountInfo"),
   44     44   
    ::aws_smithy_schema::ShapeType::String,
   45         -
    "email_address",
          45  +
    "emailAddress",
   46     46   
    2,
   47     47   
);
   48     48   
static ACCOUNTINFO_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   49     49   
    ACCOUNTINFO_SCHEMA_ID,
   50     50   
    ::aws_smithy_schema::ShapeType::Structure,
   51     51   
    &[
   52     52   
        &ACCOUNTINFO_MEMBER_ACCOUNT_ID,
   53     53   
        &ACCOUNTINFO_MEMBER_ACCOUNT_NAME,
   54     54   
        &ACCOUNTINFO_MEMBER_EMAIL_ADDRESS,
   55     55   
    ],
   56     56   
);
   57     57   
impl AccountInfo {
   58     58   
    /// The schema for this shape.
   59     59   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &ACCOUNTINFO_SCHEMA;
   60     60   
}
   61     61   
impl ::aws_smithy_schema::serde::SerializableStruct for AccountInfo {
   62     62   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   63     63   
    fn serialize_members(
   64     64   
        &self,
   65     65   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   66     66   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   67     67   
        if let Some(ref val) = self.account_id {
   68     68   
            ser.write_string(&ACCOUNTINFO_MEMBER_ACCOUNT_ID, val)?;
   69     69   
        }
   70     70   
        if let Some(ref val) = self.account_name {
   71     71   
            ser.write_string(&ACCOUNTINFO_MEMBER_ACCOUNT_NAME, val)?;
   72     72   
        }
   73     73   
        if let Some(ref val) = self.email_address {
   74     74   
            ser.write_string(&ACCOUNTINFO_MEMBER_EMAIL_ADDRESS, val)?;
   75     75   
        }
   76     76   
        Ok(())
   77     77   
    }
   78     78   
}
   79     79   
impl AccountInfo {
   80     80   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   81         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   82         -
        deserializer: &mut D,
          81  +
    pub fn deserialize(
          82  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   83     83   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   84     84   
        #[allow(unused_variables, unused_mut)]
   85     85   
        let mut builder = Self::builder();
   86     86   
        #[allow(
   87     87   
            unused_variables,
   88     88   
            unreachable_code,
   89     89   
            clippy::single_match,
   90     90   
            clippy::match_single_binding,
   91     91   
            clippy::diverging_sub_expression
   92     92   
        )]
   93         -
        deserializer.read_struct(&ACCOUNTINFO_SCHEMA, (), |_, member, deser| {
          93  +
        deserializer.read_struct(&ACCOUNTINFO_SCHEMA, &mut |member, deser| {
   94     94   
            match member.member_index() {
   95     95   
                Some(0) => {
   96     96   
                    builder.account_id = Some(deser.read_string(member)?);
   97     97   
                }
   98     98   
                Some(1) => {
   99     99   
                    builder.account_name = Some(deser.read_string(member)?);
  100    100   
                }
  101    101   
                Some(2) => {
  102    102   
                    builder.email_address = Some(deser.read_string(member)?);
  103    103   
                }
  104    104   
                _ => {}
  105    105   
            }
  106    106   
            Ok(())
  107    107   
        })?;
  108    108   
        Ok(builder.build())
  109    109   
    }
  110    110   
}
         111  +
impl AccountInfo {
         112  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         113  +
    pub fn deserialize_with_response(
         114  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         115  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         116  +
        _status: u16,
         117  +
        _body: &[u8],
         118  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         119  +
        Self::deserialize(deserializer)
         120  +
    }
         121  +
}
  111    122   
impl AccountInfo {
  112    123   
    /// Creates a new builder-style object to manufacture [`AccountInfo`](crate::types::AccountInfo).
  113    124   
    pub fn builder() -> crate::types::builders::AccountInfoBuilder {
  114    125   
        crate::types::builders::AccountInfoBuilder::default()
  115    126   
    }
  116    127   
}
  117    128   
  118    129   
/// A builder for [`AccountInfo`](crate::types::AccountInfo).
  119    130   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  120    131   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/sso/src/types/_role_credentials.rs

@@ -19,19 +175,186 @@
   39     39   
        formatter.field("session_token", &"*** Sensitive Data Redacted ***");
   40     40   
        formatter.field("expiration", &"*** Sensitive Data Redacted ***");
   41     41   
        formatter.finish()
   42     42   
    }
   43     43   
}
   44     44   
static ROLECREDENTIALS_SCHEMA_ID: ::aws_smithy_schema::ShapeId =
   45     45   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleCredentials", "com.amazonaws.sso", "RoleCredentials");
   46     46   
static ROLECREDENTIALS_MEMBER_ACCESS_KEY_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   47     47   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleCredentials$accessKeyId", "com.amazonaws.sso", "RoleCredentials"),
   48     48   
    ::aws_smithy_schema::ShapeType::String,
   49         -
    "access_key_id",
          49  +
    "accessKeyId",
   50     50   
    0,
   51     51   
);
   52     52   
static ROLECREDENTIALS_MEMBER_SECRET_ACCESS_KEY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   53     53   
    ::aws_smithy_schema::ShapeId::from_static(
   54     54   
        "com.amazonaws.sso#RoleCredentials$secretAccessKey",
   55     55   
        "com.amazonaws.sso",
   56     56   
        "RoleCredentials",
   57     57   
    ),
   58     58   
    ::aws_smithy_schema::ShapeType::String,
   59         -
    "secret_access_key",
          59  +
    "secretAccessKey",
   60     60   
    1,
   61     61   
);
   62     62   
static ROLECREDENTIALS_MEMBER_SESSION_TOKEN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   63     63   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleCredentials$sessionToken", "com.amazonaws.sso", "RoleCredentials"),
   64     64   
    ::aws_smithy_schema::ShapeType::String,
   65         -
    "session_token",
          65  +
    "sessionToken",
   66     66   
    2,
   67     67   
);
   68     68   
static ROLECREDENTIALS_MEMBER_EXPIRATION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   69     69   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleCredentials$expiration", "com.amazonaws.sso", "RoleCredentials"),
   70     70   
    ::aws_smithy_schema::ShapeType::Long,
   71     71   
    "expiration",
   72     72   
    3,
   73     73   
);
   74     74   
static ROLECREDENTIALS_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   75     75   
    ROLECREDENTIALS_SCHEMA_ID,
   76     76   
    ::aws_smithy_schema::ShapeType::Structure,
   77     77   
    &[
   78     78   
        &ROLECREDENTIALS_MEMBER_ACCESS_KEY_ID,
   79     79   
        &ROLECREDENTIALS_MEMBER_SECRET_ACCESS_KEY,
   80     80   
        &ROLECREDENTIALS_MEMBER_SESSION_TOKEN,
   81     81   
        &ROLECREDENTIALS_MEMBER_EXPIRATION,
   82     82   
    ],
   83     83   
)
   84     84   
.with_sensitive();
   85     85   
impl RoleCredentials {
   86     86   
    /// The schema for this shape.
   87     87   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &ROLECREDENTIALS_SCHEMA;
   88     88   
}
   89     89   
impl ::aws_smithy_schema::serde::SerializableStruct for RoleCredentials {
   90     90   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   91     91   
    fn serialize_members(
   92     92   
        &self,
   93     93   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   94     94   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   95     95   
        if let Some(ref val) = self.access_key_id {
   96     96   
            ser.write_string(&ROLECREDENTIALS_MEMBER_ACCESS_KEY_ID, val)?;
   97     97   
        }
   98     98   
        if let Some(ref val) = self.secret_access_key {
   99     99   
            ser.write_string(&ROLECREDENTIALS_MEMBER_SECRET_ACCESS_KEY, val)?;
  100    100   
        }
  101    101   
        if let Some(ref val) = self.session_token {
  102    102   
            ser.write_string(&ROLECREDENTIALS_MEMBER_SESSION_TOKEN, val)?;
  103    103   
        }
  104    104   
        {
  105    105   
            let val = &self.expiration;
  106    106   
            ser.write_long(&ROLECREDENTIALS_MEMBER_EXPIRATION, *val)?;
  107    107   
        }
  108    108   
        Ok(())
  109    109   
    }
  110    110   
}
  111    111   
impl RoleCredentials {
  112    112   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  113         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  114         -
        deserializer: &mut D,
         113  +
    pub fn deserialize(
         114  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  115    115   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  116    116   
        #[allow(unused_variables, unused_mut)]
  117    117   
        let mut builder = Self::builder();
  118    118   
        #[allow(
  119    119   
            unused_variables,
  120    120   
            unreachable_code,
  121    121   
            clippy::single_match,
  122    122   
            clippy::match_single_binding,
  123    123   
            clippy::diverging_sub_expression
  124    124   
        )]
  125         -
        deserializer.read_struct(&ROLECREDENTIALS_SCHEMA, (), |_, member, deser| {
         125  +
        deserializer.read_struct(&ROLECREDENTIALS_SCHEMA, &mut |member, deser| {
  126    126   
            match member.member_index() {
  127    127   
                Some(0) => {
  128    128   
                    builder.access_key_id = Some(deser.read_string(member)?);
  129    129   
                }
  130    130   
                Some(1) => {
  131    131   
                    builder.secret_access_key = Some(deser.read_string(member)?);
  132    132   
                }
  133    133   
                Some(2) => {
  134    134   
                    builder.session_token = Some(deser.read_string(member)?);
  135    135   
                }
  136    136   
                Some(3) => {
  137    137   
                    builder.expiration = Some(deser.read_long(member)?);
  138    138   
                }
  139    139   
                _ => {}
  140    140   
            }
  141    141   
            Ok(())
  142    142   
        })?;
  143    143   
        Ok(builder.build())
  144    144   
    }
  145    145   
}
         146  +
impl RoleCredentials {
         147  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         148  +
    pub fn deserialize_with_response(
         149  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         150  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         151  +
        _status: u16,
         152  +
        _body: &[u8],
         153  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         154  +
        Self::deserialize(deserializer)
         155  +
    }
         156  +
}
  146    157   
impl RoleCredentials {
  147    158   
    /// Creates a new builder-style object to manufacture [`RoleCredentials`](crate::types::RoleCredentials).
  148    159   
    pub fn builder() -> crate::types::builders::RoleCredentialsBuilder {
  149    160   
        crate::types::builders::RoleCredentialsBuilder::default()
  150    161   
    }
  151    162   
}
  152    163   
  153    164   
/// A builder for [`RoleCredentials`](crate::types::RoleCredentials).
  154    165   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
  155    166   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/sso/src/types/_role_info.rs

@@ -1,1 +118,129 @@
   17     17   
    /// <p>The identifier of the AWS account assigned to the user.</p>
   18     18   
    pub fn account_id(&self) -> ::std::option::Option<&str> {
   19     19   
        self.account_id.as_deref()
   20     20   
    }
   21     21   
}
   22     22   
static ROLEINFO_SCHEMA_ID: ::aws_smithy_schema::ShapeId =
   23     23   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleInfo", "com.amazonaws.sso", "RoleInfo");
   24     24   
static ROLEINFO_MEMBER_ROLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   25     25   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleInfo$roleName", "com.amazonaws.sso", "RoleInfo"),
   26     26   
    ::aws_smithy_schema::ShapeType::String,
   27         -
    "role_name",
          27  +
    "roleName",
   28     28   
    0,
   29     29   
);
   30     30   
static ROLEINFO_MEMBER_ACCOUNT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   31     31   
    ::aws_smithy_schema::ShapeId::from_static("com.amazonaws.sso#RoleInfo$accountId", "com.amazonaws.sso", "RoleInfo"),
   32     32   
    ::aws_smithy_schema::ShapeType::String,
   33         -
    "account_id",
          33  +
    "accountId",
   34     34   
    1,
   35     35   
);
   36     36   
static ROLEINFO_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   37     37   
    ROLEINFO_SCHEMA_ID,
   38     38   
    ::aws_smithy_schema::ShapeType::Structure,
   39     39   
    &[&ROLEINFO_MEMBER_ROLE_NAME, &ROLEINFO_MEMBER_ACCOUNT_ID],
   40     40   
);
   41     41   
impl RoleInfo {
   42     42   
    /// The schema for this shape.
   43     43   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &ROLEINFO_SCHEMA;
   44     44   
}
   45     45   
impl ::aws_smithy_schema::serde::SerializableStruct for RoleInfo {
   46     46   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   47     47   
    fn serialize_members(
   48     48   
        &self,
   49     49   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   50     50   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   51     51   
        if let Some(ref val) = self.role_name {
   52     52   
            ser.write_string(&ROLEINFO_MEMBER_ROLE_NAME, val)?;
   53     53   
        }
   54     54   
        if let Some(ref val) = self.account_id {
   55     55   
            ser.write_string(&ROLEINFO_MEMBER_ACCOUNT_ID, val)?;
   56     56   
        }
   57     57   
        Ok(())
   58     58   
    }
   59     59   
}
   60     60   
impl RoleInfo {
   61     61   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   62         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   63         -
        deserializer: &mut D,
          62  +
    pub fn deserialize(
          63  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   64     64   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   65     65   
        #[allow(unused_variables, unused_mut)]
   66     66   
        let mut builder = Self::builder();
   67     67   
        #[allow(
   68     68   
            unused_variables,
   69     69   
            unreachable_code,
   70     70   
            clippy::single_match,
   71     71   
            clippy::match_single_binding,
   72     72   
            clippy::diverging_sub_expression
   73     73   
        )]
   74         -
        deserializer.read_struct(&ROLEINFO_SCHEMA, (), |_, member, deser| {
          74  +
        deserializer.read_struct(&ROLEINFO_SCHEMA, &mut |member, deser| {
   75     75   
            match member.member_index() {
   76     76   
                Some(0) => {
   77     77   
                    builder.role_name = Some(deser.read_string(member)?);
   78     78   
                }
   79     79   
                Some(1) => {
   80     80   
                    builder.account_id = Some(deser.read_string(member)?);
   81     81   
                }
   82     82   
                _ => {}
   83     83   
            }
   84     84   
            Ok(())
   85     85   
        })?;
   86     86   
        Ok(builder.build())
   87     87   
    }
   88     88   
}
          89  +
impl RoleInfo {
          90  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          91  +
    pub fn deserialize_with_response(
          92  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          93  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          94  +
        _status: u16,
          95  +
        _body: &[u8],
          96  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          97  +
        Self::deserialize(deserializer)
          98  +
    }
          99  +
}
   89    100   
impl RoleInfo {
   90    101   
    /// Creates a new builder-style object to manufacture [`RoleInfo`](crate::types::RoleInfo).
   91    102   
    pub fn builder() -> crate::types::builders::RoleInfoBuilder {
   92    103   
        crate::types::builders::RoleInfoBuilder::default()
   93    104   
    }
   94    105   
}
   95    106   
   96    107   
/// A builder for [`RoleInfo`](crate::types::RoleInfo).
   97    108   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   98    109   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/sso/src/types/error/_invalid_request_exception.rs

@@ -19,19 +102,113 @@
   39     39   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   40     40   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   41     41   
        if let Some(ref val) = self.message {
   42     42   
            ser.write_string(&INVALIDREQUESTEXCEPTION_MEMBER_MESSAGE, val)?;
   43     43   
        }
   44     44   
        Ok(())
   45     45   
    }
   46     46   
}
   47     47   
impl InvalidRequestException {
   48     48   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   49         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   50         -
        deserializer: &mut D,
          49  +
    pub fn deserialize(
          50  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   51     51   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   52     52   
        #[allow(unused_variables, unused_mut)]
   53     53   
        let mut builder = Self::builder();
   54     54   
        #[allow(
   55     55   
            unused_variables,
   56     56   
            unreachable_code,
   57     57   
            clippy::single_match,
   58     58   
            clippy::match_single_binding,
   59     59   
            clippy::diverging_sub_expression
   60     60   
        )]
   61         -
        deserializer.read_struct(&INVALIDREQUESTEXCEPTION_SCHEMA, (), |_, member, deser| {
          61  +
        deserializer.read_struct(&INVALIDREQUESTEXCEPTION_SCHEMA, &mut |member, deser| {
   62     62   
            match member.member_index() {
   63     63   
                Some(0) => {
   64     64   
                    builder.message = Some(deser.read_string(member)?);
   65     65   
                }
   66     66   
                _ => {}
   67     67   
            }
   68     68   
            Ok(())
   69     69   
        })?;
   70     70   
        Ok(builder.build())
   71     71   
    }
   72     72   
}
          73  +
impl InvalidRequestException {
          74  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          75  +
    pub fn deserialize_with_response(
          76  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          77  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          78  +
        _status: u16,
          79  +
        _body: &[u8],
          80  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          81  +
        Self::deserialize(deserializer)
          82  +
    }
          83  +
}
   73     84   
impl InvalidRequestException {
   74     85   
    /// Returns the error message.
   75     86   
    pub fn message(&self) -> ::std::option::Option<&str> {
   76     87   
        self.message.as_deref()
   77     88   
    }
   78     89   
}
   79     90   
impl ::std::fmt::Display for InvalidRequestException {
   80     91   
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
   81     92   
        ::std::write!(f, "InvalidRequestException")?;
   82     93   
        if let ::std::option::Option::Some(inner_1) = &self.message {

tmp-codegen-diff/aws-sdk/sdk/sso/src/types/error/_resource_not_found_exception.rs

@@ -19,19 +102,113 @@
   39     39   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   40     40   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   41     41   
        if let Some(ref val) = self.message {
   42     42   
            ser.write_string(&RESOURCENOTFOUNDEXCEPTION_MEMBER_MESSAGE, val)?;
   43     43   
        }
   44     44   
        Ok(())
   45     45   
    }
   46     46   
}
   47     47   
impl ResourceNotFoundException {
   48     48   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   49         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   50         -
        deserializer: &mut D,
          49  +
    pub fn deserialize(
          50  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   51     51   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   52     52   
        #[allow(unused_variables, unused_mut)]
   53     53   
        let mut builder = Self::builder();
   54     54   
        #[allow(
   55     55   
            unused_variables,
   56     56   
            unreachable_code,
   57     57   
            clippy::single_match,
   58     58   
            clippy::match_single_binding,
   59     59   
            clippy::diverging_sub_expression
   60     60   
        )]
   61         -
        deserializer.read_struct(&RESOURCENOTFOUNDEXCEPTION_SCHEMA, (), |_, member, deser| {
          61  +
        deserializer.read_struct(&RESOURCENOTFOUNDEXCEPTION_SCHEMA, &mut |member, deser| {
   62     62   
            match member.member_index() {
   63     63   
                Some(0) => {
   64     64   
                    builder.message = Some(deser.read_string(member)?);
   65     65   
                }
   66     66   
                _ => {}
   67     67   
            }
   68     68   
            Ok(())
   69     69   
        })?;
   70     70   
        Ok(builder.build())
   71     71   
    }
   72     72   
}
          73  +
impl ResourceNotFoundException {
          74  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          75  +
    pub fn deserialize_with_response(
          76  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          77  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          78  +
        _status: u16,
          79  +
        _body: &[u8],
          80  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          81  +
        Self::deserialize(deserializer)
          82  +
    }
          83  +
}
   73     84   
impl ResourceNotFoundException {
   74     85   
    /// Returns the error message.
   75     86   
    pub fn message(&self) -> ::std::option::Option<&str> {
   76     87   
        self.message.as_deref()
   77     88   
    }
   78     89   
}
   79     90   
impl ::std::fmt::Display for ResourceNotFoundException {
   80     91   
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
   81     92   
        ::std::write!(f, "ResourceNotFoundException")?;
   82     93   
        if let ::std::option::Option::Some(inner_1) = &self.message {