@aws-sdk/client-sts 3.31.0 → 3.35.0

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 (211) hide show
  1. package/CHANGELOG.md +39 -0
  2. package/{dist/cjs → dist-cjs}/STS.js +1 -1
  3. package/dist-cjs/STS.js.map +1 -0
  4. package/{dist/cjs → dist-cjs}/STSClient.js +13 -13
  5. package/dist-cjs/STSClient.js.map +1 -0
  6. package/{dist/cjs → dist-cjs}/commands/AssumeRoleCommand.js +6 -6
  7. package/dist-cjs/commands/AssumeRoleCommand.js.map +1 -0
  8. package/{dist/cjs → dist-cjs}/commands/AssumeRoleWithSAMLCommand.js +5 -5
  9. package/dist-cjs/commands/AssumeRoleWithSAMLCommand.js.map +1 -0
  10. package/{dist/cjs → dist-cjs}/commands/AssumeRoleWithWebIdentityCommand.js +5 -5
  11. package/dist-cjs/commands/AssumeRoleWithWebIdentityCommand.js.map +1 -0
  12. package/{dist/cjs → dist-cjs}/commands/DecodeAuthorizationMessageCommand.js +6 -6
  13. package/dist-cjs/commands/DecodeAuthorizationMessageCommand.js.map +1 -0
  14. package/{dist/cjs → dist-cjs}/commands/GetAccessKeyInfoCommand.js +6 -6
  15. package/dist-cjs/commands/GetAccessKeyInfoCommand.js.map +1 -0
  16. package/{dist/cjs → dist-cjs}/commands/GetCallerIdentityCommand.js +6 -6
  17. package/dist-cjs/commands/GetCallerIdentityCommand.js.map +1 -0
  18. package/{dist/cjs → dist-cjs}/commands/GetFederationTokenCommand.js +6 -6
  19. package/dist-cjs/commands/GetFederationTokenCommand.js.map +1 -0
  20. package/{dist/cjs → dist-cjs}/commands/GetSessionTokenCommand.js +6 -6
  21. package/dist-cjs/commands/GetSessionTokenCommand.js.map +1 -0
  22. package/{dist/cjs → dist-cjs}/defaultRoleAssumers.js +4 -4
  23. package/dist-cjs/defaultRoleAssumers.js.map +1 -0
  24. package/{dist/cjs → dist-cjs}/defaultStsRoleAssumers.js +2 -2
  25. package/dist-cjs/defaultStsRoleAssumers.js.map +1 -0
  26. package/{dist/cjs → dist-cjs}/endpoints.js +1 -1
  27. package/dist-cjs/endpoints.js.map +1 -0
  28. package/dist-cjs/index.js +16 -0
  29. package/dist-cjs/index.js.map +1 -0
  30. package/{dist/cjs → dist-cjs}/models/index.js +1 -1
  31. package/{dist/cjs → dist-cjs}/models/index.js.map +1 -1
  32. package/{dist/cjs → dist-cjs}/models/models_0.js +0 -0
  33. package/dist-cjs/models/models_0.js.map +1 -0
  34. package/{dist/cjs → dist-cjs}/protocols/Aws_query.js +62 -62
  35. package/dist-cjs/protocols/Aws_query.js.map +1 -0
  36. package/{dist/cjs → dist-cjs}/runtimeConfig.browser.js +5 -4
  37. package/dist-cjs/runtimeConfig.browser.js.map +1 -0
  38. package/{dist/cjs → dist-cjs}/runtimeConfig.js +11 -10
  39. package/dist-cjs/runtimeConfig.js.map +1 -0
  40. package/{dist/cjs → dist-cjs}/runtimeConfig.native.js +1 -1
  41. package/dist-cjs/runtimeConfig.native.js.map +1 -0
  42. package/{dist/cjs → dist-cjs}/runtimeConfig.shared.js +1 -1
  43. package/dist-cjs/runtimeConfig.shared.js.map +1 -0
  44. package/{dist/es → dist-es}/STS.js +2 -9
  45. package/dist-es/STS.js.map +1 -0
  46. package/{dist/es → dist-es}/STSClient.js +2 -14
  47. package/dist-es/STSClient.js.map +1 -0
  48. package/dist-es/commands/AssumeRoleCommand.js +42 -0
  49. package/dist-es/commands/AssumeRoleCommand.js.map +1 -0
  50. package/dist-es/commands/AssumeRoleWithSAMLCommand.js +40 -0
  51. package/dist-es/commands/AssumeRoleWithSAMLCommand.js.map +1 -0
  52. package/dist-es/commands/AssumeRoleWithWebIdentityCommand.js +40 -0
  53. package/dist-es/commands/AssumeRoleWithWebIdentityCommand.js.map +1 -0
  54. package/dist-es/commands/DecodeAuthorizationMessageCommand.js +42 -0
  55. package/dist-es/commands/DecodeAuthorizationMessageCommand.js.map +1 -0
  56. package/dist-es/commands/GetAccessKeyInfoCommand.js +42 -0
  57. package/dist-es/commands/GetAccessKeyInfoCommand.js.map +1 -0
  58. package/{dist/es → dist-es}/commands/GetCallerIdentityCommand.js +4 -38
  59. package/dist-es/commands/GetCallerIdentityCommand.js.map +1 -0
  60. package/dist-es/commands/GetFederationTokenCommand.js +42 -0
  61. package/dist-es/commands/GetFederationTokenCommand.js.map +1 -0
  62. package/dist-es/commands/GetSessionTokenCommand.js +42 -0
  63. package/dist-es/commands/GetSessionTokenCommand.js.map +1 -0
  64. package/dist-es/defaultRoleAssumers.js +17 -0
  65. package/dist-es/defaultRoleAssumers.js.map +1 -0
  66. package/{dist/es → dist-es}/defaultStsRoleAssumers.js +10 -31
  67. package/dist-es/defaultStsRoleAssumers.js.map +1 -0
  68. package/{dist/es → dist-es}/endpoints.js +1 -1
  69. package/dist-es/endpoints.js.map +1 -0
  70. package/{dist/es → dist-es}/index.js +0 -0
  71. package/dist-es/index.js.map +1 -0
  72. package/{dist/es → dist-es}/models/index.js +0 -0
  73. package/dist-es/models/index.js.map +1 -0
  74. package/{dist/es → dist-es}/models/models_0.js +0 -87
  75. package/dist-es/models/models_0.js.map +1 -0
  76. package/{dist/es → dist-es}/protocols/Aws_query.js +152 -154
  77. package/dist-es/protocols/Aws_query.js.map +1 -0
  78. package/{dist/es → dist-es}/runtimeConfig.browser.js +1 -4
  79. package/dist-es/runtimeConfig.browser.js.map +1 -0
  80. package/{dist/es → dist-es}/runtimeConfig.js +3 -6
  81. package/dist-es/runtimeConfig.js.map +1 -0
  82. package/{dist/es → dist-es}/runtimeConfig.native.js +0 -3
  83. package/dist-es/runtimeConfig.native.js.map +1 -0
  84. package/{dist/es → dist-es}/runtimeConfig.shared.js +1 -4
  85. package/dist-es/runtimeConfig.shared.js.map +1 -0
  86. package/{dist/types → dist-types}/STS.d.ts +2 -2
  87. package/{dist/types → dist-types}/STSClient.d.ts +8 -8
  88. package/{dist/types → dist-types}/commands/AssumeRoleCommand.d.ts +3 -3
  89. package/{dist/types → dist-types}/commands/AssumeRoleWithSAMLCommand.d.ts +3 -3
  90. package/{dist/types → dist-types}/commands/AssumeRoleWithWebIdentityCommand.d.ts +3 -3
  91. package/{dist/types → dist-types}/commands/DecodeAuthorizationMessageCommand.d.ts +3 -3
  92. package/{dist/types → dist-types}/commands/GetAccessKeyInfoCommand.d.ts +3 -3
  93. package/{dist/types → dist-types}/commands/GetCallerIdentityCommand.d.ts +3 -3
  94. package/{dist/types → dist-types}/commands/GetFederationTokenCommand.d.ts +3 -3
  95. package/{dist/types → dist-types}/commands/GetSessionTokenCommand.d.ts +3 -3
  96. package/{dist/types → dist-types}/defaultRoleAssumers.d.ts +0 -0
  97. package/{dist/types → dist-types}/defaultStsRoleAssumers.d.ts +0 -0
  98. package/{dist/types → dist-types}/endpoints.d.ts +0 -0
  99. package/{dist/types → dist-types}/index.d.ts +0 -0
  100. package/{dist/types → dist-types}/models/index.d.ts +0 -0
  101. package/{dist/types → dist-types}/models/models_0.d.ts +0 -0
  102. package/{dist/types → dist-types}/protocols/Aws_query.d.ts +2 -2
  103. package/{dist/types → dist-types}/runtimeConfig.browser.d.ts +1 -0
  104. package/{dist/types/ts3.4 → dist-types}/runtimeConfig.d.ts +37 -36
  105. package/{dist/types/ts3.4 → dist-types}/runtimeConfig.native.d.ts +36 -35
  106. package/{dist/types → dist-types}/runtimeConfig.shared.d.ts +0 -0
  107. package/{dist/types → dist-types}/ts3.4/STS.d.ts +2 -2
  108. package/{dist/types → dist-types}/ts3.4/STSClient.d.ts +8 -8
  109. package/{dist/types → dist-types}/ts3.4/commands/AssumeRoleCommand.d.ts +3 -3
  110. package/{dist/types → dist-types}/ts3.4/commands/AssumeRoleWithSAMLCommand.d.ts +3 -3
  111. package/{dist/types → dist-types}/ts3.4/commands/AssumeRoleWithWebIdentityCommand.d.ts +3 -3
  112. package/{dist/types → dist-types}/ts3.4/commands/DecodeAuthorizationMessageCommand.d.ts +3 -3
  113. package/{dist/types → dist-types}/ts3.4/commands/GetAccessKeyInfoCommand.d.ts +3 -3
  114. package/{dist/types → dist-types}/ts3.4/commands/GetCallerIdentityCommand.d.ts +3 -3
  115. package/{dist/types → dist-types}/ts3.4/commands/GetFederationTokenCommand.d.ts +3 -3
  116. package/{dist/types → dist-types}/ts3.4/commands/GetSessionTokenCommand.d.ts +3 -3
  117. package/{dist/types → dist-types}/ts3.4/defaultRoleAssumers.d.ts +0 -0
  118. package/{dist/types → dist-types}/ts3.4/defaultStsRoleAssumers.d.ts +0 -0
  119. package/{dist/types → dist-types}/ts3.4/endpoints.d.ts +0 -0
  120. package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
  121. package/{dist/types → dist-types}/ts3.4/models/index.d.ts +0 -0
  122. package/{dist/types → dist-types}/ts3.4/models/models_0.d.ts +0 -0
  123. package/{dist/types → dist-types}/ts3.4/protocols/Aws_query.d.ts +2 -2
  124. package/{dist/types → dist-types}/ts3.4/runtimeConfig.browser.d.ts +1 -0
  125. package/{dist/types → dist-types/ts3.4}/runtimeConfig.d.ts +37 -36
  126. package/{dist/types → dist-types/ts3.4}/runtimeConfig.native.d.ts +36 -35
  127. package/{dist/types → dist-types}/ts3.4/runtimeConfig.shared.d.ts +0 -0
  128. package/package.json +50 -50
  129. package/{STS.ts → src/STS.ts} +3 -2
  130. package/{STSClient.ts → src/STSClient.ts} +30 -29
  131. package/{commands → src/commands}/AssumeRoleCommand.ts +5 -4
  132. package/{commands → src/commands}/AssumeRoleWithSAMLCommand.ts +8 -7
  133. package/{commands → src/commands}/AssumeRoleWithWebIdentityCommand.ts +8 -7
  134. package/{commands → src/commands}/DecodeAuthorizationMessageCommand.ts +8 -7
  135. package/{commands → src/commands}/GetAccessKeyInfoCommand.ts +8 -7
  136. package/{commands → src/commands}/GetCallerIdentityCommand.ts +8 -7
  137. package/{commands → src/commands}/GetFederationTokenCommand.ts +8 -7
  138. package/{commands → src/commands}/GetSessionTokenCommand.ts +8 -7
  139. package/{defaultRoleAssumers.ts → src/defaultRoleAssumers.ts} +0 -0
  140. package/{defaultStsRoleAssumers.ts → src/defaultStsRoleAssumers.ts} +0 -0
  141. package/{endpoints.ts → src/endpoints.ts} +1 -1
  142. package/{index.ts → src/index.ts} +0 -0
  143. package/{models → src/models}/index.ts +0 -0
  144. package/{models → src/models}/models_0.ts +0 -0
  145. package/{protocols → src/protocols}/Aws_query.ts +51 -50
  146. package/{runtimeConfig.browser.ts → src/runtimeConfig.browser.ts} +4 -3
  147. package/{runtimeConfig.native.ts → src/runtimeConfig.native.ts} +2 -1
  148. package/{runtimeConfig.shared.ts → src/runtimeConfig.shared.ts} +2 -1
  149. package/{runtimeConfig.ts → src/runtimeConfig.ts} +6 -5
  150. package/{defaultRoleAssumers.spec.ts → test/defaultRoleAssumers.spec.ts} +6 -5
  151. package/tsconfig.es.json +1 -3
  152. package/tsconfig.json +7 -7
  153. package/tsconfig.types.json +9 -0
  154. package/dist/cjs/STS.js.map +0 -1
  155. package/dist/cjs/STSClient.js.map +0 -1
  156. package/dist/cjs/commands/AssumeRoleCommand.js.map +0 -1
  157. package/dist/cjs/commands/AssumeRoleWithSAMLCommand.js.map +0 -1
  158. package/dist/cjs/commands/AssumeRoleWithWebIdentityCommand.js.map +0 -1
  159. package/dist/cjs/commands/DecodeAuthorizationMessageCommand.js.map +0 -1
  160. package/dist/cjs/commands/GetAccessKeyInfoCommand.js.map +0 -1
  161. package/dist/cjs/commands/GetCallerIdentityCommand.js.map +0 -1
  162. package/dist/cjs/commands/GetFederationTokenCommand.js.map +0 -1
  163. package/dist/cjs/commands/GetSessionTokenCommand.js.map +0 -1
  164. package/dist/cjs/defaultRoleAssumers.js.map +0 -1
  165. package/dist/cjs/defaultRoleAssumers.spec.js +0 -135
  166. package/dist/cjs/defaultRoleAssumers.spec.js.map +0 -1
  167. package/dist/cjs/defaultStsRoleAssumers.js.map +0 -1
  168. package/dist/cjs/endpoints.js.map +0 -1
  169. package/dist/cjs/index.js +0 -16
  170. package/dist/cjs/index.js.map +0 -1
  171. package/dist/cjs/models/models_0.js.map +0 -1
  172. package/dist/cjs/package.json +0 -93
  173. package/dist/cjs/protocols/Aws_query.js.map +0 -1
  174. package/dist/cjs/runtimeConfig.browser.js.map +0 -1
  175. package/dist/cjs/runtimeConfig.js.map +0 -1
  176. package/dist/cjs/runtimeConfig.native.js.map +0 -1
  177. package/dist/cjs/runtimeConfig.shared.js.map +0 -1
  178. package/dist/es/STS.js.map +0 -1
  179. package/dist/es/STSClient.js.map +0 -1
  180. package/dist/es/commands/AssumeRoleCommand.js +0 -150
  181. package/dist/es/commands/AssumeRoleCommand.js.map +0 -1
  182. package/dist/es/commands/AssumeRoleWithSAMLCommand.js +0 -196
  183. package/dist/es/commands/AssumeRoleWithSAMLCommand.js.map +0 -1
  184. package/dist/es/commands/AssumeRoleWithWebIdentityCommand.js +0 -200
  185. package/dist/es/commands/AssumeRoleWithWebIdentityCommand.js.map +0 -1
  186. package/dist/es/commands/DecodeAuthorizationMessageCommand.js +0 -102
  187. package/dist/es/commands/DecodeAuthorizationMessageCommand.js.map +0 -1
  188. package/dist/es/commands/GetAccessKeyInfoCommand.js +0 -84
  189. package/dist/es/commands/GetAccessKeyInfoCommand.js.map +0 -1
  190. package/dist/es/commands/GetCallerIdentityCommand.js.map +0 -1
  191. package/dist/es/commands/GetFederationTokenCommand.js +0 -205
  192. package/dist/es/commands/GetFederationTokenCommand.js.map +0 -1
  193. package/dist/es/commands/GetSessionTokenCommand.js +0 -118
  194. package/dist/es/commands/GetSessionTokenCommand.js.map +0 -1
  195. package/dist/es/defaultRoleAssumers.js +0 -33
  196. package/dist/es/defaultRoleAssumers.js.map +0 -1
  197. package/dist/es/defaultRoleAssumers.spec.js +0 -142
  198. package/dist/es/defaultRoleAssumers.spec.js.map +0 -1
  199. package/dist/es/defaultStsRoleAssumers.js.map +0 -1
  200. package/dist/es/endpoints.js.map +0 -1
  201. package/dist/es/index.js.map +0 -1
  202. package/dist/es/models/index.js.map +0 -1
  203. package/dist/es/models/models_0.js.map +0 -1
  204. package/dist/es/package.json +0 -93
  205. package/dist/es/protocols/Aws_query.js.map +0 -1
  206. package/dist/es/runtimeConfig.browser.js.map +0 -1
  207. package/dist/es/runtimeConfig.js.map +0 -1
  208. package/dist/es/runtimeConfig.native.js.map +0 -1
  209. package/dist/es/runtimeConfig.shared.js.map +0 -1
  210. package/dist/types/defaultRoleAssumers.spec.d.ts +0 -1
  211. package/dist/types/ts3.4/defaultRoleAssumers.spec.d.ts +0 -1
@@ -1,9 +1,3 @@
1
- import { STSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../STSClient";
2
- import { AssumeRoleWithWebIdentityRequest, AssumeRoleWithWebIdentityResponse } from "../models/models_0";
3
- import {
4
- deserializeAws_queryAssumeRoleWithWebIdentityCommand,
5
- serializeAws_queryAssumeRoleWithWebIdentityCommand,
6
- } from "../protocols/Aws_query";
7
1
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
8
2
  import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
9
3
  import { Command as $Command } from "@aws-sdk/smithy-client";
@@ -11,12 +5,19 @@ import {
11
5
  FinalizeHandlerArguments,
12
6
  Handler,
13
7
  HandlerExecutionContext,
14
- MiddlewareStack,
15
8
  HttpHandlerOptions as __HttpHandlerOptions,
16
9
  MetadataBearer as __MetadataBearer,
10
+ MiddlewareStack,
17
11
  SerdeContext as __SerdeContext,
18
12
  } from "@aws-sdk/types";
19
13
 
14
+ import { AssumeRoleWithWebIdentityRequest, AssumeRoleWithWebIdentityResponse } from "../models/models_0";
15
+ import {
16
+ deserializeAws_queryAssumeRoleWithWebIdentityCommand,
17
+ serializeAws_queryAssumeRoleWithWebIdentityCommand,
18
+ } from "../protocols/Aws_query";
19
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
20
+
20
21
  export interface AssumeRoleWithWebIdentityCommandInput extends AssumeRoleWithWebIdentityRequest {}
21
22
  export interface AssumeRoleWithWebIdentityCommandOutput extends AssumeRoleWithWebIdentityResponse, __MetadataBearer {}
22
23
 
@@ -1,9 +1,3 @@
1
- import { STSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../STSClient";
2
- import { DecodeAuthorizationMessageRequest, DecodeAuthorizationMessageResponse } from "../models/models_0";
3
- import {
4
- deserializeAws_queryDecodeAuthorizationMessageCommand,
5
- serializeAws_queryDecodeAuthorizationMessageCommand,
6
- } from "../protocols/Aws_query";
7
1
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
8
2
  import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
9
3
  import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
@@ -12,12 +6,19 @@ import {
12
6
  FinalizeHandlerArguments,
13
7
  Handler,
14
8
  HandlerExecutionContext,
15
- MiddlewareStack,
16
9
  HttpHandlerOptions as __HttpHandlerOptions,
17
10
  MetadataBearer as __MetadataBearer,
11
+ MiddlewareStack,
18
12
  SerdeContext as __SerdeContext,
19
13
  } from "@aws-sdk/types";
20
14
 
15
+ import { DecodeAuthorizationMessageRequest, DecodeAuthorizationMessageResponse } from "../models/models_0";
16
+ import {
17
+ deserializeAws_queryDecodeAuthorizationMessageCommand,
18
+ serializeAws_queryDecodeAuthorizationMessageCommand,
19
+ } from "../protocols/Aws_query";
20
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
21
+
21
22
  export interface DecodeAuthorizationMessageCommandInput extends DecodeAuthorizationMessageRequest {}
22
23
  export interface DecodeAuthorizationMessageCommandOutput extends DecodeAuthorizationMessageResponse, __MetadataBearer {}
23
24
 
@@ -1,9 +1,3 @@
1
- import { STSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../STSClient";
2
- import { GetAccessKeyInfoRequest, GetAccessKeyInfoResponse } from "../models/models_0";
3
- import {
4
- deserializeAws_queryGetAccessKeyInfoCommand,
5
- serializeAws_queryGetAccessKeyInfoCommand,
6
- } from "../protocols/Aws_query";
7
1
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
8
2
  import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
9
3
  import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
@@ -12,12 +6,19 @@ import {
12
6
  FinalizeHandlerArguments,
13
7
  Handler,
14
8
  HandlerExecutionContext,
15
- MiddlewareStack,
16
9
  HttpHandlerOptions as __HttpHandlerOptions,
17
10
  MetadataBearer as __MetadataBearer,
11
+ MiddlewareStack,
18
12
  SerdeContext as __SerdeContext,
19
13
  } from "@aws-sdk/types";
20
14
 
15
+ import { GetAccessKeyInfoRequest, GetAccessKeyInfoResponse } from "../models/models_0";
16
+ import {
17
+ deserializeAws_queryGetAccessKeyInfoCommand,
18
+ serializeAws_queryGetAccessKeyInfoCommand,
19
+ } from "../protocols/Aws_query";
20
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
21
+
21
22
  export interface GetAccessKeyInfoCommandInput extends GetAccessKeyInfoRequest {}
22
23
  export interface GetAccessKeyInfoCommandOutput extends GetAccessKeyInfoResponse, __MetadataBearer {}
23
24
 
@@ -1,9 +1,3 @@
1
- import { STSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../STSClient";
2
- import { GetCallerIdentityRequest, GetCallerIdentityResponse } from "../models/models_0";
3
- import {
4
- deserializeAws_queryGetCallerIdentityCommand,
5
- serializeAws_queryGetCallerIdentityCommand,
6
- } from "../protocols/Aws_query";
7
1
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
8
2
  import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
9
3
  import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
@@ -12,12 +6,19 @@ import {
12
6
  FinalizeHandlerArguments,
13
7
  Handler,
14
8
  HandlerExecutionContext,
15
- MiddlewareStack,
16
9
  HttpHandlerOptions as __HttpHandlerOptions,
17
10
  MetadataBearer as __MetadataBearer,
11
+ MiddlewareStack,
18
12
  SerdeContext as __SerdeContext,
19
13
  } from "@aws-sdk/types";
20
14
 
15
+ import { GetCallerIdentityRequest, GetCallerIdentityResponse } from "../models/models_0";
16
+ import {
17
+ deserializeAws_queryGetCallerIdentityCommand,
18
+ serializeAws_queryGetCallerIdentityCommand,
19
+ } from "../protocols/Aws_query";
20
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
21
+
21
22
  export interface GetCallerIdentityCommandInput extends GetCallerIdentityRequest {}
22
23
  export interface GetCallerIdentityCommandOutput extends GetCallerIdentityResponse, __MetadataBearer {}
23
24
 
@@ -1,9 +1,3 @@
1
- import { STSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../STSClient";
2
- import { GetFederationTokenRequest, GetFederationTokenResponse } from "../models/models_0";
3
- import {
4
- deserializeAws_queryGetFederationTokenCommand,
5
- serializeAws_queryGetFederationTokenCommand,
6
- } from "../protocols/Aws_query";
7
1
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
8
2
  import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
9
3
  import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
@@ -12,12 +6,19 @@ import {
12
6
  FinalizeHandlerArguments,
13
7
  Handler,
14
8
  HandlerExecutionContext,
15
- MiddlewareStack,
16
9
  HttpHandlerOptions as __HttpHandlerOptions,
17
10
  MetadataBearer as __MetadataBearer,
11
+ MiddlewareStack,
18
12
  SerdeContext as __SerdeContext,
19
13
  } from "@aws-sdk/types";
20
14
 
15
+ import { GetFederationTokenRequest, GetFederationTokenResponse } from "../models/models_0";
16
+ import {
17
+ deserializeAws_queryGetFederationTokenCommand,
18
+ serializeAws_queryGetFederationTokenCommand,
19
+ } from "../protocols/Aws_query";
20
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
21
+
21
22
  export interface GetFederationTokenCommandInput extends GetFederationTokenRequest {}
22
23
  export interface GetFederationTokenCommandOutput extends GetFederationTokenResponse, __MetadataBearer {}
23
24
 
@@ -1,9 +1,3 @@
1
- import { STSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../STSClient";
2
- import { GetSessionTokenRequest, GetSessionTokenResponse } from "../models/models_0";
3
- import {
4
- deserializeAws_queryGetSessionTokenCommand,
5
- serializeAws_queryGetSessionTokenCommand,
6
- } from "../protocols/Aws_query";
7
1
  import { getSerdePlugin } from "@aws-sdk/middleware-serde";
8
2
  import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
9
3
  import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
@@ -12,12 +6,19 @@ import {
12
6
  FinalizeHandlerArguments,
13
7
  Handler,
14
8
  HandlerExecutionContext,
15
- MiddlewareStack,
16
9
  HttpHandlerOptions as __HttpHandlerOptions,
17
10
  MetadataBearer as __MetadataBearer,
11
+ MiddlewareStack,
18
12
  SerdeContext as __SerdeContext,
19
13
  } from "@aws-sdk/types";
20
14
 
15
+ import { GetSessionTokenRequest, GetSessionTokenResponse } from "../models/models_0";
16
+ import {
17
+ deserializeAws_queryGetSessionTokenCommand,
18
+ serializeAws_queryGetSessionTokenCommand,
19
+ } from "../protocols/Aws_query";
20
+ import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
21
+
21
22
  export interface GetSessionTokenCommandInput extends GetSessionTokenRequest {}
22
23
  export interface GetSessionTokenCommandOutput extends GetSessionTokenResponse, __MetadataBearer {}
23
24
 
@@ -1,4 +1,4 @@
1
- import { PartitionHash, RegionHash, getRegionInfo } from "@aws-sdk/config-resolver";
1
+ import { getRegionInfo, PartitionHash, RegionHash } from "@aws-sdk/config-resolver";
2
2
  import { RegionInfoProvider } from "@aws-sdk/types";
3
3
 
4
4
  const regionHash: RegionHash = {
File without changes
File without changes
File without changes
@@ -1,3 +1,23 @@
1
+ import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
2
+ import {
3
+ expectNonNull as __expectNonNull,
4
+ expectString as __expectString,
5
+ extendedEncodeURIComponent as __extendedEncodeURIComponent,
6
+ getValueFromTextNode as __getValueFromTextNode,
7
+ parseRfc3339DateTime as __parseRfc3339DateTime,
8
+ strictParseInt32 as __strictParseInt32,
9
+ } from "@aws-sdk/smithy-client";
10
+ import {
11
+ Endpoint as __Endpoint,
12
+ HeaderBag as __HeaderBag,
13
+ MetadataBearer as __MetadataBearer,
14
+ ResponseMetadata as __ResponseMetadata,
15
+ SerdeContext as __SerdeContext,
16
+ SmithyException as __SmithyException,
17
+ } from "@aws-sdk/types";
18
+ import { decodeHTML } from "entities";
19
+ import { parse as xmlParse } from "fast-xml-parser";
20
+
1
21
  import { AssumeRoleCommandInput, AssumeRoleCommandOutput } from "../commands/AssumeRoleCommand";
2
22
  import { AssumeRoleWithSAMLCommandInput, AssumeRoleWithSAMLCommandOutput } from "../commands/AssumeRoleWithSAMLCommand";
3
23
  import {
@@ -13,13 +33,13 @@ import { GetCallerIdentityCommandInput, GetCallerIdentityCommandOutput } from ".
13
33
  import { GetFederationTokenCommandInput, GetFederationTokenCommandOutput } from "../commands/GetFederationTokenCommand";
14
34
  import { GetSessionTokenCommandInput, GetSessionTokenCommandOutput } from "../commands/GetSessionTokenCommand";
15
35
  import {
36
+ AssumedRoleUser,
16
37
  AssumeRoleRequest,
17
38
  AssumeRoleResponse,
18
39
  AssumeRoleWithSAMLRequest,
19
40
  AssumeRoleWithSAMLResponse,
20
41
  AssumeRoleWithWebIdentityRequest,
21
42
  AssumeRoleWithWebIdentityResponse,
22
- AssumedRoleUser,
23
43
  Credentials,
24
44
  DecodeAuthorizationMessageRequest,
25
45
  DecodeAuthorizationMessageResponse,
@@ -43,25 +63,6 @@ import {
43
63
  RegionDisabledException,
44
64
  Tag,
45
65
  } from "../models/models_0";
46
- import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
47
- import {
48
- expectNonNull as __expectNonNull,
49
- expectString as __expectString,
50
- extendedEncodeURIComponent as __extendedEncodeURIComponent,
51
- getValueFromTextNode as __getValueFromTextNode,
52
- parseRfc3339DateTime as __parseRfc3339DateTime,
53
- strictParseInt32 as __strictParseInt32,
54
- } from "@aws-sdk/smithy-client";
55
- import {
56
- Endpoint as __Endpoint,
57
- HeaderBag as __HeaderBag,
58
- MetadataBearer as __MetadataBearer,
59
- ResponseMetadata as __ResponseMetadata,
60
- SerdeContext as __SerdeContext,
61
- SmithyException as __SmithyException,
62
- } from "@aws-sdk/types";
63
- import { decodeHTML } from "entities";
64
- import { parse as xmlParse } from "fast-xml-parser";
65
66
 
66
67
  export const serializeAws_queryAssumeRoleCommand = async (
67
68
  input: AssumeRoleCommandInput,
@@ -217,7 +218,7 @@ const deserializeAws_queryAssumeRoleCommandError = async (
217
218
  body: await parseBody(output.body, context),
218
219
  };
219
220
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
220
- let errorCode: string = "UnknownError";
221
+ let errorCode = "UnknownError";
221
222
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
222
223
  switch (errorCode) {
223
224
  case "ExpiredTokenException":
@@ -295,7 +296,7 @@ const deserializeAws_queryAssumeRoleWithSAMLCommandError = async (
295
296
  body: await parseBody(output.body, context),
296
297
  };
297
298
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
298
- let errorCode: string = "UnknownError";
299
+ let errorCode = "UnknownError";
299
300
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
300
301
  switch (errorCode) {
301
302
  case "ExpiredTokenException":
@@ -389,7 +390,7 @@ const deserializeAws_queryAssumeRoleWithWebIdentityCommandError = async (
389
390
  body: await parseBody(output.body, context),
390
391
  };
391
392
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
392
- let errorCode: string = "UnknownError";
393
+ let errorCode = "UnknownError";
393
394
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
394
395
  switch (errorCode) {
395
396
  case "ExpiredTokenException":
@@ -491,7 +492,7 @@ const deserializeAws_queryDecodeAuthorizationMessageCommandError = async (
491
492
  body: await parseBody(output.body, context),
492
493
  };
493
494
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
494
- let errorCode: string = "UnknownError";
495
+ let errorCode = "UnknownError";
495
496
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
496
497
  switch (errorCode) {
497
498
  case "InvalidAuthorizationMessageException":
@@ -545,7 +546,7 @@ const deserializeAws_queryGetAccessKeyInfoCommandError = async (
545
546
  body: await parseBody(output.body, context),
546
547
  };
547
548
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
548
- let errorCode: string = "UnknownError";
549
+ let errorCode = "UnknownError";
549
550
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
550
551
  switch (errorCode) {
551
552
  default:
@@ -591,7 +592,7 @@ const deserializeAws_queryGetCallerIdentityCommandError = async (
591
592
  body: await parseBody(output.body, context),
592
593
  };
593
594
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
594
- let errorCode: string = "UnknownError";
595
+ let errorCode = "UnknownError";
595
596
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
596
597
  switch (errorCode) {
597
598
  default:
@@ -637,7 +638,7 @@ const deserializeAws_queryGetFederationTokenCommandError = async (
637
638
  body: await parseBody(output.body, context),
638
639
  };
639
640
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
640
- let errorCode: string = "UnknownError";
641
+ let errorCode = "UnknownError";
641
642
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
642
643
  switch (errorCode) {
643
644
  case "MalformedPolicyDocumentException":
@@ -707,7 +708,7 @@ const deserializeAws_queryGetSessionTokenCommandError = async (
707
708
  body: await parseBody(output.body, context),
708
709
  };
709
710
  let response: __SmithyException & __MetadataBearer & { [key: string]: any };
710
- let errorCode: string = "UnknownError";
711
+ let errorCode = "UnknownError";
711
712
  errorCode = loadQueryErrorCode(output, parsedOutput.body);
712
713
  switch (errorCode) {
713
714
  case "RegionDisabledException":
@@ -1040,7 +1041,7 @@ const serializeAws_queryGetSessionTokenRequest = (input: GetSessionTokenRequest,
1040
1041
  const serializeAws_querypolicyDescriptorListType = (input: PolicyDescriptorType[], context: __SerdeContext): any => {
1041
1042
  const entries: any = {};
1042
1043
  let counter = 1;
1043
- for (let entry of input) {
1044
+ for (const entry of input) {
1044
1045
  if (entry === null) {
1045
1046
  continue;
1046
1047
  }
@@ -1075,7 +1076,7 @@ const serializeAws_queryTag = (input: Tag, context: __SerdeContext): any => {
1075
1076
  const serializeAws_querytagKeyListType = (input: string[], context: __SerdeContext): any => {
1076
1077
  const entries: any = {};
1077
1078
  let counter = 1;
1078
- for (let entry of input) {
1079
+ for (const entry of input) {
1079
1080
  if (entry === null) {
1080
1081
  continue;
1081
1082
  }
@@ -1088,7 +1089,7 @@ const serializeAws_querytagKeyListType = (input: string[], context: __SerdeConte
1088
1089
  const serializeAws_querytagListType = (input: Tag[], context: __SerdeContext): any => {
1089
1090
  const entries: any = {};
1090
1091
  let counter = 1;
1091
- for (let entry of input) {
1092
+ for (const entry of input) {
1092
1093
  if (entry === null) {
1093
1094
  continue;
1094
1095
  }
@@ -1102,7 +1103,7 @@ const serializeAws_querytagListType = (input: Tag[], context: __SerdeContext): a
1102
1103
  };
1103
1104
 
1104
1105
  const deserializeAws_queryAssumedRoleUser = (output: any, context: __SerdeContext): AssumedRoleUser => {
1105
- let contents: any = {
1106
+ const contents: any = {
1106
1107
  AssumedRoleId: undefined,
1107
1108
  Arn: undefined,
1108
1109
  };
@@ -1116,7 +1117,7 @@ const deserializeAws_queryAssumedRoleUser = (output: any, context: __SerdeContex
1116
1117
  };
1117
1118
 
1118
1119
  const deserializeAws_queryAssumeRoleResponse = (output: any, context: __SerdeContext): AssumeRoleResponse => {
1119
- let contents: any = {
1120
+ const contents: any = {
1120
1121
  Credentials: undefined,
1121
1122
  AssumedRoleUser: undefined,
1122
1123
  PackedPolicySize: undefined,
@@ -1141,7 +1142,7 @@ const deserializeAws_queryAssumeRoleWithSAMLResponse = (
1141
1142
  output: any,
1142
1143
  context: __SerdeContext
1143
1144
  ): AssumeRoleWithSAMLResponse => {
1144
- let contents: any = {
1145
+ const contents: any = {
1145
1146
  Credentials: undefined,
1146
1147
  AssumedRoleUser: undefined,
1147
1148
  PackedPolicySize: undefined,
@@ -1186,7 +1187,7 @@ const deserializeAws_queryAssumeRoleWithWebIdentityResponse = (
1186
1187
  output: any,
1187
1188
  context: __SerdeContext
1188
1189
  ): AssumeRoleWithWebIdentityResponse => {
1189
- let contents: any = {
1190
+ const contents: any = {
1190
1191
  Credentials: undefined,
1191
1192
  SubjectFromWebIdentityToken: undefined,
1192
1193
  AssumedRoleUser: undefined,
@@ -1220,7 +1221,7 @@ const deserializeAws_queryAssumeRoleWithWebIdentityResponse = (
1220
1221
  };
1221
1222
 
1222
1223
  const deserializeAws_queryCredentials = (output: any, context: __SerdeContext): Credentials => {
1223
- let contents: any = {
1224
+ const contents: any = {
1224
1225
  AccessKeyId: undefined,
1225
1226
  SecretAccessKey: undefined,
1226
1227
  SessionToken: undefined,
@@ -1245,7 +1246,7 @@ const deserializeAws_queryDecodeAuthorizationMessageResponse = (
1245
1246
  output: any,
1246
1247
  context: __SerdeContext
1247
1248
  ): DecodeAuthorizationMessageResponse => {
1248
- let contents: any = {
1249
+ const contents: any = {
1249
1250
  DecodedMessage: undefined,
1250
1251
  };
1251
1252
  if (output["DecodedMessage"] !== undefined) {
@@ -1255,7 +1256,7 @@ const deserializeAws_queryDecodeAuthorizationMessageResponse = (
1255
1256
  };
1256
1257
 
1257
1258
  const deserializeAws_queryExpiredTokenException = (output: any, context: __SerdeContext): ExpiredTokenException => {
1258
- let contents: any = {
1259
+ const contents: any = {
1259
1260
  message: undefined,
1260
1261
  };
1261
1262
  if (output["message"] !== undefined) {
@@ -1265,7 +1266,7 @@ const deserializeAws_queryExpiredTokenException = (output: any, context: __Serde
1265
1266
  };
1266
1267
 
1267
1268
  const deserializeAws_queryFederatedUser = (output: any, context: __SerdeContext): FederatedUser => {
1268
- let contents: any = {
1269
+ const contents: any = {
1269
1270
  FederatedUserId: undefined,
1270
1271
  Arn: undefined,
1271
1272
  };
@@ -1282,7 +1283,7 @@ const deserializeAws_queryGetAccessKeyInfoResponse = (
1282
1283
  output: any,
1283
1284
  context: __SerdeContext
1284
1285
  ): GetAccessKeyInfoResponse => {
1285
- let contents: any = {
1286
+ const contents: any = {
1286
1287
  Account: undefined,
1287
1288
  };
1288
1289
  if (output["Account"] !== undefined) {
@@ -1295,7 +1296,7 @@ const deserializeAws_queryGetCallerIdentityResponse = (
1295
1296
  output: any,
1296
1297
  context: __SerdeContext
1297
1298
  ): GetCallerIdentityResponse => {
1298
- let contents: any = {
1299
+ const contents: any = {
1299
1300
  UserId: undefined,
1300
1301
  Account: undefined,
1301
1302
  Arn: undefined,
@@ -1316,7 +1317,7 @@ const deserializeAws_queryGetFederationTokenResponse = (
1316
1317
  output: any,
1317
1318
  context: __SerdeContext
1318
1319
  ): GetFederationTokenResponse => {
1319
- let contents: any = {
1320
+ const contents: any = {
1320
1321
  Credentials: undefined,
1321
1322
  FederatedUser: undefined,
1322
1323
  PackedPolicySize: undefined,
@@ -1334,7 +1335,7 @@ const deserializeAws_queryGetFederationTokenResponse = (
1334
1335
  };
1335
1336
 
1336
1337
  const deserializeAws_queryGetSessionTokenResponse = (output: any, context: __SerdeContext): GetSessionTokenResponse => {
1337
- let contents: any = {
1338
+ const contents: any = {
1338
1339
  Credentials: undefined,
1339
1340
  };
1340
1341
  if (output["Credentials"] !== undefined) {
@@ -1347,7 +1348,7 @@ const deserializeAws_queryIDPCommunicationErrorException = (
1347
1348
  output: any,
1348
1349
  context: __SerdeContext
1349
1350
  ): IDPCommunicationErrorException => {
1350
- let contents: any = {
1351
+ const contents: any = {
1351
1352
  message: undefined,
1352
1353
  };
1353
1354
  if (output["message"] !== undefined) {
@@ -1360,7 +1361,7 @@ const deserializeAws_queryIDPRejectedClaimException = (
1360
1361
  output: any,
1361
1362
  context: __SerdeContext
1362
1363
  ): IDPRejectedClaimException => {
1363
- let contents: any = {
1364
+ const contents: any = {
1364
1365
  message: undefined,
1365
1366
  };
1366
1367
  if (output["message"] !== undefined) {
@@ -1373,7 +1374,7 @@ const deserializeAws_queryInvalidAuthorizationMessageException = (
1373
1374
  output: any,
1374
1375
  context: __SerdeContext
1375
1376
  ): InvalidAuthorizationMessageException => {
1376
- let contents: any = {
1377
+ const contents: any = {
1377
1378
  message: undefined,
1378
1379
  };
1379
1380
  if (output["message"] !== undefined) {
@@ -1386,7 +1387,7 @@ const deserializeAws_queryInvalidIdentityTokenException = (
1386
1387
  output: any,
1387
1388
  context: __SerdeContext
1388
1389
  ): InvalidIdentityTokenException => {
1389
- let contents: any = {
1390
+ const contents: any = {
1390
1391
  message: undefined,
1391
1392
  };
1392
1393
  if (output["message"] !== undefined) {
@@ -1399,7 +1400,7 @@ const deserializeAws_queryMalformedPolicyDocumentException = (
1399
1400
  output: any,
1400
1401
  context: __SerdeContext
1401
1402
  ): MalformedPolicyDocumentException => {
1402
- let contents: any = {
1403
+ const contents: any = {
1403
1404
  message: undefined,
1404
1405
  };
1405
1406
  if (output["message"] !== undefined) {
@@ -1412,7 +1413,7 @@ const deserializeAws_queryPackedPolicyTooLargeException = (
1412
1413
  output: any,
1413
1414
  context: __SerdeContext
1414
1415
  ): PackedPolicyTooLargeException => {
1415
- let contents: any = {
1416
+ const contents: any = {
1416
1417
  message: undefined,
1417
1418
  };
1418
1419
  if (output["message"] !== undefined) {
@@ -1422,7 +1423,7 @@ const deserializeAws_queryPackedPolicyTooLargeException = (
1422
1423
  };
1423
1424
 
1424
1425
  const deserializeAws_queryRegionDisabledException = (output: any, context: __SerdeContext): RegionDisabledException => {
1425
- let contents: any = {
1426
+ const contents: any = {
1426
1427
  message: undefined,
1427
1428
  };
1428
1429
  if (output["message"] !== undefined) {
@@ -1,5 +1,3 @@
1
- import packageInfo from "./package.json";
2
-
3
1
  import { Sha256 } from "@aws-crypto/sha256-browser";
4
2
  import { FetchHttpHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
5
3
  import { invalidProvider } from "@aws-sdk/invalid-dependency";
@@ -8,8 +6,11 @@ import { fromBase64, toBase64 } from "@aws-sdk/util-base64-browser";
8
6
  import { calculateBodyLength } from "@aws-sdk/util-body-length-browser";
9
7
  import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
10
8
  import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
11
- import { STSClientConfig } from "./STSClient";
9
+
10
+ // @ts-ignore: package.json will be imported from dist folders
11
+ import packageInfo from "../package.json";
12
12
  import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
13
+ import { STSClientConfig } from "./STSClient";
13
14
 
14
15
  /**
15
16
  * @internal
@@ -1,6 +1,7 @@
1
1
  import { Sha256 } from "@aws-crypto/sha256-js";
2
- import { STSClientConfig } from "./STSClient";
2
+
3
3
  import { getRuntimeConfig as getBrowserRuntimeConfig } from "./runtimeConfig.browser";
4
+ import { STSClientConfig } from "./STSClient";
4
5
 
5
6
  /**
6
7
  * @internal
@@ -1,6 +1,7 @@
1
- import { defaultRegionInfoProvider } from "./endpoints";
2
1
  import { Logger as __Logger } from "@aws-sdk/types";
3
2
  import { parseUrl } from "@aws-sdk/url-parser";
3
+
4
+ import { defaultRegionInfoProvider } from "./endpoints";
4
5
  import { STSClientConfig } from "./STSClient";
5
6
 
6
7
  /**
@@ -1,19 +1,20 @@
1
- import packageInfo from "./package.json";
2
-
3
- import { decorateDefaultCredentialProvider } from "./defaultStsRoleAssumers";
4
1
  import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS } from "@aws-sdk/config-resolver";
5
2
  import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
6
3
  import { Hash } from "@aws-sdk/hash-node";
7
4
  import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@aws-sdk/middleware-retry";
8
5
  import { loadConfig as loadNodeConfig } from "@aws-sdk/node-config-provider";
9
6
  import { NodeHttpHandler, streamCollector } from "@aws-sdk/node-http-handler";
7
+ import { emitWarningIfUnsupportedVersion } from "@aws-sdk/smithy-client";
10
8
  import { fromBase64, toBase64 } from "@aws-sdk/util-base64-node";
11
9
  import { calculateBodyLength } from "@aws-sdk/util-body-length-node";
12
10
  import { defaultUserAgent } from "@aws-sdk/util-user-agent-node";
13
11
  import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
14
- import { STSClientConfig } from "./STSClient";
12
+
13
+ // @ts-ignore: package.json will be imported from dist folders
14
+ import packageInfo from "../package.json";
15
+ import { decorateDefaultCredentialProvider } from "./defaultStsRoleAssumers";
15
16
  import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
16
- import { emitWarningIfUnsupportedVersion } from "@aws-sdk/smithy-client";
17
+ import { STSClientConfig } from "./STSClient";
17
18
 
18
19
  /**
19
20
  * @internal
@@ -17,16 +17,17 @@ jest.mock("@aws-sdk/node-http-handler", () => ({
17
17
  streamCollector: jest.fn(),
18
18
  }));
19
19
 
20
- import { getDefaultRoleAssumer, getDefaultRoleAssumerWithWebIdentity } from "./defaultRoleAssumers";
21
- import type { AssumeRoleCommandInput } from "./commands/AssumeRoleCommand";
22
20
  import { NodeHttpHandler, streamCollector } from "@aws-sdk/node-http-handler";
23
- import { AssumeRoleWithWebIdentityCommandInput } from "./commands/AssumeRoleWithWebIdentityCommand";
21
+
22
+ import type { AssumeRoleCommandInput } from "../src/commands/AssumeRoleCommand";
23
+ import { AssumeRoleWithWebIdentityCommandInput } from "../src/commands/AssumeRoleWithWebIdentityCommand";
24
+ import { getDefaultRoleAssumer, getDefaultRoleAssumerWithWebIdentity } from "../src/defaultRoleAssumers";
24
25
  const mockConstructorInput = jest.fn();
25
- jest.mock("./STSClient", () => ({
26
+ jest.mock("../src/STSClient", () => ({
26
27
  STSClient: function (params: any) {
27
28
  mockConstructorInput(params);
28
29
  //@ts-ignore
29
- return new (jest.requireActual("./STSClient").STSClient)(params);
30
+ return new (jest.requireActual("../src/STSClient").STSClient)(params);
30
31
  },
31
32
  }));
32
33
 
package/tsconfig.es.json CHANGED
@@ -4,9 +4,7 @@
4
4
  "target": "es5",
5
5
  "module": "esnext",
6
6
  "moduleResolution": "node",
7
- "declaration": false,
8
- "declarationDir": null,
9
7
  "lib": ["dom", "es5", "es2015.promise", "es2015.collection", "es2015.iterable", "es2015.symbol.wellknown"],
10
- "outDir": "dist/es"
8
+ "outDir": "dist-es"
11
9
  }
12
10
  }