@aws-sdk/client-wisdom 3.118.1 → 3.128.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 +27 -0
- package/dist-cjs/protocols/Aws_restJson1.js +234 -258
- package/dist-es/protocols/Aws_restJson1.js +210 -234
- package/package.json +26 -26
|
@@ -16,10 +16,9 @@ export var serializeAws_restJson1CreateAssistantCommand = function (input, conte
|
|
|
16
16
|
"content-type": "application/json",
|
|
17
17
|
};
|
|
18
18
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/assistants";
|
|
19
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.description
|
|
20
|
-
input.serverSideEncryptionConfiguration !== null && {
|
|
19
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.description != null && { description: input.description })), (input.name != null && { name: input.name })), (input.serverSideEncryptionConfiguration != null && {
|
|
21
20
|
serverSideEncryptionConfiguration: serializeAws_restJson1ServerSideEncryptionConfiguration(input.serverSideEncryptionConfiguration, context),
|
|
22
|
-
})), (input.tags
|
|
21
|
+
})), (input.tags != null && { tags: serializeAws_restJson1Tags(input.tags, context) })), (input.type != null && { type: input.type })));
|
|
23
22
|
return [2, new __HttpRequest({
|
|
24
23
|
protocol: protocol,
|
|
25
24
|
hostname: hostname,
|
|
@@ -54,11 +53,9 @@ export var serializeAws_restJson1CreateAssistantAssociationCommand = function (i
|
|
|
54
53
|
else {
|
|
55
54
|
throw new Error("No value provided for input HTTP label: assistantId.");
|
|
56
55
|
}
|
|
57
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign({}, (input.association
|
|
58
|
-
input.association !== null && {
|
|
56
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign({}, (input.association != null && {
|
|
59
57
|
association: serializeAws_restJson1AssistantAssociationInputData(input.association, context),
|
|
60
|
-
})), (input.associationType !==
|
|
61
|
-
input.associationType !== null && { associationType: input.associationType })), { clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }), (input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1Tags(input.tags, context) })));
|
|
58
|
+
})), (input.associationType != null && { associationType: input.associationType })), { clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }), (input.tags != null && { tags: serializeAws_restJson1Tags(input.tags, context) })));
|
|
62
59
|
return [2, new __HttpRequest({
|
|
63
60
|
protocol: protocol,
|
|
64
61
|
hostname: hostname,
|
|
@@ -94,9 +91,7 @@ export var serializeAws_restJson1CreateContentCommand = function (input, context
|
|
|
94
91
|
else {
|
|
95
92
|
throw new Error("No value provided for input HTTP label: knowledgeBaseId.");
|
|
96
93
|
}
|
|
97
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.metadata
|
|
98
|
-
input.metadata !== null && { metadata: serializeAws_restJson1ContentMetadata(input.metadata, context) })), (input.name !== undefined && input.name !== null && { name: input.name })), (input.overrideLinkOutUri !== undefined &&
|
|
99
|
-
input.overrideLinkOutUri !== null && { overrideLinkOutUri: input.overrideLinkOutUri })), (input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1Tags(input.tags, context) })), (input.title !== undefined && input.title !== null && { title: input.title })), (input.uploadId !== undefined && input.uploadId !== null && { uploadId: input.uploadId })));
|
|
94
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.metadata != null && { metadata: serializeAws_restJson1ContentMetadata(input.metadata, context) })), (input.name != null && { name: input.name })), (input.overrideLinkOutUri != null && { overrideLinkOutUri: input.overrideLinkOutUri })), (input.tags != null && { tags: serializeAws_restJson1Tags(input.tags, context) })), (input.title != null && { title: input.title })), (input.uploadId != null && { uploadId: input.uploadId })));
|
|
100
95
|
return [2, new __HttpRequest({
|
|
101
96
|
protocol: protocol,
|
|
102
97
|
hostname: hostname,
|
|
@@ -121,17 +116,13 @@ export var serializeAws_restJson1CreateKnowledgeBaseCommand = function (input, c
|
|
|
121
116
|
"content-type": "application/json",
|
|
122
117
|
};
|
|
123
118
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/knowledgeBases";
|
|
124
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.description
|
|
125
|
-
input.knowledgeBaseType !== null && { knowledgeBaseType: input.knowledgeBaseType })), (input.name !== undefined && input.name !== null && { name: input.name })), (input.renderingConfiguration !== undefined &&
|
|
126
|
-
input.renderingConfiguration !== null && {
|
|
119
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.description != null && { description: input.description })), (input.knowledgeBaseType != null && { knowledgeBaseType: input.knowledgeBaseType })), (input.name != null && { name: input.name })), (input.renderingConfiguration != null && {
|
|
127
120
|
renderingConfiguration: serializeAws_restJson1RenderingConfiguration(input.renderingConfiguration, context),
|
|
128
|
-
})), (input.serverSideEncryptionConfiguration
|
|
129
|
-
input.serverSideEncryptionConfiguration !== null && {
|
|
121
|
+
})), (input.serverSideEncryptionConfiguration != null && {
|
|
130
122
|
serverSideEncryptionConfiguration: serializeAws_restJson1ServerSideEncryptionConfiguration(input.serverSideEncryptionConfiguration, context),
|
|
131
|
-
})), (input.sourceConfiguration
|
|
132
|
-
input.sourceConfiguration !== null && {
|
|
123
|
+
})), (input.sourceConfiguration != null && {
|
|
133
124
|
sourceConfiguration: serializeAws_restJson1SourceConfiguration(input.sourceConfiguration, context),
|
|
134
|
-
})), (input.tags
|
|
125
|
+
})), (input.tags != null && { tags: serializeAws_restJson1Tags(input.tags, context) })));
|
|
135
126
|
return [2, new __HttpRequest({
|
|
136
127
|
protocol: protocol,
|
|
137
128
|
hostname: hostname,
|
|
@@ -166,7 +157,7 @@ export var serializeAws_restJson1CreateSessionCommand = function (input, context
|
|
|
166
157
|
else {
|
|
167
158
|
throw new Error("No value provided for input HTTP label: assistantId.");
|
|
168
159
|
}
|
|
169
|
-
body = JSON.stringify(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.description
|
|
160
|
+
body = JSON.stringify(__assign(__assign(__assign({ clientToken: (_c = input.clientToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.description != null && { description: input.description })), (input.name != null && { name: input.name })), (input.tags != null && { tags: serializeAws_restJson1Tags(input.tags, context) })));
|
|
170
161
|
return [2, new __HttpRequest({
|
|
171
162
|
protocol: protocol,
|
|
172
163
|
hostname: hostname,
|
|
@@ -775,8 +766,7 @@ export var serializeAws_restJson1NotifyRecommendationsReceivedCommand = function
|
|
|
775
766
|
else {
|
|
776
767
|
throw new Error("No value provided for input HTTP label: sessionId.");
|
|
777
768
|
}
|
|
778
|
-
body = JSON.stringify(__assign({}, (input.recommendationIds
|
|
779
|
-
input.recommendationIds !== null && {
|
|
769
|
+
body = JSON.stringify(__assign({}, (input.recommendationIds != null && {
|
|
780
770
|
recommendationIds: serializeAws_restJson1RecommendationIdList(input.recommendationIds, context),
|
|
781
771
|
})));
|
|
782
772
|
return [2, new __HttpRequest({
|
|
@@ -812,7 +802,7 @@ export var serializeAws_restJson1QueryAssistantCommand = function (input, contex
|
|
|
812
802
|
else {
|
|
813
803
|
throw new Error("No value provided for input HTTP label: assistantId.");
|
|
814
804
|
}
|
|
815
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.maxResults
|
|
805
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.maxResults != null && { maxResults: input.maxResults })), (input.nextToken != null && { nextToken: input.nextToken })), (input.queryText != null && { queryText: input.queryText })));
|
|
816
806
|
return [2, new __HttpRequest({
|
|
817
807
|
protocol: protocol,
|
|
818
808
|
hostname: hostname,
|
|
@@ -879,8 +869,7 @@ export var serializeAws_restJson1SearchContentCommand = function (input, context
|
|
|
879
869
|
throw new Error("No value provided for input HTTP label: knowledgeBaseId.");
|
|
880
870
|
}
|
|
881
871
|
query = __assign(__assign({}, (input.nextToken !== undefined && { nextToken: input.nextToken })), (input.maxResults !== undefined && { maxResults: input.maxResults.toString() }));
|
|
882
|
-
body = JSON.stringify(__assign({}, (input.searchExpression
|
|
883
|
-
input.searchExpression !== null && {
|
|
872
|
+
body = JSON.stringify(__assign({}, (input.searchExpression != null && {
|
|
884
873
|
searchExpression: serializeAws_restJson1SearchExpression(input.searchExpression, context),
|
|
885
874
|
})));
|
|
886
875
|
return [2, new __HttpRequest({
|
|
@@ -918,8 +907,7 @@ export var serializeAws_restJson1SearchSessionsCommand = function (input, contex
|
|
|
918
907
|
throw new Error("No value provided for input HTTP label: assistantId.");
|
|
919
908
|
}
|
|
920
909
|
query = __assign(__assign({}, (input.nextToken !== undefined && { nextToken: input.nextToken })), (input.maxResults !== undefined && { maxResults: input.maxResults.toString() }));
|
|
921
|
-
body = JSON.stringify(__assign({}, (input.searchExpression
|
|
922
|
-
input.searchExpression !== null && {
|
|
910
|
+
body = JSON.stringify(__assign({}, (input.searchExpression != null && {
|
|
923
911
|
searchExpression: serializeAws_restJson1SearchExpression(input.searchExpression, context),
|
|
924
912
|
})));
|
|
925
913
|
return [2, new __HttpRequest({
|
|
@@ -956,7 +944,7 @@ export var serializeAws_restJson1StartContentUploadCommand = function (input, co
|
|
|
956
944
|
else {
|
|
957
945
|
throw new Error("No value provided for input HTTP label: knowledgeBaseId.");
|
|
958
946
|
}
|
|
959
|
-
body = JSON.stringify(__assign({}, (input.contentType
|
|
947
|
+
body = JSON.stringify(__assign({}, (input.contentType != null && { contentType: input.contentType })));
|
|
960
948
|
return [2, new __HttpRequest({
|
|
961
949
|
protocol: protocol,
|
|
962
950
|
hostname: hostname,
|
|
@@ -990,7 +978,7 @@ export var serializeAws_restJson1TagResourceCommand = function (input, context)
|
|
|
990
978
|
else {
|
|
991
979
|
throw new Error("No value provided for input HTTP label: resourceArn.");
|
|
992
980
|
}
|
|
993
|
-
body = JSON.stringify(__assign({}, (input.tags
|
|
981
|
+
body = JSON.stringify(__assign({}, (input.tags != null && { tags: serializeAws_restJson1Tags(input.tags, context) })));
|
|
994
982
|
return [2, new __HttpRequest({
|
|
995
983
|
protocol: protocol,
|
|
996
984
|
hostname: hostname,
|
|
@@ -1068,10 +1056,7 @@ export var serializeAws_restJson1UpdateContentCommand = function (input, context
|
|
|
1068
1056
|
else {
|
|
1069
1057
|
throw new Error("No value provided for input HTTP label: contentId.");
|
|
1070
1058
|
}
|
|
1071
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.metadata
|
|
1072
|
-
input.metadata !== null && { metadata: serializeAws_restJson1ContentMetadata(input.metadata, context) })), (input.overrideLinkOutUri !== undefined &&
|
|
1073
|
-
input.overrideLinkOutUri !== null && { overrideLinkOutUri: input.overrideLinkOutUri })), (input.removeOverrideLinkOutUri !== undefined &&
|
|
1074
|
-
input.removeOverrideLinkOutUri !== null && { removeOverrideLinkOutUri: input.removeOverrideLinkOutUri })), (input.revisionId !== undefined && input.revisionId !== null && { revisionId: input.revisionId })), (input.title !== undefined && input.title !== null && { title: input.title })), (input.uploadId !== undefined && input.uploadId !== null && { uploadId: input.uploadId })));
|
|
1059
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.metadata != null && { metadata: serializeAws_restJson1ContentMetadata(input.metadata, context) })), (input.overrideLinkOutUri != null && { overrideLinkOutUri: input.overrideLinkOutUri })), (input.removeOverrideLinkOutUri != null && { removeOverrideLinkOutUri: input.removeOverrideLinkOutUri })), (input.revisionId != null && { revisionId: input.revisionId })), (input.title != null && { title: input.title })), (input.uploadId != null && { uploadId: input.uploadId })));
|
|
1075
1060
|
return [2, new __HttpRequest({
|
|
1076
1061
|
protocol: protocol,
|
|
1077
1062
|
hostname: hostname,
|
|
@@ -1106,7 +1091,7 @@ export var serializeAws_restJson1UpdateKnowledgeBaseTemplateUriCommand = functio
|
|
|
1106
1091
|
else {
|
|
1107
1092
|
throw new Error("No value provided for input HTTP label: knowledgeBaseId.");
|
|
1108
1093
|
}
|
|
1109
|
-
body = JSON.stringify(__assign({}, (input.templateUri
|
|
1094
|
+
body = JSON.stringify(__assign({}, (input.templateUri != null && { templateUri: input.templateUri })));
|
|
1110
1095
|
return [2, new __HttpRequest({
|
|
1111
1096
|
protocol: protocol,
|
|
1112
1097
|
hostname: hostname,
|
|
@@ -1144,7 +1129,7 @@ export var deserializeAws_restJson1CreateAssistantCommand = function (output, co
|
|
|
1144
1129
|
});
|
|
1145
1130
|
}); };
|
|
1146
1131
|
var deserializeAws_restJson1CreateAssistantCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1147
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1132
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1148
1133
|
var _c;
|
|
1149
1134
|
return __generator(this, function (_d) {
|
|
1150
1135
|
switch (_d.label) {
|
|
@@ -1154,7 +1139,6 @@ var deserializeAws_restJson1CreateAssistantCommandError = function (output, cont
|
|
|
1154
1139
|
return [4, parseBody(output.body, context)];
|
|
1155
1140
|
case 1:
|
|
1156
1141
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1157
|
-
errorCode = "UnknownError";
|
|
1158
1142
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1159
1143
|
_b = errorCode;
|
|
1160
1144
|
switch (_b) {
|
|
@@ -1178,10 +1162,12 @@ var deserializeAws_restJson1CreateAssistantCommandError = function (output, cont
|
|
|
1178
1162
|
case 9: throw _d.sent();
|
|
1179
1163
|
case 10:
|
|
1180
1164
|
parsedBody = parsedOutput.body;
|
|
1165
|
+
$metadata = deserializeMetadata(output);
|
|
1166
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1181
1167
|
response = new __BaseException({
|
|
1182
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1168
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1183
1169
|
$fault: "client",
|
|
1184
|
-
$metadata:
|
|
1170
|
+
$metadata: $metadata,
|
|
1185
1171
|
});
|
|
1186
1172
|
throw __decorateServiceException(response, parsedBody);
|
|
1187
1173
|
}
|
|
@@ -1212,7 +1198,7 @@ export var deserializeAws_restJson1CreateAssistantAssociationCommand = function
|
|
|
1212
1198
|
});
|
|
1213
1199
|
}); };
|
|
1214
1200
|
var deserializeAws_restJson1CreateAssistantAssociationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1215
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1201
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1216
1202
|
var _c;
|
|
1217
1203
|
return __generator(this, function (_d) {
|
|
1218
1204
|
switch (_d.label) {
|
|
@@ -1222,7 +1208,6 @@ var deserializeAws_restJson1CreateAssistantAssociationCommandError = function (o
|
|
|
1222
1208
|
return [4, parseBody(output.body, context)];
|
|
1223
1209
|
case 1:
|
|
1224
1210
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1225
|
-
errorCode = "UnknownError";
|
|
1226
1211
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1227
1212
|
_b = errorCode;
|
|
1228
1213
|
switch (_b) {
|
|
@@ -1250,10 +1235,12 @@ var deserializeAws_restJson1CreateAssistantAssociationCommandError = function (o
|
|
|
1250
1235
|
case 11: throw _d.sent();
|
|
1251
1236
|
case 12:
|
|
1252
1237
|
parsedBody = parsedOutput.body;
|
|
1238
|
+
$metadata = deserializeMetadata(output);
|
|
1239
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1253
1240
|
response = new __BaseException({
|
|
1254
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1241
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1255
1242
|
$fault: "client",
|
|
1256
|
-
$metadata:
|
|
1243
|
+
$metadata: $metadata,
|
|
1257
1244
|
});
|
|
1258
1245
|
throw __decorateServiceException(response, parsedBody);
|
|
1259
1246
|
}
|
|
@@ -1284,7 +1271,7 @@ export var deserializeAws_restJson1CreateContentCommand = function (output, cont
|
|
|
1284
1271
|
});
|
|
1285
1272
|
}); };
|
|
1286
1273
|
var deserializeAws_restJson1CreateContentCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1287
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1274
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1288
1275
|
var _c;
|
|
1289
1276
|
return __generator(this, function (_d) {
|
|
1290
1277
|
switch (_d.label) {
|
|
@@ -1294,7 +1281,6 @@ var deserializeAws_restJson1CreateContentCommandError = function (output, contex
|
|
|
1294
1281
|
return [4, parseBody(output.body, context)];
|
|
1295
1282
|
case 1:
|
|
1296
1283
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1297
|
-
errorCode = "UnknownError";
|
|
1298
1284
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1299
1285
|
_b = errorCode;
|
|
1300
1286
|
switch (_b) {
|
|
@@ -1322,10 +1308,12 @@ var deserializeAws_restJson1CreateContentCommandError = function (output, contex
|
|
|
1322
1308
|
case 11: throw _d.sent();
|
|
1323
1309
|
case 12:
|
|
1324
1310
|
parsedBody = parsedOutput.body;
|
|
1311
|
+
$metadata = deserializeMetadata(output);
|
|
1312
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1325
1313
|
response = new __BaseException({
|
|
1326
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1314
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1327
1315
|
$fault: "client",
|
|
1328
|
-
$metadata:
|
|
1316
|
+
$metadata: $metadata,
|
|
1329
1317
|
});
|
|
1330
1318
|
throw __decorateServiceException(response, parsedBody);
|
|
1331
1319
|
}
|
|
@@ -1356,7 +1344,7 @@ export var deserializeAws_restJson1CreateKnowledgeBaseCommand = function (output
|
|
|
1356
1344
|
});
|
|
1357
1345
|
}); };
|
|
1358
1346
|
var deserializeAws_restJson1CreateKnowledgeBaseCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1359
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1347
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1360
1348
|
var _c;
|
|
1361
1349
|
return __generator(this, function (_d) {
|
|
1362
1350
|
switch (_d.label) {
|
|
@@ -1366,7 +1354,6 @@ var deserializeAws_restJson1CreateKnowledgeBaseCommandError = function (output,
|
|
|
1366
1354
|
return [4, parseBody(output.body, context)];
|
|
1367
1355
|
case 1:
|
|
1368
1356
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1369
|
-
errorCode = "UnknownError";
|
|
1370
1357
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1371
1358
|
_b = errorCode;
|
|
1372
1359
|
switch (_b) {
|
|
@@ -1390,10 +1377,12 @@ var deserializeAws_restJson1CreateKnowledgeBaseCommandError = function (output,
|
|
|
1390
1377
|
case 9: throw _d.sent();
|
|
1391
1378
|
case 10:
|
|
1392
1379
|
parsedBody = parsedOutput.body;
|
|
1380
|
+
$metadata = deserializeMetadata(output);
|
|
1381
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1393
1382
|
response = new __BaseException({
|
|
1394
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1383
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1395
1384
|
$fault: "client",
|
|
1396
|
-
$metadata:
|
|
1385
|
+
$metadata: $metadata,
|
|
1397
1386
|
});
|
|
1398
1387
|
throw __decorateServiceException(response, parsedBody);
|
|
1399
1388
|
}
|
|
@@ -1424,7 +1413,7 @@ export var deserializeAws_restJson1CreateSessionCommand = function (output, cont
|
|
|
1424
1413
|
});
|
|
1425
1414
|
}); };
|
|
1426
1415
|
var deserializeAws_restJson1CreateSessionCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1427
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1416
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1428
1417
|
var _c;
|
|
1429
1418
|
return __generator(this, function (_d) {
|
|
1430
1419
|
switch (_d.label) {
|
|
@@ -1434,7 +1423,6 @@ var deserializeAws_restJson1CreateSessionCommandError = function (output, contex
|
|
|
1434
1423
|
return [4, parseBody(output.body, context)];
|
|
1435
1424
|
case 1:
|
|
1436
1425
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1437
|
-
errorCode = "UnknownError";
|
|
1438
1426
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1439
1427
|
_b = errorCode;
|
|
1440
1428
|
switch (_b) {
|
|
@@ -1454,10 +1442,12 @@ var deserializeAws_restJson1CreateSessionCommandError = function (output, contex
|
|
|
1454
1442
|
case 7: throw _d.sent();
|
|
1455
1443
|
case 8:
|
|
1456
1444
|
parsedBody = parsedOutput.body;
|
|
1445
|
+
$metadata = deserializeMetadata(output);
|
|
1446
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1457
1447
|
response = new __BaseException({
|
|
1458
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1448
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1459
1449
|
$fault: "client",
|
|
1460
|
-
$metadata:
|
|
1450
|
+
$metadata: $metadata,
|
|
1461
1451
|
});
|
|
1462
1452
|
throw __decorateServiceException(response, parsedBody);
|
|
1463
1453
|
}
|
|
@@ -1482,7 +1472,7 @@ export var deserializeAws_restJson1DeleteAssistantCommand = function (output, co
|
|
|
1482
1472
|
});
|
|
1483
1473
|
}); };
|
|
1484
1474
|
var deserializeAws_restJson1DeleteAssistantCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1485
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1475
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1486
1476
|
var _c;
|
|
1487
1477
|
return __generator(this, function (_d) {
|
|
1488
1478
|
switch (_d.label) {
|
|
@@ -1492,7 +1482,6 @@ var deserializeAws_restJson1DeleteAssistantCommandError = function (output, cont
|
|
|
1492
1482
|
return [4, parseBody(output.body, context)];
|
|
1493
1483
|
case 1:
|
|
1494
1484
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1495
|
-
errorCode = "UnknownError";
|
|
1496
1485
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1497
1486
|
_b = errorCode;
|
|
1498
1487
|
switch (_b) {
|
|
@@ -1512,10 +1501,12 @@ var deserializeAws_restJson1DeleteAssistantCommandError = function (output, cont
|
|
|
1512
1501
|
case 7: throw _d.sent();
|
|
1513
1502
|
case 8:
|
|
1514
1503
|
parsedBody = parsedOutput.body;
|
|
1504
|
+
$metadata = deserializeMetadata(output);
|
|
1505
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1515
1506
|
response = new __BaseException({
|
|
1516
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1507
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1517
1508
|
$fault: "client",
|
|
1518
|
-
$metadata:
|
|
1509
|
+
$metadata: $metadata,
|
|
1519
1510
|
});
|
|
1520
1511
|
throw __decorateServiceException(response, parsedBody);
|
|
1521
1512
|
}
|
|
@@ -1540,7 +1531,7 @@ export var deserializeAws_restJson1DeleteAssistantAssociationCommand = function
|
|
|
1540
1531
|
});
|
|
1541
1532
|
}); };
|
|
1542
1533
|
var deserializeAws_restJson1DeleteAssistantAssociationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1543
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1534
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1544
1535
|
var _c;
|
|
1545
1536
|
return __generator(this, function (_d) {
|
|
1546
1537
|
switch (_d.label) {
|
|
@@ -1550,7 +1541,6 @@ var deserializeAws_restJson1DeleteAssistantAssociationCommandError = function (o
|
|
|
1550
1541
|
return [4, parseBody(output.body, context)];
|
|
1551
1542
|
case 1:
|
|
1552
1543
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1553
|
-
errorCode = "UnknownError";
|
|
1554
1544
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1555
1545
|
_b = errorCode;
|
|
1556
1546
|
switch (_b) {
|
|
@@ -1570,10 +1560,12 @@ var deserializeAws_restJson1DeleteAssistantAssociationCommandError = function (o
|
|
|
1570
1560
|
case 7: throw _d.sent();
|
|
1571
1561
|
case 8:
|
|
1572
1562
|
parsedBody = parsedOutput.body;
|
|
1563
|
+
$metadata = deserializeMetadata(output);
|
|
1564
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1573
1565
|
response = new __BaseException({
|
|
1574
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1566
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1575
1567
|
$fault: "client",
|
|
1576
|
-
$metadata:
|
|
1568
|
+
$metadata: $metadata,
|
|
1577
1569
|
});
|
|
1578
1570
|
throw __decorateServiceException(response, parsedBody);
|
|
1579
1571
|
}
|
|
@@ -1598,7 +1590,7 @@ export var deserializeAws_restJson1DeleteContentCommand = function (output, cont
|
|
|
1598
1590
|
});
|
|
1599
1591
|
}); };
|
|
1600
1592
|
var deserializeAws_restJson1DeleteContentCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1601
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1593
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1602
1594
|
var _c;
|
|
1603
1595
|
return __generator(this, function (_d) {
|
|
1604
1596
|
switch (_d.label) {
|
|
@@ -1608,7 +1600,6 @@ var deserializeAws_restJson1DeleteContentCommandError = function (output, contex
|
|
|
1608
1600
|
return [4, parseBody(output.body, context)];
|
|
1609
1601
|
case 1:
|
|
1610
1602
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1611
|
-
errorCode = "UnknownError";
|
|
1612
1603
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1613
1604
|
_b = errorCode;
|
|
1614
1605
|
switch (_b) {
|
|
@@ -1628,10 +1619,12 @@ var deserializeAws_restJson1DeleteContentCommandError = function (output, contex
|
|
|
1628
1619
|
case 7: throw _d.sent();
|
|
1629
1620
|
case 8:
|
|
1630
1621
|
parsedBody = parsedOutput.body;
|
|
1622
|
+
$metadata = deserializeMetadata(output);
|
|
1623
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1631
1624
|
response = new __BaseException({
|
|
1632
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1625
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1633
1626
|
$fault: "client",
|
|
1634
|
-
$metadata:
|
|
1627
|
+
$metadata: $metadata,
|
|
1635
1628
|
});
|
|
1636
1629
|
throw __decorateServiceException(response, parsedBody);
|
|
1637
1630
|
}
|
|
@@ -1656,7 +1649,7 @@ export var deserializeAws_restJson1DeleteKnowledgeBaseCommand = function (output
|
|
|
1656
1649
|
});
|
|
1657
1650
|
}); };
|
|
1658
1651
|
var deserializeAws_restJson1DeleteKnowledgeBaseCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1659
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1652
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1660
1653
|
var _c;
|
|
1661
1654
|
return __generator(this, function (_d) {
|
|
1662
1655
|
switch (_d.label) {
|
|
@@ -1666,7 +1659,6 @@ var deserializeAws_restJson1DeleteKnowledgeBaseCommandError = function (output,
|
|
|
1666
1659
|
return [4, parseBody(output.body, context)];
|
|
1667
1660
|
case 1:
|
|
1668
1661
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1669
|
-
errorCode = "UnknownError";
|
|
1670
1662
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1671
1663
|
_b = errorCode;
|
|
1672
1664
|
switch (_b) {
|
|
@@ -1690,10 +1682,12 @@ var deserializeAws_restJson1DeleteKnowledgeBaseCommandError = function (output,
|
|
|
1690
1682
|
case 9: throw _d.sent();
|
|
1691
1683
|
case 10:
|
|
1692
1684
|
parsedBody = parsedOutput.body;
|
|
1685
|
+
$metadata = deserializeMetadata(output);
|
|
1686
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1693
1687
|
response = new __BaseException({
|
|
1694
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1688
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1695
1689
|
$fault: "client",
|
|
1696
|
-
$metadata:
|
|
1690
|
+
$metadata: $metadata,
|
|
1697
1691
|
});
|
|
1698
1692
|
throw __decorateServiceException(response, parsedBody);
|
|
1699
1693
|
}
|
|
@@ -1724,7 +1718,7 @@ export var deserializeAws_restJson1GetAssistantCommand = function (output, conte
|
|
|
1724
1718
|
});
|
|
1725
1719
|
}); };
|
|
1726
1720
|
var deserializeAws_restJson1GetAssistantCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1727
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1721
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1728
1722
|
var _c;
|
|
1729
1723
|
return __generator(this, function (_d) {
|
|
1730
1724
|
switch (_d.label) {
|
|
@@ -1734,7 +1728,6 @@ var deserializeAws_restJson1GetAssistantCommandError = function (output, context
|
|
|
1734
1728
|
return [4, parseBody(output.body, context)];
|
|
1735
1729
|
case 1:
|
|
1736
1730
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1737
|
-
errorCode = "UnknownError";
|
|
1738
1731
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1739
1732
|
_b = errorCode;
|
|
1740
1733
|
switch (_b) {
|
|
@@ -1754,10 +1747,12 @@ var deserializeAws_restJson1GetAssistantCommandError = function (output, context
|
|
|
1754
1747
|
case 7: throw _d.sent();
|
|
1755
1748
|
case 8:
|
|
1756
1749
|
parsedBody = parsedOutput.body;
|
|
1750
|
+
$metadata = deserializeMetadata(output);
|
|
1751
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1757
1752
|
response = new __BaseException({
|
|
1758
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1753
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1759
1754
|
$fault: "client",
|
|
1760
|
-
$metadata:
|
|
1755
|
+
$metadata: $metadata,
|
|
1761
1756
|
});
|
|
1762
1757
|
throw __decorateServiceException(response, parsedBody);
|
|
1763
1758
|
}
|
|
@@ -1788,7 +1783,7 @@ export var deserializeAws_restJson1GetAssistantAssociationCommand = function (ou
|
|
|
1788
1783
|
});
|
|
1789
1784
|
}); };
|
|
1790
1785
|
var deserializeAws_restJson1GetAssistantAssociationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1791
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1786
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1792
1787
|
var _c;
|
|
1793
1788
|
return __generator(this, function (_d) {
|
|
1794
1789
|
switch (_d.label) {
|
|
@@ -1798,7 +1793,6 @@ var deserializeAws_restJson1GetAssistantAssociationCommandError = function (outp
|
|
|
1798
1793
|
return [4, parseBody(output.body, context)];
|
|
1799
1794
|
case 1:
|
|
1800
1795
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1801
|
-
errorCode = "UnknownError";
|
|
1802
1796
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1803
1797
|
_b = errorCode;
|
|
1804
1798
|
switch (_b) {
|
|
@@ -1818,10 +1812,12 @@ var deserializeAws_restJson1GetAssistantAssociationCommandError = function (outp
|
|
|
1818
1812
|
case 7: throw _d.sent();
|
|
1819
1813
|
case 8:
|
|
1820
1814
|
parsedBody = parsedOutput.body;
|
|
1815
|
+
$metadata = deserializeMetadata(output);
|
|
1816
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1821
1817
|
response = new __BaseException({
|
|
1822
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1818
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1823
1819
|
$fault: "client",
|
|
1824
|
-
$metadata:
|
|
1820
|
+
$metadata: $metadata,
|
|
1825
1821
|
});
|
|
1826
1822
|
throw __decorateServiceException(response, parsedBody);
|
|
1827
1823
|
}
|
|
@@ -1852,7 +1848,7 @@ export var deserializeAws_restJson1GetContentCommand = function (output, context
|
|
|
1852
1848
|
});
|
|
1853
1849
|
}); };
|
|
1854
1850
|
var deserializeAws_restJson1GetContentCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1855
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1851
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1856
1852
|
var _c;
|
|
1857
1853
|
return __generator(this, function (_d) {
|
|
1858
1854
|
switch (_d.label) {
|
|
@@ -1862,7 +1858,6 @@ var deserializeAws_restJson1GetContentCommandError = function (output, context)
|
|
|
1862
1858
|
return [4, parseBody(output.body, context)];
|
|
1863
1859
|
case 1:
|
|
1864
1860
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1865
|
-
errorCode = "UnknownError";
|
|
1866
1861
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1867
1862
|
_b = errorCode;
|
|
1868
1863
|
switch (_b) {
|
|
@@ -1882,10 +1877,12 @@ var deserializeAws_restJson1GetContentCommandError = function (output, context)
|
|
|
1882
1877
|
case 7: throw _d.sent();
|
|
1883
1878
|
case 8:
|
|
1884
1879
|
parsedBody = parsedOutput.body;
|
|
1880
|
+
$metadata = deserializeMetadata(output);
|
|
1881
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1885
1882
|
response = new __BaseException({
|
|
1886
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1883
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1887
1884
|
$fault: "client",
|
|
1888
|
-
$metadata:
|
|
1885
|
+
$metadata: $metadata,
|
|
1889
1886
|
});
|
|
1890
1887
|
throw __decorateServiceException(response, parsedBody);
|
|
1891
1888
|
}
|
|
@@ -1916,7 +1913,7 @@ export var deserializeAws_restJson1GetContentSummaryCommand = function (output,
|
|
|
1916
1913
|
});
|
|
1917
1914
|
}); };
|
|
1918
1915
|
var deserializeAws_restJson1GetContentSummaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1919
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1916
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1920
1917
|
var _c;
|
|
1921
1918
|
return __generator(this, function (_d) {
|
|
1922
1919
|
switch (_d.label) {
|
|
@@ -1926,7 +1923,6 @@ var deserializeAws_restJson1GetContentSummaryCommandError = function (output, co
|
|
|
1926
1923
|
return [4, parseBody(output.body, context)];
|
|
1927
1924
|
case 1:
|
|
1928
1925
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1929
|
-
errorCode = "UnknownError";
|
|
1930
1926
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1931
1927
|
_b = errorCode;
|
|
1932
1928
|
switch (_b) {
|
|
@@ -1946,10 +1942,12 @@ var deserializeAws_restJson1GetContentSummaryCommandError = function (output, co
|
|
|
1946
1942
|
case 7: throw _d.sent();
|
|
1947
1943
|
case 8:
|
|
1948
1944
|
parsedBody = parsedOutput.body;
|
|
1945
|
+
$metadata = deserializeMetadata(output);
|
|
1946
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1949
1947
|
response = new __BaseException({
|
|
1950
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1948
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1951
1949
|
$fault: "client",
|
|
1952
|
-
$metadata:
|
|
1950
|
+
$metadata: $metadata,
|
|
1953
1951
|
});
|
|
1954
1952
|
throw __decorateServiceException(response, parsedBody);
|
|
1955
1953
|
}
|
|
@@ -1980,7 +1978,7 @@ export var deserializeAws_restJson1GetKnowledgeBaseCommand = function (output, c
|
|
|
1980
1978
|
});
|
|
1981
1979
|
}); };
|
|
1982
1980
|
var deserializeAws_restJson1GetKnowledgeBaseCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1983
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1981
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1984
1982
|
var _c;
|
|
1985
1983
|
return __generator(this, function (_d) {
|
|
1986
1984
|
switch (_d.label) {
|
|
@@ -1990,7 +1988,6 @@ var deserializeAws_restJson1GetKnowledgeBaseCommandError = function (output, con
|
|
|
1990
1988
|
return [4, parseBody(output.body, context)];
|
|
1991
1989
|
case 1:
|
|
1992
1990
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1993
|
-
errorCode = "UnknownError";
|
|
1994
1991
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1995
1992
|
_b = errorCode;
|
|
1996
1993
|
switch (_b) {
|
|
@@ -2010,10 +2007,12 @@ var deserializeAws_restJson1GetKnowledgeBaseCommandError = function (output, con
|
|
|
2010
2007
|
case 7: throw _d.sent();
|
|
2011
2008
|
case 8:
|
|
2012
2009
|
parsedBody = parsedOutput.body;
|
|
2010
|
+
$metadata = deserializeMetadata(output);
|
|
2011
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2013
2012
|
response = new __BaseException({
|
|
2014
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2013
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2015
2014
|
$fault: "client",
|
|
2016
|
-
$metadata:
|
|
2015
|
+
$metadata: $metadata,
|
|
2017
2016
|
});
|
|
2018
2017
|
throw __decorateServiceException(response, parsedBody);
|
|
2019
2018
|
}
|
|
@@ -2048,7 +2047,7 @@ export var deserializeAws_restJson1GetRecommendationsCommand = function (output,
|
|
|
2048
2047
|
});
|
|
2049
2048
|
}); };
|
|
2050
2049
|
var deserializeAws_restJson1GetRecommendationsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2051
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2050
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2052
2051
|
var _c;
|
|
2053
2052
|
return __generator(this, function (_d) {
|
|
2054
2053
|
switch (_d.label) {
|
|
@@ -2058,7 +2057,6 @@ var deserializeAws_restJson1GetRecommendationsCommandError = function (output, c
|
|
|
2058
2057
|
return [4, parseBody(output.body, context)];
|
|
2059
2058
|
case 1:
|
|
2060
2059
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2061
|
-
errorCode = "UnknownError";
|
|
2062
2060
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2063
2061
|
_b = errorCode;
|
|
2064
2062
|
switch (_b) {
|
|
@@ -2078,10 +2076,12 @@ var deserializeAws_restJson1GetRecommendationsCommandError = function (output, c
|
|
|
2078
2076
|
case 7: throw _d.sent();
|
|
2079
2077
|
case 8:
|
|
2080
2078
|
parsedBody = parsedOutput.body;
|
|
2079
|
+
$metadata = deserializeMetadata(output);
|
|
2080
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2081
2081
|
response = new __BaseException({
|
|
2082
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2082
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2083
2083
|
$fault: "client",
|
|
2084
|
-
$metadata:
|
|
2084
|
+
$metadata: $metadata,
|
|
2085
2085
|
});
|
|
2086
2086
|
throw __decorateServiceException(response, parsedBody);
|
|
2087
2087
|
}
|
|
@@ -2112,7 +2112,7 @@ export var deserializeAws_restJson1GetSessionCommand = function (output, context
|
|
|
2112
2112
|
});
|
|
2113
2113
|
}); };
|
|
2114
2114
|
var deserializeAws_restJson1GetSessionCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2115
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2115
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2116
2116
|
var _c;
|
|
2117
2117
|
return __generator(this, function (_d) {
|
|
2118
2118
|
switch (_d.label) {
|
|
@@ -2122,7 +2122,6 @@ var deserializeAws_restJson1GetSessionCommandError = function (output, context)
|
|
|
2122
2122
|
return [4, parseBody(output.body, context)];
|
|
2123
2123
|
case 1:
|
|
2124
2124
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2125
|
-
errorCode = "UnknownError";
|
|
2126
2125
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2127
2126
|
_b = errorCode;
|
|
2128
2127
|
switch (_b) {
|
|
@@ -2142,10 +2141,12 @@ var deserializeAws_restJson1GetSessionCommandError = function (output, context)
|
|
|
2142
2141
|
case 7: throw _d.sent();
|
|
2143
2142
|
case 8:
|
|
2144
2143
|
parsedBody = parsedOutput.body;
|
|
2144
|
+
$metadata = deserializeMetadata(output);
|
|
2145
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2145
2146
|
response = new __BaseException({
|
|
2146
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2147
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2147
2148
|
$fault: "client",
|
|
2148
|
-
$metadata:
|
|
2149
|
+
$metadata: $metadata,
|
|
2149
2150
|
});
|
|
2150
2151
|
throw __decorateServiceException(response, parsedBody);
|
|
2151
2152
|
}
|
|
@@ -2180,7 +2181,7 @@ export var deserializeAws_restJson1ListAssistantAssociationsCommand = function (
|
|
|
2180
2181
|
});
|
|
2181
2182
|
}); };
|
|
2182
2183
|
var deserializeAws_restJson1ListAssistantAssociationsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2183
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2184
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2184
2185
|
var _c;
|
|
2185
2186
|
return __generator(this, function (_d) {
|
|
2186
2187
|
switch (_d.label) {
|
|
@@ -2190,7 +2191,6 @@ var deserializeAws_restJson1ListAssistantAssociationsCommandError = function (ou
|
|
|
2190
2191
|
return [4, parseBody(output.body, context)];
|
|
2191
2192
|
case 1:
|
|
2192
2193
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2193
|
-
errorCode = "UnknownError";
|
|
2194
2194
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2195
2195
|
_b = errorCode;
|
|
2196
2196
|
switch (_b) {
|
|
@@ -2210,10 +2210,12 @@ var deserializeAws_restJson1ListAssistantAssociationsCommandError = function (ou
|
|
|
2210
2210
|
case 7: throw _d.sent();
|
|
2211
2211
|
case 8:
|
|
2212
2212
|
parsedBody = parsedOutput.body;
|
|
2213
|
+
$metadata = deserializeMetadata(output);
|
|
2214
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2213
2215
|
response = new __BaseException({
|
|
2214
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2216
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2215
2217
|
$fault: "client",
|
|
2216
|
-
$metadata:
|
|
2218
|
+
$metadata: $metadata,
|
|
2217
2219
|
});
|
|
2218
2220
|
throw __decorateServiceException(response, parsedBody);
|
|
2219
2221
|
}
|
|
@@ -2248,7 +2250,7 @@ export var deserializeAws_restJson1ListAssistantsCommand = function (output, con
|
|
|
2248
2250
|
});
|
|
2249
2251
|
}); };
|
|
2250
2252
|
var deserializeAws_restJson1ListAssistantsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2251
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2253
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2252
2254
|
var _c;
|
|
2253
2255
|
return __generator(this, function (_d) {
|
|
2254
2256
|
switch (_d.label) {
|
|
@@ -2258,7 +2260,6 @@ var deserializeAws_restJson1ListAssistantsCommandError = function (output, conte
|
|
|
2258
2260
|
return [4, parseBody(output.body, context)];
|
|
2259
2261
|
case 1:
|
|
2260
2262
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2261
|
-
errorCode = "UnknownError";
|
|
2262
2263
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2263
2264
|
_b = errorCode;
|
|
2264
2265
|
switch (_b) {
|
|
@@ -2274,10 +2275,12 @@ var deserializeAws_restJson1ListAssistantsCommandError = function (output, conte
|
|
|
2274
2275
|
case 5: throw _d.sent();
|
|
2275
2276
|
case 6:
|
|
2276
2277
|
parsedBody = parsedOutput.body;
|
|
2278
|
+
$metadata = deserializeMetadata(output);
|
|
2279
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2277
2280
|
response = new __BaseException({
|
|
2278
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2281
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2279
2282
|
$fault: "client",
|
|
2280
|
-
$metadata:
|
|
2283
|
+
$metadata: $metadata,
|
|
2281
2284
|
});
|
|
2282
2285
|
throw __decorateServiceException(response, parsedBody);
|
|
2283
2286
|
}
|
|
@@ -2312,7 +2315,7 @@ export var deserializeAws_restJson1ListContentsCommand = function (output, conte
|
|
|
2312
2315
|
});
|
|
2313
2316
|
}); };
|
|
2314
2317
|
var deserializeAws_restJson1ListContentsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2315
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2318
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2316
2319
|
var _c;
|
|
2317
2320
|
return __generator(this, function (_d) {
|
|
2318
2321
|
switch (_d.label) {
|
|
@@ -2322,7 +2325,6 @@ var deserializeAws_restJson1ListContentsCommandError = function (output, context
|
|
|
2322
2325
|
return [4, parseBody(output.body, context)];
|
|
2323
2326
|
case 1:
|
|
2324
2327
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2325
|
-
errorCode = "UnknownError";
|
|
2326
2328
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2327
2329
|
_b = errorCode;
|
|
2328
2330
|
switch (_b) {
|
|
@@ -2342,10 +2344,12 @@ var deserializeAws_restJson1ListContentsCommandError = function (output, context
|
|
|
2342
2344
|
case 7: throw _d.sent();
|
|
2343
2345
|
case 8:
|
|
2344
2346
|
parsedBody = parsedOutput.body;
|
|
2347
|
+
$metadata = deserializeMetadata(output);
|
|
2348
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2345
2349
|
response = new __BaseException({
|
|
2346
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2350
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2347
2351
|
$fault: "client",
|
|
2348
|
-
$metadata:
|
|
2352
|
+
$metadata: $metadata,
|
|
2349
2353
|
});
|
|
2350
2354
|
throw __decorateServiceException(response, parsedBody);
|
|
2351
2355
|
}
|
|
@@ -2380,7 +2384,7 @@ export var deserializeAws_restJson1ListKnowledgeBasesCommand = function (output,
|
|
|
2380
2384
|
});
|
|
2381
2385
|
}); };
|
|
2382
2386
|
var deserializeAws_restJson1ListKnowledgeBasesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2383
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2387
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2384
2388
|
var _c;
|
|
2385
2389
|
return __generator(this, function (_d) {
|
|
2386
2390
|
switch (_d.label) {
|
|
@@ -2390,7 +2394,6 @@ var deserializeAws_restJson1ListKnowledgeBasesCommandError = function (output, c
|
|
|
2390
2394
|
return [4, parseBody(output.body, context)];
|
|
2391
2395
|
case 1:
|
|
2392
2396
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2393
|
-
errorCode = "UnknownError";
|
|
2394
2397
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2395
2398
|
_b = errorCode;
|
|
2396
2399
|
switch (_b) {
|
|
@@ -2406,10 +2409,12 @@ var deserializeAws_restJson1ListKnowledgeBasesCommandError = function (output, c
|
|
|
2406
2409
|
case 5: throw _d.sent();
|
|
2407
2410
|
case 6:
|
|
2408
2411
|
parsedBody = parsedOutput.body;
|
|
2412
|
+
$metadata = deserializeMetadata(output);
|
|
2413
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2409
2414
|
response = new __BaseException({
|
|
2410
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2415
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2411
2416
|
$fault: "client",
|
|
2412
|
-
$metadata:
|
|
2417
|
+
$metadata: $metadata,
|
|
2413
2418
|
});
|
|
2414
2419
|
throw __decorateServiceException(response, parsedBody);
|
|
2415
2420
|
}
|
|
@@ -2440,7 +2445,7 @@ export var deserializeAws_restJson1ListTagsForResourceCommand = function (output
|
|
|
2440
2445
|
});
|
|
2441
2446
|
}); };
|
|
2442
2447
|
var deserializeAws_restJson1ListTagsForResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2443
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2448
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2444
2449
|
var _c;
|
|
2445
2450
|
return __generator(this, function (_d) {
|
|
2446
2451
|
switch (_d.label) {
|
|
@@ -2450,7 +2455,6 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
|
|
|
2450
2455
|
return [4, parseBody(output.body, context)];
|
|
2451
2456
|
case 1:
|
|
2452
2457
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2453
|
-
errorCode = "UnknownError";
|
|
2454
2458
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2455
2459
|
_b = errorCode;
|
|
2456
2460
|
switch (_b) {
|
|
@@ -2462,10 +2466,12 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
|
|
|
2462
2466
|
case 3: throw _d.sent();
|
|
2463
2467
|
case 4:
|
|
2464
2468
|
parsedBody = parsedOutput.body;
|
|
2469
|
+
$metadata = deserializeMetadata(output);
|
|
2470
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2465
2471
|
response = new __BaseException({
|
|
2466
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2472
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2467
2473
|
$fault: "client",
|
|
2468
|
-
$metadata:
|
|
2474
|
+
$metadata: $metadata,
|
|
2469
2475
|
});
|
|
2470
2476
|
throw __decorateServiceException(response, parsedBody);
|
|
2471
2477
|
}
|
|
@@ -2500,7 +2506,7 @@ export var deserializeAws_restJson1NotifyRecommendationsReceivedCommand = functi
|
|
|
2500
2506
|
});
|
|
2501
2507
|
}); };
|
|
2502
2508
|
var deserializeAws_restJson1NotifyRecommendationsReceivedCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2503
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2509
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2504
2510
|
var _c;
|
|
2505
2511
|
return __generator(this, function (_d) {
|
|
2506
2512
|
switch (_d.label) {
|
|
@@ -2510,7 +2516,6 @@ var deserializeAws_restJson1NotifyRecommendationsReceivedCommandError = function
|
|
|
2510
2516
|
return [4, parseBody(output.body, context)];
|
|
2511
2517
|
case 1:
|
|
2512
2518
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2513
|
-
errorCode = "UnknownError";
|
|
2514
2519
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2515
2520
|
_b = errorCode;
|
|
2516
2521
|
switch (_b) {
|
|
@@ -2530,10 +2535,12 @@ var deserializeAws_restJson1NotifyRecommendationsReceivedCommandError = function
|
|
|
2530
2535
|
case 7: throw _d.sent();
|
|
2531
2536
|
case 8:
|
|
2532
2537
|
parsedBody = parsedOutput.body;
|
|
2538
|
+
$metadata = deserializeMetadata(output);
|
|
2539
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2533
2540
|
response = new __BaseException({
|
|
2534
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2541
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2535
2542
|
$fault: "client",
|
|
2536
|
-
$metadata:
|
|
2543
|
+
$metadata: $metadata,
|
|
2537
2544
|
});
|
|
2538
2545
|
throw __decorateServiceException(response, parsedBody);
|
|
2539
2546
|
}
|
|
@@ -2568,7 +2575,7 @@ export var deserializeAws_restJson1QueryAssistantCommand = function (output, con
|
|
|
2568
2575
|
});
|
|
2569
2576
|
}); };
|
|
2570
2577
|
var deserializeAws_restJson1QueryAssistantCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2571
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2578
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2572
2579
|
var _c;
|
|
2573
2580
|
return __generator(this, function (_d) {
|
|
2574
2581
|
switch (_d.label) {
|
|
@@ -2578,7 +2585,6 @@ var deserializeAws_restJson1QueryAssistantCommandError = function (output, conte
|
|
|
2578
2585
|
return [4, parseBody(output.body, context)];
|
|
2579
2586
|
case 1:
|
|
2580
2587
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2581
|
-
errorCode = "UnknownError";
|
|
2582
2588
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2583
2589
|
_b = errorCode;
|
|
2584
2590
|
switch (_b) {
|
|
@@ -2598,10 +2604,12 @@ var deserializeAws_restJson1QueryAssistantCommandError = function (output, conte
|
|
|
2598
2604
|
case 7: throw _d.sent();
|
|
2599
2605
|
case 8:
|
|
2600
2606
|
parsedBody = parsedOutput.body;
|
|
2607
|
+
$metadata = deserializeMetadata(output);
|
|
2608
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2601
2609
|
response = new __BaseException({
|
|
2602
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2610
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2603
2611
|
$fault: "client",
|
|
2604
|
-
$metadata:
|
|
2612
|
+
$metadata: $metadata,
|
|
2605
2613
|
});
|
|
2606
2614
|
throw __decorateServiceException(response, parsedBody);
|
|
2607
2615
|
}
|
|
@@ -2626,7 +2634,7 @@ export var deserializeAws_restJson1RemoveKnowledgeBaseTemplateUriCommand = funct
|
|
|
2626
2634
|
});
|
|
2627
2635
|
}); };
|
|
2628
2636
|
var deserializeAws_restJson1RemoveKnowledgeBaseTemplateUriCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2629
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2637
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2630
2638
|
var _c;
|
|
2631
2639
|
return __generator(this, function (_d) {
|
|
2632
2640
|
switch (_d.label) {
|
|
@@ -2636,7 +2644,6 @@ var deserializeAws_restJson1RemoveKnowledgeBaseTemplateUriCommandError = functio
|
|
|
2636
2644
|
return [4, parseBody(output.body, context)];
|
|
2637
2645
|
case 1:
|
|
2638
2646
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2639
|
-
errorCode = "UnknownError";
|
|
2640
2647
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2641
2648
|
_b = errorCode;
|
|
2642
2649
|
switch (_b) {
|
|
@@ -2656,10 +2663,12 @@ var deserializeAws_restJson1RemoveKnowledgeBaseTemplateUriCommandError = functio
|
|
|
2656
2663
|
case 7: throw _d.sent();
|
|
2657
2664
|
case 8:
|
|
2658
2665
|
parsedBody = parsedOutput.body;
|
|
2666
|
+
$metadata = deserializeMetadata(output);
|
|
2667
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2659
2668
|
response = new __BaseException({
|
|
2660
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2669
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2661
2670
|
$fault: "client",
|
|
2662
|
-
$metadata:
|
|
2671
|
+
$metadata: $metadata,
|
|
2663
2672
|
});
|
|
2664
2673
|
throw __decorateServiceException(response, parsedBody);
|
|
2665
2674
|
}
|
|
@@ -2694,7 +2703,7 @@ export var deserializeAws_restJson1SearchContentCommand = function (output, cont
|
|
|
2694
2703
|
});
|
|
2695
2704
|
}); };
|
|
2696
2705
|
var deserializeAws_restJson1SearchContentCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2697
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2706
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2698
2707
|
var _c;
|
|
2699
2708
|
return __generator(this, function (_d) {
|
|
2700
2709
|
switch (_d.label) {
|
|
@@ -2704,7 +2713,6 @@ var deserializeAws_restJson1SearchContentCommandError = function (output, contex
|
|
|
2704
2713
|
return [4, parseBody(output.body, context)];
|
|
2705
2714
|
case 1:
|
|
2706
2715
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2707
|
-
errorCode = "UnknownError";
|
|
2708
2716
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2709
2717
|
_b = errorCode;
|
|
2710
2718
|
switch (_b) {
|
|
@@ -2724,10 +2732,12 @@ var deserializeAws_restJson1SearchContentCommandError = function (output, contex
|
|
|
2724
2732
|
case 7: throw _d.sent();
|
|
2725
2733
|
case 8:
|
|
2726
2734
|
parsedBody = parsedOutput.body;
|
|
2735
|
+
$metadata = deserializeMetadata(output);
|
|
2736
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2727
2737
|
response = new __BaseException({
|
|
2728
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2738
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2729
2739
|
$fault: "client",
|
|
2730
|
-
$metadata:
|
|
2740
|
+
$metadata: $metadata,
|
|
2731
2741
|
});
|
|
2732
2742
|
throw __decorateServiceException(response, parsedBody);
|
|
2733
2743
|
}
|
|
@@ -2762,7 +2772,7 @@ export var deserializeAws_restJson1SearchSessionsCommand = function (output, con
|
|
|
2762
2772
|
});
|
|
2763
2773
|
}); };
|
|
2764
2774
|
var deserializeAws_restJson1SearchSessionsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2765
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2775
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2766
2776
|
var _c;
|
|
2767
2777
|
return __generator(this, function (_d) {
|
|
2768
2778
|
switch (_d.label) {
|
|
@@ -2772,7 +2782,6 @@ var deserializeAws_restJson1SearchSessionsCommandError = function (output, conte
|
|
|
2772
2782
|
return [4, parseBody(output.body, context)];
|
|
2773
2783
|
case 1:
|
|
2774
2784
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2775
|
-
errorCode = "UnknownError";
|
|
2776
2785
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2777
2786
|
_b = errorCode;
|
|
2778
2787
|
switch (_b) {
|
|
@@ -2792,10 +2801,12 @@ var deserializeAws_restJson1SearchSessionsCommandError = function (output, conte
|
|
|
2792
2801
|
case 7: throw _d.sent();
|
|
2793
2802
|
case 8:
|
|
2794
2803
|
parsedBody = parsedOutput.body;
|
|
2804
|
+
$metadata = deserializeMetadata(output);
|
|
2805
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2795
2806
|
response = new __BaseException({
|
|
2796
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2807
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2797
2808
|
$fault: "client",
|
|
2798
|
-
$metadata:
|
|
2809
|
+
$metadata: $metadata,
|
|
2799
2810
|
});
|
|
2800
2811
|
throw __decorateServiceException(response, parsedBody);
|
|
2801
2812
|
}
|
|
@@ -2838,7 +2849,7 @@ export var deserializeAws_restJson1StartContentUploadCommand = function (output,
|
|
|
2838
2849
|
});
|
|
2839
2850
|
}); };
|
|
2840
2851
|
var deserializeAws_restJson1StartContentUploadCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2841
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2852
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2842
2853
|
var _c;
|
|
2843
2854
|
return __generator(this, function (_d) {
|
|
2844
2855
|
switch (_d.label) {
|
|
@@ -2848,7 +2859,6 @@ var deserializeAws_restJson1StartContentUploadCommandError = function (output, c
|
|
|
2848
2859
|
return [4, parseBody(output.body, context)];
|
|
2849
2860
|
case 1:
|
|
2850
2861
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2851
|
-
errorCode = "UnknownError";
|
|
2852
2862
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2853
2863
|
_b = errorCode;
|
|
2854
2864
|
switch (_b) {
|
|
@@ -2868,10 +2878,12 @@ var deserializeAws_restJson1StartContentUploadCommandError = function (output, c
|
|
|
2868
2878
|
case 7: throw _d.sent();
|
|
2869
2879
|
case 8:
|
|
2870
2880
|
parsedBody = parsedOutput.body;
|
|
2881
|
+
$metadata = deserializeMetadata(output);
|
|
2882
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2871
2883
|
response = new __BaseException({
|
|
2872
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2884
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2873
2885
|
$fault: "client",
|
|
2874
|
-
$metadata:
|
|
2886
|
+
$metadata: $metadata,
|
|
2875
2887
|
});
|
|
2876
2888
|
throw __decorateServiceException(response, parsedBody);
|
|
2877
2889
|
}
|
|
@@ -2896,7 +2908,7 @@ export var deserializeAws_restJson1TagResourceCommand = function (output, contex
|
|
|
2896
2908
|
});
|
|
2897
2909
|
}); };
|
|
2898
2910
|
var deserializeAws_restJson1TagResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2899
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2911
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2900
2912
|
var _c;
|
|
2901
2913
|
return __generator(this, function (_d) {
|
|
2902
2914
|
switch (_d.label) {
|
|
@@ -2906,7 +2918,6 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
|
|
|
2906
2918
|
return [4, parseBody(output.body, context)];
|
|
2907
2919
|
case 1:
|
|
2908
2920
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2909
|
-
errorCode = "UnknownError";
|
|
2910
2921
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2911
2922
|
_b = errorCode;
|
|
2912
2923
|
switch (_b) {
|
|
@@ -2922,10 +2933,12 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
|
|
|
2922
2933
|
case 5: throw _d.sent();
|
|
2923
2934
|
case 6:
|
|
2924
2935
|
parsedBody = parsedOutput.body;
|
|
2936
|
+
$metadata = deserializeMetadata(output);
|
|
2937
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2925
2938
|
response = new __BaseException({
|
|
2926
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2939
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2927
2940
|
$fault: "client",
|
|
2928
|
-
$metadata:
|
|
2941
|
+
$metadata: $metadata,
|
|
2929
2942
|
});
|
|
2930
2943
|
throw __decorateServiceException(response, parsedBody);
|
|
2931
2944
|
}
|
|
@@ -2950,7 +2963,7 @@ export var deserializeAws_restJson1UntagResourceCommand = function (output, cont
|
|
|
2950
2963
|
});
|
|
2951
2964
|
}); };
|
|
2952
2965
|
var deserializeAws_restJson1UntagResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2953
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
2966
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
2954
2967
|
var _c;
|
|
2955
2968
|
return __generator(this, function (_d) {
|
|
2956
2969
|
switch (_d.label) {
|
|
@@ -2960,7 +2973,6 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
|
|
|
2960
2973
|
return [4, parseBody(output.body, context)];
|
|
2961
2974
|
case 1:
|
|
2962
2975
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2963
|
-
errorCode = "UnknownError";
|
|
2964
2976
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2965
2977
|
_b = errorCode;
|
|
2966
2978
|
switch (_b) {
|
|
@@ -2972,10 +2984,12 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
|
|
|
2972
2984
|
case 3: throw _d.sent();
|
|
2973
2985
|
case 4:
|
|
2974
2986
|
parsedBody = parsedOutput.body;
|
|
2987
|
+
$metadata = deserializeMetadata(output);
|
|
2988
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
2975
2989
|
response = new __BaseException({
|
|
2976
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2990
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
2977
2991
|
$fault: "client",
|
|
2978
|
-
$metadata:
|
|
2992
|
+
$metadata: $metadata,
|
|
2979
2993
|
});
|
|
2980
2994
|
throw __decorateServiceException(response, parsedBody);
|
|
2981
2995
|
}
|
|
@@ -3006,7 +3020,7 @@ export var deserializeAws_restJson1UpdateContentCommand = function (output, cont
|
|
|
3006
3020
|
});
|
|
3007
3021
|
}); };
|
|
3008
3022
|
var deserializeAws_restJson1UpdateContentCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3009
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
3023
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
3010
3024
|
var _c;
|
|
3011
3025
|
return __generator(this, function (_d) {
|
|
3012
3026
|
switch (_d.label) {
|
|
@@ -3016,7 +3030,6 @@ var deserializeAws_restJson1UpdateContentCommandError = function (output, contex
|
|
|
3016
3030
|
return [4, parseBody(output.body, context)];
|
|
3017
3031
|
case 1:
|
|
3018
3032
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
3019
|
-
errorCode = "UnknownError";
|
|
3020
3033
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3021
3034
|
_b = errorCode;
|
|
3022
3035
|
switch (_b) {
|
|
@@ -3040,10 +3053,12 @@ var deserializeAws_restJson1UpdateContentCommandError = function (output, contex
|
|
|
3040
3053
|
case 9: throw _d.sent();
|
|
3041
3054
|
case 10:
|
|
3042
3055
|
parsedBody = parsedOutput.body;
|
|
3056
|
+
$metadata = deserializeMetadata(output);
|
|
3057
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
3043
3058
|
response = new __BaseException({
|
|
3044
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
3059
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
3045
3060
|
$fault: "client",
|
|
3046
|
-
$metadata:
|
|
3061
|
+
$metadata: $metadata,
|
|
3047
3062
|
});
|
|
3048
3063
|
throw __decorateServiceException(response, parsedBody);
|
|
3049
3064
|
}
|
|
@@ -3074,7 +3089,7 @@ export var deserializeAws_restJson1UpdateKnowledgeBaseTemplateUriCommand = funct
|
|
|
3074
3089
|
});
|
|
3075
3090
|
}); };
|
|
3076
3091
|
var deserializeAws_restJson1UpdateKnowledgeBaseTemplateUriCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
3077
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
3092
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
3078
3093
|
var _c;
|
|
3079
3094
|
return __generator(this, function (_d) {
|
|
3080
3095
|
switch (_d.label) {
|
|
@@ -3084,7 +3099,6 @@ var deserializeAws_restJson1UpdateKnowledgeBaseTemplateUriCommandError = functio
|
|
|
3084
3099
|
return [4, parseBody(output.body, context)];
|
|
3085
3100
|
case 1:
|
|
3086
3101
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
3087
|
-
errorCode = "UnknownError";
|
|
3088
3102
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3089
3103
|
_b = errorCode;
|
|
3090
3104
|
switch (_b) {
|
|
@@ -3104,10 +3118,12 @@ var deserializeAws_restJson1UpdateKnowledgeBaseTemplateUriCommandError = functio
|
|
|
3104
3118
|
case 7: throw _d.sent();
|
|
3105
3119
|
case 8:
|
|
3106
3120
|
parsedBody = parsedOutput.body;
|
|
3121
|
+
$metadata = deserializeMetadata(output);
|
|
3122
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
3107
3123
|
response = new __BaseException({
|
|
3108
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
3124
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
3109
3125
|
$fault: "client",
|
|
3110
|
-
$metadata:
|
|
3126
|
+
$metadata: $metadata,
|
|
3111
3127
|
});
|
|
3112
3128
|
throw __decorateServiceException(response, parsedBody);
|
|
3113
3129
|
}
|
|
@@ -3204,9 +3220,7 @@ var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput
|
|
|
3204
3220
|
});
|
|
3205
3221
|
}); };
|
|
3206
3222
|
var serializeAws_restJson1AppIntegrationsConfiguration = function (input, context) {
|
|
3207
|
-
return __assign(__assign({}, (input.appIntegrationArn
|
|
3208
|
-
input.appIntegrationArn !== null && { appIntegrationArn: input.appIntegrationArn })), (input.objectFields !== undefined &&
|
|
3209
|
-
input.objectFields !== null && {
|
|
3223
|
+
return __assign(__assign({}, (input.appIntegrationArn != null && { appIntegrationArn: input.appIntegrationArn })), (input.objectFields != null && {
|
|
3210
3224
|
objectFields: serializeAws_restJson1ObjectFieldsList(input.objectFields, context),
|
|
3211
3225
|
}));
|
|
3212
3226
|
};
|
|
@@ -3227,7 +3241,7 @@ var serializeAws_restJson1ContentMetadata = function (input, context) {
|
|
|
3227
3241
|
}, {});
|
|
3228
3242
|
};
|
|
3229
3243
|
var serializeAws_restJson1Filter = function (input, context) {
|
|
3230
|
-
return __assign(__assign(__assign({}, (input.field
|
|
3244
|
+
return __assign(__assign(__assign({}, (input.field != null && { field: input.field })), (input.operator != null && { operator: input.operator })), (input.value != null && { value: input.value }));
|
|
3231
3245
|
};
|
|
3232
3246
|
var serializeAws_restJson1FilterList = function (input, context) {
|
|
3233
3247
|
return input
|
|
@@ -3260,14 +3274,13 @@ var serializeAws_restJson1RecommendationIdList = function (input, context) {
|
|
|
3260
3274
|
});
|
|
3261
3275
|
};
|
|
3262
3276
|
var serializeAws_restJson1RenderingConfiguration = function (input, context) {
|
|
3263
|
-
return __assign({}, (input.templateUri
|
|
3277
|
+
return __assign({}, (input.templateUri != null && { templateUri: input.templateUri }));
|
|
3264
3278
|
};
|
|
3265
3279
|
var serializeAws_restJson1SearchExpression = function (input, context) {
|
|
3266
|
-
return __assign({}, (input.filters
|
|
3267
|
-
input.filters !== null && { filters: serializeAws_restJson1FilterList(input.filters, context) }));
|
|
3280
|
+
return __assign({}, (input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }));
|
|
3268
3281
|
};
|
|
3269
3282
|
var serializeAws_restJson1ServerSideEncryptionConfiguration = function (input, context) {
|
|
3270
|
-
return __assign({}, (input.kmsKeyId
|
|
3283
|
+
return __assign({}, (input.kmsKeyId != null && { kmsKeyId: input.kmsKeyId }));
|
|
3271
3284
|
};
|
|
3272
3285
|
var serializeAws_restJson1SourceConfiguration = function (input, context) {
|
|
3273
3286
|
return SourceConfiguration.visit(input, {
|
|
@@ -3290,9 +3303,7 @@ var serializeAws_restJson1Tags = function (input, context) {
|
|
|
3290
3303
|
var deserializeAws_restJson1AppIntegrationsConfiguration = function (output, context) {
|
|
3291
3304
|
return {
|
|
3292
3305
|
appIntegrationArn: __expectString(output.appIntegrationArn),
|
|
3293
|
-
objectFields: output.objectFields
|
|
3294
|
-
? deserializeAws_restJson1ObjectFieldsList(output.objectFields, context)
|
|
3295
|
-
: undefined,
|
|
3306
|
+
objectFields: output.objectFields != null ? deserializeAws_restJson1ObjectFieldsList(output.objectFields, context) : undefined,
|
|
3296
3307
|
};
|
|
3297
3308
|
};
|
|
3298
3309
|
var deserializeAws_restJson1AssistantAssociationData = function (output, context) {
|
|
@@ -3301,13 +3312,11 @@ var deserializeAws_restJson1AssistantAssociationData = function (output, context
|
|
|
3301
3312
|
assistantAssociationArn: __expectString(output.assistantAssociationArn),
|
|
3302
3313
|
assistantAssociationId: __expectString(output.assistantAssociationId),
|
|
3303
3314
|
assistantId: __expectString(output.assistantId),
|
|
3304
|
-
associationData: output.associationData
|
|
3315
|
+
associationData: output.associationData != null
|
|
3305
3316
|
? deserializeAws_restJson1AssistantAssociationOutputData(__expectUnion(output.associationData), context)
|
|
3306
3317
|
: undefined,
|
|
3307
3318
|
associationType: __expectString(output.associationType),
|
|
3308
|
-
tags: output.tags
|
|
3309
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3310
|
-
: undefined,
|
|
3319
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3311
3320
|
};
|
|
3312
3321
|
};
|
|
3313
3322
|
var deserializeAws_restJson1AssistantAssociationOutputData = function (output, context) {
|
|
@@ -3324,13 +3333,11 @@ var deserializeAws_restJson1AssistantAssociationSummary = function (output, cont
|
|
|
3324
3333
|
assistantAssociationArn: __expectString(output.assistantAssociationArn),
|
|
3325
3334
|
assistantAssociationId: __expectString(output.assistantAssociationId),
|
|
3326
3335
|
assistantId: __expectString(output.assistantId),
|
|
3327
|
-
associationData: output.associationData
|
|
3336
|
+
associationData: output.associationData != null
|
|
3328
3337
|
? deserializeAws_restJson1AssistantAssociationOutputData(__expectUnion(output.associationData), context)
|
|
3329
3338
|
: undefined,
|
|
3330
3339
|
associationType: __expectString(output.associationType),
|
|
3331
|
-
tags: output.tags
|
|
3332
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3333
|
-
: undefined,
|
|
3340
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3334
3341
|
};
|
|
3335
3342
|
};
|
|
3336
3343
|
var deserializeAws_restJson1AssistantAssociationSummaryList = function (output, context) {
|
|
@@ -3350,13 +3357,11 @@ var deserializeAws_restJson1AssistantData = function (output, context) {
|
|
|
3350
3357
|
assistantId: __expectString(output.assistantId),
|
|
3351
3358
|
description: __expectString(output.description),
|
|
3352
3359
|
name: __expectString(output.name),
|
|
3353
|
-
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration
|
|
3360
|
+
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration != null
|
|
3354
3361
|
? deserializeAws_restJson1ServerSideEncryptionConfiguration(output.serverSideEncryptionConfiguration, context)
|
|
3355
3362
|
: undefined,
|
|
3356
3363
|
status: __expectString(output.status),
|
|
3357
|
-
tags: output.tags
|
|
3358
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3359
|
-
: undefined,
|
|
3364
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3360
3365
|
type: __expectString(output.type),
|
|
3361
3366
|
};
|
|
3362
3367
|
};
|
|
@@ -3377,13 +3382,11 @@ var deserializeAws_restJson1AssistantSummary = function (output, context) {
|
|
|
3377
3382
|
assistantId: __expectString(output.assistantId),
|
|
3378
3383
|
description: __expectString(output.description),
|
|
3379
3384
|
name: __expectString(output.name),
|
|
3380
|
-
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration
|
|
3385
|
+
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration != null
|
|
3381
3386
|
? deserializeAws_restJson1ServerSideEncryptionConfiguration(output.serverSideEncryptionConfiguration, context)
|
|
3382
3387
|
: undefined,
|
|
3383
3388
|
status: __expectString(output.status),
|
|
3384
|
-
tags: output.tags
|
|
3385
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3386
|
-
: undefined,
|
|
3389
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3387
3390
|
type: __expectString(output.type),
|
|
3388
3391
|
};
|
|
3389
3392
|
};
|
|
@@ -3395,20 +3398,14 @@ var deserializeAws_restJson1ContentData = function (output, context) {
|
|
|
3395
3398
|
knowledgeBaseArn: __expectString(output.knowledgeBaseArn),
|
|
3396
3399
|
knowledgeBaseId: __expectString(output.knowledgeBaseId),
|
|
3397
3400
|
linkOutUri: __expectString(output.linkOutUri),
|
|
3398
|
-
metadata: output.metadata
|
|
3399
|
-
? deserializeAws_restJson1ContentMetadata(output.metadata, context)
|
|
3400
|
-
: undefined,
|
|
3401
|
+
metadata: output.metadata != null ? deserializeAws_restJson1ContentMetadata(output.metadata, context) : undefined,
|
|
3401
3402
|
name: __expectString(output.name),
|
|
3402
3403
|
revisionId: __expectString(output.revisionId),
|
|
3403
3404
|
status: __expectString(output.status),
|
|
3404
|
-
tags: output.tags
|
|
3405
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3406
|
-
: undefined,
|
|
3405
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3407
3406
|
title: __expectString(output.title),
|
|
3408
3407
|
url: __expectString(output.url),
|
|
3409
|
-
urlExpiry: output.urlExpiry
|
|
3410
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.urlExpiry)))
|
|
3411
|
-
: undefined,
|
|
3408
|
+
urlExpiry: output.urlExpiry != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.urlExpiry))) : undefined,
|
|
3412
3409
|
};
|
|
3413
3410
|
};
|
|
3414
3411
|
var deserializeAws_restJson1ContentMetadata = function (output, context) {
|
|
@@ -3436,15 +3433,11 @@ var deserializeAws_restJson1ContentSummary = function (output, context) {
|
|
|
3436
3433
|
contentType: __expectString(output.contentType),
|
|
3437
3434
|
knowledgeBaseArn: __expectString(output.knowledgeBaseArn),
|
|
3438
3435
|
knowledgeBaseId: __expectString(output.knowledgeBaseId),
|
|
3439
|
-
metadata: output.metadata
|
|
3440
|
-
? deserializeAws_restJson1ContentMetadata(output.metadata, context)
|
|
3441
|
-
: undefined,
|
|
3436
|
+
metadata: output.metadata != null ? deserializeAws_restJson1ContentMetadata(output.metadata, context) : undefined,
|
|
3442
3437
|
name: __expectString(output.name),
|
|
3443
3438
|
revisionId: __expectString(output.revisionId),
|
|
3444
3439
|
status: __expectString(output.status),
|
|
3445
|
-
tags: output.tags
|
|
3446
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3447
|
-
: undefined,
|
|
3440
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3448
3441
|
title: __expectString(output.title),
|
|
3449
3442
|
};
|
|
3450
3443
|
};
|
|
@@ -3461,22 +3454,16 @@ var deserializeAws_restJson1ContentSummaryList = function (output, context) {
|
|
|
3461
3454
|
};
|
|
3462
3455
|
var deserializeAws_restJson1Document = function (output, context) {
|
|
3463
3456
|
return {
|
|
3464
|
-
contentReference: output.contentReference
|
|
3457
|
+
contentReference: output.contentReference != null
|
|
3465
3458
|
? deserializeAws_restJson1ContentReference(output.contentReference, context)
|
|
3466
3459
|
: undefined,
|
|
3467
|
-
excerpt: output.excerpt
|
|
3468
|
-
|
|
3469
|
-
: undefined,
|
|
3470
|
-
title: output.title !== undefined && output.title !== null
|
|
3471
|
-
? deserializeAws_restJson1DocumentText(output.title, context)
|
|
3472
|
-
: undefined,
|
|
3460
|
+
excerpt: output.excerpt != null ? deserializeAws_restJson1DocumentText(output.excerpt, context) : undefined,
|
|
3461
|
+
title: output.title != null ? deserializeAws_restJson1DocumentText(output.title, context) : undefined,
|
|
3473
3462
|
};
|
|
3474
3463
|
};
|
|
3475
3464
|
var deserializeAws_restJson1DocumentText = function (output, context) {
|
|
3476
3465
|
return {
|
|
3477
|
-
highlights: output.highlights
|
|
3478
|
-
? deserializeAws_restJson1Highlights(output.highlights, context)
|
|
3479
|
-
: undefined,
|
|
3466
|
+
highlights: output.highlights != null ? deserializeAws_restJson1Highlights(output.highlights, context) : undefined,
|
|
3480
3467
|
text: __expectString(output.text),
|
|
3481
3468
|
};
|
|
3482
3469
|
};
|
|
@@ -3519,23 +3506,21 @@ var deserializeAws_restJson1KnowledgeBaseData = function (output, context) {
|
|
|
3519
3506
|
knowledgeBaseArn: __expectString(output.knowledgeBaseArn),
|
|
3520
3507
|
knowledgeBaseId: __expectString(output.knowledgeBaseId),
|
|
3521
3508
|
knowledgeBaseType: __expectString(output.knowledgeBaseType),
|
|
3522
|
-
lastContentModificationTime: output.lastContentModificationTime
|
|
3509
|
+
lastContentModificationTime: output.lastContentModificationTime != null
|
|
3523
3510
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.lastContentModificationTime)))
|
|
3524
3511
|
: undefined,
|
|
3525
3512
|
name: __expectString(output.name),
|
|
3526
|
-
renderingConfiguration: output.renderingConfiguration
|
|
3513
|
+
renderingConfiguration: output.renderingConfiguration != null
|
|
3527
3514
|
? deserializeAws_restJson1RenderingConfiguration(output.renderingConfiguration, context)
|
|
3528
3515
|
: undefined,
|
|
3529
|
-
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration
|
|
3516
|
+
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration != null
|
|
3530
3517
|
? deserializeAws_restJson1ServerSideEncryptionConfiguration(output.serverSideEncryptionConfiguration, context)
|
|
3531
3518
|
: undefined,
|
|
3532
|
-
sourceConfiguration: output.sourceConfiguration
|
|
3519
|
+
sourceConfiguration: output.sourceConfiguration != null
|
|
3533
3520
|
? deserializeAws_restJson1SourceConfiguration(__expectUnion(output.sourceConfiguration), context)
|
|
3534
3521
|
: undefined,
|
|
3535
3522
|
status: __expectString(output.status),
|
|
3536
|
-
tags: output.tags
|
|
3537
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3538
|
-
: undefined,
|
|
3523
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3539
3524
|
};
|
|
3540
3525
|
};
|
|
3541
3526
|
var deserializeAws_restJson1KnowledgeBaseList = function (output, context) {
|
|
@@ -3556,19 +3541,17 @@ var deserializeAws_restJson1KnowledgeBaseSummary = function (output, context) {
|
|
|
3556
3541
|
knowledgeBaseId: __expectString(output.knowledgeBaseId),
|
|
3557
3542
|
knowledgeBaseType: __expectString(output.knowledgeBaseType),
|
|
3558
3543
|
name: __expectString(output.name),
|
|
3559
|
-
renderingConfiguration: output.renderingConfiguration
|
|
3544
|
+
renderingConfiguration: output.renderingConfiguration != null
|
|
3560
3545
|
? deserializeAws_restJson1RenderingConfiguration(output.renderingConfiguration, context)
|
|
3561
3546
|
: undefined,
|
|
3562
|
-
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration
|
|
3547
|
+
serverSideEncryptionConfiguration: output.serverSideEncryptionConfiguration != null
|
|
3563
3548
|
? deserializeAws_restJson1ServerSideEncryptionConfiguration(output.serverSideEncryptionConfiguration, context)
|
|
3564
3549
|
: undefined,
|
|
3565
|
-
sourceConfiguration: output.sourceConfiguration
|
|
3550
|
+
sourceConfiguration: output.sourceConfiguration != null
|
|
3566
3551
|
? deserializeAws_restJson1SourceConfiguration(__expectUnion(output.sourceConfiguration), context)
|
|
3567
3552
|
: undefined,
|
|
3568
3553
|
status: __expectString(output.status),
|
|
3569
|
-
tags: output.tags
|
|
3570
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3571
|
-
: undefined,
|
|
3554
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3572
3555
|
};
|
|
3573
3556
|
};
|
|
3574
3557
|
var deserializeAws_restJson1NotifyRecommendationsReceivedError = function (output, context) {
|
|
@@ -3617,9 +3600,7 @@ var deserializeAws_restJson1QueryResultsList = function (output, context) {
|
|
|
3617
3600
|
};
|
|
3618
3601
|
var deserializeAws_restJson1RecommendationData = function (output, context) {
|
|
3619
3602
|
return {
|
|
3620
|
-
document: output.document
|
|
3621
|
-
? deserializeAws_restJson1Document(output.document, context)
|
|
3622
|
-
: undefined,
|
|
3603
|
+
document: output.document != null ? deserializeAws_restJson1Document(output.document, context) : undefined,
|
|
3623
3604
|
recommendationId: __expectString(output.recommendationId),
|
|
3624
3605
|
relevanceLevel: __expectString(output.relevanceLevel),
|
|
3625
3606
|
relevanceScore: __limitedParseDouble(output.relevanceScore),
|
|
@@ -3650,11 +3631,11 @@ var deserializeAws_restJson1RecommendationList = function (output, context) {
|
|
|
3650
3631
|
};
|
|
3651
3632
|
var deserializeAws_restJson1RecommendationTrigger = function (output, context) {
|
|
3652
3633
|
return {
|
|
3653
|
-
data: output.data
|
|
3634
|
+
data: output.data != null
|
|
3654
3635
|
? deserializeAws_restJson1RecommendationTriggerData(__expectUnion(output.data), context)
|
|
3655
3636
|
: undefined,
|
|
3656
3637
|
id: __expectString(output.id),
|
|
3657
|
-
recommendationIds: output.recommendationIds
|
|
3638
|
+
recommendationIds: output.recommendationIds != null
|
|
3658
3639
|
? deserializeAws_restJson1RecommendationIdList(output.recommendationIds, context)
|
|
3659
3640
|
: undefined,
|
|
3660
3641
|
source: __expectString(output.source),
|
|
@@ -3687,9 +3668,7 @@ var deserializeAws_restJson1RenderingConfiguration = function (output, context)
|
|
|
3687
3668
|
};
|
|
3688
3669
|
var deserializeAws_restJson1ResultData = function (output, context) {
|
|
3689
3670
|
return {
|
|
3690
|
-
document: output.document
|
|
3691
|
-
? deserializeAws_restJson1Document(output.document, context)
|
|
3692
|
-
: undefined,
|
|
3671
|
+
document: output.document != null ? deserializeAws_restJson1Document(output.document, context) : undefined,
|
|
3693
3672
|
relevanceScore: __limitedParseDouble(output.relevanceScore),
|
|
3694
3673
|
resultId: __expectString(output.resultId),
|
|
3695
3674
|
};
|
|
@@ -3705,9 +3684,7 @@ var deserializeAws_restJson1SessionData = function (output, context) {
|
|
|
3705
3684
|
name: __expectString(output.name),
|
|
3706
3685
|
sessionArn: __expectString(output.sessionArn),
|
|
3707
3686
|
sessionId: __expectString(output.sessionId),
|
|
3708
|
-
tags: output.tags
|
|
3709
|
-
? deserializeAws_restJson1Tags(output.tags, context)
|
|
3710
|
-
: undefined,
|
|
3687
|
+
tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
3711
3688
|
};
|
|
3712
3689
|
};
|
|
3713
3690
|
var deserializeAws_restJson1SessionSummaries = function (output, context) {
|
|
@@ -3803,5 +3780,4 @@ var loadRestJsonErrorCode = function (output, data) {
|
|
|
3803
3780
|
if (data["__type"] !== undefined) {
|
|
3804
3781
|
return sanitizeErrorCode(data["__type"]);
|
|
3805
3782
|
}
|
|
3806
|
-
return "";
|
|
3807
3783
|
};
|