@aws-sdk/client-kendra 3.310.0 → 3.312.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.
@@ -5,586 +5,391 @@ import { KendraServiceException as __BaseException } from "../models/KendraServi
5
5
  import { AccessDeniedException, ConflictException, FeaturedResultsConflictException, InternalServerException, InvalidRequestException, ResourceAlreadyExistException, ResourceNotFoundException, ResourceUnavailableException, ServiceQuotaExceededException, ThrottlingException, ValidationException, } from "../models/models_0";
6
6
  import { ResourceInUseException, } from "../models/models_1";
7
7
  export const se_AssociateEntitiesToExperienceCommand = async (input, context) => {
8
- const headers = {
9
- "content-type": "application/x-amz-json-1.1",
10
- "x-amz-target": "AWSKendraFrontendService.AssociateEntitiesToExperience",
11
- };
8
+ const headers = sharedHeaders("AssociateEntitiesToExperience");
12
9
  let body;
13
10
  body = JSON.stringify(se_AssociateEntitiesToExperienceRequest(input, context));
14
11
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
15
12
  };
16
13
  export const se_AssociatePersonasToEntitiesCommand = async (input, context) => {
17
- const headers = {
18
- "content-type": "application/x-amz-json-1.1",
19
- "x-amz-target": "AWSKendraFrontendService.AssociatePersonasToEntities",
20
- };
14
+ const headers = sharedHeaders("AssociatePersonasToEntities");
21
15
  let body;
22
16
  body = JSON.stringify(se_AssociatePersonasToEntitiesRequest(input, context));
23
17
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
24
18
  };
25
19
  export const se_BatchDeleteDocumentCommand = async (input, context) => {
26
- const headers = {
27
- "content-type": "application/x-amz-json-1.1",
28
- "x-amz-target": "AWSKendraFrontendService.BatchDeleteDocument",
29
- };
20
+ const headers = sharedHeaders("BatchDeleteDocument");
30
21
  let body;
31
22
  body = JSON.stringify(se_BatchDeleteDocumentRequest(input, context));
32
23
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
33
24
  };
34
25
  export const se_BatchDeleteFeaturedResultsSetCommand = async (input, context) => {
35
- const headers = {
36
- "content-type": "application/x-amz-json-1.1",
37
- "x-amz-target": "AWSKendraFrontendService.BatchDeleteFeaturedResultsSet",
38
- };
26
+ const headers = sharedHeaders("BatchDeleteFeaturedResultsSet");
39
27
  let body;
40
28
  body = JSON.stringify(se_BatchDeleteFeaturedResultsSetRequest(input, context));
41
29
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
42
30
  };
43
31
  export const se_BatchGetDocumentStatusCommand = async (input, context) => {
44
- const headers = {
45
- "content-type": "application/x-amz-json-1.1",
46
- "x-amz-target": "AWSKendraFrontendService.BatchGetDocumentStatus",
47
- };
32
+ const headers = sharedHeaders("BatchGetDocumentStatus");
48
33
  let body;
49
34
  body = JSON.stringify(se_BatchGetDocumentStatusRequest(input, context));
50
35
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
51
36
  };
52
37
  export const se_BatchPutDocumentCommand = async (input, context) => {
53
- const headers = {
54
- "content-type": "application/x-amz-json-1.1",
55
- "x-amz-target": "AWSKendraFrontendService.BatchPutDocument",
56
- };
38
+ const headers = sharedHeaders("BatchPutDocument");
57
39
  let body;
58
40
  body = JSON.stringify(se_BatchPutDocumentRequest(input, context));
59
41
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
60
42
  };
61
43
  export const se_ClearQuerySuggestionsCommand = async (input, context) => {
62
- const headers = {
63
- "content-type": "application/x-amz-json-1.1",
64
- "x-amz-target": "AWSKendraFrontendService.ClearQuerySuggestions",
65
- };
44
+ const headers = sharedHeaders("ClearQuerySuggestions");
66
45
  let body;
67
46
  body = JSON.stringify(se_ClearQuerySuggestionsRequest(input, context));
68
47
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
69
48
  };
70
49
  export const se_CreateAccessControlConfigurationCommand = async (input, context) => {
71
- const headers = {
72
- "content-type": "application/x-amz-json-1.1",
73
- "x-amz-target": "AWSKendraFrontendService.CreateAccessControlConfiguration",
74
- };
50
+ const headers = sharedHeaders("CreateAccessControlConfiguration");
75
51
  let body;
76
52
  body = JSON.stringify(se_CreateAccessControlConfigurationRequest(input, context));
77
53
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
78
54
  };
79
55
  export const se_CreateDataSourceCommand = async (input, context) => {
80
- const headers = {
81
- "content-type": "application/x-amz-json-1.1",
82
- "x-amz-target": "AWSKendraFrontendService.CreateDataSource",
83
- };
56
+ const headers = sharedHeaders("CreateDataSource");
84
57
  let body;
85
58
  body = JSON.stringify(se_CreateDataSourceRequest(input, context));
86
59
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
87
60
  };
88
61
  export const se_CreateExperienceCommand = async (input, context) => {
89
- const headers = {
90
- "content-type": "application/x-amz-json-1.1",
91
- "x-amz-target": "AWSKendraFrontendService.CreateExperience",
92
- };
62
+ const headers = sharedHeaders("CreateExperience");
93
63
  let body;
94
64
  body = JSON.stringify(se_CreateExperienceRequest(input, context));
95
65
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
96
66
  };
97
67
  export const se_CreateFaqCommand = async (input, context) => {
98
- const headers = {
99
- "content-type": "application/x-amz-json-1.1",
100
- "x-amz-target": "AWSKendraFrontendService.CreateFaq",
101
- };
68
+ const headers = sharedHeaders("CreateFaq");
102
69
  let body;
103
70
  body = JSON.stringify(se_CreateFaqRequest(input, context));
104
71
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
105
72
  };
106
73
  export const se_CreateFeaturedResultsSetCommand = async (input, context) => {
107
- const headers = {
108
- "content-type": "application/x-amz-json-1.1",
109
- "x-amz-target": "AWSKendraFrontendService.CreateFeaturedResultsSet",
110
- };
74
+ const headers = sharedHeaders("CreateFeaturedResultsSet");
111
75
  let body;
112
76
  body = JSON.stringify(se_CreateFeaturedResultsSetRequest(input, context));
113
77
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
114
78
  };
115
79
  export const se_CreateIndexCommand = async (input, context) => {
116
- const headers = {
117
- "content-type": "application/x-amz-json-1.1",
118
- "x-amz-target": "AWSKendraFrontendService.CreateIndex",
119
- };
80
+ const headers = sharedHeaders("CreateIndex");
120
81
  let body;
121
82
  body = JSON.stringify(se_CreateIndexRequest(input, context));
122
83
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
123
84
  };
124
85
  export const se_CreateQuerySuggestionsBlockListCommand = async (input, context) => {
125
- const headers = {
126
- "content-type": "application/x-amz-json-1.1",
127
- "x-amz-target": "AWSKendraFrontendService.CreateQuerySuggestionsBlockList",
128
- };
86
+ const headers = sharedHeaders("CreateQuerySuggestionsBlockList");
129
87
  let body;
130
88
  body = JSON.stringify(se_CreateQuerySuggestionsBlockListRequest(input, context));
131
89
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
132
90
  };
133
91
  export const se_CreateThesaurusCommand = async (input, context) => {
134
- const headers = {
135
- "content-type": "application/x-amz-json-1.1",
136
- "x-amz-target": "AWSKendraFrontendService.CreateThesaurus",
137
- };
92
+ const headers = sharedHeaders("CreateThesaurus");
138
93
  let body;
139
94
  body = JSON.stringify(se_CreateThesaurusRequest(input, context));
140
95
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
141
96
  };
142
97
  export const se_DeleteAccessControlConfigurationCommand = async (input, context) => {
143
- const headers = {
144
- "content-type": "application/x-amz-json-1.1",
145
- "x-amz-target": "AWSKendraFrontendService.DeleteAccessControlConfiguration",
146
- };
98
+ const headers = sharedHeaders("DeleteAccessControlConfiguration");
147
99
  let body;
148
100
  body = JSON.stringify(se_DeleteAccessControlConfigurationRequest(input, context));
149
101
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
150
102
  };
151
103
  export const se_DeleteDataSourceCommand = async (input, context) => {
152
- const headers = {
153
- "content-type": "application/x-amz-json-1.1",
154
- "x-amz-target": "AWSKendraFrontendService.DeleteDataSource",
155
- };
104
+ const headers = sharedHeaders("DeleteDataSource");
156
105
  let body;
157
106
  body = JSON.stringify(se_DeleteDataSourceRequest(input, context));
158
107
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
159
108
  };
160
109
  export const se_DeleteExperienceCommand = async (input, context) => {
161
- const headers = {
162
- "content-type": "application/x-amz-json-1.1",
163
- "x-amz-target": "AWSKendraFrontendService.DeleteExperience",
164
- };
110
+ const headers = sharedHeaders("DeleteExperience");
165
111
  let body;
166
112
  body = JSON.stringify(se_DeleteExperienceRequest(input, context));
167
113
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
168
114
  };
169
115
  export const se_DeleteFaqCommand = async (input, context) => {
170
- const headers = {
171
- "content-type": "application/x-amz-json-1.1",
172
- "x-amz-target": "AWSKendraFrontendService.DeleteFaq",
173
- };
116
+ const headers = sharedHeaders("DeleteFaq");
174
117
  let body;
175
118
  body = JSON.stringify(se_DeleteFaqRequest(input, context));
176
119
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
177
120
  };
178
121
  export const se_DeleteIndexCommand = async (input, context) => {
179
- const headers = {
180
- "content-type": "application/x-amz-json-1.1",
181
- "x-amz-target": "AWSKendraFrontendService.DeleteIndex",
182
- };
122
+ const headers = sharedHeaders("DeleteIndex");
183
123
  let body;
184
124
  body = JSON.stringify(se_DeleteIndexRequest(input, context));
185
125
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
186
126
  };
187
127
  export const se_DeletePrincipalMappingCommand = async (input, context) => {
188
- const headers = {
189
- "content-type": "application/x-amz-json-1.1",
190
- "x-amz-target": "AWSKendraFrontendService.DeletePrincipalMapping",
191
- };
128
+ const headers = sharedHeaders("DeletePrincipalMapping");
192
129
  let body;
193
130
  body = JSON.stringify(se_DeletePrincipalMappingRequest(input, context));
194
131
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
195
132
  };
196
133
  export const se_DeleteQuerySuggestionsBlockListCommand = async (input, context) => {
197
- const headers = {
198
- "content-type": "application/x-amz-json-1.1",
199
- "x-amz-target": "AWSKendraFrontendService.DeleteQuerySuggestionsBlockList",
200
- };
134
+ const headers = sharedHeaders("DeleteQuerySuggestionsBlockList");
201
135
  let body;
202
136
  body = JSON.stringify(se_DeleteQuerySuggestionsBlockListRequest(input, context));
203
137
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
204
138
  };
205
139
  export const se_DeleteThesaurusCommand = async (input, context) => {
206
- const headers = {
207
- "content-type": "application/x-amz-json-1.1",
208
- "x-amz-target": "AWSKendraFrontendService.DeleteThesaurus",
209
- };
140
+ const headers = sharedHeaders("DeleteThesaurus");
210
141
  let body;
211
142
  body = JSON.stringify(se_DeleteThesaurusRequest(input, context));
212
143
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
213
144
  };
214
145
  export const se_DescribeAccessControlConfigurationCommand = async (input, context) => {
215
- const headers = {
216
- "content-type": "application/x-amz-json-1.1",
217
- "x-amz-target": "AWSKendraFrontendService.DescribeAccessControlConfiguration",
218
- };
146
+ const headers = sharedHeaders("DescribeAccessControlConfiguration");
219
147
  let body;
220
148
  body = JSON.stringify(se_DescribeAccessControlConfigurationRequest(input, context));
221
149
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
222
150
  };
223
151
  export const se_DescribeDataSourceCommand = async (input, context) => {
224
- const headers = {
225
- "content-type": "application/x-amz-json-1.1",
226
- "x-amz-target": "AWSKendraFrontendService.DescribeDataSource",
227
- };
152
+ const headers = sharedHeaders("DescribeDataSource");
228
153
  let body;
229
154
  body = JSON.stringify(se_DescribeDataSourceRequest(input, context));
230
155
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
231
156
  };
232
157
  export const se_DescribeExperienceCommand = async (input, context) => {
233
- const headers = {
234
- "content-type": "application/x-amz-json-1.1",
235
- "x-amz-target": "AWSKendraFrontendService.DescribeExperience",
236
- };
158
+ const headers = sharedHeaders("DescribeExperience");
237
159
  let body;
238
160
  body = JSON.stringify(se_DescribeExperienceRequest(input, context));
239
161
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
240
162
  };
241
163
  export const se_DescribeFaqCommand = async (input, context) => {
242
- const headers = {
243
- "content-type": "application/x-amz-json-1.1",
244
- "x-amz-target": "AWSKendraFrontendService.DescribeFaq",
245
- };
164
+ const headers = sharedHeaders("DescribeFaq");
246
165
  let body;
247
166
  body = JSON.stringify(se_DescribeFaqRequest(input, context));
248
167
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
249
168
  };
250
169
  export const se_DescribeFeaturedResultsSetCommand = async (input, context) => {
251
- const headers = {
252
- "content-type": "application/x-amz-json-1.1",
253
- "x-amz-target": "AWSKendraFrontendService.DescribeFeaturedResultsSet",
254
- };
170
+ const headers = sharedHeaders("DescribeFeaturedResultsSet");
255
171
  let body;
256
172
  body = JSON.stringify(se_DescribeFeaturedResultsSetRequest(input, context));
257
173
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
258
174
  };
259
175
  export const se_DescribeIndexCommand = async (input, context) => {
260
- const headers = {
261
- "content-type": "application/x-amz-json-1.1",
262
- "x-amz-target": "AWSKendraFrontendService.DescribeIndex",
263
- };
176
+ const headers = sharedHeaders("DescribeIndex");
264
177
  let body;
265
178
  body = JSON.stringify(se_DescribeIndexRequest(input, context));
266
179
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
267
180
  };
268
181
  export const se_DescribePrincipalMappingCommand = async (input, context) => {
269
- const headers = {
270
- "content-type": "application/x-amz-json-1.1",
271
- "x-amz-target": "AWSKendraFrontendService.DescribePrincipalMapping",
272
- };
182
+ const headers = sharedHeaders("DescribePrincipalMapping");
273
183
  let body;
274
184
  body = JSON.stringify(se_DescribePrincipalMappingRequest(input, context));
275
185
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
276
186
  };
277
187
  export const se_DescribeQuerySuggestionsBlockListCommand = async (input, context) => {
278
- const headers = {
279
- "content-type": "application/x-amz-json-1.1",
280
- "x-amz-target": "AWSKendraFrontendService.DescribeQuerySuggestionsBlockList",
281
- };
188
+ const headers = sharedHeaders("DescribeQuerySuggestionsBlockList");
282
189
  let body;
283
190
  body = JSON.stringify(se_DescribeQuerySuggestionsBlockListRequest(input, context));
284
191
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
285
192
  };
286
193
  export const se_DescribeQuerySuggestionsConfigCommand = async (input, context) => {
287
- const headers = {
288
- "content-type": "application/x-amz-json-1.1",
289
- "x-amz-target": "AWSKendraFrontendService.DescribeQuerySuggestionsConfig",
290
- };
194
+ const headers = sharedHeaders("DescribeQuerySuggestionsConfig");
291
195
  let body;
292
196
  body = JSON.stringify(se_DescribeQuerySuggestionsConfigRequest(input, context));
293
197
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
294
198
  };
295
199
  export const se_DescribeThesaurusCommand = async (input, context) => {
296
- const headers = {
297
- "content-type": "application/x-amz-json-1.1",
298
- "x-amz-target": "AWSKendraFrontendService.DescribeThesaurus",
299
- };
200
+ const headers = sharedHeaders("DescribeThesaurus");
300
201
  let body;
301
202
  body = JSON.stringify(se_DescribeThesaurusRequest(input, context));
302
203
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
303
204
  };
304
205
  export const se_DisassociateEntitiesFromExperienceCommand = async (input, context) => {
305
- const headers = {
306
- "content-type": "application/x-amz-json-1.1",
307
- "x-amz-target": "AWSKendraFrontendService.DisassociateEntitiesFromExperience",
308
- };
206
+ const headers = sharedHeaders("DisassociateEntitiesFromExperience");
309
207
  let body;
310
208
  body = JSON.stringify(se_DisassociateEntitiesFromExperienceRequest(input, context));
311
209
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
312
210
  };
313
211
  export const se_DisassociatePersonasFromEntitiesCommand = async (input, context) => {
314
- const headers = {
315
- "content-type": "application/x-amz-json-1.1",
316
- "x-amz-target": "AWSKendraFrontendService.DisassociatePersonasFromEntities",
317
- };
212
+ const headers = sharedHeaders("DisassociatePersonasFromEntities");
318
213
  let body;
319
214
  body = JSON.stringify(se_DisassociatePersonasFromEntitiesRequest(input, context));
320
215
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
321
216
  };
322
217
  export const se_GetQuerySuggestionsCommand = async (input, context) => {
323
- const headers = {
324
- "content-type": "application/x-amz-json-1.1",
325
- "x-amz-target": "AWSKendraFrontendService.GetQuerySuggestions",
326
- };
218
+ const headers = sharedHeaders("GetQuerySuggestions");
327
219
  let body;
328
220
  body = JSON.stringify(se_GetQuerySuggestionsRequest(input, context));
329
221
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
330
222
  };
331
223
  export const se_GetSnapshotsCommand = async (input, context) => {
332
- const headers = {
333
- "content-type": "application/x-amz-json-1.1",
334
- "x-amz-target": "AWSKendraFrontendService.GetSnapshots",
335
- };
224
+ const headers = sharedHeaders("GetSnapshots");
336
225
  let body;
337
226
  body = JSON.stringify(se_GetSnapshotsRequest(input, context));
338
227
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
339
228
  };
340
229
  export const se_ListAccessControlConfigurationsCommand = async (input, context) => {
341
- const headers = {
342
- "content-type": "application/x-amz-json-1.1",
343
- "x-amz-target": "AWSKendraFrontendService.ListAccessControlConfigurations",
344
- };
230
+ const headers = sharedHeaders("ListAccessControlConfigurations");
345
231
  let body;
346
232
  body = JSON.stringify(se_ListAccessControlConfigurationsRequest(input, context));
347
233
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
348
234
  };
349
235
  export const se_ListDataSourcesCommand = async (input, context) => {
350
- const headers = {
351
- "content-type": "application/x-amz-json-1.1",
352
- "x-amz-target": "AWSKendraFrontendService.ListDataSources",
353
- };
236
+ const headers = sharedHeaders("ListDataSources");
354
237
  let body;
355
238
  body = JSON.stringify(se_ListDataSourcesRequest(input, context));
356
239
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
357
240
  };
358
241
  export const se_ListDataSourceSyncJobsCommand = async (input, context) => {
359
- const headers = {
360
- "content-type": "application/x-amz-json-1.1",
361
- "x-amz-target": "AWSKendraFrontendService.ListDataSourceSyncJobs",
362
- };
242
+ const headers = sharedHeaders("ListDataSourceSyncJobs");
363
243
  let body;
364
244
  body = JSON.stringify(se_ListDataSourceSyncJobsRequest(input, context));
365
245
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
366
246
  };
367
247
  export const se_ListEntityPersonasCommand = async (input, context) => {
368
- const headers = {
369
- "content-type": "application/x-amz-json-1.1",
370
- "x-amz-target": "AWSKendraFrontendService.ListEntityPersonas",
371
- };
248
+ const headers = sharedHeaders("ListEntityPersonas");
372
249
  let body;
373
250
  body = JSON.stringify(se_ListEntityPersonasRequest(input, context));
374
251
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
375
252
  };
376
253
  export const se_ListExperienceEntitiesCommand = async (input, context) => {
377
- const headers = {
378
- "content-type": "application/x-amz-json-1.1",
379
- "x-amz-target": "AWSKendraFrontendService.ListExperienceEntities",
380
- };
254
+ const headers = sharedHeaders("ListExperienceEntities");
381
255
  let body;
382
256
  body = JSON.stringify(se_ListExperienceEntitiesRequest(input, context));
383
257
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
384
258
  };
385
259
  export const se_ListExperiencesCommand = async (input, context) => {
386
- const headers = {
387
- "content-type": "application/x-amz-json-1.1",
388
- "x-amz-target": "AWSKendraFrontendService.ListExperiences",
389
- };
260
+ const headers = sharedHeaders("ListExperiences");
390
261
  let body;
391
262
  body = JSON.stringify(se_ListExperiencesRequest(input, context));
392
263
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
393
264
  };
394
265
  export const se_ListFaqsCommand = async (input, context) => {
395
- const headers = {
396
- "content-type": "application/x-amz-json-1.1",
397
- "x-amz-target": "AWSKendraFrontendService.ListFaqs",
398
- };
266
+ const headers = sharedHeaders("ListFaqs");
399
267
  let body;
400
268
  body = JSON.stringify(se_ListFaqsRequest(input, context));
401
269
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
402
270
  };
403
271
  export const se_ListFeaturedResultsSetsCommand = async (input, context) => {
404
- const headers = {
405
- "content-type": "application/x-amz-json-1.1",
406
- "x-amz-target": "AWSKendraFrontendService.ListFeaturedResultsSets",
407
- };
272
+ const headers = sharedHeaders("ListFeaturedResultsSets");
408
273
  let body;
409
274
  body = JSON.stringify(se_ListFeaturedResultsSetsRequest(input, context));
410
275
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
411
276
  };
412
277
  export const se_ListGroupsOlderThanOrderingIdCommand = async (input, context) => {
413
- const headers = {
414
- "content-type": "application/x-amz-json-1.1",
415
- "x-amz-target": "AWSKendraFrontendService.ListGroupsOlderThanOrderingId",
416
- };
278
+ const headers = sharedHeaders("ListGroupsOlderThanOrderingId");
417
279
  let body;
418
280
  body = JSON.stringify(se_ListGroupsOlderThanOrderingIdRequest(input, context));
419
281
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
420
282
  };
421
283
  export const se_ListIndicesCommand = async (input, context) => {
422
- const headers = {
423
- "content-type": "application/x-amz-json-1.1",
424
- "x-amz-target": "AWSKendraFrontendService.ListIndices",
425
- };
284
+ const headers = sharedHeaders("ListIndices");
426
285
  let body;
427
286
  body = JSON.stringify(se_ListIndicesRequest(input, context));
428
287
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
429
288
  };
430
289
  export const se_ListQuerySuggestionsBlockListsCommand = async (input, context) => {
431
- const headers = {
432
- "content-type": "application/x-amz-json-1.1",
433
- "x-amz-target": "AWSKendraFrontendService.ListQuerySuggestionsBlockLists",
434
- };
290
+ const headers = sharedHeaders("ListQuerySuggestionsBlockLists");
435
291
  let body;
436
292
  body = JSON.stringify(se_ListQuerySuggestionsBlockListsRequest(input, context));
437
293
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
438
294
  };
439
295
  export const se_ListTagsForResourceCommand = async (input, context) => {
440
- const headers = {
441
- "content-type": "application/x-amz-json-1.1",
442
- "x-amz-target": "AWSKendraFrontendService.ListTagsForResource",
443
- };
296
+ const headers = sharedHeaders("ListTagsForResource");
444
297
  let body;
445
298
  body = JSON.stringify(se_ListTagsForResourceRequest(input, context));
446
299
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
447
300
  };
448
301
  export const se_ListThesauriCommand = async (input, context) => {
449
- const headers = {
450
- "content-type": "application/x-amz-json-1.1",
451
- "x-amz-target": "AWSKendraFrontendService.ListThesauri",
452
- };
302
+ const headers = sharedHeaders("ListThesauri");
453
303
  let body;
454
304
  body = JSON.stringify(se_ListThesauriRequest(input, context));
455
305
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
456
306
  };
457
307
  export const se_PutPrincipalMappingCommand = async (input, context) => {
458
- const headers = {
459
- "content-type": "application/x-amz-json-1.1",
460
- "x-amz-target": "AWSKendraFrontendService.PutPrincipalMapping",
461
- };
308
+ const headers = sharedHeaders("PutPrincipalMapping");
462
309
  let body;
463
310
  body = JSON.stringify(se_PutPrincipalMappingRequest(input, context));
464
311
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
465
312
  };
466
313
  export const se_QueryCommand = async (input, context) => {
467
- const headers = {
468
- "content-type": "application/x-amz-json-1.1",
469
- "x-amz-target": "AWSKendraFrontendService.Query",
470
- };
314
+ const headers = sharedHeaders("Query");
471
315
  let body;
472
316
  body = JSON.stringify(se_QueryRequest(input, context));
473
317
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
474
318
  };
475
319
  export const se_StartDataSourceSyncJobCommand = async (input, context) => {
476
- const headers = {
477
- "content-type": "application/x-amz-json-1.1",
478
- "x-amz-target": "AWSKendraFrontendService.StartDataSourceSyncJob",
479
- };
320
+ const headers = sharedHeaders("StartDataSourceSyncJob");
480
321
  let body;
481
322
  body = JSON.stringify(se_StartDataSourceSyncJobRequest(input, context));
482
323
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
483
324
  };
484
325
  export const se_StopDataSourceSyncJobCommand = async (input, context) => {
485
- const headers = {
486
- "content-type": "application/x-amz-json-1.1",
487
- "x-amz-target": "AWSKendraFrontendService.StopDataSourceSyncJob",
488
- };
326
+ const headers = sharedHeaders("StopDataSourceSyncJob");
489
327
  let body;
490
328
  body = JSON.stringify(se_StopDataSourceSyncJobRequest(input, context));
491
329
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
492
330
  };
493
331
  export const se_SubmitFeedbackCommand = async (input, context) => {
494
- const headers = {
495
- "content-type": "application/x-amz-json-1.1",
496
- "x-amz-target": "AWSKendraFrontendService.SubmitFeedback",
497
- };
332
+ const headers = sharedHeaders("SubmitFeedback");
498
333
  let body;
499
334
  body = JSON.stringify(se_SubmitFeedbackRequest(input, context));
500
335
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
501
336
  };
502
337
  export const se_TagResourceCommand = async (input, context) => {
503
- const headers = {
504
- "content-type": "application/x-amz-json-1.1",
505
- "x-amz-target": "AWSKendraFrontendService.TagResource",
506
- };
338
+ const headers = sharedHeaders("TagResource");
507
339
  let body;
508
340
  body = JSON.stringify(se_TagResourceRequest(input, context));
509
341
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
510
342
  };
511
343
  export const se_UntagResourceCommand = async (input, context) => {
512
- const headers = {
513
- "content-type": "application/x-amz-json-1.1",
514
- "x-amz-target": "AWSKendraFrontendService.UntagResource",
515
- };
344
+ const headers = sharedHeaders("UntagResource");
516
345
  let body;
517
346
  body = JSON.stringify(se_UntagResourceRequest(input, context));
518
347
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
519
348
  };
520
349
  export const se_UpdateAccessControlConfigurationCommand = async (input, context) => {
521
- const headers = {
522
- "content-type": "application/x-amz-json-1.1",
523
- "x-amz-target": "AWSKendraFrontendService.UpdateAccessControlConfiguration",
524
- };
350
+ const headers = sharedHeaders("UpdateAccessControlConfiguration");
525
351
  let body;
526
352
  body = JSON.stringify(se_UpdateAccessControlConfigurationRequest(input, context));
527
353
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
528
354
  };
529
355
  export const se_UpdateDataSourceCommand = async (input, context) => {
530
- const headers = {
531
- "content-type": "application/x-amz-json-1.1",
532
- "x-amz-target": "AWSKendraFrontendService.UpdateDataSource",
533
- };
356
+ const headers = sharedHeaders("UpdateDataSource");
534
357
  let body;
535
358
  body = JSON.stringify(se_UpdateDataSourceRequest(input, context));
536
359
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
537
360
  };
538
361
  export const se_UpdateExperienceCommand = async (input, context) => {
539
- const headers = {
540
- "content-type": "application/x-amz-json-1.1",
541
- "x-amz-target": "AWSKendraFrontendService.UpdateExperience",
542
- };
362
+ const headers = sharedHeaders("UpdateExperience");
543
363
  let body;
544
364
  body = JSON.stringify(se_UpdateExperienceRequest(input, context));
545
365
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
546
366
  };
547
367
  export const se_UpdateFeaturedResultsSetCommand = async (input, context) => {
548
- const headers = {
549
- "content-type": "application/x-amz-json-1.1",
550
- "x-amz-target": "AWSKendraFrontendService.UpdateFeaturedResultsSet",
551
- };
368
+ const headers = sharedHeaders("UpdateFeaturedResultsSet");
552
369
  let body;
553
370
  body = JSON.stringify(se_UpdateFeaturedResultsSetRequest(input, context));
554
371
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
555
372
  };
556
373
  export const se_UpdateIndexCommand = async (input, context) => {
557
- const headers = {
558
- "content-type": "application/x-amz-json-1.1",
559
- "x-amz-target": "AWSKendraFrontendService.UpdateIndex",
560
- };
374
+ const headers = sharedHeaders("UpdateIndex");
561
375
  let body;
562
376
  body = JSON.stringify(se_UpdateIndexRequest(input, context));
563
377
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
564
378
  };
565
379
  export const se_UpdateQuerySuggestionsBlockListCommand = async (input, context) => {
566
- const headers = {
567
- "content-type": "application/x-amz-json-1.1",
568
- "x-amz-target": "AWSKendraFrontendService.UpdateQuerySuggestionsBlockList",
569
- };
380
+ const headers = sharedHeaders("UpdateQuerySuggestionsBlockList");
570
381
  let body;
571
382
  body = JSON.stringify(se_UpdateQuerySuggestionsBlockListRequest(input, context));
572
383
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
573
384
  };
574
385
  export const se_UpdateQuerySuggestionsConfigCommand = async (input, context) => {
575
- const headers = {
576
- "content-type": "application/x-amz-json-1.1",
577
- "x-amz-target": "AWSKendraFrontendService.UpdateQuerySuggestionsConfig",
578
- };
386
+ const headers = sharedHeaders("UpdateQuerySuggestionsConfig");
579
387
  let body;
580
388
  body = JSON.stringify(se_UpdateQuerySuggestionsConfigRequest(input, context));
581
389
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
582
390
  };
583
391
  export const se_UpdateThesaurusCommand = async (input, context) => {
584
- const headers = {
585
- "content-type": "application/x-amz-json-1.1",
586
- "x-amz-target": "AWSKendraFrontendService.UpdateThesaurus",
587
- };
392
+ const headers = sharedHeaders("UpdateThesaurus");
588
393
  let body;
589
394
  body = JSON.stringify(se_UpdateThesaurusRequest(input, context));
590
395
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
@@ -8585,6 +8390,12 @@ const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, bod
8585
8390
  }
8586
8391
  return new __HttpRequest(contents);
8587
8392
  };
8393
+ function sharedHeaders(operation) {
8394
+ return {
8395
+ "content-type": "application/x-amz-json-1.1",
8396
+ "x-amz-target": `AWSKendraFrontendService.${operation}`,
8397
+ };
8398
+ }
8588
8399
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
8589
8400
  if (encoded.length) {
8590
8401
  return JSON.parse(encoded);