aws_sdk_sso/client/
get_role_credentials.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 [`GetRoleCredentials`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder) operation.
4                            ///
5                            /// - The fluent builder is configurable:
6    ///   - [`role_name(impl Into<String>)`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::role_name) / [`set_role_name(Option<String>)`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::set_role_name):<br>required: **true**<br><p>The friendly name of the role that is assigned to the user.</p><br>
7    ///   - [`account_id(impl Into<String>)`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::account_id) / [`set_account_id(Option<String>)`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::set_account_id):<br>required: **true**<br><p>The identifier for the AWS account that is assigned to the user.</p><br>
8    ///   - [`access_token(impl Into<String>)`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::access_token) / [`set_access_token(Option<String>)`](crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::set_access_token):<br>required: **true**<br><p>The token issued by the <code>CreateToken</code> API call. For more information, see <a href="https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html">CreateToken</a> in the <i>IAM Identity Center OIDC API Reference Guide</i>.</p><br>
9                            /// - On success, responds with [`GetRoleCredentialsOutput`](crate::operation::get_role_credentials::GetRoleCredentialsOutput) with field(s):
10    ///   - [`role_credentials(Option<RoleCredentials>)`](crate::operation::get_role_credentials::GetRoleCredentialsOutput::role_credentials): <p>The credentials for the role that is assigned to the user.</p>
11                            /// - On failure, responds with [`SdkError<GetRoleCredentialsError>`](crate::operation::get_role_credentials::GetRoleCredentialsError)
12    pub fn get_role_credentials(&self) -> crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder {
13                                crate::operation::get_role_credentials::builders::GetRoleCredentialsFluentBuilder::new(self.handle.clone())
14                            }
15}
16