@aws-sdk/client-sagemaker-a2i-runtime 3.141.0 → 3.146.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 +30 -0
- package/dist-cjs/protocols/Aws_restJson1.js +82 -128
- package/dist-es/protocols/Aws_restJson1.js +100 -124
- package/package.json +11 -6
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,36 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [3.146.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.145.0...v3.146.0) (2022-08-09)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* **client-sagemaker-a2i-runtime:** Fix bug with parsing ISO-8601 CreationTime in Java SDK in DescribeHumanLoop ([d2380d7](https://github.com/aws/aws-sdk-js-v3/commit/d2380d70e1b23d94b77415b373a433487ffb9e95))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [3.145.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.144.0...v3.145.0) (2022-08-08)
|
|
18
|
+
|
|
19
|
+
**Note:** Version bump only for package @aws-sdk/client-sagemaker-a2i-runtime
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
# [3.142.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.141.0...v3.142.0) (2022-08-02)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
### Features
|
|
29
|
+
|
|
30
|
+
* **codegen:** general data mapping function ([#3830](https://github.com/aws/aws-sdk-js-v3/issues/3830)) ([9417eae](https://github.com/aws/aws-sdk-js-v3/commit/9417eae722806799fb4c15c07921574268c1165c))
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
6
36
|
# [3.141.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.140.0...v3.141.0) (2022-08-01)
|
|
7
37
|
|
|
8
38
|
|
|
@@ -9,16 +9,7 @@ const serializeAws_restJson1DeleteHumanLoopCommand = async (input, context) => {
|
|
|
9
9
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
10
10
|
const headers = {};
|
|
11
11
|
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/human-loops/{HumanLoopName}";
|
|
12
|
-
|
|
13
|
-
const labelValue = input.HumanLoopName;
|
|
14
|
-
if (labelValue.length <= 0) {
|
|
15
|
-
throw new Error("Empty value provided for input HTTP label: HumanLoopName.");
|
|
16
|
-
}
|
|
17
|
-
resolvedPath = resolvedPath.replace("{HumanLoopName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
|
|
18
|
-
}
|
|
19
|
-
else {
|
|
20
|
-
throw new Error("No value provided for input HTTP label: HumanLoopName.");
|
|
21
|
-
}
|
|
12
|
+
resolvedPath = (0, smithy_client_1.resolvedPath)(resolvedPath, input, "HumanLoopName", () => input.HumanLoopName, "{HumanLoopName}", false);
|
|
22
13
|
let body;
|
|
23
14
|
return new protocol_http_1.HttpRequest({
|
|
24
15
|
protocol,
|
|
@@ -35,16 +26,7 @@ const serializeAws_restJson1DescribeHumanLoopCommand = async (input, context) =>
|
|
|
35
26
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
36
27
|
const headers = {};
|
|
37
28
|
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/human-loops/{HumanLoopName}";
|
|
38
|
-
|
|
39
|
-
const labelValue = input.HumanLoopName;
|
|
40
|
-
if (labelValue.length <= 0) {
|
|
41
|
-
throw new Error("Empty value provided for input HTTP label: HumanLoopName.");
|
|
42
|
-
}
|
|
43
|
-
resolvedPath = resolvedPath.replace("{HumanLoopName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
|
|
44
|
-
}
|
|
45
|
-
else {
|
|
46
|
-
throw new Error("No value provided for input HTTP label: HumanLoopName.");
|
|
47
|
-
}
|
|
29
|
+
resolvedPath = (0, smithy_client_1.resolvedPath)(resolvedPath, input, "HumanLoopName", () => input.HumanLoopName, "{HumanLoopName}", false);
|
|
48
30
|
let body;
|
|
49
31
|
return new protocol_http_1.HttpRequest({
|
|
50
32
|
protocol,
|
|
@@ -61,18 +43,20 @@ const serializeAws_restJson1ListHumanLoopsCommand = async (input, context) => {
|
|
|
61
43
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
62
44
|
const headers = {};
|
|
63
45
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/human-loops";
|
|
64
|
-
const query = {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
46
|
+
const query = map({
|
|
47
|
+
CreationTimeAfter: [
|
|
48
|
+
() => input.CreationTimeAfter !== void 0,
|
|
49
|
+
() => (input.CreationTimeAfter.toISOString().split(".")[0] + "Z").toString(),
|
|
50
|
+
],
|
|
51
|
+
CreationTimeBefore: [
|
|
52
|
+
() => input.CreationTimeBefore !== void 0,
|
|
53
|
+
() => (input.CreationTimeBefore.toISOString().split(".")[0] + "Z").toString(),
|
|
54
|
+
],
|
|
55
|
+
FlowDefinitionArn: [, input.FlowDefinitionArn],
|
|
56
|
+
SortOrder: [, input.SortOrder],
|
|
57
|
+
NextToken: [, input.NextToken],
|
|
58
|
+
MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
|
|
59
|
+
});
|
|
76
60
|
let body;
|
|
77
61
|
return new protocol_http_1.HttpRequest({
|
|
78
62
|
protocol,
|
|
@@ -139,11 +123,11 @@ const deserializeAws_restJson1DeleteHumanLoopCommand = async (output, context) =
|
|
|
139
123
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
140
124
|
return deserializeAws_restJson1DeleteHumanLoopCommandError(output, context);
|
|
141
125
|
}
|
|
142
|
-
const contents = {
|
|
126
|
+
const contents = map({
|
|
143
127
|
$metadata: deserializeMetadata(output),
|
|
144
|
-
};
|
|
128
|
+
});
|
|
145
129
|
await collectBody(output.body, context);
|
|
146
|
-
return
|
|
130
|
+
return contents;
|
|
147
131
|
};
|
|
148
132
|
exports.deserializeAws_restJson1DeleteHumanLoopCommand = deserializeAws_restJson1DeleteHumanLoopCommand;
|
|
149
133
|
const deserializeAws_restJson1DeleteHumanLoopCommandError = async (output, context) => {
|
|
@@ -151,7 +135,6 @@ const deserializeAws_restJson1DeleteHumanLoopCommandError = async (output, conte
|
|
|
151
135
|
...output,
|
|
152
136
|
body: await parseBody(output.body, context),
|
|
153
137
|
};
|
|
154
|
-
let response;
|
|
155
138
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
156
139
|
switch (errorCode) {
|
|
157
140
|
case "InternalServerException":
|
|
@@ -168,57 +151,47 @@ const deserializeAws_restJson1DeleteHumanLoopCommandError = async (output, conte
|
|
|
168
151
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
169
152
|
default:
|
|
170
153
|
const parsedBody = parsedOutput.body;
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
$metadata,
|
|
154
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
155
|
+
output,
|
|
156
|
+
parsedBody,
|
|
157
|
+
exceptionCtor: SageMakerA2IRuntimeServiceException_1.SageMakerA2IRuntimeServiceException,
|
|
158
|
+
errorCode,
|
|
177
159
|
});
|
|
178
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
179
160
|
}
|
|
180
161
|
};
|
|
181
162
|
const deserializeAws_restJson1DescribeHumanLoopCommand = async (output, context) => {
|
|
182
163
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
183
164
|
return deserializeAws_restJson1DescribeHumanLoopCommandError(output, context);
|
|
184
165
|
}
|
|
185
|
-
const contents = {
|
|
166
|
+
const contents = map({
|
|
186
167
|
$metadata: deserializeMetadata(output),
|
|
187
|
-
|
|
188
|
-
FailureCode: undefined,
|
|
189
|
-
FailureReason: undefined,
|
|
190
|
-
FlowDefinitionArn: undefined,
|
|
191
|
-
HumanLoopArn: undefined,
|
|
192
|
-
HumanLoopName: undefined,
|
|
193
|
-
HumanLoopOutput: undefined,
|
|
194
|
-
HumanLoopStatus: undefined,
|
|
195
|
-
};
|
|
168
|
+
});
|
|
196
169
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
197
|
-
if (data.CreationTime
|
|
198
|
-
contents.CreationTime = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.
|
|
170
|
+
if (data.CreationTime != null) {
|
|
171
|
+
contents.CreationTime = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTime)(data.CreationTime));
|
|
199
172
|
}
|
|
200
|
-
if (data.FailureCode
|
|
173
|
+
if (data.FailureCode != null) {
|
|
201
174
|
contents.FailureCode = (0, smithy_client_1.expectString)(data.FailureCode);
|
|
202
175
|
}
|
|
203
|
-
if (data.FailureReason
|
|
176
|
+
if (data.FailureReason != null) {
|
|
204
177
|
contents.FailureReason = (0, smithy_client_1.expectString)(data.FailureReason);
|
|
205
178
|
}
|
|
206
|
-
if (data.FlowDefinitionArn
|
|
179
|
+
if (data.FlowDefinitionArn != null) {
|
|
207
180
|
contents.FlowDefinitionArn = (0, smithy_client_1.expectString)(data.FlowDefinitionArn);
|
|
208
181
|
}
|
|
209
|
-
if (data.HumanLoopArn
|
|
182
|
+
if (data.HumanLoopArn != null) {
|
|
210
183
|
contents.HumanLoopArn = (0, smithy_client_1.expectString)(data.HumanLoopArn);
|
|
211
184
|
}
|
|
212
|
-
if (data.HumanLoopName
|
|
185
|
+
if (data.HumanLoopName != null) {
|
|
213
186
|
contents.HumanLoopName = (0, smithy_client_1.expectString)(data.HumanLoopName);
|
|
214
187
|
}
|
|
215
|
-
if (data.HumanLoopOutput
|
|
188
|
+
if (data.HumanLoopOutput != null) {
|
|
216
189
|
contents.HumanLoopOutput = deserializeAws_restJson1HumanLoopOutput(data.HumanLoopOutput, context);
|
|
217
190
|
}
|
|
218
|
-
if (data.HumanLoopStatus
|
|
191
|
+
if (data.HumanLoopStatus != null) {
|
|
219
192
|
contents.HumanLoopStatus = (0, smithy_client_1.expectString)(data.HumanLoopStatus);
|
|
220
193
|
}
|
|
221
|
-
return
|
|
194
|
+
return contents;
|
|
222
195
|
};
|
|
223
196
|
exports.deserializeAws_restJson1DescribeHumanLoopCommand = deserializeAws_restJson1DescribeHumanLoopCommand;
|
|
224
197
|
const deserializeAws_restJson1DescribeHumanLoopCommandError = async (output, context) => {
|
|
@@ -226,7 +199,6 @@ const deserializeAws_restJson1DescribeHumanLoopCommandError = async (output, con
|
|
|
226
199
|
...output,
|
|
227
200
|
body: await parseBody(output.body, context),
|
|
228
201
|
};
|
|
229
|
-
let response;
|
|
230
202
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
231
203
|
switch (errorCode) {
|
|
232
204
|
case "InternalServerException":
|
|
@@ -243,33 +215,29 @@ const deserializeAws_restJson1DescribeHumanLoopCommandError = async (output, con
|
|
|
243
215
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
244
216
|
default:
|
|
245
217
|
const parsedBody = parsedOutput.body;
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
$metadata,
|
|
218
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
219
|
+
output,
|
|
220
|
+
parsedBody,
|
|
221
|
+
exceptionCtor: SageMakerA2IRuntimeServiceException_1.SageMakerA2IRuntimeServiceException,
|
|
222
|
+
errorCode,
|
|
252
223
|
});
|
|
253
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
254
224
|
}
|
|
255
225
|
};
|
|
256
226
|
const deserializeAws_restJson1ListHumanLoopsCommand = async (output, context) => {
|
|
257
227
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
258
228
|
return deserializeAws_restJson1ListHumanLoopsCommandError(output, context);
|
|
259
229
|
}
|
|
260
|
-
const contents = {
|
|
230
|
+
const contents = map({
|
|
261
231
|
$metadata: deserializeMetadata(output),
|
|
262
|
-
|
|
263
|
-
NextToken: undefined,
|
|
264
|
-
};
|
|
232
|
+
});
|
|
265
233
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
266
|
-
if (data.HumanLoopSummaries
|
|
234
|
+
if (data.HumanLoopSummaries != null) {
|
|
267
235
|
contents.HumanLoopSummaries = deserializeAws_restJson1HumanLoopSummaries(data.HumanLoopSummaries, context);
|
|
268
236
|
}
|
|
269
|
-
if (data.NextToken
|
|
237
|
+
if (data.NextToken != null) {
|
|
270
238
|
contents.NextToken = (0, smithy_client_1.expectString)(data.NextToken);
|
|
271
239
|
}
|
|
272
|
-
return
|
|
240
|
+
return contents;
|
|
273
241
|
};
|
|
274
242
|
exports.deserializeAws_restJson1ListHumanLoopsCommand = deserializeAws_restJson1ListHumanLoopsCommand;
|
|
275
243
|
const deserializeAws_restJson1ListHumanLoopsCommandError = async (output, context) => {
|
|
@@ -277,7 +245,6 @@ const deserializeAws_restJson1ListHumanLoopsCommandError = async (output, contex
|
|
|
277
245
|
...output,
|
|
278
246
|
body: await parseBody(output.body, context),
|
|
279
247
|
};
|
|
280
|
-
let response;
|
|
281
248
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
282
249
|
switch (errorCode) {
|
|
283
250
|
case "InternalServerException":
|
|
@@ -294,29 +261,26 @@ const deserializeAws_restJson1ListHumanLoopsCommandError = async (output, contex
|
|
|
294
261
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
295
262
|
default:
|
|
296
263
|
const parsedBody = parsedOutput.body;
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
$metadata,
|
|
264
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
265
|
+
output,
|
|
266
|
+
parsedBody,
|
|
267
|
+
exceptionCtor: SageMakerA2IRuntimeServiceException_1.SageMakerA2IRuntimeServiceException,
|
|
268
|
+
errorCode,
|
|
303
269
|
});
|
|
304
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
305
270
|
}
|
|
306
271
|
};
|
|
307
272
|
const deserializeAws_restJson1StartHumanLoopCommand = async (output, context) => {
|
|
308
273
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
309
274
|
return deserializeAws_restJson1StartHumanLoopCommandError(output, context);
|
|
310
275
|
}
|
|
311
|
-
const contents = {
|
|
276
|
+
const contents = map({
|
|
312
277
|
$metadata: deserializeMetadata(output),
|
|
313
|
-
|
|
314
|
-
};
|
|
278
|
+
});
|
|
315
279
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
316
|
-
if (data.HumanLoopArn
|
|
280
|
+
if (data.HumanLoopArn != null) {
|
|
317
281
|
contents.HumanLoopArn = (0, smithy_client_1.expectString)(data.HumanLoopArn);
|
|
318
282
|
}
|
|
319
|
-
return
|
|
283
|
+
return contents;
|
|
320
284
|
};
|
|
321
285
|
exports.deserializeAws_restJson1StartHumanLoopCommand = deserializeAws_restJson1StartHumanLoopCommand;
|
|
322
286
|
const deserializeAws_restJson1StartHumanLoopCommandError = async (output, context) => {
|
|
@@ -324,7 +288,6 @@ const deserializeAws_restJson1StartHumanLoopCommandError = async (output, contex
|
|
|
324
288
|
...output,
|
|
325
289
|
body: await parseBody(output.body, context),
|
|
326
290
|
};
|
|
327
|
-
let response;
|
|
328
291
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
329
292
|
switch (errorCode) {
|
|
330
293
|
case "ConflictException":
|
|
@@ -344,25 +307,23 @@ const deserializeAws_restJson1StartHumanLoopCommandError = async (output, contex
|
|
|
344
307
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
345
308
|
default:
|
|
346
309
|
const parsedBody = parsedOutput.body;
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
$metadata,
|
|
310
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
311
|
+
output,
|
|
312
|
+
parsedBody,
|
|
313
|
+
exceptionCtor: SageMakerA2IRuntimeServiceException_1.SageMakerA2IRuntimeServiceException,
|
|
314
|
+
errorCode,
|
|
353
315
|
});
|
|
354
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
355
316
|
}
|
|
356
317
|
};
|
|
357
318
|
const deserializeAws_restJson1StopHumanLoopCommand = async (output, context) => {
|
|
358
319
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
359
320
|
return deserializeAws_restJson1StopHumanLoopCommandError(output, context);
|
|
360
321
|
}
|
|
361
|
-
const contents = {
|
|
322
|
+
const contents = map({
|
|
362
323
|
$metadata: deserializeMetadata(output),
|
|
363
|
-
};
|
|
324
|
+
});
|
|
364
325
|
await collectBody(output.body, context);
|
|
365
|
-
return
|
|
326
|
+
return contents;
|
|
366
327
|
};
|
|
367
328
|
exports.deserializeAws_restJson1StopHumanLoopCommand = deserializeAws_restJson1StopHumanLoopCommand;
|
|
368
329
|
const deserializeAws_restJson1StopHumanLoopCommandError = async (output, context) => {
|
|
@@ -370,7 +331,6 @@ const deserializeAws_restJson1StopHumanLoopCommandError = async (output, context
|
|
|
370
331
|
...output,
|
|
371
332
|
body: await parseBody(output.body, context),
|
|
372
333
|
};
|
|
373
|
-
let response;
|
|
374
334
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
375
335
|
switch (errorCode) {
|
|
376
336
|
case "InternalServerException":
|
|
@@ -387,20 +347,19 @@ const deserializeAws_restJson1StopHumanLoopCommandError = async (output, context
|
|
|
387
347
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
388
348
|
default:
|
|
389
349
|
const parsedBody = parsedOutput.body;
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
$metadata,
|
|
350
|
+
(0, smithy_client_1.throwDefaultError)({
|
|
351
|
+
output,
|
|
352
|
+
parsedBody,
|
|
353
|
+
exceptionCtor: SageMakerA2IRuntimeServiceException_1.SageMakerA2IRuntimeServiceException,
|
|
354
|
+
errorCode,
|
|
396
355
|
});
|
|
397
|
-
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
398
356
|
}
|
|
399
357
|
};
|
|
358
|
+
const map = smithy_client_1.map;
|
|
400
359
|
const deserializeAws_restJson1ConflictExceptionResponse = async (parsedOutput, context) => {
|
|
401
|
-
const contents = {};
|
|
360
|
+
const contents = map({});
|
|
402
361
|
const data = parsedOutput.body;
|
|
403
|
-
if (data.Message
|
|
362
|
+
if (data.Message != null) {
|
|
404
363
|
contents.Message = (0, smithy_client_1.expectString)(data.Message);
|
|
405
364
|
}
|
|
406
365
|
const exception = new models_0_1.ConflictException({
|
|
@@ -410,9 +369,9 @@ const deserializeAws_restJson1ConflictExceptionResponse = async (parsedOutput, c
|
|
|
410
369
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
411
370
|
};
|
|
412
371
|
const deserializeAws_restJson1InternalServerExceptionResponse = async (parsedOutput, context) => {
|
|
413
|
-
const contents = {};
|
|
372
|
+
const contents = map({});
|
|
414
373
|
const data = parsedOutput.body;
|
|
415
|
-
if (data.Message
|
|
374
|
+
if (data.Message != null) {
|
|
416
375
|
contents.Message = (0, smithy_client_1.expectString)(data.Message);
|
|
417
376
|
}
|
|
418
377
|
const exception = new models_0_1.InternalServerException({
|
|
@@ -422,9 +381,9 @@ const deserializeAws_restJson1InternalServerExceptionResponse = async (parsedOut
|
|
|
422
381
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
423
382
|
};
|
|
424
383
|
const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (parsedOutput, context) => {
|
|
425
|
-
const contents = {};
|
|
384
|
+
const contents = map({});
|
|
426
385
|
const data = parsedOutput.body;
|
|
427
|
-
if (data.Message
|
|
386
|
+
if (data.Message != null) {
|
|
428
387
|
contents.Message = (0, smithy_client_1.expectString)(data.Message);
|
|
429
388
|
}
|
|
430
389
|
const exception = new models_0_1.ResourceNotFoundException({
|
|
@@ -434,9 +393,9 @@ const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (parsedO
|
|
|
434
393
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
435
394
|
};
|
|
436
395
|
const deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = async (parsedOutput, context) => {
|
|
437
|
-
const contents = {};
|
|
396
|
+
const contents = map({});
|
|
438
397
|
const data = parsedOutput.body;
|
|
439
|
-
if (data.Message
|
|
398
|
+
if (data.Message != null) {
|
|
440
399
|
contents.Message = (0, smithy_client_1.expectString)(data.Message);
|
|
441
400
|
}
|
|
442
401
|
const exception = new models_0_1.ServiceQuotaExceededException({
|
|
@@ -446,9 +405,9 @@ const deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = async (par
|
|
|
446
405
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
447
406
|
};
|
|
448
407
|
const deserializeAws_restJson1ThrottlingExceptionResponse = async (parsedOutput, context) => {
|
|
449
|
-
const contents = {};
|
|
408
|
+
const contents = map({});
|
|
450
409
|
const data = parsedOutput.body;
|
|
451
|
-
if (data.Message
|
|
410
|
+
if (data.Message != null) {
|
|
452
411
|
contents.Message = (0, smithy_client_1.expectString)(data.Message);
|
|
453
412
|
}
|
|
454
413
|
const exception = new models_0_1.ThrottlingException({
|
|
@@ -458,9 +417,9 @@ const deserializeAws_restJson1ThrottlingExceptionResponse = async (parsedOutput,
|
|
|
458
417
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
459
418
|
};
|
|
460
419
|
const deserializeAws_restJson1ValidationExceptionResponse = async (parsedOutput, context) => {
|
|
461
|
-
const contents = {};
|
|
420
|
+
const contents = map({});
|
|
462
421
|
const data = parsedOutput.body;
|
|
463
|
-
if (data.Message
|
|
422
|
+
if (data.Message != null) {
|
|
464
423
|
contents.Message = (0, smithy_client_1.expectString)(data.Message);
|
|
465
424
|
}
|
|
466
425
|
const exception = new models_0_1.ValidationException({
|
|
@@ -473,9 +432,6 @@ const serializeAws_restJson1ContentClassifiers = (input, context) => {
|
|
|
473
432
|
return input
|
|
474
433
|
.filter((e) => e != null)
|
|
475
434
|
.map((entry) => {
|
|
476
|
-
if (entry === null) {
|
|
477
|
-
return null;
|
|
478
|
-
}
|
|
479
435
|
return entry;
|
|
480
436
|
});
|
|
481
437
|
};
|
|
@@ -509,9 +465,7 @@ const deserializeAws_restJson1HumanLoopSummaries = (output, context) => {
|
|
|
509
465
|
};
|
|
510
466
|
const deserializeAws_restJson1HumanLoopSummary = (output, context) => {
|
|
511
467
|
return {
|
|
512
|
-
CreationTime: output.CreationTime != null
|
|
513
|
-
? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.CreationTime)))
|
|
514
|
-
: undefined,
|
|
468
|
+
CreationTime: output.CreationTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTime)(output.CreationTime)) : undefined,
|
|
515
469
|
FailureReason: (0, smithy_client_1.expectString)(output.FailureReason),
|
|
516
470
|
FlowDefinitionArn: (0, smithy_client_1.expectString)(output.FlowDefinitionArn),
|
|
517
471
|
HumanLoopName: (0, smithy_client_1.expectString)(output.HumanLoopName),
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { __assign, __awaiter, __generator } from "tslib";
|
|
2
2
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull,
|
|
3
|
+
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map as __map, parseRfc3339DateTime as __parseRfc3339DateTime, resolvedPath as __resolvedPath, throwDefaultError, } from "@aws-sdk/smithy-client";
|
|
4
4
|
import { ConflictException, InternalServerException, ResourceNotFoundException, ServiceQuotaExceededException, ThrottlingException, ValidationException, } from "../models/models_0";
|
|
5
5
|
import { SageMakerA2IRuntimeServiceException as __BaseException } from "../models/SageMakerA2IRuntimeServiceException";
|
|
6
6
|
export var serializeAws_restJson1DeleteHumanLoopCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
7
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath,
|
|
7
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
8
8
|
return __generator(this, function (_c) {
|
|
9
9
|
switch (_c.label) {
|
|
10
10
|
case 0: return [4, context.endpoint()];
|
|
@@ -12,16 +12,7 @@ export var serializeAws_restJson1DeleteHumanLoopCommand = function (input, conte
|
|
|
12
12
|
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
13
13
|
headers = {};
|
|
14
14
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/human-loops/{HumanLoopName}";
|
|
15
|
-
|
|
16
|
-
labelValue = input.HumanLoopName;
|
|
17
|
-
if (labelValue.length <= 0) {
|
|
18
|
-
throw new Error("Empty value provided for input HTTP label: HumanLoopName.");
|
|
19
|
-
}
|
|
20
|
-
resolvedPath = resolvedPath.replace("{HumanLoopName}", __extendedEncodeURIComponent(labelValue));
|
|
21
|
-
}
|
|
22
|
-
else {
|
|
23
|
-
throw new Error("No value provided for input HTTP label: HumanLoopName.");
|
|
24
|
-
}
|
|
15
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "HumanLoopName", function () { return input.HumanLoopName; }, "{HumanLoopName}", false);
|
|
25
16
|
return [2, new __HttpRequest({
|
|
26
17
|
protocol: protocol,
|
|
27
18
|
hostname: hostname,
|
|
@@ -35,7 +26,7 @@ export var serializeAws_restJson1DeleteHumanLoopCommand = function (input, conte
|
|
|
35
26
|
});
|
|
36
27
|
}); };
|
|
37
28
|
export var serializeAws_restJson1DescribeHumanLoopCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
38
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath,
|
|
29
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
39
30
|
return __generator(this, function (_c) {
|
|
40
31
|
switch (_c.label) {
|
|
41
32
|
case 0: return [4, context.endpoint()];
|
|
@@ -43,16 +34,7 @@ export var serializeAws_restJson1DescribeHumanLoopCommand = function (input, con
|
|
|
43
34
|
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
44
35
|
headers = {};
|
|
45
36
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/human-loops/{HumanLoopName}";
|
|
46
|
-
|
|
47
|
-
labelValue = input.HumanLoopName;
|
|
48
|
-
if (labelValue.length <= 0) {
|
|
49
|
-
throw new Error("Empty value provided for input HTTP label: HumanLoopName.");
|
|
50
|
-
}
|
|
51
|
-
resolvedPath = resolvedPath.replace("{HumanLoopName}", __extendedEncodeURIComponent(labelValue));
|
|
52
|
-
}
|
|
53
|
-
else {
|
|
54
|
-
throw new Error("No value provided for input HTTP label: HumanLoopName.");
|
|
55
|
-
}
|
|
37
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "HumanLoopName", function () { return input.HumanLoopName; }, "{HumanLoopName}", false);
|
|
56
38
|
return [2, new __HttpRequest({
|
|
57
39
|
protocol: protocol,
|
|
58
40
|
hostname: hostname,
|
|
@@ -74,11 +56,20 @@ export var serializeAws_restJson1ListHumanLoopsCommand = function (input, contex
|
|
|
74
56
|
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
75
57
|
headers = {};
|
|
76
58
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/human-loops";
|
|
77
|
-
query =
|
|
78
|
-
CreationTimeAfter:
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
59
|
+
query = map({
|
|
60
|
+
CreationTimeAfter: [
|
|
61
|
+
function () { return input.CreationTimeAfter !== void 0; },
|
|
62
|
+
function () { return (input.CreationTimeAfter.toISOString().split(".")[0] + "Z").toString(); },
|
|
63
|
+
],
|
|
64
|
+
CreationTimeBefore: [
|
|
65
|
+
function () { return input.CreationTimeBefore !== void 0; },
|
|
66
|
+
function () { return (input.CreationTimeBefore.toISOString().split(".")[0] + "Z").toString(); },
|
|
67
|
+
],
|
|
68
|
+
FlowDefinitionArn: [, input.FlowDefinitionArn],
|
|
69
|
+
SortOrder: [, input.SortOrder],
|
|
70
|
+
NextToken: [, input.NextToken],
|
|
71
|
+
MaxResults: [function () { return input.MaxResults !== void 0; }, function () { return input.MaxResults.toString(); }],
|
|
72
|
+
});
|
|
82
73
|
return [2, new __HttpRequest({
|
|
83
74
|
protocol: protocol,
|
|
84
75
|
hostname: hostname,
|
|
@@ -152,18 +143,18 @@ export var deserializeAws_restJson1DeleteHumanLoopCommand = function (output, co
|
|
|
152
143
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
153
144
|
return [2, deserializeAws_restJson1DeleteHumanLoopCommandError(output, context)];
|
|
154
145
|
}
|
|
155
|
-
contents = {
|
|
146
|
+
contents = map({
|
|
156
147
|
$metadata: deserializeMetadata(output),
|
|
157
|
-
};
|
|
148
|
+
});
|
|
158
149
|
return [4, collectBody(output.body, context)];
|
|
159
150
|
case 1:
|
|
160
151
|
_a.sent();
|
|
161
|
-
return [2,
|
|
152
|
+
return [2, contents];
|
|
162
153
|
}
|
|
163
154
|
});
|
|
164
155
|
}); };
|
|
165
156
|
var deserializeAws_restJson1DeleteHumanLoopCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
166
|
-
var parsedOutput, _a,
|
|
157
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
167
158
|
var _c;
|
|
168
159
|
return __generator(this, function (_d) {
|
|
169
160
|
switch (_d.label) {
|
|
@@ -196,14 +187,14 @@ var deserializeAws_restJson1DeleteHumanLoopCommandError = function (output, cont
|
|
|
196
187
|
case 9: throw _d.sent();
|
|
197
188
|
case 10:
|
|
198
189
|
parsedBody = parsedOutput.body;
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
$metadata: $metadata,
|
|
190
|
+
throwDefaultError({
|
|
191
|
+
output: output,
|
|
192
|
+
parsedBody: parsedBody,
|
|
193
|
+
exceptionCtor: __BaseException,
|
|
194
|
+
errorCode: errorCode,
|
|
205
195
|
});
|
|
206
|
-
|
|
196
|
+
_d.label = 11;
|
|
197
|
+
case 11: return [2];
|
|
207
198
|
}
|
|
208
199
|
});
|
|
209
200
|
}); };
|
|
@@ -215,52 +206,44 @@ export var deserializeAws_restJson1DescribeHumanLoopCommand = function (output,
|
|
|
215
206
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
216
207
|
return [2, deserializeAws_restJson1DescribeHumanLoopCommandError(output, context)];
|
|
217
208
|
}
|
|
218
|
-
contents = {
|
|
209
|
+
contents = map({
|
|
219
210
|
$metadata: deserializeMetadata(output),
|
|
220
|
-
|
|
221
|
-
FailureCode: undefined,
|
|
222
|
-
FailureReason: undefined,
|
|
223
|
-
FlowDefinitionArn: undefined,
|
|
224
|
-
HumanLoopArn: undefined,
|
|
225
|
-
HumanLoopName: undefined,
|
|
226
|
-
HumanLoopOutput: undefined,
|
|
227
|
-
HumanLoopStatus: undefined,
|
|
228
|
-
};
|
|
211
|
+
});
|
|
229
212
|
_a = __expectNonNull;
|
|
230
213
|
_b = __expectObject;
|
|
231
214
|
return [4, parseBody(output.body, context)];
|
|
232
215
|
case 1:
|
|
233
216
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
234
|
-
if (data.CreationTime
|
|
235
|
-
contents.CreationTime = __expectNonNull(
|
|
217
|
+
if (data.CreationTime != null) {
|
|
218
|
+
contents.CreationTime = __expectNonNull(__parseRfc3339DateTime(data.CreationTime));
|
|
236
219
|
}
|
|
237
|
-
if (data.FailureCode
|
|
220
|
+
if (data.FailureCode != null) {
|
|
238
221
|
contents.FailureCode = __expectString(data.FailureCode);
|
|
239
222
|
}
|
|
240
|
-
if (data.FailureReason
|
|
223
|
+
if (data.FailureReason != null) {
|
|
241
224
|
contents.FailureReason = __expectString(data.FailureReason);
|
|
242
225
|
}
|
|
243
|
-
if (data.FlowDefinitionArn
|
|
226
|
+
if (data.FlowDefinitionArn != null) {
|
|
244
227
|
contents.FlowDefinitionArn = __expectString(data.FlowDefinitionArn);
|
|
245
228
|
}
|
|
246
|
-
if (data.HumanLoopArn
|
|
229
|
+
if (data.HumanLoopArn != null) {
|
|
247
230
|
contents.HumanLoopArn = __expectString(data.HumanLoopArn);
|
|
248
231
|
}
|
|
249
|
-
if (data.HumanLoopName
|
|
232
|
+
if (data.HumanLoopName != null) {
|
|
250
233
|
contents.HumanLoopName = __expectString(data.HumanLoopName);
|
|
251
234
|
}
|
|
252
|
-
if (data.HumanLoopOutput
|
|
235
|
+
if (data.HumanLoopOutput != null) {
|
|
253
236
|
contents.HumanLoopOutput = deserializeAws_restJson1HumanLoopOutput(data.HumanLoopOutput, context);
|
|
254
237
|
}
|
|
255
|
-
if (data.HumanLoopStatus
|
|
238
|
+
if (data.HumanLoopStatus != null) {
|
|
256
239
|
contents.HumanLoopStatus = __expectString(data.HumanLoopStatus);
|
|
257
240
|
}
|
|
258
|
-
return [2,
|
|
241
|
+
return [2, contents];
|
|
259
242
|
}
|
|
260
243
|
});
|
|
261
244
|
}); };
|
|
262
245
|
var deserializeAws_restJson1DescribeHumanLoopCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
263
|
-
var parsedOutput, _a,
|
|
246
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
264
247
|
var _c;
|
|
265
248
|
return __generator(this, function (_d) {
|
|
266
249
|
switch (_d.label) {
|
|
@@ -293,14 +276,14 @@ var deserializeAws_restJson1DescribeHumanLoopCommandError = function (output, co
|
|
|
293
276
|
case 9: throw _d.sent();
|
|
294
277
|
case 10:
|
|
295
278
|
parsedBody = parsedOutput.body;
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
$metadata: $metadata,
|
|
279
|
+
throwDefaultError({
|
|
280
|
+
output: output,
|
|
281
|
+
parsedBody: parsedBody,
|
|
282
|
+
exceptionCtor: __BaseException,
|
|
283
|
+
errorCode: errorCode,
|
|
302
284
|
});
|
|
303
|
-
|
|
285
|
+
_d.label = 11;
|
|
286
|
+
case 11: return [2];
|
|
304
287
|
}
|
|
305
288
|
});
|
|
306
289
|
}); };
|
|
@@ -312,28 +295,26 @@ export var deserializeAws_restJson1ListHumanLoopsCommand = function (output, con
|
|
|
312
295
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
313
296
|
return [2, deserializeAws_restJson1ListHumanLoopsCommandError(output, context)];
|
|
314
297
|
}
|
|
315
|
-
contents = {
|
|
298
|
+
contents = map({
|
|
316
299
|
$metadata: deserializeMetadata(output),
|
|
317
|
-
|
|
318
|
-
NextToken: undefined,
|
|
319
|
-
};
|
|
300
|
+
});
|
|
320
301
|
_a = __expectNonNull;
|
|
321
302
|
_b = __expectObject;
|
|
322
303
|
return [4, parseBody(output.body, context)];
|
|
323
304
|
case 1:
|
|
324
305
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
325
|
-
if (data.HumanLoopSummaries
|
|
306
|
+
if (data.HumanLoopSummaries != null) {
|
|
326
307
|
contents.HumanLoopSummaries = deserializeAws_restJson1HumanLoopSummaries(data.HumanLoopSummaries, context);
|
|
327
308
|
}
|
|
328
|
-
if (data.NextToken
|
|
309
|
+
if (data.NextToken != null) {
|
|
329
310
|
contents.NextToken = __expectString(data.NextToken);
|
|
330
311
|
}
|
|
331
|
-
return [2,
|
|
312
|
+
return [2, contents];
|
|
332
313
|
}
|
|
333
314
|
});
|
|
334
315
|
}); };
|
|
335
316
|
var deserializeAws_restJson1ListHumanLoopsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
336
|
-
var parsedOutput, _a,
|
|
317
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
337
318
|
var _c;
|
|
338
319
|
return __generator(this, function (_d) {
|
|
339
320
|
switch (_d.label) {
|
|
@@ -366,14 +347,14 @@ var deserializeAws_restJson1ListHumanLoopsCommandError = function (output, conte
|
|
|
366
347
|
case 9: throw _d.sent();
|
|
367
348
|
case 10:
|
|
368
349
|
parsedBody = parsedOutput.body;
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
$metadata: $metadata,
|
|
350
|
+
throwDefaultError({
|
|
351
|
+
output: output,
|
|
352
|
+
parsedBody: parsedBody,
|
|
353
|
+
exceptionCtor: __BaseException,
|
|
354
|
+
errorCode: errorCode,
|
|
375
355
|
});
|
|
376
|
-
|
|
356
|
+
_d.label = 11;
|
|
357
|
+
case 11: return [2];
|
|
377
358
|
}
|
|
378
359
|
});
|
|
379
360
|
}); };
|
|
@@ -385,24 +366,23 @@ export var deserializeAws_restJson1StartHumanLoopCommand = function (output, con
|
|
|
385
366
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
386
367
|
return [2, deserializeAws_restJson1StartHumanLoopCommandError(output, context)];
|
|
387
368
|
}
|
|
388
|
-
contents = {
|
|
369
|
+
contents = map({
|
|
389
370
|
$metadata: deserializeMetadata(output),
|
|
390
|
-
|
|
391
|
-
};
|
|
371
|
+
});
|
|
392
372
|
_a = __expectNonNull;
|
|
393
373
|
_b = __expectObject;
|
|
394
374
|
return [4, parseBody(output.body, context)];
|
|
395
375
|
case 1:
|
|
396
376
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
397
|
-
if (data.HumanLoopArn
|
|
377
|
+
if (data.HumanLoopArn != null) {
|
|
398
378
|
contents.HumanLoopArn = __expectString(data.HumanLoopArn);
|
|
399
379
|
}
|
|
400
|
-
return [2,
|
|
380
|
+
return [2, contents];
|
|
401
381
|
}
|
|
402
382
|
});
|
|
403
383
|
}); };
|
|
404
384
|
var deserializeAws_restJson1StartHumanLoopCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
405
|
-
var parsedOutput, _a,
|
|
385
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
406
386
|
var _c;
|
|
407
387
|
return __generator(this, function (_d) {
|
|
408
388
|
switch (_d.label) {
|
|
@@ -439,14 +419,14 @@ var deserializeAws_restJson1StartHumanLoopCommandError = function (output, conte
|
|
|
439
419
|
case 11: throw _d.sent();
|
|
440
420
|
case 12:
|
|
441
421
|
parsedBody = parsedOutput.body;
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
$metadata: $metadata,
|
|
422
|
+
throwDefaultError({
|
|
423
|
+
output: output,
|
|
424
|
+
parsedBody: parsedBody,
|
|
425
|
+
exceptionCtor: __BaseException,
|
|
426
|
+
errorCode: errorCode,
|
|
448
427
|
});
|
|
449
|
-
|
|
428
|
+
_d.label = 13;
|
|
429
|
+
case 13: return [2];
|
|
450
430
|
}
|
|
451
431
|
});
|
|
452
432
|
}); };
|
|
@@ -458,18 +438,18 @@ export var deserializeAws_restJson1StopHumanLoopCommand = function (output, cont
|
|
|
458
438
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
459
439
|
return [2, deserializeAws_restJson1StopHumanLoopCommandError(output, context)];
|
|
460
440
|
}
|
|
461
|
-
contents = {
|
|
441
|
+
contents = map({
|
|
462
442
|
$metadata: deserializeMetadata(output),
|
|
463
|
-
};
|
|
443
|
+
});
|
|
464
444
|
return [4, collectBody(output.body, context)];
|
|
465
445
|
case 1:
|
|
466
446
|
_a.sent();
|
|
467
|
-
return [2,
|
|
447
|
+
return [2, contents];
|
|
468
448
|
}
|
|
469
449
|
});
|
|
470
450
|
}); };
|
|
471
451
|
var deserializeAws_restJson1StopHumanLoopCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
472
|
-
var parsedOutput, _a,
|
|
452
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
473
453
|
var _c;
|
|
474
454
|
return __generator(this, function (_d) {
|
|
475
455
|
switch (_d.label) {
|
|
@@ -502,23 +482,24 @@ var deserializeAws_restJson1StopHumanLoopCommandError = function (output, contex
|
|
|
502
482
|
case 9: throw _d.sent();
|
|
503
483
|
case 10:
|
|
504
484
|
parsedBody = parsedOutput.body;
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
$metadata: $metadata,
|
|
485
|
+
throwDefaultError({
|
|
486
|
+
output: output,
|
|
487
|
+
parsedBody: parsedBody,
|
|
488
|
+
exceptionCtor: __BaseException,
|
|
489
|
+
errorCode: errorCode,
|
|
511
490
|
});
|
|
512
|
-
|
|
491
|
+
_d.label = 11;
|
|
492
|
+
case 11: return [2];
|
|
513
493
|
}
|
|
514
494
|
});
|
|
515
495
|
}); };
|
|
496
|
+
var map = __map;
|
|
516
497
|
var deserializeAws_restJson1ConflictExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
517
498
|
var contents, data, exception;
|
|
518
499
|
return __generator(this, function (_a) {
|
|
519
|
-
contents = {};
|
|
500
|
+
contents = map({});
|
|
520
501
|
data = parsedOutput.body;
|
|
521
|
-
if (data.Message
|
|
502
|
+
if (data.Message != null) {
|
|
522
503
|
contents.Message = __expectString(data.Message);
|
|
523
504
|
}
|
|
524
505
|
exception = new ConflictException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -528,9 +509,9 @@ var deserializeAws_restJson1ConflictExceptionResponse = function (parsedOutput,
|
|
|
528
509
|
var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
529
510
|
var contents, data, exception;
|
|
530
511
|
return __generator(this, function (_a) {
|
|
531
|
-
contents = {};
|
|
512
|
+
contents = map({});
|
|
532
513
|
data = parsedOutput.body;
|
|
533
|
-
if (data.Message
|
|
514
|
+
if (data.Message != null) {
|
|
534
515
|
contents.Message = __expectString(data.Message);
|
|
535
516
|
}
|
|
536
517
|
exception = new InternalServerException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -540,9 +521,9 @@ var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOu
|
|
|
540
521
|
var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
541
522
|
var contents, data, exception;
|
|
542
523
|
return __generator(this, function (_a) {
|
|
543
|
-
contents = {};
|
|
524
|
+
contents = map({});
|
|
544
525
|
data = parsedOutput.body;
|
|
545
|
-
if (data.Message
|
|
526
|
+
if (data.Message != null) {
|
|
546
527
|
contents.Message = __expectString(data.Message);
|
|
547
528
|
}
|
|
548
529
|
exception = new ResourceNotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -552,9 +533,9 @@ var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsed
|
|
|
552
533
|
var deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
553
534
|
var contents, data, exception;
|
|
554
535
|
return __generator(this, function (_a) {
|
|
555
|
-
contents = {};
|
|
536
|
+
contents = map({});
|
|
556
537
|
data = parsedOutput.body;
|
|
557
|
-
if (data.Message
|
|
538
|
+
if (data.Message != null) {
|
|
558
539
|
contents.Message = __expectString(data.Message);
|
|
559
540
|
}
|
|
560
541
|
exception = new ServiceQuotaExceededException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -564,9 +545,9 @@ var deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = function (pa
|
|
|
564
545
|
var deserializeAws_restJson1ThrottlingExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
565
546
|
var contents, data, exception;
|
|
566
547
|
return __generator(this, function (_a) {
|
|
567
|
-
contents = {};
|
|
548
|
+
contents = map({});
|
|
568
549
|
data = parsedOutput.body;
|
|
569
|
-
if (data.Message
|
|
550
|
+
if (data.Message != null) {
|
|
570
551
|
contents.Message = __expectString(data.Message);
|
|
571
552
|
}
|
|
572
553
|
exception = new ThrottlingException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -576,9 +557,9 @@ var deserializeAws_restJson1ThrottlingExceptionResponse = function (parsedOutput
|
|
|
576
557
|
var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
577
558
|
var contents, data, exception;
|
|
578
559
|
return __generator(this, function (_a) {
|
|
579
|
-
contents = {};
|
|
560
|
+
contents = map({});
|
|
580
561
|
data = parsedOutput.body;
|
|
581
|
-
if (data.Message
|
|
562
|
+
if (data.Message != null) {
|
|
582
563
|
contents.Message = __expectString(data.Message);
|
|
583
564
|
}
|
|
584
565
|
exception = new ValidationException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
@@ -589,9 +570,6 @@ var serializeAws_restJson1ContentClassifiers = function (input, context) {
|
|
|
589
570
|
return input
|
|
590
571
|
.filter(function (e) { return e != null; })
|
|
591
572
|
.map(function (entry) {
|
|
592
|
-
if (entry === null) {
|
|
593
|
-
return null;
|
|
594
|
-
}
|
|
595
573
|
return entry;
|
|
596
574
|
});
|
|
597
575
|
};
|
|
@@ -621,9 +599,7 @@ var deserializeAws_restJson1HumanLoopSummaries = function (output, context) {
|
|
|
621
599
|
};
|
|
622
600
|
var deserializeAws_restJson1HumanLoopSummary = function (output, context) {
|
|
623
601
|
return {
|
|
624
|
-
CreationTime: output.CreationTime != null
|
|
625
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreationTime)))
|
|
626
|
-
: undefined,
|
|
602
|
+
CreationTime: output.CreationTime != null ? __expectNonNull(__parseRfc3339DateTime(output.CreationTime)) : undefined,
|
|
627
603
|
FailureReason: __expectString(output.FailureReason),
|
|
628
604
|
FlowDefinitionArn: __expectString(output.FlowDefinitionArn),
|
|
629
605
|
HumanLoopName: __expectString(output.HumanLoopName),
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-sagemaker-a2i-runtime",
|
|
3
3
|
"description": "AWS SDK for JavaScript Sagemaker A2i Runtime Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.146.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
@@ -18,9 +18,9 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@aws-crypto/sha256-browser": "2.0.0",
|
|
20
20
|
"@aws-crypto/sha256-js": "2.0.0",
|
|
21
|
-
"@aws-sdk/client-sts": "3.
|
|
21
|
+
"@aws-sdk/client-sts": "3.145.0",
|
|
22
22
|
"@aws-sdk/config-resolver": "3.130.0",
|
|
23
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
23
|
+
"@aws-sdk/credential-provider-node": "3.145.0",
|
|
24
24
|
"@aws-sdk/fetch-http-handler": "3.131.0",
|
|
25
25
|
"@aws-sdk/hash-node": "3.127.0",
|
|
26
26
|
"@aws-sdk/invalid-dependency": "3.127.0",
|
|
@@ -36,15 +36,15 @@
|
|
|
36
36
|
"@aws-sdk/node-config-provider": "3.127.0",
|
|
37
37
|
"@aws-sdk/node-http-handler": "3.127.0",
|
|
38
38
|
"@aws-sdk/protocol-http": "3.127.0",
|
|
39
|
-
"@aws-sdk/smithy-client": "3.
|
|
39
|
+
"@aws-sdk/smithy-client": "3.142.0",
|
|
40
40
|
"@aws-sdk/types": "3.127.0",
|
|
41
41
|
"@aws-sdk/url-parser": "3.127.0",
|
|
42
42
|
"@aws-sdk/util-base64-browser": "3.109.0",
|
|
43
43
|
"@aws-sdk/util-base64-node": "3.55.0",
|
|
44
44
|
"@aws-sdk/util-body-length-browser": "3.55.0",
|
|
45
45
|
"@aws-sdk/util-body-length-node": "3.55.0",
|
|
46
|
-
"@aws-sdk/util-defaults-mode-browser": "3.
|
|
47
|
-
"@aws-sdk/util-defaults-mode-node": "3.
|
|
46
|
+
"@aws-sdk/util-defaults-mode-browser": "3.142.0",
|
|
47
|
+
"@aws-sdk/util-defaults-mode-node": "3.142.0",
|
|
48
48
|
"@aws-sdk/util-user-agent-browser": "3.127.0",
|
|
49
49
|
"@aws-sdk/util-user-agent-node": "3.127.0",
|
|
50
50
|
"@aws-sdk/util-utf8-browser": "3.109.0",
|
|
@@ -61,6 +61,11 @@
|
|
|
61
61
|
"typedoc": "0.19.2",
|
|
62
62
|
"typescript": "~4.6.2"
|
|
63
63
|
},
|
|
64
|
+
"overrides": {
|
|
65
|
+
"typedoc": {
|
|
66
|
+
"typescript": "~4.6.2"
|
|
67
|
+
}
|
|
68
|
+
},
|
|
64
69
|
"engines": {
|
|
65
70
|
"node": ">=12.0.0"
|
|
66
71
|
},
|