aws_sdk_s3control/client/get_data_access.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 [`GetDataAccess`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder) operation.
4 ///
5 /// - The fluent builder is configurable:
6 /// - [`account_id(impl Into<String>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::account_id) / [`set_account_id(Option<String>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::set_account_id):<br>required: **true**<br><p>The Amazon Web Services account ID of the S3 Access Grants instance.</p><br>
7 /// - [`target(impl Into<String>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::target) / [`set_target(Option<String>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::set_target):<br>required: **true**<br><p>The S3 URI path of the data to which you are requesting temporary access credentials. If the requesting account has an access grant for this data, S3 Access Grants vends temporary access credentials in the response.</p><br>
8 /// - [`permission(Permission)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::permission) / [`set_permission(Option<Permission>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::set_permission):<br>required: **true**<br><p>The type of permission granted to your S3 data, which can be set to one of the following values:</p> <ul> <li> <p><code>READ</code> – Grant read-only access to the S3 data.</p></li> <li> <p><code>WRITE</code> – Grant write-only access to the S3 data.</p></li> <li> <p><code>READWRITE</code> – Grant both read and write access to the S3 data.</p></li> </ul><br>
9 /// - [`duration_seconds(i32)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::duration_seconds) / [`set_duration_seconds(Option<i32>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::set_duration_seconds):<br>required: **false**<br><p>The session duration, in seconds, of the temporary access credential that S3 Access Grants vends to the grantee or client application. The default value is 1 hour, but the grantee can specify a range from 900 seconds (15 minutes) up to 43200 seconds (12 hours). If the grantee requests a value higher than this maximum, the operation fails.</p><br>
10 /// - [`privilege(Privilege)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::privilege) / [`set_privilege(Option<Privilege>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::set_privilege):<br>required: **false**<br><p>The scope of the temporary access credential that S3 Access Grants vends to the grantee or client application.</p> <ul> <li> <p><code>Default</code> – The scope of the returned temporary access token is the scope of the grant that is closest to the target scope.</p></li> <li> <p><code>Minimal</code> – The scope of the returned temporary access token is the same as the requested target scope as long as the requested scope is the same as or a subset of the grant scope.</p></li> </ul><br>
11 /// - [`target_type(S3PrefixType)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::target_type) / [`set_target_type(Option<S3PrefixType>)`](crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::set_target_type):<br>required: **false**<br><p>The type of <code>Target</code>. The only possible value is <code>Object</code>. Pass this value if the target data that you would like to access is a path to an object. Do not pass this value if the target data is a bucket or a bucket and a prefix.</p><br>
12 /// - On success, responds with [`GetDataAccessOutput`](crate::operation::get_data_access::GetDataAccessOutput) with field(s):
13 /// - [`credentials(Option<Credentials>)`](crate::operation::get_data_access::GetDataAccessOutput::credentials): <p>The temporary credential token that S3 Access Grants vends.</p>
14 /// - [`matched_grant_target(Option<String>)`](crate::operation::get_data_access::GetDataAccessOutput::matched_grant_target): <p>The S3 URI path of the data to which you are being granted temporary access credentials.</p>
15 /// - [`grantee(Option<Grantee>)`](crate::operation::get_data_access::GetDataAccessOutput::grantee): <p>The user, group, or role that was granted access to the S3 location scope. For directory identities, this API also returns the grants of the IAM role used for the identity-aware request. For more information on identity-aware sessions, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_sts-setcontext.html">Granting permissions to use identity-aware console sessions</a>.</p>
16 /// - On failure, responds with [`SdkError<GetDataAccessError>`](crate::operation::get_data_access::GetDataAccessError)
17 pub fn get_data_access(&self) -> crate::operation::get_data_access::builders::GetDataAccessFluentBuilder {
18 crate::operation::get_data_access::builders::GetDataAccessFluentBuilder::new(self.handle.clone())
19 }
20}