@aws-sdk/client-wisdom 3.476.0 → 3.477.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/dist-cjs/protocols/Aws_restJson1.js +242 -559
- package/dist-es/protocols/Aws_restJson1.js +243 -560
- package/package.json +5 -4
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { awsExpectUnion as __expectUnion } from "@aws-sdk/core";
|
|
2
|
-
import {
|
|
3
|
-
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, limitedParseDouble as __limitedParseDouble, map, parseEpochTimestamp as __parseEpochTimestamp,
|
|
2
|
+
import { requestBuilder as rb } from "@smithy/core";
|
|
3
|
+
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, limitedParseDouble as __limitedParseDouble, map, parseEpochTimestamp as __parseEpochTimestamp, take, withBaseException, } from "@smithy/smithy-client";
|
|
4
4
|
import { v4 as generateIdempotencyToken } from "uuid";
|
|
5
5
|
import { AccessDeniedException, ConflictException, PreconditionFailedException, RequestTimeoutException, ResourceNotFoundException, ServiceQuotaExceededException, TooManyTagsException, ValidationException, } from "../models/models_0";
|
|
6
6
|
import { WisdomServiceException as __BaseException } from "../models/WisdomServiceException";
|
|
7
7
|
export const se_CreateAssistantCommand = async (input, context) => {
|
|
8
|
-
const
|
|
8
|
+
const b = rb(input, context);
|
|
9
9
|
const headers = {
|
|
10
10
|
"content-type": "application/json",
|
|
11
11
|
};
|
|
12
|
-
|
|
12
|
+
b.bp("/assistants");
|
|
13
13
|
let body;
|
|
14
14
|
body = JSON.stringify(take(input, {
|
|
15
15
|
clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
@@ -19,23 +19,16 @@ export const se_CreateAssistantCommand = async (input, context) => {
|
|
|
19
19
|
tags: (_) => _json(_),
|
|
20
20
|
type: [],
|
|
21
21
|
}));
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
hostname,
|
|
25
|
-
port,
|
|
26
|
-
method: "POST",
|
|
27
|
-
headers,
|
|
28
|
-
path: resolvedPath,
|
|
29
|
-
body,
|
|
30
|
-
});
|
|
22
|
+
b.m("POST").h(headers).b(body);
|
|
23
|
+
return b.build();
|
|
31
24
|
};
|
|
32
25
|
export const se_CreateAssistantAssociationCommand = async (input, context) => {
|
|
33
|
-
const
|
|
26
|
+
const b = rb(input, context);
|
|
34
27
|
const headers = {
|
|
35
28
|
"content-type": "application/json",
|
|
36
29
|
};
|
|
37
|
-
|
|
38
|
-
|
|
30
|
+
b.bp("/assistants/{assistantId}/associations");
|
|
31
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
39
32
|
let body;
|
|
40
33
|
body = JSON.stringify(take(input, {
|
|
41
34
|
association: (_) => _json(_),
|
|
@@ -43,24 +36,16 @@ export const se_CreateAssistantAssociationCommand = async (input, context) => {
|
|
|
43
36
|
clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
44
37
|
tags: (_) => _json(_),
|
|
45
38
|
}));
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
hostname,
|
|
49
|
-
port,
|
|
50
|
-
method: "POST",
|
|
51
|
-
headers,
|
|
52
|
-
path: resolvedPath,
|
|
53
|
-
body,
|
|
54
|
-
});
|
|
39
|
+
b.m("POST").h(headers).b(body);
|
|
40
|
+
return b.build();
|
|
55
41
|
};
|
|
56
42
|
export const se_CreateContentCommand = async (input, context) => {
|
|
57
|
-
const
|
|
43
|
+
const b = rb(input, context);
|
|
58
44
|
const headers = {
|
|
59
45
|
"content-type": "application/json",
|
|
60
46
|
};
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
47
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/contents");
|
|
48
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
64
49
|
let body;
|
|
65
50
|
body = JSON.stringify(take(input, {
|
|
66
51
|
clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
@@ -71,22 +56,15 @@ export const se_CreateContentCommand = async (input, context) => {
|
|
|
71
56
|
title: [],
|
|
72
57
|
uploadId: [],
|
|
73
58
|
}));
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
hostname,
|
|
77
|
-
port,
|
|
78
|
-
method: "POST",
|
|
79
|
-
headers,
|
|
80
|
-
path: resolvedPath,
|
|
81
|
-
body,
|
|
82
|
-
});
|
|
59
|
+
b.m("POST").h(headers).b(body);
|
|
60
|
+
return b.build();
|
|
83
61
|
};
|
|
84
62
|
export const se_CreateKnowledgeBaseCommand = async (input, context) => {
|
|
85
|
-
const
|
|
63
|
+
const b = rb(input, context);
|
|
86
64
|
const headers = {
|
|
87
65
|
"content-type": "application/json",
|
|
88
66
|
};
|
|
89
|
-
|
|
67
|
+
b.bp("/knowledgeBases");
|
|
90
68
|
let body;
|
|
91
69
|
body = JSON.stringify(take(input, {
|
|
92
70
|
clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
@@ -98,24 +76,16 @@ export const se_CreateKnowledgeBaseCommand = async (input, context) => {
|
|
|
98
76
|
sourceConfiguration: (_) => _json(_),
|
|
99
77
|
tags: (_) => _json(_),
|
|
100
78
|
}));
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
hostname,
|
|
104
|
-
port,
|
|
105
|
-
method: "POST",
|
|
106
|
-
headers,
|
|
107
|
-
path: resolvedPath,
|
|
108
|
-
body,
|
|
109
|
-
});
|
|
79
|
+
b.m("POST").h(headers).b(body);
|
|
80
|
+
return b.build();
|
|
110
81
|
};
|
|
111
82
|
export const se_CreateQuickResponseCommand = async (input, context) => {
|
|
112
|
-
const
|
|
83
|
+
const b = rb(input, context);
|
|
113
84
|
const headers = {
|
|
114
85
|
"content-type": "application/json",
|
|
115
86
|
};
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
87
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/quickResponses");
|
|
88
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
119
89
|
let body;
|
|
120
90
|
body = JSON.stringify(take(input, {
|
|
121
91
|
channels: (_) => _json(_),
|
|
@@ -130,23 +100,16 @@ export const se_CreateQuickResponseCommand = async (input, context) => {
|
|
|
130
100
|
shortcutKey: [],
|
|
131
101
|
tags: (_) => _json(_),
|
|
132
102
|
}));
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
hostname,
|
|
136
|
-
port,
|
|
137
|
-
method: "POST",
|
|
138
|
-
headers,
|
|
139
|
-
path: resolvedPath,
|
|
140
|
-
body,
|
|
141
|
-
});
|
|
103
|
+
b.m("POST").h(headers).b(body);
|
|
104
|
+
return b.build();
|
|
142
105
|
};
|
|
143
106
|
export const se_CreateSessionCommand = async (input, context) => {
|
|
144
|
-
const
|
|
107
|
+
const b = rb(input, context);
|
|
145
108
|
const headers = {
|
|
146
109
|
"content-type": "application/json",
|
|
147
110
|
};
|
|
148
|
-
|
|
149
|
-
|
|
111
|
+
b.bp("/assistants/{assistantId}/sessions");
|
|
112
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
150
113
|
let body;
|
|
151
114
|
body = JSON.stringify(take(input, {
|
|
152
115
|
clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
@@ -154,599 +117,361 @@ export const se_CreateSessionCommand = async (input, context) => {
|
|
|
154
117
|
name: [],
|
|
155
118
|
tags: (_) => _json(_),
|
|
156
119
|
}));
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
hostname,
|
|
160
|
-
port,
|
|
161
|
-
method: "POST",
|
|
162
|
-
headers,
|
|
163
|
-
path: resolvedPath,
|
|
164
|
-
body,
|
|
165
|
-
});
|
|
120
|
+
b.m("POST").h(headers).b(body);
|
|
121
|
+
return b.build();
|
|
166
122
|
};
|
|
167
123
|
export const se_DeleteAssistantCommand = async (input, context) => {
|
|
168
|
-
const
|
|
124
|
+
const b = rb(input, context);
|
|
169
125
|
const headers = {};
|
|
170
|
-
|
|
171
|
-
|
|
126
|
+
b.bp("/assistants/{assistantId}");
|
|
127
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
172
128
|
let body;
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
hostname,
|
|
176
|
-
port,
|
|
177
|
-
method: "DELETE",
|
|
178
|
-
headers,
|
|
179
|
-
path: resolvedPath,
|
|
180
|
-
body,
|
|
181
|
-
});
|
|
129
|
+
b.m("DELETE").h(headers).b(body);
|
|
130
|
+
return b.build();
|
|
182
131
|
};
|
|
183
132
|
export const se_DeleteAssistantAssociationCommand = async (input, context) => {
|
|
184
|
-
const
|
|
133
|
+
const b = rb(input, context);
|
|
185
134
|
const headers = {};
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "assistantId", () => input.assistantId, "{assistantId}", false);
|
|
135
|
+
b.bp("/assistants/{assistantId}/associations/{assistantAssociationId}");
|
|
136
|
+
b.p("assistantAssociationId", () => input.assistantAssociationId, "{assistantAssociationId}", false);
|
|
137
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
190
138
|
let body;
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
hostname,
|
|
194
|
-
port,
|
|
195
|
-
method: "DELETE",
|
|
196
|
-
headers,
|
|
197
|
-
path: resolvedPath,
|
|
198
|
-
body,
|
|
199
|
-
});
|
|
139
|
+
b.m("DELETE").h(headers).b(body);
|
|
140
|
+
return b.build();
|
|
200
141
|
};
|
|
201
142
|
export const se_DeleteContentCommand = async (input, context) => {
|
|
202
|
-
const
|
|
143
|
+
const b = rb(input, context);
|
|
203
144
|
const headers = {};
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "contentId", () => input.contentId, "{contentId}", false);
|
|
145
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/contents/{contentId}");
|
|
146
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
147
|
+
b.p("contentId", () => input.contentId, "{contentId}", false);
|
|
208
148
|
let body;
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
hostname,
|
|
212
|
-
port,
|
|
213
|
-
method: "DELETE",
|
|
214
|
-
headers,
|
|
215
|
-
path: resolvedPath,
|
|
216
|
-
body,
|
|
217
|
-
});
|
|
149
|
+
b.m("DELETE").h(headers).b(body);
|
|
150
|
+
return b.build();
|
|
218
151
|
};
|
|
219
152
|
export const se_DeleteImportJobCommand = async (input, context) => {
|
|
220
|
-
const
|
|
153
|
+
const b = rb(input, context);
|
|
221
154
|
const headers = {};
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "importJobId", () => input.importJobId, "{importJobId}", false);
|
|
155
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/importJobs/{importJobId}");
|
|
156
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
157
|
+
b.p("importJobId", () => input.importJobId, "{importJobId}", false);
|
|
226
158
|
let body;
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
hostname,
|
|
230
|
-
port,
|
|
231
|
-
method: "DELETE",
|
|
232
|
-
headers,
|
|
233
|
-
path: resolvedPath,
|
|
234
|
-
body,
|
|
235
|
-
});
|
|
159
|
+
b.m("DELETE").h(headers).b(body);
|
|
160
|
+
return b.build();
|
|
236
161
|
};
|
|
237
162
|
export const se_DeleteKnowledgeBaseCommand = async (input, context) => {
|
|
238
|
-
const
|
|
163
|
+
const b = rb(input, context);
|
|
239
164
|
const headers = {};
|
|
240
|
-
|
|
241
|
-
|
|
165
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}");
|
|
166
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
242
167
|
let body;
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
hostname,
|
|
246
|
-
port,
|
|
247
|
-
method: "DELETE",
|
|
248
|
-
headers,
|
|
249
|
-
path: resolvedPath,
|
|
250
|
-
body,
|
|
251
|
-
});
|
|
168
|
+
b.m("DELETE").h(headers).b(body);
|
|
169
|
+
return b.build();
|
|
252
170
|
};
|
|
253
171
|
export const se_DeleteQuickResponseCommand = async (input, context) => {
|
|
254
|
-
const
|
|
172
|
+
const b = rb(input, context);
|
|
255
173
|
const headers = {};
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "quickResponseId", () => input.quickResponseId, "{quickResponseId}", false);
|
|
174
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/quickResponses/{quickResponseId}");
|
|
175
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
176
|
+
b.p("quickResponseId", () => input.quickResponseId, "{quickResponseId}", false);
|
|
260
177
|
let body;
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
hostname,
|
|
264
|
-
port,
|
|
265
|
-
method: "DELETE",
|
|
266
|
-
headers,
|
|
267
|
-
path: resolvedPath,
|
|
268
|
-
body,
|
|
269
|
-
});
|
|
178
|
+
b.m("DELETE").h(headers).b(body);
|
|
179
|
+
return b.build();
|
|
270
180
|
};
|
|
271
181
|
export const se_GetAssistantCommand = async (input, context) => {
|
|
272
|
-
const
|
|
182
|
+
const b = rb(input, context);
|
|
273
183
|
const headers = {};
|
|
274
|
-
|
|
275
|
-
|
|
184
|
+
b.bp("/assistants/{assistantId}");
|
|
185
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
276
186
|
let body;
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
hostname,
|
|
280
|
-
port,
|
|
281
|
-
method: "GET",
|
|
282
|
-
headers,
|
|
283
|
-
path: resolvedPath,
|
|
284
|
-
body,
|
|
285
|
-
});
|
|
187
|
+
b.m("GET").h(headers).b(body);
|
|
188
|
+
return b.build();
|
|
286
189
|
};
|
|
287
190
|
export const se_GetAssistantAssociationCommand = async (input, context) => {
|
|
288
|
-
const
|
|
191
|
+
const b = rb(input, context);
|
|
289
192
|
const headers = {};
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "assistantId", () => input.assistantId, "{assistantId}", false);
|
|
193
|
+
b.bp("/assistants/{assistantId}/associations/{assistantAssociationId}");
|
|
194
|
+
b.p("assistantAssociationId", () => input.assistantAssociationId, "{assistantAssociationId}", false);
|
|
195
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
294
196
|
let body;
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
hostname,
|
|
298
|
-
port,
|
|
299
|
-
method: "GET",
|
|
300
|
-
headers,
|
|
301
|
-
path: resolvedPath,
|
|
302
|
-
body,
|
|
303
|
-
});
|
|
197
|
+
b.m("GET").h(headers).b(body);
|
|
198
|
+
return b.build();
|
|
304
199
|
};
|
|
305
200
|
export const se_GetContentCommand = async (input, context) => {
|
|
306
|
-
const
|
|
201
|
+
const b = rb(input, context);
|
|
307
202
|
const headers = {};
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
203
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/contents/{contentId}");
|
|
204
|
+
b.p("contentId", () => input.contentId, "{contentId}", false);
|
|
205
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
312
206
|
let body;
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
hostname,
|
|
316
|
-
port,
|
|
317
|
-
method: "GET",
|
|
318
|
-
headers,
|
|
319
|
-
path: resolvedPath,
|
|
320
|
-
body,
|
|
321
|
-
});
|
|
207
|
+
b.m("GET").h(headers).b(body);
|
|
208
|
+
return b.build();
|
|
322
209
|
};
|
|
323
210
|
export const se_GetContentSummaryCommand = async (input, context) => {
|
|
324
|
-
const
|
|
211
|
+
const b = rb(input, context);
|
|
325
212
|
const headers = {};
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
213
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/contents/{contentId}/summary");
|
|
214
|
+
b.p("contentId", () => input.contentId, "{contentId}", false);
|
|
215
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
330
216
|
let body;
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
hostname,
|
|
334
|
-
port,
|
|
335
|
-
method: "GET",
|
|
336
|
-
headers,
|
|
337
|
-
path: resolvedPath,
|
|
338
|
-
body,
|
|
339
|
-
});
|
|
217
|
+
b.m("GET").h(headers).b(body);
|
|
218
|
+
return b.build();
|
|
340
219
|
};
|
|
341
220
|
export const se_GetImportJobCommand = async (input, context) => {
|
|
342
|
-
const
|
|
221
|
+
const b = rb(input, context);
|
|
343
222
|
const headers = {};
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
223
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/importJobs/{importJobId}");
|
|
224
|
+
b.p("importJobId", () => input.importJobId, "{importJobId}", false);
|
|
225
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
348
226
|
let body;
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
hostname,
|
|
352
|
-
port,
|
|
353
|
-
method: "GET",
|
|
354
|
-
headers,
|
|
355
|
-
path: resolvedPath,
|
|
356
|
-
body,
|
|
357
|
-
});
|
|
227
|
+
b.m("GET").h(headers).b(body);
|
|
228
|
+
return b.build();
|
|
358
229
|
};
|
|
359
230
|
export const se_GetKnowledgeBaseCommand = async (input, context) => {
|
|
360
|
-
const
|
|
231
|
+
const b = rb(input, context);
|
|
361
232
|
const headers = {};
|
|
362
|
-
|
|
363
|
-
|
|
233
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}");
|
|
234
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
364
235
|
let body;
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
hostname,
|
|
368
|
-
port,
|
|
369
|
-
method: "GET",
|
|
370
|
-
headers,
|
|
371
|
-
path: resolvedPath,
|
|
372
|
-
body,
|
|
373
|
-
});
|
|
236
|
+
b.m("GET").h(headers).b(body);
|
|
237
|
+
return b.build();
|
|
374
238
|
};
|
|
375
239
|
export const se_GetQuickResponseCommand = async (input, context) => {
|
|
376
|
-
const
|
|
240
|
+
const b = rb(input, context);
|
|
377
241
|
const headers = {};
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
242
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/quickResponses/{quickResponseId}");
|
|
243
|
+
b.p("quickResponseId", () => input.quickResponseId, "{quickResponseId}", false);
|
|
244
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
382
245
|
let body;
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
hostname,
|
|
386
|
-
port,
|
|
387
|
-
method: "GET",
|
|
388
|
-
headers,
|
|
389
|
-
path: resolvedPath,
|
|
390
|
-
body,
|
|
391
|
-
});
|
|
246
|
+
b.m("GET").h(headers).b(body);
|
|
247
|
+
return b.build();
|
|
392
248
|
};
|
|
393
249
|
export const se_GetRecommendationsCommand = async (input, context) => {
|
|
394
|
-
const
|
|
250
|
+
const b = rb(input, context);
|
|
395
251
|
const headers = {};
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "sessionId", () => input.sessionId, "{sessionId}", false);
|
|
252
|
+
b.bp("/assistants/{assistantId}/sessions/{sessionId}/recommendations");
|
|
253
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
254
|
+
b.p("sessionId", () => input.sessionId, "{sessionId}", false);
|
|
400
255
|
const query = map({
|
|
401
|
-
|
|
402
|
-
|
|
256
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
257
|
+
[_wTS]: [() => input.waitTimeSeconds !== void 0, () => input[_wTS].toString()],
|
|
403
258
|
});
|
|
404
259
|
let body;
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
hostname,
|
|
408
|
-
port,
|
|
409
|
-
method: "GET",
|
|
410
|
-
headers,
|
|
411
|
-
path: resolvedPath,
|
|
412
|
-
query,
|
|
413
|
-
body,
|
|
414
|
-
});
|
|
260
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
261
|
+
return b.build();
|
|
415
262
|
};
|
|
416
263
|
export const se_GetSessionCommand = async (input, context) => {
|
|
417
|
-
const
|
|
264
|
+
const b = rb(input, context);
|
|
418
265
|
const headers = {};
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "sessionId", () => input.sessionId, "{sessionId}", false);
|
|
266
|
+
b.bp("/assistants/{assistantId}/sessions/{sessionId}");
|
|
267
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
268
|
+
b.p("sessionId", () => input.sessionId, "{sessionId}", false);
|
|
423
269
|
let body;
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
hostname,
|
|
427
|
-
port,
|
|
428
|
-
method: "GET",
|
|
429
|
-
headers,
|
|
430
|
-
path: resolvedPath,
|
|
431
|
-
body,
|
|
432
|
-
});
|
|
270
|
+
b.m("GET").h(headers).b(body);
|
|
271
|
+
return b.build();
|
|
433
272
|
};
|
|
434
273
|
export const se_ListAssistantAssociationsCommand = async (input, context) => {
|
|
435
|
-
const
|
|
274
|
+
const b = rb(input, context);
|
|
436
275
|
const headers = {};
|
|
437
|
-
|
|
438
|
-
|
|
276
|
+
b.bp("/assistants/{assistantId}/associations");
|
|
277
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
439
278
|
const query = map({
|
|
440
|
-
|
|
441
|
-
|
|
279
|
+
[_nT]: [, input[_nT]],
|
|
280
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
442
281
|
});
|
|
443
282
|
let body;
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
hostname,
|
|
447
|
-
port,
|
|
448
|
-
method: "GET",
|
|
449
|
-
headers,
|
|
450
|
-
path: resolvedPath,
|
|
451
|
-
query,
|
|
452
|
-
body,
|
|
453
|
-
});
|
|
283
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
284
|
+
return b.build();
|
|
454
285
|
};
|
|
455
286
|
export const se_ListAssistantsCommand = async (input, context) => {
|
|
456
|
-
const
|
|
287
|
+
const b = rb(input, context);
|
|
457
288
|
const headers = {};
|
|
458
|
-
|
|
289
|
+
b.bp("/assistants");
|
|
459
290
|
const query = map({
|
|
460
|
-
|
|
461
|
-
|
|
291
|
+
[_nT]: [, input[_nT]],
|
|
292
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
462
293
|
});
|
|
463
294
|
let body;
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
hostname,
|
|
467
|
-
port,
|
|
468
|
-
method: "GET",
|
|
469
|
-
headers,
|
|
470
|
-
path: resolvedPath,
|
|
471
|
-
query,
|
|
472
|
-
body,
|
|
473
|
-
});
|
|
295
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
296
|
+
return b.build();
|
|
474
297
|
};
|
|
475
298
|
export const se_ListContentsCommand = async (input, context) => {
|
|
476
|
-
const
|
|
299
|
+
const b = rb(input, context);
|
|
477
300
|
const headers = {};
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
301
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/contents");
|
|
302
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
481
303
|
const query = map({
|
|
482
|
-
|
|
483
|
-
|
|
304
|
+
[_nT]: [, input[_nT]],
|
|
305
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
484
306
|
});
|
|
485
307
|
let body;
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
hostname,
|
|
489
|
-
port,
|
|
490
|
-
method: "GET",
|
|
491
|
-
headers,
|
|
492
|
-
path: resolvedPath,
|
|
493
|
-
query,
|
|
494
|
-
body,
|
|
495
|
-
});
|
|
308
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
309
|
+
return b.build();
|
|
496
310
|
};
|
|
497
311
|
export const se_ListImportJobsCommand = async (input, context) => {
|
|
498
|
-
const
|
|
312
|
+
const b = rb(input, context);
|
|
499
313
|
const headers = {};
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
314
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/importJobs");
|
|
315
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
503
316
|
const query = map({
|
|
504
|
-
|
|
505
|
-
|
|
317
|
+
[_nT]: [, input[_nT]],
|
|
318
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
506
319
|
});
|
|
507
320
|
let body;
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
hostname,
|
|
511
|
-
port,
|
|
512
|
-
method: "GET",
|
|
513
|
-
headers,
|
|
514
|
-
path: resolvedPath,
|
|
515
|
-
query,
|
|
516
|
-
body,
|
|
517
|
-
});
|
|
321
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
322
|
+
return b.build();
|
|
518
323
|
};
|
|
519
324
|
export const se_ListKnowledgeBasesCommand = async (input, context) => {
|
|
520
|
-
const
|
|
325
|
+
const b = rb(input, context);
|
|
521
326
|
const headers = {};
|
|
522
|
-
|
|
327
|
+
b.bp("/knowledgeBases");
|
|
523
328
|
const query = map({
|
|
524
|
-
|
|
525
|
-
|
|
329
|
+
[_nT]: [, input[_nT]],
|
|
330
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
526
331
|
});
|
|
527
332
|
let body;
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
hostname,
|
|
531
|
-
port,
|
|
532
|
-
method: "GET",
|
|
533
|
-
headers,
|
|
534
|
-
path: resolvedPath,
|
|
535
|
-
query,
|
|
536
|
-
body,
|
|
537
|
-
});
|
|
333
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
334
|
+
return b.build();
|
|
538
335
|
};
|
|
539
336
|
export const se_ListQuickResponsesCommand = async (input, context) => {
|
|
540
|
-
const
|
|
337
|
+
const b = rb(input, context);
|
|
541
338
|
const headers = {};
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
339
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/quickResponses");
|
|
340
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
545
341
|
const query = map({
|
|
546
|
-
|
|
547
|
-
|
|
342
|
+
[_nT]: [, input[_nT]],
|
|
343
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
548
344
|
});
|
|
549
345
|
let body;
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
hostname,
|
|
553
|
-
port,
|
|
554
|
-
method: "GET",
|
|
555
|
-
headers,
|
|
556
|
-
path: resolvedPath,
|
|
557
|
-
query,
|
|
558
|
-
body,
|
|
559
|
-
});
|
|
346
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
347
|
+
return b.build();
|
|
560
348
|
};
|
|
561
349
|
export const se_ListTagsForResourceCommand = async (input, context) => {
|
|
562
|
-
const
|
|
350
|
+
const b = rb(input, context);
|
|
563
351
|
const headers = {};
|
|
564
|
-
|
|
565
|
-
|
|
352
|
+
b.bp("/tags/{resourceArn}");
|
|
353
|
+
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
566
354
|
let body;
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
hostname,
|
|
570
|
-
port,
|
|
571
|
-
method: "GET",
|
|
572
|
-
headers,
|
|
573
|
-
path: resolvedPath,
|
|
574
|
-
body,
|
|
575
|
-
});
|
|
355
|
+
b.m("GET").h(headers).b(body);
|
|
356
|
+
return b.build();
|
|
576
357
|
};
|
|
577
358
|
export const se_NotifyRecommendationsReceivedCommand = async (input, context) => {
|
|
578
|
-
const
|
|
359
|
+
const b = rb(input, context);
|
|
579
360
|
const headers = {
|
|
580
361
|
"content-type": "application/json",
|
|
581
362
|
};
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "sessionId", () => input.sessionId, "{sessionId}", false);
|
|
363
|
+
b.bp("/assistants/{assistantId}/sessions/{sessionId}/recommendations/notify");
|
|
364
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
365
|
+
b.p("sessionId", () => input.sessionId, "{sessionId}", false);
|
|
586
366
|
let body;
|
|
587
367
|
body = JSON.stringify(take(input, {
|
|
588
368
|
recommendationIds: (_) => _json(_),
|
|
589
369
|
}));
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
hostname,
|
|
593
|
-
port,
|
|
594
|
-
method: "POST",
|
|
595
|
-
headers,
|
|
596
|
-
path: resolvedPath,
|
|
597
|
-
body,
|
|
598
|
-
});
|
|
370
|
+
b.m("POST").h(headers).b(body);
|
|
371
|
+
return b.build();
|
|
599
372
|
};
|
|
600
373
|
export const se_QueryAssistantCommand = async (input, context) => {
|
|
601
|
-
const
|
|
374
|
+
const b = rb(input, context);
|
|
602
375
|
const headers = {
|
|
603
376
|
"content-type": "application/json",
|
|
604
377
|
};
|
|
605
|
-
|
|
606
|
-
|
|
378
|
+
b.bp("/assistants/{assistantId}/query");
|
|
379
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
607
380
|
let body;
|
|
608
381
|
body = JSON.stringify(take(input, {
|
|
609
382
|
maxResults: [],
|
|
610
383
|
nextToken: [],
|
|
611
384
|
queryText: [],
|
|
612
385
|
}));
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
hostname,
|
|
616
|
-
port,
|
|
617
|
-
method: "POST",
|
|
618
|
-
headers,
|
|
619
|
-
path: resolvedPath,
|
|
620
|
-
body,
|
|
621
|
-
});
|
|
386
|
+
b.m("POST").h(headers).b(body);
|
|
387
|
+
return b.build();
|
|
622
388
|
};
|
|
623
389
|
export const se_RemoveKnowledgeBaseTemplateUriCommand = async (input, context) => {
|
|
624
|
-
const
|
|
390
|
+
const b = rb(input, context);
|
|
625
391
|
const headers = {};
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
392
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/templateUri");
|
|
393
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
629
394
|
let body;
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
hostname,
|
|
633
|
-
port,
|
|
634
|
-
method: "DELETE",
|
|
635
|
-
headers,
|
|
636
|
-
path: resolvedPath,
|
|
637
|
-
body,
|
|
638
|
-
});
|
|
395
|
+
b.m("DELETE").h(headers).b(body);
|
|
396
|
+
return b.build();
|
|
639
397
|
};
|
|
640
398
|
export const se_SearchContentCommand = async (input, context) => {
|
|
641
|
-
const
|
|
399
|
+
const b = rb(input, context);
|
|
642
400
|
const headers = {
|
|
643
401
|
"content-type": "application/json",
|
|
644
402
|
};
|
|
645
|
-
|
|
646
|
-
|
|
403
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/search");
|
|
404
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
647
405
|
const query = map({
|
|
648
|
-
|
|
649
|
-
|
|
406
|
+
[_nT]: [, input[_nT]],
|
|
407
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
650
408
|
});
|
|
651
409
|
let body;
|
|
652
410
|
body = JSON.stringify(take(input, {
|
|
653
411
|
searchExpression: (_) => _json(_),
|
|
654
412
|
}));
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
hostname,
|
|
658
|
-
port,
|
|
659
|
-
method: "POST",
|
|
660
|
-
headers,
|
|
661
|
-
path: resolvedPath,
|
|
662
|
-
query,
|
|
663
|
-
body,
|
|
664
|
-
});
|
|
413
|
+
b.m("POST").h(headers).q(query).b(body);
|
|
414
|
+
return b.build();
|
|
665
415
|
};
|
|
666
416
|
export const se_SearchQuickResponsesCommand = async (input, context) => {
|
|
667
|
-
const
|
|
417
|
+
const b = rb(input, context);
|
|
668
418
|
const headers = {
|
|
669
419
|
"content-type": "application/json",
|
|
670
420
|
};
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
421
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/search/quickResponses");
|
|
422
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
674
423
|
const query = map({
|
|
675
|
-
|
|
676
|
-
|
|
424
|
+
[_nT]: [, input[_nT]],
|
|
425
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
677
426
|
});
|
|
678
427
|
let body;
|
|
679
428
|
body = JSON.stringify(take(input, {
|
|
680
429
|
attributes: (_) => _json(_),
|
|
681
430
|
searchExpression: (_) => _json(_),
|
|
682
431
|
}));
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
hostname,
|
|
686
|
-
port,
|
|
687
|
-
method: "POST",
|
|
688
|
-
headers,
|
|
689
|
-
path: resolvedPath,
|
|
690
|
-
query,
|
|
691
|
-
body,
|
|
692
|
-
});
|
|
432
|
+
b.m("POST").h(headers).q(query).b(body);
|
|
433
|
+
return b.build();
|
|
693
434
|
};
|
|
694
435
|
export const se_SearchSessionsCommand = async (input, context) => {
|
|
695
|
-
const
|
|
436
|
+
const b = rb(input, context);
|
|
696
437
|
const headers = {
|
|
697
438
|
"content-type": "application/json",
|
|
698
439
|
};
|
|
699
|
-
|
|
700
|
-
|
|
440
|
+
b.bp("/assistants/{assistantId}/searchSessions");
|
|
441
|
+
b.p("assistantId", () => input.assistantId, "{assistantId}", false);
|
|
701
442
|
const query = map({
|
|
702
|
-
|
|
703
|
-
|
|
443
|
+
[_nT]: [, input[_nT]],
|
|
444
|
+
[_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
|
|
704
445
|
});
|
|
705
446
|
let body;
|
|
706
447
|
body = JSON.stringify(take(input, {
|
|
707
448
|
searchExpression: (_) => _json(_),
|
|
708
449
|
}));
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
hostname,
|
|
712
|
-
port,
|
|
713
|
-
method: "POST",
|
|
714
|
-
headers,
|
|
715
|
-
path: resolvedPath,
|
|
716
|
-
query,
|
|
717
|
-
body,
|
|
718
|
-
});
|
|
450
|
+
b.m("POST").h(headers).q(query).b(body);
|
|
451
|
+
return b.build();
|
|
719
452
|
};
|
|
720
453
|
export const se_StartContentUploadCommand = async (input, context) => {
|
|
721
|
-
const
|
|
454
|
+
const b = rb(input, context);
|
|
722
455
|
const headers = {
|
|
723
456
|
"content-type": "application/json",
|
|
724
457
|
};
|
|
725
|
-
|
|
726
|
-
|
|
458
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/upload");
|
|
459
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
727
460
|
let body;
|
|
728
461
|
body = JSON.stringify(take(input, {
|
|
729
462
|
contentType: [],
|
|
730
463
|
presignedUrlTimeToLive: [],
|
|
731
464
|
}));
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
hostname,
|
|
735
|
-
port,
|
|
736
|
-
method: "POST",
|
|
737
|
-
headers,
|
|
738
|
-
path: resolvedPath,
|
|
739
|
-
body,
|
|
740
|
-
});
|
|
465
|
+
b.m("POST").h(headers).b(body);
|
|
466
|
+
return b.build();
|
|
741
467
|
};
|
|
742
468
|
export const se_StartImportJobCommand = async (input, context) => {
|
|
743
|
-
const
|
|
469
|
+
const b = rb(input, context);
|
|
744
470
|
const headers = {
|
|
745
471
|
"content-type": "application/json",
|
|
746
472
|
};
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
473
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/importJobs");
|
|
474
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
750
475
|
let body;
|
|
751
476
|
body = JSON.stringify(take(input, {
|
|
752
477
|
clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
@@ -755,69 +480,46 @@ export const se_StartImportJobCommand = async (input, context) => {
|
|
|
755
480
|
metadata: (_) => _json(_),
|
|
756
481
|
uploadId: [],
|
|
757
482
|
}));
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
hostname,
|
|
761
|
-
port,
|
|
762
|
-
method: "POST",
|
|
763
|
-
headers,
|
|
764
|
-
path: resolvedPath,
|
|
765
|
-
body,
|
|
766
|
-
});
|
|
483
|
+
b.m("POST").h(headers).b(body);
|
|
484
|
+
return b.build();
|
|
767
485
|
};
|
|
768
486
|
export const se_TagResourceCommand = async (input, context) => {
|
|
769
|
-
const
|
|
487
|
+
const b = rb(input, context);
|
|
770
488
|
const headers = {
|
|
771
489
|
"content-type": "application/json",
|
|
772
490
|
};
|
|
773
|
-
|
|
774
|
-
|
|
491
|
+
b.bp("/tags/{resourceArn}");
|
|
492
|
+
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
775
493
|
let body;
|
|
776
494
|
body = JSON.stringify(take(input, {
|
|
777
495
|
tags: (_) => _json(_),
|
|
778
496
|
}));
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
hostname,
|
|
782
|
-
port,
|
|
783
|
-
method: "POST",
|
|
784
|
-
headers,
|
|
785
|
-
path: resolvedPath,
|
|
786
|
-
body,
|
|
787
|
-
});
|
|
497
|
+
b.m("POST").h(headers).b(body);
|
|
498
|
+
return b.build();
|
|
788
499
|
};
|
|
789
500
|
export const se_UntagResourceCommand = async (input, context) => {
|
|
790
|
-
const
|
|
501
|
+
const b = rb(input, context);
|
|
791
502
|
const headers = {};
|
|
792
|
-
|
|
793
|
-
|
|
503
|
+
b.bp("/tags/{resourceArn}");
|
|
504
|
+
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
794
505
|
const query = map({
|
|
795
|
-
|
|
506
|
+
[_tK]: [
|
|
796
507
|
__expectNonNull(input.tagKeys, `tagKeys`) != null,
|
|
797
|
-
() => (input
|
|
508
|
+
() => (input[_tK] || []).map((_entry) => _entry),
|
|
798
509
|
],
|
|
799
510
|
});
|
|
800
511
|
let body;
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
hostname,
|
|
804
|
-
port,
|
|
805
|
-
method: "DELETE",
|
|
806
|
-
headers,
|
|
807
|
-
path: resolvedPath,
|
|
808
|
-
query,
|
|
809
|
-
body,
|
|
810
|
-
});
|
|
512
|
+
b.m("DELETE").h(headers).q(query).b(body);
|
|
513
|
+
return b.build();
|
|
811
514
|
};
|
|
812
515
|
export const se_UpdateContentCommand = async (input, context) => {
|
|
813
|
-
const
|
|
516
|
+
const b = rb(input, context);
|
|
814
517
|
const headers = {
|
|
815
518
|
"content-type": "application/json",
|
|
816
519
|
};
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "contentId", () => input.contentId, "{contentId}", false);
|
|
520
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/contents/{contentId}");
|
|
521
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
522
|
+
b.p("contentId", () => input.contentId, "{contentId}", false);
|
|
821
523
|
let body;
|
|
822
524
|
body = JSON.stringify(take(input, {
|
|
823
525
|
metadata: (_) => _json(_),
|
|
@@ -827,47 +529,31 @@ export const se_UpdateContentCommand = async (input, context) => {
|
|
|
827
529
|
title: [],
|
|
828
530
|
uploadId: [],
|
|
829
531
|
}));
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
hostname,
|
|
833
|
-
port,
|
|
834
|
-
method: "POST",
|
|
835
|
-
headers,
|
|
836
|
-
path: resolvedPath,
|
|
837
|
-
body,
|
|
838
|
-
});
|
|
532
|
+
b.m("POST").h(headers).b(body);
|
|
533
|
+
return b.build();
|
|
839
534
|
};
|
|
840
535
|
export const se_UpdateKnowledgeBaseTemplateUriCommand = async (input, context) => {
|
|
841
|
-
const
|
|
536
|
+
const b = rb(input, context);
|
|
842
537
|
const headers = {
|
|
843
538
|
"content-type": "application/json",
|
|
844
539
|
};
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
540
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/templateUri");
|
|
541
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
848
542
|
let body;
|
|
849
543
|
body = JSON.stringify(take(input, {
|
|
850
544
|
templateUri: [],
|
|
851
545
|
}));
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
hostname,
|
|
855
|
-
port,
|
|
856
|
-
method: "POST",
|
|
857
|
-
headers,
|
|
858
|
-
path: resolvedPath,
|
|
859
|
-
body,
|
|
860
|
-
});
|
|
546
|
+
b.m("POST").h(headers).b(body);
|
|
547
|
+
return b.build();
|
|
861
548
|
};
|
|
862
549
|
export const se_UpdateQuickResponseCommand = async (input, context) => {
|
|
863
|
-
const
|
|
550
|
+
const b = rb(input, context);
|
|
864
551
|
const headers = {
|
|
865
552
|
"content-type": "application/json",
|
|
866
553
|
};
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "quickResponseId", () => input.quickResponseId, "{quickResponseId}", false);
|
|
554
|
+
b.bp("/knowledgeBases/{knowledgeBaseId}/quickResponses/{quickResponseId}");
|
|
555
|
+
b.p("knowledgeBaseId", () => input.knowledgeBaseId, "{knowledgeBaseId}", false);
|
|
556
|
+
b.p("quickResponseId", () => input.quickResponseId, "{quickResponseId}", false);
|
|
871
557
|
let body;
|
|
872
558
|
body = JSON.stringify(take(input, {
|
|
873
559
|
channels: (_) => _json(_),
|
|
@@ -883,15 +569,8 @@ export const se_UpdateQuickResponseCommand = async (input, context) => {
|
|
|
883
569
|
removeShortcutKey: [],
|
|
884
570
|
shortcutKey: [],
|
|
885
571
|
}));
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
hostname,
|
|
889
|
-
port,
|
|
890
|
-
method: "POST",
|
|
891
|
-
headers,
|
|
892
|
-
path: resolvedPath,
|
|
893
|
-
body,
|
|
894
|
-
});
|
|
572
|
+
b.m("POST").h(headers).b(body);
|
|
573
|
+
return b.build();
|
|
895
574
|
};
|
|
896
575
|
export const de_CreateAssistantCommand = async (output, context) => {
|
|
897
576
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
@@ -2801,6 +2480,10 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
|
2801
2480
|
value !== "" &&
|
|
2802
2481
|
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
2803
2482
|
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
2483
|
+
const _mR = "maxResults";
|
|
2484
|
+
const _nT = "nextToken";
|
|
2485
|
+
const _tK = "tagKeys";
|
|
2486
|
+
const _wTS = "waitTimeSeconds";
|
|
2804
2487
|
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
2805
2488
|
if (encoded.length) {
|
|
2806
2489
|
return JSON.parse(encoded);
|