aws_sdk_mpa/client/
get_session.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 [`GetSession`](crate::operation::get_session::builders::GetSessionFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`session_arn(impl Into<String>)`](crate::operation::get_session::builders::GetSessionFluentBuilder::session_arn) / [`set_session_arn(Option<String>)`](crate::operation::get_session::builders::GetSessionFluentBuilder::set_session_arn):<br>required: **true**<br><p>Amazon Resource Name (ARN) for the session.</p><br>
7    /// - On success, responds with [`GetSessionOutput`](crate::operation::get_session::GetSessionOutput) with field(s):
8    ///   - [`session_arn(Option<String>)`](crate::operation::get_session::GetSessionOutput::session_arn): <p>Amazon Resource Name (ARN) for the session.</p>
9    ///   - [`approval_team_arn(Option<String>)`](crate::operation::get_session::GetSessionOutput::approval_team_arn): <p>Amazon Resource Name (ARN) for the approval team.</p>
10    ///   - [`approval_team_name(Option<String>)`](crate::operation::get_session::GetSessionOutput::approval_team_name): <p>Name of the approval team.</p>
11    ///   - [`protected_resource_arn(Option<String>)`](crate::operation::get_session::GetSessionOutput::protected_resource_arn): <p>Amazon Resource Name (ARN) for the protected operation.</p>
12    ///   - [`approval_strategy(Option<ApprovalStrategyResponse>)`](crate::operation::get_session::GetSessionOutput::approval_strategy): <p>An <code>ApprovalStrategyResponse</code> object. Contains details for how the team grants approval</p>
13    ///   - [`number_of_approvers(Option<i32>)`](crate::operation::get_session::GetSessionOutput::number_of_approvers): <p>Total number of approvers in the session.</p>
14    ///   - [`initiation_time(Option<DateTime>)`](crate::operation::get_session::GetSessionOutput::initiation_time): <p>Timestamp when the session was initiated.</p>
15    ///   - [`expiration_time(Option<DateTime>)`](crate::operation::get_session::GetSessionOutput::expiration_time): <p>Timestamp when the session will expire.</p>
16    ///   - [`completion_time(Option<DateTime>)`](crate::operation::get_session::GetSessionOutput::completion_time): <p>Timestamp when the session completed.</p>
17    ///   - [`description(Option<String>)`](crate::operation::get_session::GetSessionOutput::description): <p>Description for the session.</p>
18    ///   - [`metadata(Option<HashMap::<String, String>>)`](crate::operation::get_session::GetSessionOutput::metadata): <p>Metadata for the session.</p>
19    ///   - [`status(Option<SessionStatus>)`](crate::operation::get_session::GetSessionOutput::status): <p>Status for the session. For example, if the team has approved the requested operation.</p>
20    ///   - [`status_code(Option<SessionStatusCode>)`](crate::operation::get_session::GetSessionOutput::status_code): <p>Status code of the session.</p>
21    ///   - [`status_message(Option<String>)`](crate::operation::get_session::GetSessionOutput::status_message): <p>Message describing the status for session.</p>
22    ///   - [`execution_status(Option<SessionExecutionStatus>)`](crate::operation::get_session::GetSessionOutput::execution_status): <p>Status for the protected operation. For example, if the operation is <code>PENDING</code>.</p>
23    ///   - [`action_name(Option<String>)`](crate::operation::get_session::GetSessionOutput::action_name): <p>Name of the protected operation.</p>
24    ///   - [`requester_service_principal(Option<String>)`](crate::operation::get_session::GetSessionOutput::requester_service_principal): <p><a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_principal.html#principal-services">Service principal</a> for the service associated with the protected operation.</p>
25    ///   - [`requester_principal_arn(Option<String>)`](crate::operation::get_session::GetSessionOutput::requester_principal_arn): <p><a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/intro-structure.html#intro-structure-request">IAM principal</a> that made the operation request.</p>
26    ///   - [`requester_account_id(Option<String>)`](crate::operation::get_session::GetSessionOutput::requester_account_id): <p>ID for the account that made the operation request.</p>
27    ///   - [`requester_region(Option<String>)`](crate::operation::get_session::GetSessionOutput::requester_region): <p>Amazon Web Services Region where the operation request originated.</p>
28    ///   - [`requester_comment(Option<String>)`](crate::operation::get_session::GetSessionOutput::requester_comment): <p>Message from the account that made the operation request</p>
29    ///   - [`action_completion_strategy(Option<ActionCompletionStrategy>)`](crate::operation::get_session::GetSessionOutput::action_completion_strategy): <p>Strategy for executing the protected operation. <code>AUTO_COMPLETION_UPON_APPROVAL</code> means the operation is automatically executed using the requester's permissions, if approved.</p>
30    ///   - [`approver_responses(Option<Vec::<GetSessionResponseApproverResponse>>)`](crate::operation::get_session::GetSessionOutput::approver_responses): <p>An array of <code>GetSessionResponseApproverResponse</code> objects. Contains details for approver responses in the session.</p>
31    /// - On failure, responds with [`SdkError<GetSessionError>`](crate::operation::get_session::GetSessionError)
32    pub fn get_session(&self) -> crate::operation::get_session::builders::GetSessionFluentBuilder {
33        crate::operation::get_session::builders::GetSessionFluentBuilder::new(self.handle.clone())
34    }
35}