@aws-sdk/client-dynamodb 3.37.0 → 3.41.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.
- package/CHANGELOG.md +42 -0
- package/README.md +18 -16
- package/dist-cjs/commands/index.js +53 -0
- package/dist-cjs/endpoints.js +154 -27
- package/dist-cjs/index.js +5 -60
- package/dist-cjs/pagination/index.js +9 -0
- package/dist-cjs/runtimeConfig.browser.js +6 -3
- package/dist-cjs/runtimeConfig.js +5 -3
- package/dist-cjs/waiters/index.js +5 -0
- package/dist-es/commands/index.js +50 -0
- package/dist-es/endpoints.js +154 -27
- package/dist-es/index.js +5 -60
- package/dist-es/pagination/index.js +6 -0
- package/dist-es/runtimeConfig.browser.js +3 -2
- package/dist-es/runtimeConfig.js +3 -3
- package/dist-es/waiters/index.js +2 -0
- package/dist-types/DynamoDB.d.ts +606 -567
- package/dist-types/DynamoDBClient.d.ts +24 -15
- package/dist-types/commands/BatchExecuteStatementCommand.d.ts +7 -4
- package/dist-types/commands/BatchGetItemCommand.d.ts +27 -26
- package/dist-types/commands/BatchWriteItemCommand.d.ts +51 -47
- package/dist-types/commands/CreateBackupCommand.d.ts +19 -19
- package/dist-types/commands/CreateGlobalTableCommand.d.ts +32 -43
- package/dist-types/commands/CreateTableCommand.d.ts +14 -14
- package/dist-types/commands/DeleteBackupCommand.d.ts +3 -2
- package/dist-types/commands/DeleteItemCommand.d.ts +12 -7
- package/dist-types/commands/DeleteTableCommand.d.ts +18 -16
- package/dist-types/commands/DescribeBackupCommand.d.ts +3 -2
- package/dist-types/commands/DescribeContinuousBackupsCommand.d.ts +12 -11
- package/dist-types/commands/DescribeContributorInsightsCommand.d.ts +3 -2
- package/dist-types/commands/DescribeEndpointsCommand.d.ts +1 -1
- package/dist-types/commands/DescribeExportCommand.d.ts +1 -1
- package/dist-types/commands/DescribeGlobalTableCommand.d.ts +6 -5
- package/dist-types/commands/DescribeGlobalTableSettingsCommand.d.ts +5 -4
- package/dist-types/commands/DescribeKinesisStreamingDestinationCommand.d.ts +1 -1
- package/dist-types/commands/DescribeLimitsCommand.d.ts +51 -41
- package/dist-types/commands/DescribeTableCommand.d.ts +11 -8
- package/dist-types/commands/DescribeTableReplicaAutoScalingCommand.d.ts +5 -4
- package/dist-types/commands/DescribeTimeToLiveCommand.d.ts +1 -1
- package/dist-types/commands/DisableKinesisStreamingDestinationCommand.d.ts +1 -1
- package/dist-types/commands/EnableKinesisStreamingDestinationCommand.d.ts +5 -5
- package/dist-types/commands/ExecuteStatementCommand.d.ts +3 -4
- package/dist-types/commands/ExecuteTransactionCommand.d.ts +9 -4
- package/dist-types/commands/ExportTableToPointInTimeCommand.d.ts +1 -1
- package/dist-types/commands/GetItemCommand.d.ts +9 -8
- package/dist-types/commands/ListBackupsCommand.d.ts +7 -7
- package/dist-types/commands/ListContributorInsightsCommand.d.ts +3 -2
- package/dist-types/commands/ListExportsCommand.d.ts +1 -1
- package/dist-types/commands/ListGlobalTablesCommand.d.ts +5 -4
- package/dist-types/commands/ListTablesCommand.d.ts +4 -4
- package/dist-types/commands/ListTagsOfResourceCommand.d.ts +5 -5
- package/dist-types/commands/PutItemCommand.d.ts +52 -45
- package/dist-types/commands/QueryCommand.d.ts +40 -44
- package/dist-types/commands/RestoreTableFromBackupCommand.d.ts +19 -19
- package/dist-types/commands/RestoreTableToPointInTimeCommand.d.ts +36 -41
- package/dist-types/commands/ScanCommand.d.ts +17 -16
- package/dist-types/commands/TagResourceCommand.d.ts +3 -4
- package/dist-types/commands/TransactGetItemsCommand.d.ts +12 -11
- package/dist-types/commands/TransactWriteItemsCommand.d.ts +49 -47
- package/dist-types/commands/UntagResourceCommand.d.ts +3 -4
- package/dist-types/commands/UpdateContinuousBackupsCommand.d.ts +10 -10
- package/dist-types/commands/UpdateContributorInsightsCommand.d.ts +7 -2
- package/dist-types/commands/UpdateGlobalTableCommand.d.ts +12 -17
- package/dist-types/commands/UpdateGlobalTableSettingsCommand.d.ts +1 -1
- package/dist-types/commands/UpdateItemCommand.d.ts +8 -4
- package/dist-types/commands/UpdateTableCommand.d.ts +15 -13
- package/dist-types/commands/UpdateTableReplicaAutoScalingCommand.d.ts +5 -4
- package/dist-types/commands/UpdateTimeToLiveCommand.d.ts +15 -15
- package/dist-types/commands/index.d.ts +50 -0
- package/dist-types/index.d.ts +5 -60
- package/dist-types/models/models_0.d.ts +3413 -2779
- package/dist-types/pagination/index.d.ts +6 -0
- package/dist-types/runtimeConfig.browser.d.ts +2 -0
- package/dist-types/runtimeConfig.d.ts +2 -0
- package/dist-types/runtimeConfig.native.d.ts +2 -0
- package/dist-types/ts3.4/DynamoDBClient.d.ts +4 -0
- package/dist-types/ts3.4/commands/index.d.ts +50 -0
- package/dist-types/ts3.4/index.d.ts +5 -60
- package/dist-types/ts3.4/pagination/index.d.ts +6 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +2 -0
- package/dist-types/ts3.4/waiters/index.d.ts +2 -0
- package/dist-types/waiters/index.d.ts +2 -0
- package/package.json +28 -28
package/dist-es/endpoints.js
CHANGED
|
@@ -1,37 +1,98 @@
|
|
|
1
1
|
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import { getRegionInfo } from "@aws-sdk/config-resolver";
|
|
3
3
|
var regionHash = {
|
|
4
|
-
"ca-central-1
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
"ca-central-1": {
|
|
5
|
+
variants: [
|
|
6
|
+
{
|
|
7
|
+
hostname: "dynamodb.ca-central-1.amazonaws.com",
|
|
8
|
+
tags: [],
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
hostname: "dynamodb-fips.ca-central-1.amazonaws.com",
|
|
12
|
+
tags: ["fips"],
|
|
13
|
+
},
|
|
14
|
+
],
|
|
7
15
|
},
|
|
8
16
|
local: {
|
|
9
|
-
|
|
17
|
+
variants: [
|
|
18
|
+
{
|
|
19
|
+
hostname: "localhost:8000",
|
|
20
|
+
tags: [],
|
|
21
|
+
},
|
|
22
|
+
],
|
|
10
23
|
signingRegion: "us-east-1",
|
|
11
24
|
},
|
|
12
|
-
"us-east-1
|
|
13
|
-
|
|
14
|
-
|
|
25
|
+
"us-east-1": {
|
|
26
|
+
variants: [
|
|
27
|
+
{
|
|
28
|
+
hostname: "dynamodb.us-east-1.amazonaws.com",
|
|
29
|
+
tags: [],
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
hostname: "dynamodb-fips.us-east-1.amazonaws.com",
|
|
33
|
+
tags: ["fips"],
|
|
34
|
+
},
|
|
35
|
+
],
|
|
15
36
|
},
|
|
16
|
-
"us-east-2
|
|
17
|
-
|
|
18
|
-
|
|
37
|
+
"us-east-2": {
|
|
38
|
+
variants: [
|
|
39
|
+
{
|
|
40
|
+
hostname: "dynamodb.us-east-2.amazonaws.com",
|
|
41
|
+
tags: [],
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
hostname: "dynamodb-fips.us-east-2.amazonaws.com",
|
|
45
|
+
tags: ["fips"],
|
|
46
|
+
},
|
|
47
|
+
],
|
|
19
48
|
},
|
|
20
|
-
"us-gov-east-1
|
|
21
|
-
|
|
22
|
-
|
|
49
|
+
"us-gov-east-1": {
|
|
50
|
+
variants: [
|
|
51
|
+
{
|
|
52
|
+
hostname: "dynamodb.us-gov-east-1.amazonaws.com",
|
|
53
|
+
tags: [],
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
hostname: "dynamodb.us-gov-east-1.amazonaws.com",
|
|
57
|
+
tags: ["fips"],
|
|
58
|
+
},
|
|
59
|
+
],
|
|
23
60
|
},
|
|
24
|
-
"us-gov-west-1
|
|
25
|
-
|
|
26
|
-
|
|
61
|
+
"us-gov-west-1": {
|
|
62
|
+
variants: [
|
|
63
|
+
{
|
|
64
|
+
hostname: "dynamodb.us-gov-west-1.amazonaws.com",
|
|
65
|
+
tags: [],
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
hostname: "dynamodb.us-gov-west-1.amazonaws.com",
|
|
69
|
+
tags: ["fips"],
|
|
70
|
+
},
|
|
71
|
+
],
|
|
27
72
|
},
|
|
28
|
-
"us-west-1
|
|
29
|
-
|
|
30
|
-
|
|
73
|
+
"us-west-1": {
|
|
74
|
+
variants: [
|
|
75
|
+
{
|
|
76
|
+
hostname: "dynamodb.us-west-1.amazonaws.com",
|
|
77
|
+
tags: [],
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
hostname: "dynamodb-fips.us-west-1.amazonaws.com",
|
|
81
|
+
tags: ["fips"],
|
|
82
|
+
},
|
|
83
|
+
],
|
|
31
84
|
},
|
|
32
|
-
"us-west-2
|
|
33
|
-
|
|
34
|
-
|
|
85
|
+
"us-west-2": {
|
|
86
|
+
variants: [
|
|
87
|
+
{
|
|
88
|
+
hostname: "dynamodb.us-west-2.amazonaws.com",
|
|
89
|
+
tags: [],
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
hostname: "dynamodb-fips.us-west-2.amazonaws.com",
|
|
93
|
+
tags: ["fips"],
|
|
94
|
+
},
|
|
95
|
+
],
|
|
35
96
|
},
|
|
36
97
|
};
|
|
37
98
|
var partitionHash = {
|
|
@@ -65,23 +126,89 @@ var partitionHash = {
|
|
|
65
126
|
"us-west-2",
|
|
66
127
|
"us-west-2-fips",
|
|
67
128
|
],
|
|
68
|
-
|
|
129
|
+
regionRegex: "^(us|eu|ap|sa|ca|me|af)\\-\\w+\\-\\d+$",
|
|
130
|
+
variants: [
|
|
131
|
+
{
|
|
132
|
+
hostname: "dynamodb.{region}.amazonaws.com",
|
|
133
|
+
tags: [],
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
hostname: "dynamodb-fips.{region}.amazonaws.com",
|
|
137
|
+
tags: ["fips"],
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
hostname: "dynamodb-fips.{region}.api.aws",
|
|
141
|
+
tags: ["dualstack", "fips"],
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
hostname: "dynamodb.{region}.api.aws",
|
|
145
|
+
tags: ["dualstack"],
|
|
146
|
+
},
|
|
147
|
+
],
|
|
69
148
|
},
|
|
70
149
|
"aws-cn": {
|
|
71
150
|
regions: ["cn-north-1", "cn-northwest-1"],
|
|
72
|
-
|
|
151
|
+
regionRegex: "^cn\\-\\w+\\-\\d+$",
|
|
152
|
+
variants: [
|
|
153
|
+
{
|
|
154
|
+
hostname: "dynamodb.{region}.amazonaws.com.cn",
|
|
155
|
+
tags: [],
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
hostname: "dynamodb-fips.{region}.amazonaws.com.cn",
|
|
159
|
+
tags: ["fips"],
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
hostname: "dynamodb-fips.{region}.api.amazonwebservices.com.cn",
|
|
163
|
+
tags: ["dualstack", "fips"],
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
hostname: "dynamodb.{region}.api.amazonwebservices.com.cn",
|
|
167
|
+
tags: ["dualstack"],
|
|
168
|
+
},
|
|
169
|
+
],
|
|
73
170
|
},
|
|
74
171
|
"aws-iso": {
|
|
75
172
|
regions: ["us-iso-east-1", "us-iso-west-1"],
|
|
76
|
-
|
|
173
|
+
regionRegex: "^us\\-iso\\-\\w+\\-\\d+$",
|
|
174
|
+
variants: [
|
|
175
|
+
{
|
|
176
|
+
hostname: "dynamodb.{region}.c2s.ic.gov",
|
|
177
|
+
tags: [],
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
hostname: "dynamodb-fips.{region}.c2s.ic.gov",
|
|
181
|
+
tags: ["fips"],
|
|
182
|
+
},
|
|
183
|
+
],
|
|
77
184
|
},
|
|
78
185
|
"aws-iso-b": {
|
|
79
186
|
regions: ["us-isob-east-1"],
|
|
80
|
-
|
|
187
|
+
regionRegex: "^us\\-isob\\-\\w+\\-\\d+$",
|
|
188
|
+
variants: [
|
|
189
|
+
{
|
|
190
|
+
hostname: "dynamodb.{region}.sc2s.sgov.gov",
|
|
191
|
+
tags: [],
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
hostname: "dynamodb-fips.{region}.sc2s.sgov.gov",
|
|
195
|
+
tags: ["fips"],
|
|
196
|
+
},
|
|
197
|
+
],
|
|
81
198
|
},
|
|
82
199
|
"aws-us-gov": {
|
|
83
200
|
regions: ["us-gov-east-1", "us-gov-east-1-fips", "us-gov-west-1", "us-gov-west-1-fips"],
|
|
84
|
-
|
|
201
|
+
regionRegex: "^us\\-gov\\-\\w+\\-\\d+$",
|
|
202
|
+
variants: [
|
|
203
|
+
{
|
|
204
|
+
hostname: "dynamodb.{region}.amazonaws.com",
|
|
205
|
+
tags: [],
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
hostname: "dynamodb.{region}.amazonaws.com",
|
|
209
|
+
tags: ["fips"],
|
|
210
|
+
},
|
|
211
|
+
],
|
|
85
212
|
},
|
|
86
213
|
};
|
|
87
214
|
export var defaultRegionInfoProvider = function (region, options) { return __awaiter(void 0, void 0, void 0, function () {
|
package/dist-es/index.js
CHANGED
|
@@ -1,61 +1,6 @@
|
|
|
1
|
-
export * from "./DynamoDBClient";
|
|
2
1
|
export * from "./DynamoDB";
|
|
3
|
-
export * from "./
|
|
4
|
-
export * from "./commands
|
|
5
|
-
export * from "./
|
|
6
|
-
export * from "./
|
|
7
|
-
export * from "./
|
|
8
|
-
export * from "./commands/CreateTableCommand";
|
|
9
|
-
export * from "./commands/DeleteBackupCommand";
|
|
10
|
-
export * from "./commands/DeleteItemCommand";
|
|
11
|
-
export * from "./commands/DeleteTableCommand";
|
|
12
|
-
export * from "./commands/DescribeBackupCommand";
|
|
13
|
-
export * from "./commands/DescribeContinuousBackupsCommand";
|
|
14
|
-
export * from "./commands/DescribeContributorInsightsCommand";
|
|
15
|
-
export * from "./commands/DescribeEndpointsCommand";
|
|
16
|
-
export * from "./commands/DescribeExportCommand";
|
|
17
|
-
export * from "./commands/DescribeGlobalTableCommand";
|
|
18
|
-
export * from "./commands/DescribeGlobalTableSettingsCommand";
|
|
19
|
-
export * from "./commands/DescribeKinesisStreamingDestinationCommand";
|
|
20
|
-
export * from "./commands/DescribeLimitsCommand";
|
|
21
|
-
export * from "./commands/DescribeTableCommand";
|
|
22
|
-
export * from "./waiters/waitForTableExists";
|
|
23
|
-
export * from "./waiters/waitForTableNotExists";
|
|
24
|
-
export * from "./commands/DescribeTableReplicaAutoScalingCommand";
|
|
25
|
-
export * from "./commands/DescribeTimeToLiveCommand";
|
|
26
|
-
export * from "./commands/DisableKinesisStreamingDestinationCommand";
|
|
27
|
-
export * from "./commands/EnableKinesisStreamingDestinationCommand";
|
|
28
|
-
export * from "./commands/ExecuteStatementCommand";
|
|
29
|
-
export * from "./commands/ExecuteTransactionCommand";
|
|
30
|
-
export * from "./commands/ExportTableToPointInTimeCommand";
|
|
31
|
-
export * from "./commands/GetItemCommand";
|
|
32
|
-
export * from "./commands/ListBackupsCommand";
|
|
33
|
-
export * from "./commands/ListContributorInsightsCommand";
|
|
34
|
-
export * from "./pagination/ListContributorInsightsPaginator";
|
|
35
|
-
export * from "./commands/ListExportsCommand";
|
|
36
|
-
export * from "./pagination/ListExportsPaginator";
|
|
37
|
-
export * from "./commands/ListGlobalTablesCommand";
|
|
38
|
-
export * from "./commands/ListTablesCommand";
|
|
39
|
-
export * from "./pagination/ListTablesPaginator";
|
|
40
|
-
export * from "./commands/ListTagsOfResourceCommand";
|
|
41
|
-
export * from "./commands/PutItemCommand";
|
|
42
|
-
export * from "./commands/QueryCommand";
|
|
43
|
-
export * from "./pagination/QueryPaginator";
|
|
44
|
-
export * from "./commands/RestoreTableFromBackupCommand";
|
|
45
|
-
export * from "./commands/RestoreTableToPointInTimeCommand";
|
|
46
|
-
export * from "./commands/ScanCommand";
|
|
47
|
-
export * from "./pagination/ScanPaginator";
|
|
48
|
-
export * from "./commands/TagResourceCommand";
|
|
49
|
-
export * from "./commands/TransactGetItemsCommand";
|
|
50
|
-
export * from "./commands/TransactWriteItemsCommand";
|
|
51
|
-
export * from "./commands/UntagResourceCommand";
|
|
52
|
-
export * from "./commands/UpdateContinuousBackupsCommand";
|
|
53
|
-
export * from "./commands/UpdateContributorInsightsCommand";
|
|
54
|
-
export * from "./commands/UpdateGlobalTableCommand";
|
|
55
|
-
export * from "./commands/UpdateGlobalTableSettingsCommand";
|
|
56
|
-
export * from "./commands/UpdateItemCommand";
|
|
57
|
-
export * from "./commands/UpdateTableCommand";
|
|
58
|
-
export * from "./commands/UpdateTableReplicaAutoScalingCommand";
|
|
59
|
-
export * from "./commands/UpdateTimeToLiveCommand";
|
|
60
|
-
export * from "./pagination/Interfaces";
|
|
61
|
-
export * from "./models/index";
|
|
2
|
+
export * from "./DynamoDBClient";
|
|
3
|
+
export * from "./commands";
|
|
4
|
+
export * from "./models";
|
|
5
|
+
export * from "./pagination";
|
|
6
|
+
export * from "./waiters";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { __assign } from "tslib";
|
|
2
2
|
import packageInfo from "../package.json";
|
|
3
3
|
import { Sha256 } from "@aws-crypto/sha256-browser";
|
|
4
|
+
import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
|
|
4
5
|
import { FetchHttpHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
|
|
5
6
|
import { invalidProvider } from "@aws-sdk/invalid-dependency";
|
|
6
7
|
import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/middleware-retry";
|
|
@@ -10,7 +11,7 @@ import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
|
|
|
10
11
|
import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
|
|
11
12
|
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
12
13
|
export var getRuntimeConfig = function (config) {
|
|
13
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
14
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
14
15
|
var clientSharedValues = getSharedRuntimeConfig(config);
|
|
15
|
-
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), endpointDiscoveryEnabledProvider: (_f = config === null || config === void 0 ? void 0 : config.endpointDiscoveryEnabledProvider) !== null && _f !== void 0 ? _f : (function () { return Promise.resolve(undefined); }), maxAttempts: (_g = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _g !== void 0 ? _g : DEFAULT_MAX_ATTEMPTS, region: (_h = config === null || config === void 0 ? void 0 : config.region) !== null && _h !== void 0 ? _h : invalidProvider("Region is missing"), requestHandler: (_j = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _j !== void 0 ? _j : new FetchHttpHandler(), retryMode: (_k = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _k !== void 0 ? _k : (function () { return Promise.resolve(DEFAULT_RETRY_MODE); }), sha256: (_l = config === null || config === void 0 ? void 0 : config.sha256) !== null && _l !== void 0 ? _l : Sha256, streamCollector: (_m = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _m !== void 0 ? _m : streamCollector,
|
|
16
|
+
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), endpointDiscoveryEnabledProvider: (_f = config === null || config === void 0 ? void 0 : config.endpointDiscoveryEnabledProvider) !== null && _f !== void 0 ? _f : (function () { return Promise.resolve(undefined); }), maxAttempts: (_g = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _g !== void 0 ? _g : DEFAULT_MAX_ATTEMPTS, region: (_h = config === null || config === void 0 ? void 0 : config.region) !== null && _h !== void 0 ? _h : invalidProvider("Region is missing"), requestHandler: (_j = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _j !== void 0 ? _j : new FetchHttpHandler(), retryMode: (_k = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _k !== void 0 ? _k : (function () { return Promise.resolve(DEFAULT_RETRY_MODE); }), sha256: (_l = config === null || config === void 0 ? void 0 : config.sha256) !== null && _l !== void 0 ? _l : Sha256, streamCollector: (_m = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _m !== void 0 ? _m : streamCollector, useDualstackEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _o !== void 0 ? _o : (function () { return Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT); }), useFipsEndpoint: (_p = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _p !== void 0 ? _p : (function () { return Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT); }), utf8Decoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _q !== void 0 ? _q : fromUtf8, utf8Encoder: (_r = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _r !== void 0 ? _r : toUtf8 });
|
|
16
17
|
};
|
package/dist-es/runtimeConfig.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { __assign } from "tslib";
|
|
2
2
|
import packageInfo from "../package.json";
|
|
3
3
|
import { decorateDefaultCredentialProvider } from "@aws-sdk/client-sts";
|
|
4
|
-
import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS } from "@aws-sdk/config-resolver";
|
|
4
|
+
import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, } from "@aws-sdk/config-resolver";
|
|
5
5
|
import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
|
|
6
6
|
import { Hash } from "@aws-sdk/hash-node";
|
|
7
7
|
import { NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS } from "@aws-sdk/middleware-endpoint-discovery";
|
|
@@ -15,8 +15,8 @@ import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
|
|
|
15
15
|
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
16
16
|
import { emitWarningIfUnsupportedVersion } from "@aws-sdk/smithy-client";
|
|
17
17
|
export var getRuntimeConfig = function (config) {
|
|
18
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
18
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
19
19
|
emitWarningIfUnsupportedVersion(process.version);
|
|
20
20
|
var clientSharedValues = getSharedRuntimeConfig(config);
|
|
21
|
-
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), endpointDiscoveryEnabledProvider: (_f = config === null || config === void 0 ? void 0 : config.endpointDiscoveryEnabledProvider) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS), maxAttempts: (_g = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_h = config === null || config === void 0 ? void 0 : config.region) !== null && _h !== void 0 ? _h : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_j = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _j !== void 0 ? _j : new NodeHttpHandler(), retryMode: (_k = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _k !== void 0 ? _k : loadNodeConfig(NODE_RETRY_MODE_CONFIG_OPTIONS), sha256: (_l = config === null || config === void 0 ? void 0 : config.sha256) !== null && _l !== void 0 ? _l : Hash.bind(null, "sha256"), streamCollector: (_m = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _m !== void 0 ? _m : streamCollector,
|
|
21
|
+
return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), endpointDiscoveryEnabledProvider: (_f = config === null || config === void 0 ? void 0 : config.endpointDiscoveryEnabledProvider) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_ENDPOINT_DISCOVERY_CONFIG_OPTIONS), maxAttempts: (_g = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_h = config === null || config === void 0 ? void 0 : config.region) !== null && _h !== void 0 ? _h : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_j = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _j !== void 0 ? _j : new NodeHttpHandler(), retryMode: (_k = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _k !== void 0 ? _k : loadNodeConfig(NODE_RETRY_MODE_CONFIG_OPTIONS), sha256: (_l = config === null || config === void 0 ? void 0 : config.sha256) !== null && _l !== void 0 ? _l : Hash.bind(null, "sha256"), streamCollector: (_m = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _m !== void 0 ? _m : streamCollector, useDualstackEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _o !== void 0 ? _o : loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS), useFipsEndpoint: (_p = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _p !== void 0 ? _p : loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS), utf8Decoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _q !== void 0 ? _q : fromUtf8, utf8Encoder: (_r = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _r !== void 0 ? _r : toUtf8 });
|
|
22
22
|
};
|