@aws-sdk/client-sts 3.186.0 → 3.186.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/dist-cjs/protocols/Aws_query.js +2 -2
  2. package/dist-cjs/xml-parser.js +18 -0
  3. package/dist-es/protocols/Aws_query.js +1 -1
  4. package/dist-es/xml-parser.js +15 -0
  5. package/dist-types/ts3.4/STS.d.ts +626 -140
  6. package/dist-types/ts3.4/STSClient.d.ts +156 -151
  7. package/dist-types/ts3.4/commands/AssumeRoleCommand.d.ts +124 -32
  8. package/dist-types/ts3.4/commands/AssumeRoleWithSAMLCommand.d.ts +166 -36
  9. package/dist-types/ts3.4/commands/AssumeRoleWithWebIdentityCommand.d.ts +170 -39
  10. package/dist-types/ts3.4/commands/DecodeAuthorizationMessageCommand.d.ts +70 -39
  11. package/dist-types/ts3.4/commands/GetAccessKeyInfoCommand.d.ts +52 -35
  12. package/dist-types/ts3.4/commands/GetCallerIdentityCommand.d.ts +44 -36
  13. package/dist-types/ts3.4/commands/GetFederationTokenCommand.d.ts +120 -36
  14. package/dist-types/ts3.4/commands/GetSessionTokenCommand.d.ts +93 -35
  15. package/dist-types/ts3.4/commands/index.d.ts +8 -8
  16. package/dist-types/ts3.4/defaultRoleAssumers.d.ts +20 -22
  17. package/dist-types/ts3.4/defaultStsRoleAssumers.d.ts +35 -25
  18. package/dist-types/ts3.4/endpoints.d.ts +2 -2
  19. package/dist-types/ts3.4/index.d.ts +6 -6
  20. package/dist-types/ts3.4/models/STSServiceException.d.ts +10 -7
  21. package/dist-types/ts3.4/models/index.d.ts +1 -1
  22. package/dist-types/ts3.4/models/models_0.d.ts +1146 -238
  23. package/dist-types/ts3.4/protocols/Aws_query.d.ts +26 -101
  24. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +40 -67
  25. package/dist-types/ts3.4/runtimeConfig.d.ts +40 -65
  26. package/dist-types/ts3.4/runtimeConfig.native.d.ts +39 -68
  27. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +13 -10
  28. package/dist-types/ts3.4/xml-parser.d.ts +4 -0
  29. package/dist-types/xml-parser.d.ts +4 -0
  30. package/package.json +2 -2
@@ -1,151 +1,156 @@
1
- import {
2
- EndpointsInputConfig,
3
- EndpointsResolvedConfig,
4
- RegionInputConfig,
5
- RegionResolvedConfig,
6
- } from "@aws-sdk/config-resolver";
7
- import {
8
- HostHeaderInputConfig,
9
- HostHeaderResolvedConfig,
10
- } from "@aws-sdk/middleware-host-header";
11
- import {
12
- RetryInputConfig,
13
- RetryResolvedConfig,
14
- } from "@aws-sdk/middleware-retry";
15
- import {
16
- StsAuthInputConfig,
17
- StsAuthResolvedConfig,
18
- } from "@aws-sdk/middleware-sdk-sts";
19
- import {
20
- UserAgentInputConfig,
21
- UserAgentResolvedConfig,
22
- } from "@aws-sdk/middleware-user-agent";
23
- import { HttpHandler as __HttpHandler } from "@aws-sdk/protocol-http";
24
- import {
25
- Client as __Client,
26
- DefaultsMode,
27
- SmithyConfiguration as __SmithyConfiguration,
28
- SmithyResolvedConfiguration as __SmithyResolvedConfiguration,
29
- } from "@aws-sdk/smithy-client";
30
- import {
31
- BodyLengthCalculator as __BodyLengthCalculator,
32
- Credentials as __Credentials,
33
- Decoder as __Decoder,
34
- Encoder as __Encoder,
35
- HashConstructor as __HashConstructor,
36
- HttpHandlerOptions as __HttpHandlerOptions,
37
- Logger as __Logger,
38
- Provider as __Provider,
39
- Provider,
40
- RegionInfoProvider,
41
- StreamCollector as __StreamCollector,
42
- UrlParser as __UrlParser,
43
- UserAgent as __UserAgent,
44
- } from "@aws-sdk/types";
45
- import {
46
- AssumeRoleCommandInput,
47
- AssumeRoleCommandOutput,
48
- } from "./commands/AssumeRoleCommand";
49
- import {
50
- AssumeRoleWithSAMLCommandInput,
51
- AssumeRoleWithSAMLCommandOutput,
52
- } from "./commands/AssumeRoleWithSAMLCommand";
53
- import {
54
- AssumeRoleWithWebIdentityCommandInput,
55
- AssumeRoleWithWebIdentityCommandOutput,
56
- } from "./commands/AssumeRoleWithWebIdentityCommand";
57
- import {
58
- DecodeAuthorizationMessageCommandInput,
59
- DecodeAuthorizationMessageCommandOutput,
60
- } from "./commands/DecodeAuthorizationMessageCommand";
61
- import {
62
- GetAccessKeyInfoCommandInput,
63
- GetAccessKeyInfoCommandOutput,
64
- } from "./commands/GetAccessKeyInfoCommand";
65
- import {
66
- GetCallerIdentityCommandInput,
67
- GetCallerIdentityCommandOutput,
68
- } from "./commands/GetCallerIdentityCommand";
69
- import {
70
- GetFederationTokenCommandInput,
71
- GetFederationTokenCommandOutput,
72
- } from "./commands/GetFederationTokenCommand";
73
- import {
74
- GetSessionTokenCommandInput,
75
- GetSessionTokenCommandOutput,
76
- } from "./commands/GetSessionTokenCommand";
77
- export declare type ServiceInputTypes =
78
- | AssumeRoleCommandInput
79
- | AssumeRoleWithSAMLCommandInput
80
- | AssumeRoleWithWebIdentityCommandInput
81
- | DecodeAuthorizationMessageCommandInput
82
- | GetAccessKeyInfoCommandInput
83
- | GetCallerIdentityCommandInput
84
- | GetFederationTokenCommandInput
85
- | GetSessionTokenCommandInput;
86
- export declare type ServiceOutputTypes =
87
- | AssumeRoleCommandOutput
88
- | AssumeRoleWithSAMLCommandOutput
89
- | AssumeRoleWithWebIdentityCommandOutput
90
- | DecodeAuthorizationMessageCommandOutput
91
- | GetAccessKeyInfoCommandOutput
92
- | GetCallerIdentityCommandOutput
93
- | GetFederationTokenCommandOutput
94
- | GetSessionTokenCommandOutput;
95
- export interface ClientDefaults
96
- extends Partial<__SmithyResolvedConfiguration<__HttpHandlerOptions>> {
97
- requestHandler?: __HttpHandler;
98
- sha256?: __HashConstructor;
99
- urlParser?: __UrlParser;
100
- bodyLengthChecker?: __BodyLengthCalculator;
101
- streamCollector?: __StreamCollector;
102
- base64Decoder?: __Decoder;
103
- base64Encoder?: __Encoder;
104
- utf8Decoder?: __Decoder;
105
- utf8Encoder?: __Encoder;
106
- runtime?: string;
107
- disableHostPrefix?: boolean;
108
- maxAttempts?: number | __Provider<number>;
109
- retryMode?: string | __Provider<string>;
110
- logger?: __Logger;
111
- useDualstackEndpoint?: boolean | __Provider<boolean>;
112
- useFipsEndpoint?: boolean | __Provider<boolean>;
113
- serviceId?: string;
114
- region?: string | __Provider<string>;
115
- credentialDefaultProvider?: (input: any) => __Provider<__Credentials>;
116
- regionInfoProvider?: RegionInfoProvider;
117
- defaultUserAgentProvider?: Provider<__UserAgent>;
118
- defaultsMode?: DefaultsMode | Provider<DefaultsMode>;
119
- }
120
- declare type STSClientConfigType = Partial<
121
- __SmithyConfiguration<__HttpHandlerOptions>
122
- > &
123
- ClientDefaults &
124
- RegionInputConfig &
125
- EndpointsInputConfig &
126
- RetryInputConfig &
127
- HostHeaderInputConfig &
128
- StsAuthInputConfig &
129
- UserAgentInputConfig;
130
- export interface STSClientConfig extends STSClientConfigType {}
131
- declare type STSClientResolvedConfigType =
132
- __SmithyResolvedConfiguration<__HttpHandlerOptions> &
133
- Required<ClientDefaults> &
134
- RegionResolvedConfig &
135
- EndpointsResolvedConfig &
136
- RetryResolvedConfig &
137
- HostHeaderResolvedConfig &
138
- StsAuthResolvedConfig &
139
- UserAgentResolvedConfig;
140
- export interface STSClientResolvedConfig extends STSClientResolvedConfigType {}
141
- export declare class STSClient extends __Client<
142
- __HttpHandlerOptions,
143
- ServiceInputTypes,
144
- ServiceOutputTypes,
145
- STSClientResolvedConfig
146
- > {
147
- readonly config: STSClientResolvedConfig;
148
- constructor(configuration: STSClientConfig);
149
- destroy(): void;
150
- }
151
- export {};
1
+ import { EndpointsInputConfig, EndpointsResolvedConfig, RegionInputConfig, RegionResolvedConfig } from "@aws-sdk/config-resolver";
2
+ import { HostHeaderInputConfig, HostHeaderResolvedConfig } from "@aws-sdk/middleware-host-header";
3
+ import { RetryInputConfig, RetryResolvedConfig } from "@aws-sdk/middleware-retry";
4
+ import { StsAuthInputConfig, StsAuthResolvedConfig } from "@aws-sdk/middleware-sdk-sts";
5
+ import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
6
+ import { HttpHandler as __HttpHandler } from "@aws-sdk/protocol-http";
7
+ import { Client as __Client, DefaultsMode, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@aws-sdk/smithy-client";
8
+ import { BodyLengthCalculator as __BodyLengthCalculator, Credentials as __Credentials, Decoder as __Decoder, Encoder as __Encoder, HashConstructor as __HashConstructor, HttpHandlerOptions as __HttpHandlerOptions, Logger as __Logger, Provider as __Provider, Provider, RegionInfoProvider, StreamCollector as __StreamCollector, UrlParser as __UrlParser, UserAgent as __UserAgent } from "@aws-sdk/types";
9
+ import { AssumeRoleCommandInput, AssumeRoleCommandOutput } from "./commands/AssumeRoleCommand";
10
+ import { AssumeRoleWithSAMLCommandInput, AssumeRoleWithSAMLCommandOutput } from "./commands/AssumeRoleWithSAMLCommand";
11
+ import { AssumeRoleWithWebIdentityCommandInput, AssumeRoleWithWebIdentityCommandOutput } from "./commands/AssumeRoleWithWebIdentityCommand";
12
+ import { DecodeAuthorizationMessageCommandInput, DecodeAuthorizationMessageCommandOutput } from "./commands/DecodeAuthorizationMessageCommand";
13
+ import { GetAccessKeyInfoCommandInput, GetAccessKeyInfoCommandOutput } from "./commands/GetAccessKeyInfoCommand";
14
+ import { GetCallerIdentityCommandInput, GetCallerIdentityCommandOutput } from "./commands/GetCallerIdentityCommand";
15
+ import { GetFederationTokenCommandInput, GetFederationTokenCommandOutput } from "./commands/GetFederationTokenCommand";
16
+ import { GetSessionTokenCommandInput, GetSessionTokenCommandOutput } from "./commands/GetSessionTokenCommand";
17
+ export declare type ServiceInputTypes = AssumeRoleCommandInput | AssumeRoleWithSAMLCommandInput | AssumeRoleWithWebIdentityCommandInput | DecodeAuthorizationMessageCommandInput | GetAccessKeyInfoCommandInput | GetCallerIdentityCommandInput | GetFederationTokenCommandInput | GetSessionTokenCommandInput;
18
+ export declare type ServiceOutputTypes = AssumeRoleCommandOutput | AssumeRoleWithSAMLCommandOutput | AssumeRoleWithWebIdentityCommandOutput | DecodeAuthorizationMessageCommandOutput | GetAccessKeyInfoCommandOutput | GetCallerIdentityCommandOutput | GetFederationTokenCommandOutput | GetSessionTokenCommandOutput;
19
+ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__HttpHandlerOptions>> {
20
+ /**
21
+ * The HTTP handler to use. Fetch in browser and Https in Nodejs.
22
+ */
23
+ requestHandler?: __HttpHandler;
24
+ /**
25
+ * A constructor for a class implementing the {@link __Hash} interface
26
+ * that computes the SHA-256 HMAC or checksum of a string or binary buffer.
27
+ * @internal
28
+ */
29
+ sha256?: __HashConstructor;
30
+ /**
31
+ * The function that will be used to convert strings into HTTP endpoints.
32
+ * @internal
33
+ */
34
+ urlParser?: __UrlParser;
35
+ /**
36
+ * A function that can calculate the length of a request body.
37
+ * @internal
38
+ */
39
+ bodyLengthChecker?: __BodyLengthCalculator;
40
+ /**
41
+ * A function that converts a stream into an array of bytes.
42
+ * @internal
43
+ */
44
+ streamCollector?: __StreamCollector;
45
+ /**
46
+ * The function that will be used to convert a base64-encoded string to a byte array.
47
+ * @internal
48
+ */
49
+ base64Decoder?: __Decoder;
50
+ /**
51
+ * The function that will be used to convert binary data to a base64-encoded string.
52
+ * @internal
53
+ */
54
+ base64Encoder?: __Encoder;
55
+ /**
56
+ * The function that will be used to convert a UTF8-encoded string to a byte array.
57
+ * @internal
58
+ */
59
+ utf8Decoder?: __Decoder;
60
+ /**
61
+ * The function that will be used to convert binary data to a UTF-8 encoded string.
62
+ * @internal
63
+ */
64
+ utf8Encoder?: __Encoder;
65
+ /**
66
+ * The runtime environment.
67
+ * @internal
68
+ */
69
+ runtime?: string;
70
+ /**
71
+ * Disable dyanamically changing the endpoint of the client based on the hostPrefix
72
+ * trait of an operation.
73
+ */
74
+ disableHostPrefix?: boolean;
75
+ /**
76
+ * Value for how many times a request will be made at most in case of retry.
77
+ */
78
+ maxAttempts?: number | __Provider<number>;
79
+ /**
80
+ * Specifies which retry algorithm to use.
81
+ */
82
+ retryMode?: string | __Provider<string>;
83
+ /**
84
+ * Optional logger for logging debug/info/warn/error.
85
+ */
86
+ logger?: __Logger;
87
+ /**
88
+ * Enables IPv6/IPv4 dualstack endpoint.
89
+ */
90
+ useDualstackEndpoint?: boolean | __Provider<boolean>;
91
+ /**
92
+ * Enables FIPS compatible endpoints.
93
+ */
94
+ useFipsEndpoint?: boolean | __Provider<boolean>;
95
+ /**
96
+ * Unique service identifier.
97
+ * @internal
98
+ */
99
+ serviceId?: string;
100
+ /**
101
+ * The AWS region to which this client will send requests
102
+ */
103
+ region?: string | __Provider<string>;
104
+ /**
105
+ * Default credentials provider; Not available in browser runtime.
106
+ * @internal
107
+ */
108
+ credentialDefaultProvider?: (input: any) => __Provider<__Credentials>;
109
+ /**
110
+ * Fetch related hostname, signing name or signing region with given region.
111
+ * @internal
112
+ */
113
+ regionInfoProvider?: RegionInfoProvider;
114
+ /**
115
+ * The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header
116
+ * @internal
117
+ */
118
+ defaultUserAgentProvider?: Provider<__UserAgent>;
119
+ /**
120
+ * The {@link DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK.
121
+ */
122
+ defaultsMode?: DefaultsMode | Provider<DefaultsMode>;
123
+ }
124
+ declare type STSClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & RegionInputConfig & EndpointsInputConfig & RetryInputConfig & HostHeaderInputConfig & StsAuthInputConfig & UserAgentInputConfig;
125
+ /**
126
+ * The configuration interface of STSClient class constructor that set the region, credentials and other options.
127
+ */
128
+ export interface STSClientConfig extends STSClientConfigType {
129
+ }
130
+ declare type STSClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> & Required<ClientDefaults> & RegionResolvedConfig & EndpointsResolvedConfig & RetryResolvedConfig & HostHeaderResolvedConfig & StsAuthResolvedConfig & UserAgentResolvedConfig;
131
+ /**
132
+ * The resolved configuration interface of STSClient class. This is resolved and normalized from the {@link STSClientConfig | constructor configuration interface}.
133
+ */
134
+ export interface STSClientResolvedConfig extends STSClientResolvedConfigType {
135
+ }
136
+ /**
137
+ * <fullname>Security Token Service</fullname>
138
+ * <p>Security Token Service (STS) enables you to request temporary, limited-privilege
139
+ * credentials for Identity and Access Management (IAM) users or for users that you
140
+ * authenticate (federated users). This guide provides descriptions of the STS API. For
141
+ * more information about using this service, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html">Temporary Security Credentials</a>.</p>
142
+ */
143
+ export declare class STSClient extends __Client<__HttpHandlerOptions, ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig> {
144
+ /**
145
+ * The resolved configuration of STSClient class. This is resolved and normalized from the {@link STSClientConfig | constructor configuration interface}.
146
+ */
147
+ readonly config: STSClientResolvedConfig;
148
+ constructor(configuration: STSClientConfig);
149
+ /**
150
+ * Destroy underlying resources, like sockets. It's usually not necessary to do this.
151
+ * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
152
+ * Otherwise, sockets might stay open for quite a long time before the server terminates them.
153
+ */
154
+ destroy(): void;
155
+ }
156
+ export {};
@@ -1,32 +1,124 @@
1
- import { Command as $Command } from "@aws-sdk/smithy-client";
2
- import {
3
- Handler,
4
- HttpHandlerOptions as __HttpHandlerOptions,
5
- MetadataBearer as __MetadataBearer,
6
- MiddlewareStack,
7
- } from "@aws-sdk/types";
8
- import { AssumeRoleRequest, AssumeRoleResponse } from "../models/models_0";
9
- import {
10
- ServiceInputTypes,
11
- ServiceOutputTypes,
12
- STSClientResolvedConfig,
13
- } from "../STSClient";
14
- export interface AssumeRoleCommandInput extends AssumeRoleRequest {}
15
- export interface AssumeRoleCommandOutput
16
- extends AssumeRoleResponse,
17
- __MetadataBearer {}
18
- export declare class AssumeRoleCommand extends $Command<
19
- AssumeRoleCommandInput,
20
- AssumeRoleCommandOutput,
21
- STSClientResolvedConfig
22
- > {
23
- readonly input: AssumeRoleCommandInput;
24
- constructor(input: AssumeRoleCommandInput);
25
- resolveMiddleware(
26
- clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
27
- configuration: STSClientResolvedConfig,
28
- options?: __HttpHandlerOptions
29
- ): Handler<AssumeRoleCommandInput, AssumeRoleCommandOutput>;
30
- private serialize;
31
- private deserialize;
32
- }
1
+ import { Command as $Command } from "@aws-sdk/smithy-client";
2
+ import { Handler, HttpHandlerOptions as __HttpHandlerOptions, MetadataBearer as __MetadataBearer, MiddlewareStack } from "@aws-sdk/types";
3
+ import { AssumeRoleRequest, AssumeRoleResponse } from "../models/models_0";
4
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
5
+ export interface AssumeRoleCommandInput extends AssumeRoleRequest {
6
+ }
7
+ export interface AssumeRoleCommandOutput extends AssumeRoleResponse, __MetadataBearer {
8
+ }
9
+ /**
10
+ * <p>Returns a set of temporary security credentials that you can use to access Amazon Web Services
11
+ * resources that you might not normally have access to. These temporary credentials consist
12
+ * of an access key ID, a secret access key, and a security token. Typically, you use
13
+ * <code>AssumeRole</code> within your account or for cross-account access. For a
14
+ * comparison of <code>AssumeRole</code> with other API operations that produce temporary
15
+ * credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting Temporary Security
16
+ * Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing the
17
+ * Amazon Web Services STS API operations</a> in the <i>IAM User Guide</i>.</p>
18
+ * <p>
19
+ * <b>Permissions</b>
20
+ * </p>
21
+ * <p>The temporary security credentials created by <code>AssumeRole</code> can be used to
22
+ * make API calls to any Amazon Web Services service with the following exception: You cannot call the
23
+ * Amazon Web Services STS <code>GetFederationToken</code> or <code>GetSessionToken</code> API
24
+ * operations.</p>
25
+ * <p>(Optional) You can pass inline or managed <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">session policies</a> to
26
+ * this operation. You can pass a single JSON policy document to use as an inline session
27
+ * policy. You can also specify up to 10 managed policies to use as managed session policies.
28
+ * The plaintext that you use for both inline and managed session policies can't exceed 2,048
29
+ * characters. Passing policies to this operation returns new
30
+ * temporary credentials. The resulting session's permissions are the intersection of the
31
+ * role's identity-based policy and the session policies. You can use the role's temporary
32
+ * credentials in subsequent Amazon Web Services API calls to access resources in the account that owns
33
+ * the role. You cannot use session policies to grant more permissions than those allowed
34
+ * by the identity-based policy of the role that is being assumed. For more information, see
35
+ * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session
36
+ * Policies</a> in the <i>IAM User Guide</i>.</p>
37
+ * <p>When you create a role, you create two policies: A role trust policy that specifies
38
+ * <i>who</i> can assume the role and a permissions policy that specifies
39
+ * <i>what</i> can be done with the role. You specify the trusted principal
40
+ * who is allowed to assume the role in the role trust policy.</p>
41
+ * <p>To assume a role from a different account, your Amazon Web Services account must be trusted by the
42
+ * role. The trust relationship is defined in the role's trust policy when the role is
43
+ * created. That trust policy states which accounts are allowed to delegate that access to
44
+ * users in the account. </p>
45
+ * <p>A user who wants to access a role in a different account must also have permissions that
46
+ * are delegated from the user account administrator. The administrator must attach a policy
47
+ * that allows the user to call <code>AssumeRole</code> for the ARN of the role in the other
48
+ * account.</p>
49
+ * <p>To allow a user to assume a role in the same account, you can do either of the
50
+ * following:</p>
51
+ * <ul>
52
+ * <li>
53
+ * <p>Attach a policy to the user that allows the user to call <code>AssumeRole</code>
54
+ * (as long as the role's trust policy trusts the account).</p>
55
+ * </li>
56
+ * <li>
57
+ * <p>Add the user as a principal directly in the role's trust policy.</p>
58
+ * </li>
59
+ * </ul>
60
+ * <p>You can do either because the role’s trust policy acts as an IAM resource-based
61
+ * policy. When a resource-based policy grants access to a principal in the same account, no
62
+ * additional identity-based policy is required. For more information about trust policies and
63
+ * resource-based policies, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html">IAM Policies</a> in the
64
+ * <i>IAM User Guide</i>.</p>
65
+ *
66
+ * <p>
67
+ * <b>Tags</b>
68
+ * </p>
69
+ * <p>(Optional) You can pass tag key-value pairs to your session. These tags are called
70
+ * session tags. For more information about session tags, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html">Passing Session Tags in STS</a> in the
71
+ * <i>IAM User Guide</i>.</p>
72
+ * <p>An administrator must grant you the permissions necessary to pass session tags. The
73
+ * administrator can also create granular permissions to allow you to pass only specific
74
+ * session tags. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html">Tutorial: Using Tags
75
+ * for Attribute-Based Access Control</a> in the
76
+ * <i>IAM User Guide</i>.</p>
77
+ * <p>You can set the session tags as transitive. Transitive tags persist during role
78
+ * chaining. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining">Chaining Roles
79
+ * with Session Tags</a> in the <i>IAM User Guide</i>.</p>
80
+ * <p>
81
+ * <b>Using MFA with AssumeRole</b>
82
+ * </p>
83
+ * <p>(Optional) You can include multi-factor authentication (MFA) information when you call
84
+ * <code>AssumeRole</code>. This is useful for cross-account scenarios to ensure that the
85
+ * user that assumes the role has been authenticated with an Amazon Web Services MFA device. In that
86
+ * scenario, the trust policy of the role being assumed includes a condition that tests for
87
+ * MFA authentication. If the caller does not include valid MFA information, the request to
88
+ * assume the role is denied. The condition in a trust policy that tests for MFA
89
+ * authentication might look like the following example.</p>
90
+ * <p>
91
+ * <code>"Condition": {"Bool": {"aws:MultiFactorAuthPresent": true}}</code>
92
+ * </p>
93
+ * <p>For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html">Configuring MFA-Protected API Access</a>
94
+ * in the <i>IAM User Guide</i> guide.</p>
95
+ * <p>To use MFA with <code>AssumeRole</code>, you pass values for the
96
+ * <code>SerialNumber</code> and <code>TokenCode</code> parameters. The
97
+ * <code>SerialNumber</code> value identifies the user's hardware or virtual MFA device.
98
+ * The <code>TokenCode</code> is the time-based one-time password (TOTP) that the MFA device
99
+ * produces. </p>
100
+ * @example
101
+ * Use a bare-bones client and the command you need to make an API call.
102
+ * ```javascript
103
+ * import { STSClient, AssumeRoleCommand } from "@aws-sdk/client-sts"; // ES Modules import
104
+ * // const { STSClient, AssumeRoleCommand } = require("@aws-sdk/client-sts"); // CommonJS import
105
+ * const client = new STSClient(config);
106
+ * const command = new AssumeRoleCommand(input);
107
+ * const response = await client.send(command);
108
+ * ```
109
+ *
110
+ * @see {@link AssumeRoleCommandInput} for command's `input` shape.
111
+ * @see {@link AssumeRoleCommandOutput} for command's `response` shape.
112
+ * @see {@link STSClientResolvedConfig | config} for STSClient's `config` shape.
113
+ *
114
+ */
115
+ export declare class AssumeRoleCommand extends $Command<AssumeRoleCommandInput, AssumeRoleCommandOutput, STSClientResolvedConfig> {
116
+ readonly input: AssumeRoleCommandInput;
117
+ constructor(input: AssumeRoleCommandInput);
118
+ /**
119
+ * @internal
120
+ */
121
+ resolveMiddleware(clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, configuration: STSClientResolvedConfig, options?: __HttpHandlerOptions): Handler<AssumeRoleCommandInput, AssumeRoleCommandOutput>;
122
+ private serialize;
123
+ private deserialize;
124
+ }