/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { template class AmazonWebServiceResult; namespace Utils { namespace Xml { class XmlDocument; } // namespace Xml } // namespace Utils namespace STS { namespace Model { /** *

Contains the response to a successful GetFederationToken request, * including temporary Amazon Web Services credentials that can be used to make * Amazon Web Services requests.

See Also:

AWS * API Reference

*/ class GetFederationTokenResult { public: AWS_STS_API GetFederationTokenResult(); AWS_STS_API GetFederationTokenResult(const Aws::AmazonWebServiceResult& result); AWS_STS_API GetFederationTokenResult& operator=(const Aws::AmazonWebServiceResult& result); /** *

The temporary security credentials, which include an access key ID, a secret * access key, and a security (or session) token.

The size of the * security token that STS API operations return is not fixed. We strongly * recommend that you make no assumptions about the maximum size.

*/ inline const Credentials& GetCredentials() const{ return m_credentials; } /** *

The temporary security credentials, which include an access key ID, a secret * access key, and a security (or session) token.

The size of the * security token that STS API operations return is not fixed. We strongly * recommend that you make no assumptions about the maximum size.

*/ inline void SetCredentials(const Credentials& value) { m_credentials = value; } /** *

The temporary security credentials, which include an access key ID, a secret * access key, and a security (or session) token.

The size of the * security token that STS API operations return is not fixed. We strongly * recommend that you make no assumptions about the maximum size.

*/ inline void SetCredentials(Credentials&& value) { m_credentials = std::move(value); } /** *

The temporary security credentials, which include an access key ID, a secret * access key, and a security (or session) token.

The size of the * security token that STS API operations return is not fixed. We strongly * recommend that you make no assumptions about the maximum size.

*/ inline GetFederationTokenResult& WithCredentials(const Credentials& value) { SetCredentials(value); return *this;} /** *

The temporary security credentials, which include an access key ID, a secret * access key, and a security (or session) token.

The size of the * security token that STS API operations return is not fixed. We strongly * recommend that you make no assumptions about the maximum size.

*/ inline GetFederationTokenResult& WithCredentials(Credentials&& value) { SetCredentials(std::move(value)); return *this;} /** *

Identifiers for the federated user associated with the credentials (such as * arn:aws:sts::123456789012:federated-user/Bob or * 123456789012:Bob). You can use the federated user's ARN in your * resource-based policies, such as an Amazon S3 bucket policy.

*/ inline const FederatedUser& GetFederatedUser() const{ return m_federatedUser; } /** *

Identifiers for the federated user associated with the credentials (such as * arn:aws:sts::123456789012:federated-user/Bob or * 123456789012:Bob). You can use the federated user's ARN in your * resource-based policies, such as an Amazon S3 bucket policy.

*/ inline void SetFederatedUser(const FederatedUser& value) { m_federatedUser = value; } /** *

Identifiers for the federated user associated with the credentials (such as * arn:aws:sts::123456789012:federated-user/Bob or * 123456789012:Bob). You can use the federated user's ARN in your * resource-based policies, such as an Amazon S3 bucket policy.

*/ inline void SetFederatedUser(FederatedUser&& value) { m_federatedUser = std::move(value); } /** *

Identifiers for the federated user associated with the credentials (such as * arn:aws:sts::123456789012:federated-user/Bob or * 123456789012:Bob). You can use the federated user's ARN in your * resource-based policies, such as an Amazon S3 bucket policy.

*/ inline GetFederationTokenResult& WithFederatedUser(const FederatedUser& value) { SetFederatedUser(value); return *this;} /** *

Identifiers for the federated user associated with the credentials (such as * arn:aws:sts::123456789012:federated-user/Bob or * 123456789012:Bob). You can use the federated user's ARN in your * resource-based policies, such as an Amazon S3 bucket policy.

*/ inline GetFederationTokenResult& WithFederatedUser(FederatedUser&& value) { SetFederatedUser(std::move(value)); return *this;} /** *

A percentage value that indicates the packed size of the session policies and * session tags combined passed in the request. The request fails if the packed * size is greater than 100 percent, which means the policies and tags exceeded the * allowed space.

*/ inline int GetPackedPolicySize() const{ return m_packedPolicySize; } /** *

A percentage value that indicates the packed size of the session policies and * session tags combined passed in the request. The request fails if the packed * size is greater than 100 percent, which means the policies and tags exceeded the * allowed space.

*/ inline void SetPackedPolicySize(int value) { m_packedPolicySize = value; } /** *

A percentage value that indicates the packed size of the session policies and * session tags combined passed in the request. The request fails if the packed * size is greater than 100 percent, which means the policies and tags exceeded the * allowed space.

*/ inline GetFederationTokenResult& WithPackedPolicySize(int value) { SetPackedPolicySize(value); return *this;} inline const ResponseMetadata& GetResponseMetadata() const{ return m_responseMetadata; } inline void SetResponseMetadata(const ResponseMetadata& value) { m_responseMetadata = value; } inline void SetResponseMetadata(ResponseMetadata&& value) { m_responseMetadata = std::move(value); } inline GetFederationTokenResult& WithResponseMetadata(const ResponseMetadata& value) { SetResponseMetadata(value); return *this;} inline GetFederationTokenResult& WithResponseMetadata(ResponseMetadata&& value) { SetResponseMetadata(std::move(value)); return *this;} private: Credentials m_credentials; FederatedUser m_federatedUser; int m_packedPolicySize; ResponseMetadata m_responseMetadata; }; } // namespace Model } // namespace STS } // namespace Aws