@aws-sdk/client-wellarchitected 3.474.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.
@@ -1,123 +1,88 @@
1
- import { HttpRequest as __HttpRequest } from "@smithy/protocol-http";
2
- import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, map, parseEpochTimestamp as __parseEpochTimestamp, resolvedPath as __resolvedPath, take, withBaseException, } from "@smithy/smithy-client";
1
+ import { requestBuilder as rb } from "@smithy/core";
2
+ import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, map, parseEpochTimestamp as __parseEpochTimestamp, take, withBaseException, } from "@smithy/smithy-client";
3
3
  import { v4 as generateIdempotencyToken } from "uuid";
4
4
  import { AccessDeniedException, ConflictException, InternalServerException, ResourceNotFoundException, ServiceQuotaExceededException, ThrottlingException, ValidationException, } from "../models/models_0";
5
5
  import { WellArchitectedServiceException as __BaseException } from "../models/WellArchitectedServiceException";
6
6
  export const se_AssociateLensesCommand = async (input, context) => {
7
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
7
+ const b = rb(input, context);
8
8
  const headers = {
9
9
  "content-type": "application/json",
10
10
  };
11
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/associateLenses";
12
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
11
+ b.bp("/workloads/{WorkloadId}/associateLenses");
12
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
13
13
  let body;
14
14
  body = JSON.stringify(take(input, {
15
15
  LensAliases: (_) => _json(_),
16
16
  }));
17
- return new __HttpRequest({
18
- protocol,
19
- hostname,
20
- port,
21
- method: "PATCH",
22
- headers,
23
- path: resolvedPath,
24
- body,
25
- });
17
+ b.m("PATCH").h(headers).b(body);
18
+ return b.build();
26
19
  };
27
20
  export const se_AssociateProfilesCommand = async (input, context) => {
28
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
21
+ const b = rb(input, context);
29
22
  const headers = {
30
23
  "content-type": "application/json",
31
24
  };
32
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/associateProfiles";
33
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
25
+ b.bp("/workloads/{WorkloadId}/associateProfiles");
26
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
34
27
  let body;
35
28
  body = JSON.stringify(take(input, {
36
29
  ProfileArns: (_) => _json(_),
37
30
  }));
38
- return new __HttpRequest({
39
- protocol,
40
- hostname,
41
- port,
42
- method: "PATCH",
43
- headers,
44
- path: resolvedPath,
45
- body,
46
- });
31
+ b.m("PATCH").h(headers).b(body);
32
+ return b.build();
47
33
  };
48
34
  export const se_CreateLensShareCommand = async (input, context) => {
49
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
35
+ const b = rb(input, context);
50
36
  const headers = {
51
37
  "content-type": "application/json",
52
38
  };
53
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}/shares";
54
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
39
+ b.bp("/lenses/{LensAlias}/shares");
40
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
55
41
  let body;
56
42
  body = JSON.stringify(take(input, {
57
43
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
58
44
  SharedWith: [],
59
45
  }));
60
- return new __HttpRequest({
61
- protocol,
62
- hostname,
63
- port,
64
- method: "POST",
65
- headers,
66
- path: resolvedPath,
67
- body,
68
- });
46
+ b.m("POST").h(headers).b(body);
47
+ return b.build();
69
48
  };
70
49
  export const se_CreateLensVersionCommand = async (input, context) => {
71
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
50
+ const b = rb(input, context);
72
51
  const headers = {
73
52
  "content-type": "application/json",
74
53
  };
75
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}/versions";
76
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
54
+ b.bp("/lenses/{LensAlias}/versions");
55
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
77
56
  let body;
78
57
  body = JSON.stringify(take(input, {
79
58
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
80
59
  IsMajorVersion: [],
81
60
  LensVersion: [],
82
61
  }));
83
- return new __HttpRequest({
84
- protocol,
85
- hostname,
86
- port,
87
- method: "POST",
88
- headers,
89
- path: resolvedPath,
90
- body,
91
- });
62
+ b.m("POST").h(headers).b(body);
63
+ return b.build();
92
64
  };
93
65
  export const se_CreateMilestoneCommand = async (input, context) => {
94
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
66
+ const b = rb(input, context);
95
67
  const headers = {
96
68
  "content-type": "application/json",
97
69
  };
98
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/milestones";
99
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
70
+ b.bp("/workloads/{WorkloadId}/milestones");
71
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
100
72
  let body;
101
73
  body = JSON.stringify(take(input, {
102
74
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
103
75
  MilestoneName: [],
104
76
  }));
105
- return new __HttpRequest({
106
- protocol,
107
- hostname,
108
- port,
109
- method: "POST",
110
- headers,
111
- path: resolvedPath,
112
- body,
113
- });
77
+ b.m("POST").h(headers).b(body);
78
+ return b.build();
114
79
  };
115
80
  export const se_CreateProfileCommand = async (input, context) => {
116
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
81
+ const b = rb(input, context);
117
82
  const headers = {
118
83
  "content-type": "application/json",
119
84
  };
120
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles";
85
+ b.bp("/profiles");
121
86
  let body;
122
87
  body = JSON.stringify(take(input, {
123
88
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
@@ -126,44 +91,30 @@ export const se_CreateProfileCommand = async (input, context) => {
126
91
  ProfileQuestions: (_) => _json(_),
127
92
  Tags: (_) => _json(_),
128
93
  }));
129
- return new __HttpRequest({
130
- protocol,
131
- hostname,
132
- port,
133
- method: "POST",
134
- headers,
135
- path: resolvedPath,
136
- body,
137
- });
94
+ b.m("POST").h(headers).b(body);
95
+ return b.build();
138
96
  };
139
97
  export const se_CreateProfileShareCommand = async (input, context) => {
140
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
98
+ const b = rb(input, context);
141
99
  const headers = {
142
100
  "content-type": "application/json",
143
101
  };
144
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles/{ProfileArn}/shares";
145
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
102
+ b.bp("/profiles/{ProfileArn}/shares");
103
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
146
104
  let body;
147
105
  body = JSON.stringify(take(input, {
148
106
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
149
107
  SharedWith: [],
150
108
  }));
151
- return new __HttpRequest({
152
- protocol,
153
- hostname,
154
- port,
155
- method: "POST",
156
- headers,
157
- path: resolvedPath,
158
- body,
159
- });
109
+ b.m("POST").h(headers).b(body);
110
+ return b.build();
160
111
  };
161
112
  export const se_CreateReviewTemplateCommand = async (input, context) => {
162
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
113
+ const b = rb(input, context);
163
114
  const headers = {
164
115
  "content-type": "application/json",
165
116
  };
166
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/reviewTemplates";
117
+ b.bp("/reviewTemplates");
167
118
  let body;
168
119
  body = JSON.stringify(take(input, {
169
120
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
@@ -173,44 +124,30 @@ export const se_CreateReviewTemplateCommand = async (input, context) => {
173
124
  Tags: (_) => _json(_),
174
125
  TemplateName: [],
175
126
  }));
176
- return new __HttpRequest({
177
- protocol,
178
- hostname,
179
- port,
180
- method: "POST",
181
- headers,
182
- path: resolvedPath,
183
- body,
184
- });
127
+ b.m("POST").h(headers).b(body);
128
+ return b.build();
185
129
  };
186
130
  export const se_CreateTemplateShareCommand = async (input, context) => {
187
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
131
+ const b = rb(input, context);
188
132
  const headers = {
189
133
  "content-type": "application/json",
190
134
  };
191
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/templates/shares/{TemplateArn}";
192
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
135
+ b.bp("/templates/shares/{TemplateArn}");
136
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
193
137
  let body;
194
138
  body = JSON.stringify(take(input, {
195
139
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
196
140
  SharedWith: [],
197
141
  }));
198
- return new __HttpRequest({
199
- protocol,
200
- hostname,
201
- port,
202
- method: "POST",
203
- headers,
204
- path: resolvedPath,
205
- body,
206
- });
142
+ b.m("POST").h(headers).b(body);
143
+ return b.build();
207
144
  };
208
145
  export const se_CreateWorkloadCommand = async (input, context) => {
209
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
146
+ const b = rb(input, context);
210
147
  const headers = {
211
148
  "content-type": "application/json",
212
149
  };
213
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads";
150
+ b.bp("/workloads");
214
151
  let body;
215
152
  body = JSON.stringify(take(input, {
216
153
  AccountIds: (_) => _json(_),
@@ -233,532 +170,323 @@ export const se_CreateWorkloadCommand = async (input, context) => {
233
170
  Tags: (_) => _json(_),
234
171
  WorkloadName: [],
235
172
  }));
236
- return new __HttpRequest({
237
- protocol,
238
- hostname,
239
- port,
240
- method: "POST",
241
- headers,
242
- path: resolvedPath,
243
- body,
244
- });
173
+ b.m("POST").h(headers).b(body);
174
+ return b.build();
245
175
  };
246
176
  export const se_CreateWorkloadShareCommand = async (input, context) => {
247
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
177
+ const b = rb(input, context);
248
178
  const headers = {
249
179
  "content-type": "application/json",
250
180
  };
251
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/shares";
252
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
181
+ b.bp("/workloads/{WorkloadId}/shares");
182
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
253
183
  let body;
254
184
  body = JSON.stringify(take(input, {
255
185
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
256
186
  PermissionType: [],
257
187
  SharedWith: [],
258
188
  }));
259
- return new __HttpRequest({
260
- protocol,
261
- hostname,
262
- port,
263
- method: "POST",
264
- headers,
265
- path: resolvedPath,
266
- body,
267
- });
189
+ b.m("POST").h(headers).b(body);
190
+ return b.build();
268
191
  };
269
192
  export const se_DeleteLensCommand = async (input, context) => {
270
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
193
+ const b = rb(input, context);
271
194
  const headers = {};
272
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}";
273
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
195
+ b.bp("/lenses/{LensAlias}");
196
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
274
197
  const query = map({
275
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
276
- LensStatus: [, __expectNonNull(input.LensStatus, `LensStatus`)],
198
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
199
+ [_LS]: [, __expectNonNull(input[_LS], `LensStatus`)],
277
200
  });
278
201
  let body;
279
- return new __HttpRequest({
280
- protocol,
281
- hostname,
282
- port,
283
- method: "DELETE",
284
- headers,
285
- path: resolvedPath,
286
- query,
287
- body,
288
- });
202
+ b.m("DELETE").h(headers).q(query).b(body);
203
+ return b.build();
289
204
  };
290
205
  export const se_DeleteLensShareCommand = async (input, context) => {
291
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
206
+ const b = rb(input, context);
292
207
  const headers = {};
293
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}/shares/{ShareId}";
294
- resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId, "{ShareId}", false);
295
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
208
+ b.bp("/lenses/{LensAlias}/shares/{ShareId}");
209
+ b.p("ShareId", () => input.ShareId, "{ShareId}", false);
210
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
296
211
  const query = map({
297
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
212
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
298
213
  });
299
214
  let body;
300
- return new __HttpRequest({
301
- protocol,
302
- hostname,
303
- port,
304
- method: "DELETE",
305
- headers,
306
- path: resolvedPath,
307
- query,
308
- body,
309
- });
215
+ b.m("DELETE").h(headers).q(query).b(body);
216
+ return b.build();
310
217
  };
311
218
  export const se_DeleteProfileCommand = async (input, context) => {
312
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
219
+ const b = rb(input, context);
313
220
  const headers = {};
314
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles/{ProfileArn}";
315
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
221
+ b.bp("/profiles/{ProfileArn}");
222
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
316
223
  const query = map({
317
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
224
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
318
225
  });
319
226
  let body;
320
- return new __HttpRequest({
321
- protocol,
322
- hostname,
323
- port,
324
- method: "DELETE",
325
- headers,
326
- path: resolvedPath,
327
- query,
328
- body,
329
- });
227
+ b.m("DELETE").h(headers).q(query).b(body);
228
+ return b.build();
330
229
  };
331
230
  export const se_DeleteProfileShareCommand = async (input, context) => {
332
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
231
+ const b = rb(input, context);
333
232
  const headers = {};
334
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles/{ProfileArn}/shares/{ShareId}";
335
- resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId, "{ShareId}", false);
336
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
233
+ b.bp("/profiles/{ProfileArn}/shares/{ShareId}");
234
+ b.p("ShareId", () => input.ShareId, "{ShareId}", false);
235
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
337
236
  const query = map({
338
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
237
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
339
238
  });
340
239
  let body;
341
- return new __HttpRequest({
342
- protocol,
343
- hostname,
344
- port,
345
- method: "DELETE",
346
- headers,
347
- path: resolvedPath,
348
- query,
349
- body,
350
- });
240
+ b.m("DELETE").h(headers).q(query).b(body);
241
+ return b.build();
351
242
  };
352
243
  export const se_DeleteReviewTemplateCommand = async (input, context) => {
353
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
244
+ const b = rb(input, context);
354
245
  const headers = {};
355
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/reviewTemplates/{TemplateArn}";
356
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
246
+ b.bp("/reviewTemplates/{TemplateArn}");
247
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
357
248
  const query = map({
358
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
249
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
359
250
  });
360
251
  let body;
361
- return new __HttpRequest({
362
- protocol,
363
- hostname,
364
- port,
365
- method: "DELETE",
366
- headers,
367
- path: resolvedPath,
368
- query,
369
- body,
370
- });
252
+ b.m("DELETE").h(headers).q(query).b(body);
253
+ return b.build();
371
254
  };
372
255
  export const se_DeleteTemplateShareCommand = async (input, context) => {
373
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
256
+ const b = rb(input, context);
374
257
  const headers = {};
375
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/templates/shares/{TemplateArn}/{ShareId}";
376
- resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId, "{ShareId}", false);
377
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
258
+ b.bp("/templates/shares/{TemplateArn}/{ShareId}");
259
+ b.p("ShareId", () => input.ShareId, "{ShareId}", false);
260
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
378
261
  const query = map({
379
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
262
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
380
263
  });
381
264
  let body;
382
- return new __HttpRequest({
383
- protocol,
384
- hostname,
385
- port,
386
- method: "DELETE",
387
- headers,
388
- path: resolvedPath,
389
- query,
390
- body,
391
- });
265
+ b.m("DELETE").h(headers).q(query).b(body);
266
+ return b.build();
392
267
  };
393
268
  export const se_DeleteWorkloadCommand = async (input, context) => {
394
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
269
+ const b = rb(input, context);
395
270
  const headers = {};
396
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}";
397
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
271
+ b.bp("/workloads/{WorkloadId}");
272
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
398
273
  const query = map({
399
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
274
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
400
275
  });
401
276
  let body;
402
- return new __HttpRequest({
403
- protocol,
404
- hostname,
405
- port,
406
- method: "DELETE",
407
- headers,
408
- path: resolvedPath,
409
- query,
410
- body,
411
- });
277
+ b.m("DELETE").h(headers).q(query).b(body);
278
+ return b.build();
412
279
  };
413
280
  export const se_DeleteWorkloadShareCommand = async (input, context) => {
414
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
281
+ const b = rb(input, context);
415
282
  const headers = {};
416
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/shares/{ShareId}";
417
- resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId, "{ShareId}", false);
418
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
283
+ b.bp("/workloads/{WorkloadId}/shares/{ShareId}");
284
+ b.p("ShareId", () => input.ShareId, "{ShareId}", false);
285
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
419
286
  const query = map({
420
- ClientRequestToken: [, __expectNonNull(input.ClientRequestToken, `ClientRequestToken`)],
287
+ [_CRT]: [, __expectNonNull(input[_CRT], `ClientRequestToken`)],
421
288
  });
422
289
  let body;
423
- return new __HttpRequest({
424
- protocol,
425
- hostname,
426
- port,
427
- method: "DELETE",
428
- headers,
429
- path: resolvedPath,
430
- query,
431
- body,
432
- });
290
+ b.m("DELETE").h(headers).q(query).b(body);
291
+ return b.build();
433
292
  };
434
293
  export const se_DisassociateLensesCommand = async (input, context) => {
435
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
294
+ const b = rb(input, context);
436
295
  const headers = {
437
296
  "content-type": "application/json",
438
297
  };
439
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
440
- "/workloads/{WorkloadId}/disassociateLenses";
441
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
298
+ b.bp("/workloads/{WorkloadId}/disassociateLenses");
299
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
442
300
  let body;
443
301
  body = JSON.stringify(take(input, {
444
302
  LensAliases: (_) => _json(_),
445
303
  }));
446
- return new __HttpRequest({
447
- protocol,
448
- hostname,
449
- port,
450
- method: "PATCH",
451
- headers,
452
- path: resolvedPath,
453
- body,
454
- });
304
+ b.m("PATCH").h(headers).b(body);
305
+ return b.build();
455
306
  };
456
307
  export const se_DisassociateProfilesCommand = async (input, context) => {
457
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
308
+ const b = rb(input, context);
458
309
  const headers = {
459
310
  "content-type": "application/json",
460
311
  };
461
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
462
- "/workloads/{WorkloadId}/disassociateProfiles";
463
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
312
+ b.bp("/workloads/{WorkloadId}/disassociateProfiles");
313
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
464
314
  let body;
465
315
  body = JSON.stringify(take(input, {
466
316
  ProfileArns: (_) => _json(_),
467
317
  }));
468
- return new __HttpRequest({
469
- protocol,
470
- hostname,
471
- port,
472
- method: "PATCH",
473
- headers,
474
- path: resolvedPath,
475
- body,
476
- });
318
+ b.m("PATCH").h(headers).b(body);
319
+ return b.build();
477
320
  };
478
321
  export const se_ExportLensCommand = async (input, context) => {
479
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
322
+ const b = rb(input, context);
480
323
  const headers = {};
481
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}/export";
482
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
324
+ b.bp("/lenses/{LensAlias}/export");
325
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
483
326
  const query = map({
484
- LensVersion: [, input.LensVersion],
327
+ [_LV]: [, input[_LV]],
485
328
  });
486
329
  let body;
487
- return new __HttpRequest({
488
- protocol,
489
- hostname,
490
- port,
491
- method: "GET",
492
- headers,
493
- path: resolvedPath,
494
- query,
495
- body,
496
- });
330
+ b.m("GET").h(headers).q(query).b(body);
331
+ return b.build();
497
332
  };
498
333
  export const se_GetAnswerCommand = async (input, context) => {
499
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
334
+ const b = rb(input, context);
500
335
  const headers = {};
501
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
502
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}/answers/{QuestionId}";
503
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
504
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
505
- resolvedPath = __resolvedPath(resolvedPath, input, "QuestionId", () => input.QuestionId, "{QuestionId}", false);
336
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}/answers/{QuestionId}");
337
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
338
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
339
+ b.p("QuestionId", () => input.QuestionId, "{QuestionId}", false);
506
340
  const query = map({
507
- MilestoneNumber: [() => input.MilestoneNumber !== void 0, () => input.MilestoneNumber.toString()],
341
+ [_MN]: [() => input.MilestoneNumber !== void 0, () => input[_MN].toString()],
508
342
  });
509
343
  let body;
510
- return new __HttpRequest({
511
- protocol,
512
- hostname,
513
- port,
514
- method: "GET",
515
- headers,
516
- path: resolvedPath,
517
- query,
518
- body,
519
- });
344
+ b.m("GET").h(headers).q(query).b(body);
345
+ return b.build();
520
346
  };
521
347
  export const se_GetConsolidatedReportCommand = async (input, context) => {
522
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
348
+ const b = rb(input, context);
523
349
  const headers = {};
524
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/consolidatedReport";
350
+ b.bp("/consolidatedReport");
525
351
  const query = map({
526
- Format: [, __expectNonNull(input.Format, `Format`)],
527
- IncludeSharedResources: [
528
- () => input.IncludeSharedResources !== void 0,
529
- () => input.IncludeSharedResources.toString(),
530
- ],
531
- NextToken: [, input.NextToken],
532
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
352
+ [_F]: [, __expectNonNull(input[_F], `Format`)],
353
+ [_ISR]: [() => input.IncludeSharedResources !== void 0, () => input[_ISR].toString()],
354
+ [_NT]: [, input[_NT]],
355
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
533
356
  });
534
357
  let body;
535
- return new __HttpRequest({
536
- protocol,
537
- hostname,
538
- port,
539
- method: "GET",
540
- headers,
541
- path: resolvedPath,
542
- query,
543
- body,
544
- });
358
+ b.m("GET").h(headers).q(query).b(body);
359
+ return b.build();
545
360
  };
546
361
  export const se_GetLensCommand = async (input, context) => {
547
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
362
+ const b = rb(input, context);
548
363
  const headers = {};
549
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}";
550
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
364
+ b.bp("/lenses/{LensAlias}");
365
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
551
366
  const query = map({
552
- LensVersion: [, input.LensVersion],
367
+ [_LV]: [, input[_LV]],
553
368
  });
554
369
  let body;
555
- return new __HttpRequest({
556
- protocol,
557
- hostname,
558
- port,
559
- method: "GET",
560
- headers,
561
- path: resolvedPath,
562
- query,
563
- body,
564
- });
370
+ b.m("GET").h(headers).q(query).b(body);
371
+ return b.build();
565
372
  };
566
373
  export const se_GetLensReviewCommand = async (input, context) => {
567
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
374
+ const b = rb(input, context);
568
375
  const headers = {};
569
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
570
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}";
571
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
572
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
376
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}");
377
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
378
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
573
379
  const query = map({
574
- MilestoneNumber: [() => input.MilestoneNumber !== void 0, () => input.MilestoneNumber.toString()],
380
+ [_MN]: [() => input.MilestoneNumber !== void 0, () => input[_MN].toString()],
575
381
  });
576
382
  let body;
577
- return new __HttpRequest({
578
- protocol,
579
- hostname,
580
- port,
581
- method: "GET",
582
- headers,
583
- path: resolvedPath,
584
- query,
585
- body,
586
- });
383
+ b.m("GET").h(headers).q(query).b(body);
384
+ return b.build();
587
385
  };
588
386
  export const se_GetLensReviewReportCommand = async (input, context) => {
589
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
387
+ const b = rb(input, context);
590
388
  const headers = {};
591
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
592
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}/report";
593
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
594
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
389
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}/report");
390
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
391
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
595
392
  const query = map({
596
- MilestoneNumber: [() => input.MilestoneNumber !== void 0, () => input.MilestoneNumber.toString()],
393
+ [_MN]: [() => input.MilestoneNumber !== void 0, () => input[_MN].toString()],
597
394
  });
598
395
  let body;
599
- return new __HttpRequest({
600
- protocol,
601
- hostname,
602
- port,
603
- method: "GET",
604
- headers,
605
- path: resolvedPath,
606
- query,
607
- body,
608
- });
396
+ b.m("GET").h(headers).q(query).b(body);
397
+ return b.build();
609
398
  };
610
399
  export const se_GetLensVersionDifferenceCommand = async (input, context) => {
611
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
400
+ const b = rb(input, context);
612
401
  const headers = {};
613
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}/versionDifference";
614
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
402
+ b.bp("/lenses/{LensAlias}/versionDifference");
403
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
615
404
  const query = map({
616
- BaseLensVersion: [, input.BaseLensVersion],
617
- TargetLensVersion: [, input.TargetLensVersion],
405
+ [_BLV]: [, input[_BLV]],
406
+ [_TLV]: [, input[_TLV]],
618
407
  });
619
408
  let body;
620
- return new __HttpRequest({
621
- protocol,
622
- hostname,
623
- port,
624
- method: "GET",
625
- headers,
626
- path: resolvedPath,
627
- query,
628
- body,
629
- });
409
+ b.m("GET").h(headers).q(query).b(body);
410
+ return b.build();
630
411
  };
631
412
  export const se_GetMilestoneCommand = async (input, context) => {
632
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
413
+ const b = rb(input, context);
633
414
  const headers = {};
634
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
635
- "/workloads/{WorkloadId}/milestones/{MilestoneNumber}";
636
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
637
- resolvedPath = __resolvedPath(resolvedPath, input, "MilestoneNumber", () => input.MilestoneNumber.toString(), "{MilestoneNumber}", false);
415
+ b.bp("/workloads/{WorkloadId}/milestones/{MilestoneNumber}");
416
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
417
+ b.p("MilestoneNumber", () => input.MilestoneNumber.toString(), "{MilestoneNumber}", false);
638
418
  let body;
639
- return new __HttpRequest({
640
- protocol,
641
- hostname,
642
- port,
643
- method: "GET",
644
- headers,
645
- path: resolvedPath,
646
- body,
647
- });
419
+ b.m("GET").h(headers).b(body);
420
+ return b.build();
648
421
  };
649
422
  export const se_GetProfileCommand = async (input, context) => {
650
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
423
+ const b = rb(input, context);
651
424
  const headers = {};
652
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles/{ProfileArn}";
653
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
425
+ b.bp("/profiles/{ProfileArn}");
426
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
654
427
  const query = map({
655
- ProfileVersion: [, input.ProfileVersion],
428
+ [_PV]: [, input[_PV]],
656
429
  });
657
430
  let body;
658
- return new __HttpRequest({
659
- protocol,
660
- hostname,
661
- port,
662
- method: "GET",
663
- headers,
664
- path: resolvedPath,
665
- query,
666
- body,
667
- });
431
+ b.m("GET").h(headers).q(query).b(body);
432
+ return b.build();
668
433
  };
669
434
  export const se_GetProfileTemplateCommand = async (input, context) => {
670
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
435
+ const b = rb(input, context);
671
436
  const headers = {
672
437
  "content-type": "application/json",
673
438
  };
674
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profileTemplate";
439
+ b.bp("/profileTemplate");
675
440
  let body;
676
441
  body = "";
677
- return new __HttpRequest({
678
- protocol,
679
- hostname,
680
- port,
681
- method: "GET",
682
- headers,
683
- path: resolvedPath,
684
- body,
685
- });
442
+ b.m("GET").h(headers).b(body);
443
+ return b.build();
686
444
  };
687
445
  export const se_GetReviewTemplateCommand = async (input, context) => {
688
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
446
+ const b = rb(input, context);
689
447
  const headers = {};
690
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/reviewTemplates/{TemplateArn}";
691
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
448
+ b.bp("/reviewTemplates/{TemplateArn}");
449
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
692
450
  let body;
693
- return new __HttpRequest({
694
- protocol,
695
- hostname,
696
- port,
697
- method: "GET",
698
- headers,
699
- path: resolvedPath,
700
- body,
701
- });
451
+ b.m("GET").h(headers).b(body);
452
+ return b.build();
702
453
  };
703
454
  export const se_GetReviewTemplateAnswerCommand = async (input, context) => {
704
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
455
+ const b = rb(input, context);
705
456
  const headers = {};
706
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
707
- "/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/answers/{QuestionId}";
708
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
709
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
710
- resolvedPath = __resolvedPath(resolvedPath, input, "QuestionId", () => input.QuestionId, "{QuestionId}", false);
457
+ b.bp("/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/answers/{QuestionId}");
458
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
459
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
460
+ b.p("QuestionId", () => input.QuestionId, "{QuestionId}", false);
711
461
  let body;
712
- return new __HttpRequest({
713
- protocol,
714
- hostname,
715
- port,
716
- method: "GET",
717
- headers,
718
- path: resolvedPath,
719
- body,
720
- });
462
+ b.m("GET").h(headers).b(body);
463
+ return b.build();
721
464
  };
722
465
  export const se_GetReviewTemplateLensReviewCommand = async (input, context) => {
723
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
466
+ const b = rb(input, context);
724
467
  const headers = {};
725
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
726
- "/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}";
727
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
728
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
468
+ b.bp("/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}");
469
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
470
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
729
471
  let body;
730
- return new __HttpRequest({
731
- protocol,
732
- hostname,
733
- port,
734
- method: "GET",
735
- headers,
736
- path: resolvedPath,
737
- body,
738
- });
472
+ b.m("GET").h(headers).b(body);
473
+ return b.build();
739
474
  };
740
475
  export const se_GetWorkloadCommand = async (input, context) => {
741
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
476
+ const b = rb(input, context);
742
477
  const headers = {};
743
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}";
744
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
478
+ b.bp("/workloads/{WorkloadId}");
479
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
745
480
  let body;
746
- return new __HttpRequest({
747
- protocol,
748
- hostname,
749
- port,
750
- method: "GET",
751
- headers,
752
- path: resolvedPath,
753
- body,
754
- });
481
+ b.m("GET").h(headers).b(body);
482
+ return b.build();
755
483
  };
756
484
  export const se_ImportLensCommand = async (input, context) => {
757
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
485
+ const b = rb(input, context);
758
486
  const headers = {
759
487
  "content-type": "application/json",
760
488
  };
761
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/importLens";
489
+ b.bp("/importLens");
762
490
  let body;
763
491
  body = JSON.stringify(take(input, {
764
492
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
@@ -766,49 +494,33 @@ export const se_ImportLensCommand = async (input, context) => {
766
494
  LensAlias: [],
767
495
  Tags: (_) => _json(_),
768
496
  }));
769
- return new __HttpRequest({
770
- protocol,
771
- hostname,
772
- port,
773
- method: "PUT",
774
- headers,
775
- path: resolvedPath,
776
- body,
777
- });
497
+ b.m("PUT").h(headers).b(body);
498
+ return b.build();
778
499
  };
779
500
  export const se_ListAnswersCommand = async (input, context) => {
780
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
501
+ const b = rb(input, context);
781
502
  const headers = {};
782
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
783
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}/answers";
784
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
785
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
503
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}/answers");
504
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
505
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
786
506
  const query = map({
787
- PillarId: [, input.PillarId],
788
- MilestoneNumber: [() => input.MilestoneNumber !== void 0, () => input.MilestoneNumber.toString()],
789
- NextToken: [, input.NextToken],
790
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
791
- QuestionPriority: [, input.QuestionPriority],
507
+ [_PI]: [, input[_PI]],
508
+ [_MN]: [() => input.MilestoneNumber !== void 0, () => input[_MN].toString()],
509
+ [_NT]: [, input[_NT]],
510
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
511
+ [_QP]: [, input[_QP]],
792
512
  });
793
513
  let body;
794
- return new __HttpRequest({
795
- protocol,
796
- hostname,
797
- port,
798
- method: "GET",
799
- headers,
800
- path: resolvedPath,
801
- query,
802
- body,
803
- });
514
+ b.m("GET").h(headers).q(query).b(body);
515
+ return b.build();
804
516
  };
805
517
  export const se_ListCheckDetailsCommand = async (input, context) => {
806
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
518
+ const b = rb(input, context);
807
519
  const headers = {
808
520
  "content-type": "application/json",
809
521
  };
810
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/checks";
811
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
522
+ b.bp("/workloads/{WorkloadId}/checks");
523
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
812
524
  let body;
813
525
  body = JSON.stringify(take(input, {
814
526
  ChoiceId: [],
@@ -818,23 +530,16 @@ export const se_ListCheckDetailsCommand = async (input, context) => {
818
530
  PillarId: [],
819
531
  QuestionId: [],
820
532
  }));
821
- return new __HttpRequest({
822
- protocol,
823
- hostname,
824
- port,
825
- method: "POST",
826
- headers,
827
- path: resolvedPath,
828
- body,
829
- });
533
+ b.m("POST").h(headers).b(body);
534
+ return b.build();
830
535
  };
831
536
  export const se_ListCheckSummariesCommand = async (input, context) => {
832
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
537
+ const b = rb(input, context);
833
538
  const headers = {
834
539
  "content-type": "application/json",
835
540
  };
836
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/checkSummaries";
837
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
541
+ b.bp("/workloads/{WorkloadId}/checkSummaries");
542
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
838
543
  let body;
839
544
  body = JSON.stringify(take(input, {
840
545
  ChoiceId: [],
@@ -844,139 +549,91 @@ export const se_ListCheckSummariesCommand = async (input, context) => {
844
549
  PillarId: [],
845
550
  QuestionId: [],
846
551
  }));
847
- return new __HttpRequest({
848
- protocol,
849
- hostname,
850
- port,
851
- method: "POST",
852
- headers,
853
- path: resolvedPath,
854
- body,
855
- });
552
+ b.m("POST").h(headers).b(body);
553
+ return b.build();
856
554
  };
857
555
  export const se_ListLensesCommand = async (input, context) => {
858
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
556
+ const b = rb(input, context);
859
557
  const headers = {};
860
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses";
558
+ b.bp("/lenses");
861
559
  const query = map({
862
- NextToken: [, input.NextToken],
863
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
864
- LensType: [, input.LensType],
865
- LensStatus: [, input.LensStatus],
866
- LensName: [, input.LensName],
560
+ [_NT]: [, input[_NT]],
561
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
562
+ [_LT]: [, input[_LT]],
563
+ [_LS]: [, input[_LS]],
564
+ [_LN]: [, input[_LN]],
867
565
  });
868
566
  let body;
869
- return new __HttpRequest({
870
- protocol,
871
- hostname,
872
- port,
873
- method: "GET",
874
- headers,
875
- path: resolvedPath,
876
- query,
877
- body,
878
- });
567
+ b.m("GET").h(headers).q(query).b(body);
568
+ return b.build();
879
569
  };
880
570
  export const se_ListLensReviewImprovementsCommand = async (input, context) => {
881
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
571
+ const b = rb(input, context);
882
572
  const headers = {};
883
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
884
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}/improvements";
885
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
886
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
573
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}/improvements");
574
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
575
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
887
576
  const query = map({
888
- PillarId: [, input.PillarId],
889
- MilestoneNumber: [() => input.MilestoneNumber !== void 0, () => input.MilestoneNumber.toString()],
890
- NextToken: [, input.NextToken],
891
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
892
- QuestionPriority: [, input.QuestionPriority],
577
+ [_PI]: [, input[_PI]],
578
+ [_MN]: [() => input.MilestoneNumber !== void 0, () => input[_MN].toString()],
579
+ [_NT]: [, input[_NT]],
580
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
581
+ [_QP]: [, input[_QP]],
893
582
  });
894
583
  let body;
895
- return new __HttpRequest({
896
- protocol,
897
- hostname,
898
- port,
899
- method: "GET",
900
- headers,
901
- path: resolvedPath,
902
- query,
903
- body,
904
- });
584
+ b.m("GET").h(headers).q(query).b(body);
585
+ return b.build();
905
586
  };
906
587
  export const se_ListLensReviewsCommand = async (input, context) => {
907
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
588
+ const b = rb(input, context);
908
589
  const headers = {};
909
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/lensReviews";
910
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
590
+ b.bp("/workloads/{WorkloadId}/lensReviews");
591
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
911
592
  const query = map({
912
- MilestoneNumber: [() => input.MilestoneNumber !== void 0, () => input.MilestoneNumber.toString()],
913
- NextToken: [, input.NextToken],
914
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
593
+ [_MN]: [() => input.MilestoneNumber !== void 0, () => input[_MN].toString()],
594
+ [_NT]: [, input[_NT]],
595
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
915
596
  });
916
597
  let body;
917
- return new __HttpRequest({
918
- protocol,
919
- hostname,
920
- port,
921
- method: "GET",
922
- headers,
923
- path: resolvedPath,
924
- query,
925
- body,
926
- });
598
+ b.m("GET").h(headers).q(query).b(body);
599
+ return b.build();
927
600
  };
928
601
  export const se_ListLensSharesCommand = async (input, context) => {
929
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
602
+ const b = rb(input, context);
930
603
  const headers = {};
931
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}/shares";
932
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
604
+ b.bp("/lenses/{LensAlias}/shares");
605
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
933
606
  const query = map({
934
- SharedWithPrefix: [, input.SharedWithPrefix],
935
- NextToken: [, input.NextToken],
936
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
937
- Status: [, input.Status],
607
+ [_SWP]: [, input[_SWP]],
608
+ [_NT]: [, input[_NT]],
609
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
610
+ [_S]: [, input[_S]],
938
611
  });
939
612
  let body;
940
- return new __HttpRequest({
941
- protocol,
942
- hostname,
943
- port,
944
- method: "GET",
945
- headers,
946
- path: resolvedPath,
947
- query,
948
- body,
949
- });
613
+ b.m("GET").h(headers).q(query).b(body);
614
+ return b.build();
950
615
  };
951
616
  export const se_ListMilestonesCommand = async (input, context) => {
952
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
617
+ const b = rb(input, context);
953
618
  const headers = {
954
619
  "content-type": "application/json",
955
620
  };
956
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
957
- "/workloads/{WorkloadId}/milestonesSummaries";
958
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
621
+ b.bp("/workloads/{WorkloadId}/milestonesSummaries");
622
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
959
623
  let body;
960
624
  body = JSON.stringify(take(input, {
961
625
  MaxResults: [],
962
626
  NextToken: [],
963
627
  }));
964
- return new __HttpRequest({
965
- protocol,
966
- hostname,
967
- port,
968
- method: "POST",
969
- headers,
970
- path: resolvedPath,
971
- body,
972
- });
628
+ b.m("POST").h(headers).b(body);
629
+ return b.build();
973
630
  };
974
631
  export const se_ListNotificationsCommand = async (input, context) => {
975
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
632
+ const b = rb(input, context);
976
633
  const headers = {
977
634
  "content-type": "application/json",
978
635
  };
979
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/notifications";
636
+ b.bp("/notifications");
980
637
  let body;
981
638
  body = JSON.stringify(take(input, {
982
639
  MaxResults: [],
@@ -984,289 +641,187 @@ export const se_ListNotificationsCommand = async (input, context) => {
984
641
  ResourceArn: [],
985
642
  WorkloadId: [],
986
643
  }));
987
- return new __HttpRequest({
988
- protocol,
989
- hostname,
990
- port,
991
- method: "POST",
992
- headers,
993
- path: resolvedPath,
994
- body,
995
- });
644
+ b.m("POST").h(headers).b(body);
645
+ return b.build();
996
646
  };
997
647
  export const se_ListProfileNotificationsCommand = async (input, context) => {
998
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
648
+ const b = rb(input, context);
999
649
  const headers = {};
1000
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profileNotifications";
650
+ b.bp("/profileNotifications");
1001
651
  const query = map({
1002
- WorkloadId: [, input.WorkloadId],
1003
- NextToken: [, input.NextToken],
1004
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
652
+ [_WI]: [, input[_WI]],
653
+ [_NT]: [, input[_NT]],
654
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
1005
655
  });
1006
656
  let body;
1007
- return new __HttpRequest({
1008
- protocol,
1009
- hostname,
1010
- port,
1011
- method: "GET",
1012
- headers,
1013
- path: resolvedPath,
1014
- query,
1015
- body,
1016
- });
657
+ b.m("GET").h(headers).q(query).b(body);
658
+ return b.build();
1017
659
  };
1018
660
  export const se_ListProfilesCommand = async (input, context) => {
1019
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
661
+ const b = rb(input, context);
1020
662
  const headers = {};
1021
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profileSummaries";
663
+ b.bp("/profileSummaries");
1022
664
  const query = map({
1023
- ProfileNamePrefix: [, input.ProfileNamePrefix],
1024
- ProfileOwnerType: [, input.ProfileOwnerType],
1025
- NextToken: [, input.NextToken],
1026
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
665
+ [_PNP]: [, input[_PNP]],
666
+ [_POT]: [, input[_POT]],
667
+ [_NT]: [, input[_NT]],
668
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
1027
669
  });
1028
670
  let body;
1029
- return new __HttpRequest({
1030
- protocol,
1031
- hostname,
1032
- port,
1033
- method: "GET",
1034
- headers,
1035
- path: resolvedPath,
1036
- query,
1037
- body,
1038
- });
671
+ b.m("GET").h(headers).q(query).b(body);
672
+ return b.build();
1039
673
  };
1040
674
  export const se_ListProfileSharesCommand = async (input, context) => {
1041
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
675
+ const b = rb(input, context);
1042
676
  const headers = {};
1043
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles/{ProfileArn}/shares";
1044
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
677
+ b.bp("/profiles/{ProfileArn}/shares");
678
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
1045
679
  const query = map({
1046
- SharedWithPrefix: [, input.SharedWithPrefix],
1047
- NextToken: [, input.NextToken],
1048
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
1049
- Status: [, input.Status],
680
+ [_SWP]: [, input[_SWP]],
681
+ [_NT]: [, input[_NT]],
682
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
683
+ [_S]: [, input[_S]],
1050
684
  });
1051
685
  let body;
1052
- return new __HttpRequest({
1053
- protocol,
1054
- hostname,
1055
- port,
1056
- method: "GET",
1057
- headers,
1058
- path: resolvedPath,
1059
- query,
1060
- body,
1061
- });
686
+ b.m("GET").h(headers).q(query).b(body);
687
+ return b.build();
1062
688
  };
1063
689
  export const se_ListReviewTemplateAnswersCommand = async (input, context) => {
1064
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
690
+ const b = rb(input, context);
1065
691
  const headers = {};
1066
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1067
- "/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/answers";
1068
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1069
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
692
+ b.bp("/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/answers");
693
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
694
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
1070
695
  const query = map({
1071
- PillarId: [, input.PillarId],
1072
- NextToken: [, input.NextToken],
1073
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
696
+ [_PI]: [, input[_PI]],
697
+ [_NT]: [, input[_NT]],
698
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
1074
699
  });
1075
700
  let body;
1076
- return new __HttpRequest({
1077
- protocol,
1078
- hostname,
1079
- port,
1080
- method: "GET",
1081
- headers,
1082
- path: resolvedPath,
1083
- query,
1084
- body,
1085
- });
701
+ b.m("GET").h(headers).q(query).b(body);
702
+ return b.build();
1086
703
  };
1087
704
  export const se_ListReviewTemplatesCommand = async (input, context) => {
1088
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
705
+ const b = rb(input, context);
1089
706
  const headers = {};
1090
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/reviewTemplates";
707
+ b.bp("/reviewTemplates");
1091
708
  const query = map({
1092
- NextToken: [, input.NextToken],
1093
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
709
+ [_NT]: [, input[_NT]],
710
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
1094
711
  });
1095
712
  let body;
1096
- return new __HttpRequest({
1097
- protocol,
1098
- hostname,
1099
- port,
1100
- method: "GET",
1101
- headers,
1102
- path: resolvedPath,
1103
- query,
1104
- body,
1105
- });
713
+ b.m("GET").h(headers).q(query).b(body);
714
+ return b.build();
1106
715
  };
1107
716
  export const se_ListShareInvitationsCommand = async (input, context) => {
1108
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
717
+ const b = rb(input, context);
1109
718
  const headers = {};
1110
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/shareInvitations";
719
+ b.bp("/shareInvitations");
1111
720
  const query = map({
1112
- WorkloadNamePrefix: [, input.WorkloadNamePrefix],
1113
- LensNamePrefix: [, input.LensNamePrefix],
1114
- ShareResourceType: [, input.ShareResourceType],
1115
- NextToken: [, input.NextToken],
1116
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
1117
- ProfileNamePrefix: [, input.ProfileNamePrefix],
1118
- TemplateNamePrefix: [, input.TemplateNamePrefix],
721
+ [_WNP]: [, input[_WNP]],
722
+ [_LNP]: [, input[_LNP]],
723
+ [_SRT]: [, input[_SRT]],
724
+ [_NT]: [, input[_NT]],
725
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
726
+ [_PNP]: [, input[_PNP]],
727
+ [_TNP]: [, input[_TNP]],
1119
728
  });
1120
729
  let body;
1121
- return new __HttpRequest({
1122
- protocol,
1123
- hostname,
1124
- port,
1125
- method: "GET",
1126
- headers,
1127
- path: resolvedPath,
1128
- query,
1129
- body,
1130
- });
730
+ b.m("GET").h(headers).q(query).b(body);
731
+ return b.build();
1131
732
  };
1132
733
  export const se_ListTagsForResourceCommand = async (input, context) => {
1133
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
734
+ const b = rb(input, context);
1134
735
  const headers = {};
1135
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{WorkloadArn}";
1136
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadArn", () => input.WorkloadArn, "{WorkloadArn}", false);
736
+ b.bp("/tags/{WorkloadArn}");
737
+ b.p("WorkloadArn", () => input.WorkloadArn, "{WorkloadArn}", false);
1137
738
  let body;
1138
- return new __HttpRequest({
1139
- protocol,
1140
- hostname,
1141
- port,
1142
- method: "GET",
1143
- headers,
1144
- path: resolvedPath,
1145
- body,
1146
- });
739
+ b.m("GET").h(headers).b(body);
740
+ return b.build();
1147
741
  };
1148
742
  export const se_ListTemplateSharesCommand = async (input, context) => {
1149
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
743
+ const b = rb(input, context);
1150
744
  const headers = {};
1151
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/templates/shares/{TemplateArn}";
1152
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
745
+ b.bp("/templates/shares/{TemplateArn}");
746
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1153
747
  const query = map({
1154
- SharedWithPrefix: [, input.SharedWithPrefix],
1155
- NextToken: [, input.NextToken],
1156
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
1157
- Status: [, input.Status],
748
+ [_SWP]: [, input[_SWP]],
749
+ [_NT]: [, input[_NT]],
750
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
751
+ [_S]: [, input[_S]],
1158
752
  });
1159
753
  let body;
1160
- return new __HttpRequest({
1161
- protocol,
1162
- hostname,
1163
- port,
1164
- method: "GET",
1165
- headers,
1166
- path: resolvedPath,
1167
- query,
1168
- body,
1169
- });
754
+ b.m("GET").h(headers).q(query).b(body);
755
+ return b.build();
1170
756
  };
1171
757
  export const se_ListWorkloadsCommand = async (input, context) => {
1172
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
758
+ const b = rb(input, context);
1173
759
  const headers = {
1174
760
  "content-type": "application/json",
1175
761
  };
1176
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloadsSummaries";
762
+ b.bp("/workloadsSummaries");
1177
763
  let body;
1178
764
  body = JSON.stringify(take(input, {
1179
765
  MaxResults: [],
1180
766
  NextToken: [],
1181
767
  WorkloadNamePrefix: [],
1182
768
  }));
1183
- return new __HttpRequest({
1184
- protocol,
1185
- hostname,
1186
- port,
1187
- method: "POST",
1188
- headers,
1189
- path: resolvedPath,
1190
- body,
1191
- });
769
+ b.m("POST").h(headers).b(body);
770
+ return b.build();
1192
771
  };
1193
772
  export const se_ListWorkloadSharesCommand = async (input, context) => {
1194
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
773
+ const b = rb(input, context);
1195
774
  const headers = {};
1196
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/shares";
1197
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
775
+ b.bp("/workloads/{WorkloadId}/shares");
776
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1198
777
  const query = map({
1199
- SharedWithPrefix: [, input.SharedWithPrefix],
1200
- NextToken: [, input.NextToken],
1201
- MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
1202
- Status: [, input.Status],
778
+ [_SWP]: [, input[_SWP]],
779
+ [_NT]: [, input[_NT]],
780
+ [_MR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
781
+ [_S]: [, input[_S]],
1203
782
  });
1204
783
  let body;
1205
- return new __HttpRequest({
1206
- protocol,
1207
- hostname,
1208
- port,
1209
- method: "GET",
1210
- headers,
1211
- path: resolvedPath,
1212
- query,
1213
- body,
1214
- });
784
+ b.m("GET").h(headers).q(query).b(body);
785
+ return b.build();
1215
786
  };
1216
787
  export const se_TagResourceCommand = async (input, context) => {
1217
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
788
+ const b = rb(input, context);
1218
789
  const headers = {
1219
790
  "content-type": "application/json",
1220
791
  };
1221
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{WorkloadArn}";
1222
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadArn", () => input.WorkloadArn, "{WorkloadArn}", false);
792
+ b.bp("/tags/{WorkloadArn}");
793
+ b.p("WorkloadArn", () => input.WorkloadArn, "{WorkloadArn}", false);
1223
794
  let body;
1224
795
  body = JSON.stringify(take(input, {
1225
796
  Tags: (_) => _json(_),
1226
797
  }));
1227
- return new __HttpRequest({
1228
- protocol,
1229
- hostname,
1230
- port,
1231
- method: "POST",
1232
- headers,
1233
- path: resolvedPath,
1234
- body,
1235
- });
798
+ b.m("POST").h(headers).b(body);
799
+ return b.build();
1236
800
  };
1237
801
  export const se_UntagResourceCommand = async (input, context) => {
1238
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
802
+ const b = rb(input, context);
1239
803
  const headers = {};
1240
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{WorkloadArn}";
1241
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadArn", () => input.WorkloadArn, "{WorkloadArn}", false);
804
+ b.bp("/tags/{WorkloadArn}");
805
+ b.p("WorkloadArn", () => input.WorkloadArn, "{WorkloadArn}", false);
1242
806
  const query = map({
1243
- tagKeys: [
807
+ [_tK]: [
1244
808
  __expectNonNull(input.TagKeys, `TagKeys`) != null,
1245
- () => (input.TagKeys || []).map((_entry) => _entry),
809
+ () => (input[_TK] || []).map((_entry) => _entry),
1246
810
  ],
1247
811
  });
1248
812
  let body;
1249
- return new __HttpRequest({
1250
- protocol,
1251
- hostname,
1252
- port,
1253
- method: "DELETE",
1254
- headers,
1255
- path: resolvedPath,
1256
- query,
1257
- body,
1258
- });
813
+ b.m("DELETE").h(headers).q(query).b(body);
814
+ return b.build();
1259
815
  };
1260
816
  export const se_UpdateAnswerCommand = async (input, context) => {
1261
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
817
+ const b = rb(input, context);
1262
818
  const headers = {
1263
819
  "content-type": "application/json",
1264
820
  };
1265
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1266
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}/answers/{QuestionId}";
1267
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1268
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
1269
- resolvedPath = __resolvedPath(resolvedPath, input, "QuestionId", () => input.QuestionId, "{QuestionId}", false);
821
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}/answers/{QuestionId}");
822
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
823
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
824
+ b.p("QuestionId", () => input.QuestionId, "{QuestionId}", false);
1270
825
  let body;
1271
826
  body = JSON.stringify(take(input, {
1272
827
  ChoiceUpdates: (_) => _json(_),
@@ -1275,90 +830,61 @@ export const se_UpdateAnswerCommand = async (input, context) => {
1275
830
  Reason: [],
1276
831
  SelectedChoices: (_) => _json(_),
1277
832
  }));
1278
- return new __HttpRequest({
1279
- protocol,
1280
- hostname,
1281
- port,
1282
- method: "PATCH",
1283
- headers,
1284
- path: resolvedPath,
1285
- body,
1286
- });
833
+ b.m("PATCH").h(headers).b(body);
834
+ return b.build();
1287
835
  };
1288
836
  export const se_UpdateGlobalSettingsCommand = async (input, context) => {
1289
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
837
+ const b = rb(input, context);
1290
838
  const headers = {
1291
839
  "content-type": "application/json",
1292
840
  };
1293
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/global-settings";
841
+ b.bp("/global-settings");
1294
842
  let body;
1295
843
  body = JSON.stringify(take(input, {
1296
844
  DiscoveryIntegrationStatus: [],
1297
845
  OrganizationSharingStatus: [],
1298
846
  }));
1299
- return new __HttpRequest({
1300
- protocol,
1301
- hostname,
1302
- port,
1303
- method: "PATCH",
1304
- headers,
1305
- path: resolvedPath,
1306
- body,
1307
- });
847
+ b.m("PATCH").h(headers).b(body);
848
+ return b.build();
1308
849
  };
1309
850
  export const se_UpdateLensReviewCommand = async (input, context) => {
1310
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
851
+ const b = rb(input, context);
1311
852
  const headers = {
1312
853
  "content-type": "application/json",
1313
854
  };
1314
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1315
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}";
1316
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1317
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
855
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}");
856
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
857
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
1318
858
  let body;
1319
859
  body = JSON.stringify(take(input, {
1320
860
  LensNotes: [],
1321
861
  PillarNotes: (_) => _json(_),
1322
862
  }));
1323
- return new __HttpRequest({
1324
- protocol,
1325
- hostname,
1326
- port,
1327
- method: "PATCH",
1328
- headers,
1329
- path: resolvedPath,
1330
- body,
1331
- });
863
+ b.m("PATCH").h(headers).b(body);
864
+ return b.build();
1332
865
  };
1333
866
  export const se_UpdateProfileCommand = async (input, context) => {
1334
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
867
+ const b = rb(input, context);
1335
868
  const headers = {
1336
869
  "content-type": "application/json",
1337
870
  };
1338
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles/{ProfileArn}";
1339
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
871
+ b.bp("/profiles/{ProfileArn}");
872
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
1340
873
  let body;
1341
874
  body = JSON.stringify(take(input, {
1342
875
  ProfileDescription: [],
1343
876
  ProfileQuestions: (_) => _json(_),
1344
877
  }));
1345
- return new __HttpRequest({
1346
- protocol,
1347
- hostname,
1348
- port,
1349
- method: "PATCH",
1350
- headers,
1351
- path: resolvedPath,
1352
- body,
1353
- });
878
+ b.m("PATCH").h(headers).b(body);
879
+ return b.build();
1354
880
  };
1355
881
  export const se_UpdateReviewTemplateCommand = async (input, context) => {
1356
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
882
+ const b = rb(input, context);
1357
883
  const headers = {
1358
884
  "content-type": "application/json",
1359
885
  };
1360
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/reviewTemplates/{TemplateArn}";
1361
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
886
+ b.bp("/reviewTemplates/{TemplateArn}");
887
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1362
888
  let body;
1363
889
  body = JSON.stringify(take(input, {
1364
890
  Description: [],
@@ -1367,26 +893,18 @@ export const se_UpdateReviewTemplateCommand = async (input, context) => {
1367
893
  Notes: [],
1368
894
  TemplateName: [],
1369
895
  }));
1370
- return new __HttpRequest({
1371
- protocol,
1372
- hostname,
1373
- port,
1374
- method: "PATCH",
1375
- headers,
1376
- path: resolvedPath,
1377
- body,
1378
- });
896
+ b.m("PATCH").h(headers).b(body);
897
+ return b.build();
1379
898
  };
1380
899
  export const se_UpdateReviewTemplateAnswerCommand = async (input, context) => {
1381
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
900
+ const b = rb(input, context);
1382
901
  const headers = {
1383
902
  "content-type": "application/json",
1384
903
  };
1385
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1386
- "/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/answers/{QuestionId}";
1387
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1388
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
1389
- resolvedPath = __resolvedPath(resolvedPath, input, "QuestionId", () => input.QuestionId, "{QuestionId}", false);
904
+ b.bp("/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/answers/{QuestionId}");
905
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
906
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
907
+ b.p("QuestionId", () => input.QuestionId, "{QuestionId}", false);
1390
908
  let body;
1391
909
  body = JSON.stringify(take(input, {
1392
910
  ChoiceUpdates: (_) => _json(_),
@@ -1395,68 +913,46 @@ export const se_UpdateReviewTemplateAnswerCommand = async (input, context) => {
1395
913
  Reason: [],
1396
914
  SelectedChoices: (_) => _json(_),
1397
915
  }));
1398
- return new __HttpRequest({
1399
- protocol,
1400
- hostname,
1401
- port,
1402
- method: "PATCH",
1403
- headers,
1404
- path: resolvedPath,
1405
- body,
1406
- });
916
+ b.m("PATCH").h(headers).b(body);
917
+ return b.build();
1407
918
  };
1408
919
  export const se_UpdateReviewTemplateLensReviewCommand = async (input, context) => {
1409
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
920
+ const b = rb(input, context);
1410
921
  const headers = {
1411
922
  "content-type": "application/json",
1412
923
  };
1413
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1414
- "/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}";
1415
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1416
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
924
+ b.bp("/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}");
925
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
926
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
1417
927
  let body;
1418
928
  body = JSON.stringify(take(input, {
1419
929
  LensNotes: [],
1420
930
  PillarNotes: (_) => _json(_),
1421
931
  }));
1422
- return new __HttpRequest({
1423
- protocol,
1424
- hostname,
1425
- port,
1426
- method: "PATCH",
1427
- headers,
1428
- path: resolvedPath,
1429
- body,
1430
- });
932
+ b.m("PATCH").h(headers).b(body);
933
+ return b.build();
1431
934
  };
1432
935
  export const se_UpdateShareInvitationCommand = async (input, context) => {
1433
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
936
+ const b = rb(input, context);
1434
937
  const headers = {
1435
938
  "content-type": "application/json",
1436
939
  };
1437
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/shareInvitations/{ShareInvitationId}";
1438
- resolvedPath = __resolvedPath(resolvedPath, input, "ShareInvitationId", () => input.ShareInvitationId, "{ShareInvitationId}", false);
940
+ b.bp("/shareInvitations/{ShareInvitationId}");
941
+ b.p("ShareInvitationId", () => input.ShareInvitationId, "{ShareInvitationId}", false);
1439
942
  let body;
1440
943
  body = JSON.stringify(take(input, {
1441
944
  ShareInvitationAction: [],
1442
945
  }));
1443
- return new __HttpRequest({
1444
- protocol,
1445
- hostname,
1446
- port,
1447
- method: "PATCH",
1448
- headers,
1449
- path: resolvedPath,
1450
- body,
1451
- });
946
+ b.m("PATCH").h(headers).b(body);
947
+ return b.build();
1452
948
  };
1453
949
  export const se_UpdateWorkloadCommand = async (input, context) => {
1454
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
950
+ const b = rb(input, context);
1455
951
  const headers = {
1456
952
  "content-type": "application/json",
1457
953
  };
1458
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}";
1459
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
954
+ b.bp("/workloads/{WorkloadId}");
955
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1460
956
  let body;
1461
957
  body = JSON.stringify(take(input, {
1462
958
  AccountIds: (_) => _json(_),
@@ -1476,108 +972,70 @@ export const se_UpdateWorkloadCommand = async (input, context) => {
1476
972
  ReviewOwner: [],
1477
973
  WorkloadName: [],
1478
974
  }));
1479
- return new __HttpRequest({
1480
- protocol,
1481
- hostname,
1482
- port,
1483
- method: "PATCH",
1484
- headers,
1485
- path: resolvedPath,
1486
- body,
1487
- });
975
+ b.m("PATCH").h(headers).b(body);
976
+ return b.build();
1488
977
  };
1489
978
  export const se_UpdateWorkloadShareCommand = async (input, context) => {
1490
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
979
+ const b = rb(input, context);
1491
980
  const headers = {
1492
981
  "content-type": "application/json",
1493
982
  };
1494
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}/shares/{ShareId}";
1495
- resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId, "{ShareId}", false);
1496
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
983
+ b.bp("/workloads/{WorkloadId}/shares/{ShareId}");
984
+ b.p("ShareId", () => input.ShareId, "{ShareId}", false);
985
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1497
986
  let body;
1498
987
  body = JSON.stringify(take(input, {
1499
988
  PermissionType: [],
1500
989
  }));
1501
- return new __HttpRequest({
1502
- protocol,
1503
- hostname,
1504
- port,
1505
- method: "PATCH",
1506
- headers,
1507
- path: resolvedPath,
1508
- body,
1509
- });
990
+ b.m("PATCH").h(headers).b(body);
991
+ return b.build();
1510
992
  };
1511
993
  export const se_UpgradeLensReviewCommand = async (input, context) => {
1512
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
994
+ const b = rb(input, context);
1513
995
  const headers = {
1514
996
  "content-type": "application/json",
1515
997
  };
1516
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1517
- "/workloads/{WorkloadId}/lensReviews/{LensAlias}/upgrade";
1518
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1519
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
998
+ b.bp("/workloads/{WorkloadId}/lensReviews/{LensAlias}/upgrade");
999
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1000
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
1520
1001
  let body;
1521
1002
  body = JSON.stringify(take(input, {
1522
1003
  ClientRequestToken: [],
1523
1004
  MilestoneName: [],
1524
1005
  }));
1525
- return new __HttpRequest({
1526
- protocol,
1527
- hostname,
1528
- port,
1529
- method: "PUT",
1530
- headers,
1531
- path: resolvedPath,
1532
- body,
1533
- });
1006
+ b.m("PUT").h(headers).b(body);
1007
+ return b.build();
1534
1008
  };
1535
1009
  export const se_UpgradeProfileVersionCommand = async (input, context) => {
1536
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1010
+ const b = rb(input, context);
1537
1011
  const headers = {
1538
1012
  "content-type": "application/json",
1539
1013
  };
1540
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1541
- "/workloads/{WorkloadId}/profiles/{ProfileArn}/upgrade";
1542
- resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1543
- resolvedPath = __resolvedPath(resolvedPath, input, "ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
1014
+ b.bp("/workloads/{WorkloadId}/profiles/{ProfileArn}/upgrade");
1015
+ b.p("WorkloadId", () => input.WorkloadId, "{WorkloadId}", false);
1016
+ b.p("ProfileArn", () => input.ProfileArn, "{ProfileArn}", false);
1544
1017
  let body;
1545
1018
  body = JSON.stringify(take(input, {
1546
1019
  ClientRequestToken: [true, (_) => _ ?? generateIdempotencyToken()],
1547
1020
  MilestoneName: [],
1548
1021
  }));
1549
- return new __HttpRequest({
1550
- protocol,
1551
- hostname,
1552
- port,
1553
- method: "PUT",
1554
- headers,
1555
- path: resolvedPath,
1556
- body,
1557
- });
1022
+ b.m("PUT").h(headers).b(body);
1023
+ return b.build();
1558
1024
  };
1559
1025
  export const se_UpgradeReviewTemplateLensReviewCommand = async (input, context) => {
1560
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1026
+ const b = rb(input, context);
1561
1027
  const headers = {
1562
1028
  "content-type": "application/json",
1563
1029
  };
1564
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
1565
- "/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/upgrade";
1566
- resolvedPath = __resolvedPath(resolvedPath, input, "TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1567
- resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias, "{LensAlias}", false);
1030
+ b.bp("/reviewTemplates/{TemplateArn}/lensReviews/{LensAlias}/upgrade");
1031
+ b.p("TemplateArn", () => input.TemplateArn, "{TemplateArn}", false);
1032
+ b.p("LensAlias", () => input.LensAlias, "{LensAlias}", false);
1568
1033
  let body;
1569
1034
  body = JSON.stringify(take(input, {
1570
1035
  ClientRequestToken: [],
1571
1036
  }));
1572
- return new __HttpRequest({
1573
- protocol,
1574
- hostname,
1575
- port,
1576
- method: "PUT",
1577
- headers,
1578
- path: resolvedPath,
1579
- body,
1580
- });
1037
+ b.m("PUT").h(headers).b(body);
1038
+ return b.build();
1581
1039
  };
1582
1040
  export const de_AssociateLensesCommand = async (output, context) => {
1583
1041
  if (output.statusCode !== 200 && output.statusCode >= 300) {
@@ -5215,6 +4673,32 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
5215
4673
  value !== "" &&
5216
4674
  (!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
5217
4675
  (!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
4676
+ const _BLV = "BaseLensVersion";
4677
+ const _CRT = "ClientRequestToken";
4678
+ const _F = "Format";
4679
+ const _ISR = "IncludeSharedResources";
4680
+ const _LN = "LensName";
4681
+ const _LNP = "LensNamePrefix";
4682
+ const _LS = "LensStatus";
4683
+ const _LT = "LensType";
4684
+ const _LV = "LensVersion";
4685
+ const _MN = "MilestoneNumber";
4686
+ const _MR = "MaxResults";
4687
+ const _NT = "NextToken";
4688
+ const _PI = "PillarId";
4689
+ const _PNP = "ProfileNamePrefix";
4690
+ const _POT = "ProfileOwnerType";
4691
+ const _PV = "ProfileVersion";
4692
+ const _QP = "QuestionPriority";
4693
+ const _S = "Status";
4694
+ const _SRT = "ShareResourceType";
4695
+ const _SWP = "SharedWithPrefix";
4696
+ const _TK = "TagKeys";
4697
+ const _TLV = "TargetLensVersion";
4698
+ const _TNP = "TemplateNamePrefix";
4699
+ const _WI = "WorkloadId";
4700
+ const _WNP = "WorkloadNamePrefix";
4701
+ const _tK = "tagKeys";
5218
4702
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
5219
4703
  if (encoded.length) {
5220
4704
  return JSON.parse(encoded);