@aws-sdk/client-imagebuilder 3.200.0 → 3.202.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,25 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.202.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.201.0...v3.202.0) (2022-11-02)
7
+
8
+ **Note:** Version bump only for package @aws-sdk/client-imagebuilder
9
+
10
+
11
+
12
+
13
+
14
+ # [3.201.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.200.0...v3.201.0) (2022-11-01)
15
+
16
+
17
+ ### Features
18
+
19
+ * end support for Node.js 12.x ([#4123](https://github.com/aws/aws-sdk-js-v3/issues/4123)) ([83f913e](https://github.com/aws/aws-sdk-js-v3/commit/83f913ec2ac3878d8726c6964f585550dc5caf3e))
20
+
21
+
22
+
23
+
24
+
6
25
  # [3.200.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.199.0...v3.200.0) (2022-10-31)
7
26
 
8
27
  **Note:** Version bump only for package @aws-sdk/client-imagebuilder
@@ -2,11 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.resolveClientEndpointParameters = void 0;
4
4
  const resolveClientEndpointParameters = (options) => {
5
- var _a, _b;
6
5
  return {
7
6
  ...options,
8
- useDualstackEndpoint: (_a = options.useDualstackEndpoint) !== null && _a !== void 0 ? _a : false,
9
- useFipsEndpoint: (_b = options.useFipsEndpoint) !== null && _b !== void 0 ? _b : false,
7
+ useDualstackEndpoint: options.useDualstackEndpoint ?? false,
8
+ useFipsEndpoint: options.useFipsEndpoint ?? false,
10
9
  defaultSigningName: "imagebuilder",
11
10
  };
12
11
  };
@@ -8,15 +8,14 @@ const uuid_1 = require("uuid");
8
8
  const ImagebuilderServiceException_1 = require("../models/ImagebuilderServiceException");
9
9
  const models_0_1 = require("../models/models_0");
10
10
  const serializeAws_restJson1CancelImageCreationCommand = async (input, context) => {
11
- var _a;
12
11
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
13
12
  const headers = {
14
13
  "content-type": "application/json",
15
14
  };
16
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CancelImageCreation";
15
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CancelImageCreation";
17
16
  let body;
18
17
  body = JSON.stringify({
19
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
18
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
20
19
  ...(input.imageBuildVersionArn != null && { imageBuildVersionArn: input.imageBuildVersionArn }),
21
20
  });
22
21
  return new protocol_http_1.HttpRequest({
@@ -31,16 +30,15 @@ const serializeAws_restJson1CancelImageCreationCommand = async (input, context)
31
30
  };
32
31
  exports.serializeAws_restJson1CancelImageCreationCommand = serializeAws_restJson1CancelImageCreationCommand;
33
32
  const serializeAws_restJson1CreateComponentCommand = async (input, context) => {
34
- var _a;
35
33
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
36
34
  const headers = {
37
35
  "content-type": "application/json",
38
36
  };
39
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateComponent";
37
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateComponent";
40
38
  let body;
41
39
  body = JSON.stringify({
42
40
  ...(input.changeDescription != null && { changeDescription: input.changeDescription }),
43
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
41
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
44
42
  ...(input.data != null && { data: input.data }),
45
43
  ...(input.description != null && { description: input.description }),
46
44
  ...(input.kmsKeyId != null && { kmsKeyId: input.kmsKeyId }),
@@ -65,15 +63,14 @@ const serializeAws_restJson1CreateComponentCommand = async (input, context) => {
65
63
  };
66
64
  exports.serializeAws_restJson1CreateComponentCommand = serializeAws_restJson1CreateComponentCommand;
67
65
  const serializeAws_restJson1CreateContainerRecipeCommand = async (input, context) => {
68
- var _a;
69
66
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
70
67
  const headers = {
71
68
  "content-type": "application/json",
72
69
  };
73
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateContainerRecipe";
70
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateContainerRecipe";
74
71
  let body;
75
72
  body = JSON.stringify({
76
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
73
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
77
74
  ...(input.components != null && {
78
75
  components: serializeAws_restJson1ComponentConfigurationList(input.components, context),
79
76
  }),
@@ -108,15 +105,14 @@ const serializeAws_restJson1CreateContainerRecipeCommand = async (input, context
108
105
  };
109
106
  exports.serializeAws_restJson1CreateContainerRecipeCommand = serializeAws_restJson1CreateContainerRecipeCommand;
110
107
  const serializeAws_restJson1CreateDistributionConfigurationCommand = async (input, context) => {
111
- var _a;
112
108
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
113
109
  const headers = {
114
110
  "content-type": "application/json",
115
111
  };
116
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateDistributionConfiguration";
112
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateDistributionConfiguration";
117
113
  let body;
118
114
  body = JSON.stringify({
119
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
115
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
120
116
  ...(input.description != null && { description: input.description }),
121
117
  ...(input.distributions != null && {
122
118
  distributions: serializeAws_restJson1DistributionList(input.distributions, context),
@@ -136,15 +132,14 @@ const serializeAws_restJson1CreateDistributionConfigurationCommand = async (inpu
136
132
  };
137
133
  exports.serializeAws_restJson1CreateDistributionConfigurationCommand = serializeAws_restJson1CreateDistributionConfigurationCommand;
138
134
  const serializeAws_restJson1CreateImageCommand = async (input, context) => {
139
- var _a;
140
135
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
141
136
  const headers = {
142
137
  "content-type": "application/json",
143
138
  };
144
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateImage";
139
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateImage";
145
140
  let body;
146
141
  body = JSON.stringify({
147
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
142
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
148
143
  ...(input.containerRecipeArn != null && { containerRecipeArn: input.containerRecipeArn }),
149
144
  ...(input.distributionConfigurationArn != null && {
150
145
  distributionConfigurationArn: input.distributionConfigurationArn,
@@ -173,15 +168,14 @@ const serializeAws_restJson1CreateImageCommand = async (input, context) => {
173
168
  };
174
169
  exports.serializeAws_restJson1CreateImageCommand = serializeAws_restJson1CreateImageCommand;
175
170
  const serializeAws_restJson1CreateImagePipelineCommand = async (input, context) => {
176
- var _a;
177
171
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
178
172
  const headers = {
179
173
  "content-type": "application/json",
180
174
  };
181
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateImagePipeline";
175
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateImagePipeline";
182
176
  let body;
183
177
  body = JSON.stringify({
184
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
178
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
185
179
  ...(input.containerRecipeArn != null && { containerRecipeArn: input.containerRecipeArn }),
186
180
  ...(input.description != null && { description: input.description }),
187
181
  ...(input.distributionConfigurationArn != null && {
@@ -214,12 +208,11 @@ const serializeAws_restJson1CreateImagePipelineCommand = async (input, context)
214
208
  };
215
209
  exports.serializeAws_restJson1CreateImagePipelineCommand = serializeAws_restJson1CreateImagePipelineCommand;
216
210
  const serializeAws_restJson1CreateImageRecipeCommand = async (input, context) => {
217
- var _a;
218
211
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
219
212
  const headers = {
220
213
  "content-type": "application/json",
221
214
  };
222
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateImageRecipe";
215
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateImageRecipe";
223
216
  let body;
224
217
  body = JSON.stringify({
225
218
  ...(input.additionalInstanceConfiguration != null && {
@@ -228,7 +221,7 @@ const serializeAws_restJson1CreateImageRecipeCommand = async (input, context) =>
228
221
  ...(input.blockDeviceMappings != null && {
229
222
  blockDeviceMappings: serializeAws_restJson1InstanceBlockDeviceMappings(input.blockDeviceMappings, context),
230
223
  }),
231
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
224
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
232
225
  ...(input.components != null && {
233
226
  components: serializeAws_restJson1ComponentConfigurationList(input.components, context),
234
227
  }),
@@ -251,15 +244,14 @@ const serializeAws_restJson1CreateImageRecipeCommand = async (input, context) =>
251
244
  };
252
245
  exports.serializeAws_restJson1CreateImageRecipeCommand = serializeAws_restJson1CreateImageRecipeCommand;
253
246
  const serializeAws_restJson1CreateInfrastructureConfigurationCommand = async (input, context) => {
254
- var _a;
255
247
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
256
248
  const headers = {
257
249
  "content-type": "application/json",
258
250
  };
259
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/CreateInfrastructureConfiguration";
251
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateInfrastructureConfiguration";
260
252
  let body;
261
253
  body = JSON.stringify({
262
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
254
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
263
255
  ...(input.description != null && { description: input.description }),
264
256
  ...(input.instanceMetadataOptions != null && {
265
257
  instanceMetadataOptions: serializeAws_restJson1InstanceMetadataOptions(input.instanceMetadataOptions, context),
@@ -296,7 +288,7 @@ exports.serializeAws_restJson1CreateInfrastructureConfigurationCommand = seriali
296
288
  const serializeAws_restJson1DeleteComponentCommand = async (input, context) => {
297
289
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
298
290
  const headers = {};
299
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteComponent";
291
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteComponent";
300
292
  const query = map({
301
293
  componentBuildVersionArn: [, input.componentBuildVersionArn],
302
294
  });
@@ -316,7 +308,7 @@ exports.serializeAws_restJson1DeleteComponentCommand = serializeAws_restJson1Del
316
308
  const serializeAws_restJson1DeleteContainerRecipeCommand = async (input, context) => {
317
309
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
318
310
  const headers = {};
319
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteContainerRecipe";
311
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteContainerRecipe";
320
312
  const query = map({
321
313
  containerRecipeArn: [, input.containerRecipeArn],
322
314
  });
@@ -336,7 +328,7 @@ exports.serializeAws_restJson1DeleteContainerRecipeCommand = serializeAws_restJs
336
328
  const serializeAws_restJson1DeleteDistributionConfigurationCommand = async (input, context) => {
337
329
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
338
330
  const headers = {};
339
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteDistributionConfiguration";
331
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteDistributionConfiguration";
340
332
  const query = map({
341
333
  distributionConfigurationArn: [, input.distributionConfigurationArn],
342
334
  });
@@ -356,7 +348,7 @@ exports.serializeAws_restJson1DeleteDistributionConfigurationCommand = serialize
356
348
  const serializeAws_restJson1DeleteImageCommand = async (input, context) => {
357
349
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
358
350
  const headers = {};
359
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImage";
351
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImage";
360
352
  const query = map({
361
353
  imageBuildVersionArn: [, input.imageBuildVersionArn],
362
354
  });
@@ -376,7 +368,7 @@ exports.serializeAws_restJson1DeleteImageCommand = serializeAws_restJson1DeleteI
376
368
  const serializeAws_restJson1DeleteImagePipelineCommand = async (input, context) => {
377
369
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
378
370
  const headers = {};
379
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImagePipeline";
371
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImagePipeline";
380
372
  const query = map({
381
373
  imagePipelineArn: [, input.imagePipelineArn],
382
374
  });
@@ -396,7 +388,7 @@ exports.serializeAws_restJson1DeleteImagePipelineCommand = serializeAws_restJson
396
388
  const serializeAws_restJson1DeleteImageRecipeCommand = async (input, context) => {
397
389
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
398
390
  const headers = {};
399
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImageRecipe";
391
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImageRecipe";
400
392
  const query = map({
401
393
  imageRecipeArn: [, input.imageRecipeArn],
402
394
  });
@@ -416,7 +408,7 @@ exports.serializeAws_restJson1DeleteImageRecipeCommand = serializeAws_restJson1D
416
408
  const serializeAws_restJson1DeleteInfrastructureConfigurationCommand = async (input, context) => {
417
409
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
418
410
  const headers = {};
419
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteInfrastructureConfiguration";
411
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteInfrastructureConfiguration";
420
412
  const query = map({
421
413
  infrastructureConfigurationArn: [, input.infrastructureConfigurationArn],
422
414
  });
@@ -436,7 +428,7 @@ exports.serializeAws_restJson1DeleteInfrastructureConfigurationCommand = seriali
436
428
  const serializeAws_restJson1GetComponentCommand = async (input, context) => {
437
429
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
438
430
  const headers = {};
439
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetComponent";
431
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetComponent";
440
432
  const query = map({
441
433
  componentBuildVersionArn: [, input.componentBuildVersionArn],
442
434
  });
@@ -456,7 +448,7 @@ exports.serializeAws_restJson1GetComponentCommand = serializeAws_restJson1GetCom
456
448
  const serializeAws_restJson1GetComponentPolicyCommand = async (input, context) => {
457
449
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
458
450
  const headers = {};
459
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetComponentPolicy";
451
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetComponentPolicy";
460
452
  const query = map({
461
453
  componentArn: [, input.componentArn],
462
454
  });
@@ -476,7 +468,7 @@ exports.serializeAws_restJson1GetComponentPolicyCommand = serializeAws_restJson1
476
468
  const serializeAws_restJson1GetContainerRecipeCommand = async (input, context) => {
477
469
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
478
470
  const headers = {};
479
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetContainerRecipe";
471
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetContainerRecipe";
480
472
  const query = map({
481
473
  containerRecipeArn: [, input.containerRecipeArn],
482
474
  });
@@ -496,7 +488,7 @@ exports.serializeAws_restJson1GetContainerRecipeCommand = serializeAws_restJson1
496
488
  const serializeAws_restJson1GetContainerRecipePolicyCommand = async (input, context) => {
497
489
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
498
490
  const headers = {};
499
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetContainerRecipePolicy";
491
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetContainerRecipePolicy";
500
492
  const query = map({
501
493
  containerRecipeArn: [, input.containerRecipeArn],
502
494
  });
@@ -516,7 +508,7 @@ exports.serializeAws_restJson1GetContainerRecipePolicyCommand = serializeAws_res
516
508
  const serializeAws_restJson1GetDistributionConfigurationCommand = async (input, context) => {
517
509
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
518
510
  const headers = {};
519
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetDistributionConfiguration";
511
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetDistributionConfiguration";
520
512
  const query = map({
521
513
  distributionConfigurationArn: [, input.distributionConfigurationArn],
522
514
  });
@@ -536,7 +528,7 @@ exports.serializeAws_restJson1GetDistributionConfigurationCommand = serializeAws
536
528
  const serializeAws_restJson1GetImageCommand = async (input, context) => {
537
529
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
538
530
  const headers = {};
539
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetImage";
531
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImage";
540
532
  const query = map({
541
533
  imageBuildVersionArn: [, input.imageBuildVersionArn],
542
534
  });
@@ -556,7 +548,7 @@ exports.serializeAws_restJson1GetImageCommand = serializeAws_restJson1GetImageCo
556
548
  const serializeAws_restJson1GetImagePipelineCommand = async (input, context) => {
557
549
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
558
550
  const headers = {};
559
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetImagePipeline";
551
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImagePipeline";
560
552
  const query = map({
561
553
  imagePipelineArn: [, input.imagePipelineArn],
562
554
  });
@@ -576,7 +568,7 @@ exports.serializeAws_restJson1GetImagePipelineCommand = serializeAws_restJson1Ge
576
568
  const serializeAws_restJson1GetImagePolicyCommand = async (input, context) => {
577
569
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
578
570
  const headers = {};
579
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetImagePolicy";
571
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImagePolicy";
580
572
  const query = map({
581
573
  imageArn: [, input.imageArn],
582
574
  });
@@ -596,7 +588,7 @@ exports.serializeAws_restJson1GetImagePolicyCommand = serializeAws_restJson1GetI
596
588
  const serializeAws_restJson1GetImageRecipeCommand = async (input, context) => {
597
589
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
598
590
  const headers = {};
599
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetImageRecipe";
591
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImageRecipe";
600
592
  const query = map({
601
593
  imageRecipeArn: [, input.imageRecipeArn],
602
594
  });
@@ -616,7 +608,7 @@ exports.serializeAws_restJson1GetImageRecipeCommand = serializeAws_restJson1GetI
616
608
  const serializeAws_restJson1GetImageRecipePolicyCommand = async (input, context) => {
617
609
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
618
610
  const headers = {};
619
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetImageRecipePolicy";
611
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImageRecipePolicy";
620
612
  const query = map({
621
613
  imageRecipeArn: [, input.imageRecipeArn],
622
614
  });
@@ -636,7 +628,7 @@ exports.serializeAws_restJson1GetImageRecipePolicyCommand = serializeAws_restJso
636
628
  const serializeAws_restJson1GetInfrastructureConfigurationCommand = async (input, context) => {
637
629
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
638
630
  const headers = {};
639
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetInfrastructureConfiguration";
631
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetInfrastructureConfiguration";
640
632
  const query = map({
641
633
  infrastructureConfigurationArn: [, input.infrastructureConfigurationArn],
642
634
  });
@@ -654,16 +646,15 @@ const serializeAws_restJson1GetInfrastructureConfigurationCommand = async (input
654
646
  };
655
647
  exports.serializeAws_restJson1GetInfrastructureConfigurationCommand = serializeAws_restJson1GetInfrastructureConfigurationCommand;
656
648
  const serializeAws_restJson1ImportComponentCommand = async (input, context) => {
657
- var _a;
658
649
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
659
650
  const headers = {
660
651
  "content-type": "application/json",
661
652
  };
662
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ImportComponent";
653
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ImportComponent";
663
654
  let body;
664
655
  body = JSON.stringify({
665
656
  ...(input.changeDescription != null && { changeDescription: input.changeDescription }),
666
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
657
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
667
658
  ...(input.data != null && { data: input.data }),
668
659
  ...(input.description != null && { description: input.description }),
669
660
  ...(input.format != null && { format: input.format }),
@@ -687,15 +678,14 @@ const serializeAws_restJson1ImportComponentCommand = async (input, context) => {
687
678
  };
688
679
  exports.serializeAws_restJson1ImportComponentCommand = serializeAws_restJson1ImportComponentCommand;
689
680
  const serializeAws_restJson1ImportVmImageCommand = async (input, context) => {
690
- var _a;
691
681
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
692
682
  const headers = {
693
683
  "content-type": "application/json",
694
684
  };
695
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ImportVmImage";
685
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ImportVmImage";
696
686
  let body;
697
687
  body = JSON.stringify({
698
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
688
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
699
689
  ...(input.description != null && { description: input.description }),
700
690
  ...(input.name != null && { name: input.name }),
701
691
  ...(input.osVersion != null && { osVersion: input.osVersion }),
@@ -720,7 +710,7 @@ const serializeAws_restJson1ListComponentBuildVersionsCommand = async (input, co
720
710
  const headers = {
721
711
  "content-type": "application/json",
722
712
  };
723
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListComponentBuildVersions";
713
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListComponentBuildVersions";
724
714
  let body;
725
715
  body = JSON.stringify({
726
716
  ...(input.componentVersionArn != null && { componentVersionArn: input.componentVersionArn }),
@@ -743,7 +733,7 @@ const serializeAws_restJson1ListComponentsCommand = async (input, context) => {
743
733
  const headers = {
744
734
  "content-type": "application/json",
745
735
  };
746
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListComponents";
736
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListComponents";
747
737
  let body;
748
738
  body = JSON.stringify({
749
739
  ...(input.byName != null && { byName: input.byName }),
@@ -768,7 +758,7 @@ const serializeAws_restJson1ListContainerRecipesCommand = async (input, context)
768
758
  const headers = {
769
759
  "content-type": "application/json",
770
760
  };
771
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListContainerRecipes";
761
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListContainerRecipes";
772
762
  let body;
773
763
  body = JSON.stringify({
774
764
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -792,7 +782,7 @@ const serializeAws_restJson1ListDistributionConfigurationsCommand = async (input
792
782
  const headers = {
793
783
  "content-type": "application/json",
794
784
  };
795
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListDistributionConfigurations";
785
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListDistributionConfigurations";
796
786
  let body;
797
787
  body = JSON.stringify({
798
788
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -815,7 +805,7 @@ const serializeAws_restJson1ListImageBuildVersionsCommand = async (input, contex
815
805
  const headers = {
816
806
  "content-type": "application/json",
817
807
  };
818
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListImageBuildVersions";
808
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListImageBuildVersions";
819
809
  let body;
820
810
  body = JSON.stringify({
821
811
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -839,7 +829,7 @@ const serializeAws_restJson1ListImagePackagesCommand = async (input, context) =>
839
829
  const headers = {
840
830
  "content-type": "application/json",
841
831
  };
842
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListImagePackages";
832
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListImagePackages";
843
833
  let body;
844
834
  body = JSON.stringify({
845
835
  ...(input.imageBuildVersionArn != null && { imageBuildVersionArn: input.imageBuildVersionArn }),
@@ -862,7 +852,7 @@ const serializeAws_restJson1ListImagePipelineImagesCommand = async (input, conte
862
852
  const headers = {
863
853
  "content-type": "application/json",
864
854
  };
865
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListImagePipelineImages";
855
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListImagePipelineImages";
866
856
  let body;
867
857
  body = JSON.stringify({
868
858
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -886,7 +876,7 @@ const serializeAws_restJson1ListImagePipelinesCommand = async (input, context) =
886
876
  const headers = {
887
877
  "content-type": "application/json",
888
878
  };
889
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListImagePipelines";
879
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListImagePipelines";
890
880
  let body;
891
881
  body = JSON.stringify({
892
882
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -909,7 +899,7 @@ const serializeAws_restJson1ListImageRecipesCommand = async (input, context) =>
909
899
  const headers = {
910
900
  "content-type": "application/json",
911
901
  };
912
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListImageRecipes";
902
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListImageRecipes";
913
903
  let body;
914
904
  body = JSON.stringify({
915
905
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -933,7 +923,7 @@ const serializeAws_restJson1ListImagesCommand = async (input, context) => {
933
923
  const headers = {
934
924
  "content-type": "application/json",
935
925
  };
936
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListImages";
926
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListImages";
937
927
  let body;
938
928
  body = JSON.stringify({
939
929
  ...(input.byName != null && { byName: input.byName }),
@@ -959,7 +949,7 @@ const serializeAws_restJson1ListInfrastructureConfigurationsCommand = async (inp
959
949
  const headers = {
960
950
  "content-type": "application/json",
961
951
  };
962
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListInfrastructureConfigurations";
952
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListInfrastructureConfigurations";
963
953
  let body;
964
954
  body = JSON.stringify({
965
955
  ...(input.filters != null && { filters: serializeAws_restJson1FilterList(input.filters, context) }),
@@ -980,7 +970,7 @@ exports.serializeAws_restJson1ListInfrastructureConfigurationsCommand = serializ
980
970
  const serializeAws_restJson1ListTagsForResourceCommand = async (input, context) => {
981
971
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
982
972
  const headers = {};
983
- let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
973
+ let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
984
974
  resolvedPath = (0, smithy_client_1.resolvedPath)(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
985
975
  let body;
986
976
  return new protocol_http_1.HttpRequest({
@@ -999,7 +989,7 @@ const serializeAws_restJson1PutComponentPolicyCommand = async (input, context) =
999
989
  const headers = {
1000
990
  "content-type": "application/json",
1001
991
  };
1002
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/PutComponentPolicy";
992
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/PutComponentPolicy";
1003
993
  let body;
1004
994
  body = JSON.stringify({
1005
995
  ...(input.componentArn != null && { componentArn: input.componentArn }),
@@ -1021,7 +1011,7 @@ const serializeAws_restJson1PutContainerRecipePolicyCommand = async (input, cont
1021
1011
  const headers = {
1022
1012
  "content-type": "application/json",
1023
1013
  };
1024
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/PutContainerRecipePolicy";
1014
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/PutContainerRecipePolicy";
1025
1015
  let body;
1026
1016
  body = JSON.stringify({
1027
1017
  ...(input.containerRecipeArn != null && { containerRecipeArn: input.containerRecipeArn }),
@@ -1043,7 +1033,7 @@ const serializeAws_restJson1PutImagePolicyCommand = async (input, context) => {
1043
1033
  const headers = {
1044
1034
  "content-type": "application/json",
1045
1035
  };
1046
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/PutImagePolicy";
1036
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/PutImagePolicy";
1047
1037
  let body;
1048
1038
  body = JSON.stringify({
1049
1039
  ...(input.imageArn != null && { imageArn: input.imageArn }),
@@ -1065,7 +1055,7 @@ const serializeAws_restJson1PutImageRecipePolicyCommand = async (input, context)
1065
1055
  const headers = {
1066
1056
  "content-type": "application/json",
1067
1057
  };
1068
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/PutImageRecipePolicy";
1058
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/PutImageRecipePolicy";
1069
1059
  let body;
1070
1060
  body = JSON.stringify({
1071
1061
  ...(input.imageRecipeArn != null && { imageRecipeArn: input.imageRecipeArn }),
@@ -1083,15 +1073,14 @@ const serializeAws_restJson1PutImageRecipePolicyCommand = async (input, context)
1083
1073
  };
1084
1074
  exports.serializeAws_restJson1PutImageRecipePolicyCommand = serializeAws_restJson1PutImageRecipePolicyCommand;
1085
1075
  const serializeAws_restJson1StartImagePipelineExecutionCommand = async (input, context) => {
1086
- var _a;
1087
1076
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1088
1077
  const headers = {
1089
1078
  "content-type": "application/json",
1090
1079
  };
1091
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/StartImagePipelineExecution";
1080
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/StartImagePipelineExecution";
1092
1081
  let body;
1093
1082
  body = JSON.stringify({
1094
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
1083
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
1095
1084
  ...(input.imagePipelineArn != null && { imagePipelineArn: input.imagePipelineArn }),
1096
1085
  });
1097
1086
  return new protocol_http_1.HttpRequest({
@@ -1110,7 +1099,7 @@ const serializeAws_restJson1TagResourceCommand = async (input, context) => {
1110
1099
  const headers = {
1111
1100
  "content-type": "application/json",
1112
1101
  };
1113
- let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
1102
+ let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
1114
1103
  resolvedPath = (0, smithy_client_1.resolvedPath)(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
1115
1104
  let body;
1116
1105
  body = JSON.stringify({
@@ -1130,7 +1119,7 @@ exports.serializeAws_restJson1TagResourceCommand = serializeAws_restJson1TagReso
1130
1119
  const serializeAws_restJson1UntagResourceCommand = async (input, context) => {
1131
1120
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1132
1121
  const headers = {};
1133
- let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
1122
+ let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
1134
1123
  resolvedPath = (0, smithy_client_1.resolvedPath)(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
1135
1124
  const query = map({
1136
1125
  tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys || []).map((_entry) => _entry)],
@@ -1149,15 +1138,14 @@ const serializeAws_restJson1UntagResourceCommand = async (input, context) => {
1149
1138
  };
1150
1139
  exports.serializeAws_restJson1UntagResourceCommand = serializeAws_restJson1UntagResourceCommand;
1151
1140
  const serializeAws_restJson1UpdateDistributionConfigurationCommand = async (input, context) => {
1152
- var _a;
1153
1141
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1154
1142
  const headers = {
1155
1143
  "content-type": "application/json",
1156
1144
  };
1157
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateDistributionConfiguration";
1145
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateDistributionConfiguration";
1158
1146
  let body;
1159
1147
  body = JSON.stringify({
1160
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
1148
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
1161
1149
  ...(input.description != null && { description: input.description }),
1162
1150
  ...(input.distributionConfigurationArn != null && {
1163
1151
  distributionConfigurationArn: input.distributionConfigurationArn,
@@ -1178,15 +1166,14 @@ const serializeAws_restJson1UpdateDistributionConfigurationCommand = async (inpu
1178
1166
  };
1179
1167
  exports.serializeAws_restJson1UpdateDistributionConfigurationCommand = serializeAws_restJson1UpdateDistributionConfigurationCommand;
1180
1168
  const serializeAws_restJson1UpdateImagePipelineCommand = async (input, context) => {
1181
- var _a;
1182
1169
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1183
1170
  const headers = {
1184
1171
  "content-type": "application/json",
1185
1172
  };
1186
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateImagePipeline";
1173
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateImagePipeline";
1187
1174
  let body;
1188
1175
  body = JSON.stringify({
1189
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
1176
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
1190
1177
  ...(input.containerRecipeArn != null && { containerRecipeArn: input.containerRecipeArn }),
1191
1178
  ...(input.description != null && { description: input.description }),
1192
1179
  ...(input.distributionConfigurationArn != null && {
@@ -1218,15 +1205,14 @@ const serializeAws_restJson1UpdateImagePipelineCommand = async (input, context)
1218
1205
  };
1219
1206
  exports.serializeAws_restJson1UpdateImagePipelineCommand = serializeAws_restJson1UpdateImagePipelineCommand;
1220
1207
  const serializeAws_restJson1UpdateInfrastructureConfigurationCommand = async (input, context) => {
1221
- var _a;
1222
1208
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1223
1209
  const headers = {
1224
1210
  "content-type": "application/json",
1225
1211
  };
1226
- const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateInfrastructureConfiguration";
1212
+ const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateInfrastructureConfiguration";
1227
1213
  let body;
1228
1214
  body = JSON.stringify({
1229
- clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
1215
+ clientToken: input.clientToken ?? (0, uuid_1.v4)(),
1230
1216
  ...(input.description != null && { description: input.description }),
1231
1217
  ...(input.infrastructureConfigurationArn != null && {
1232
1218
  infrastructureConfigurationArn: input.infrastructureConfigurationArn,
@@ -5519,15 +5505,12 @@ const deserializeAws_restJson1TargetContainerRepository = (output, context) => {
5519
5505
  service: (0, smithy_client_1.expectString)(output.service),
5520
5506
  };
5521
5507
  };
5522
- const deserializeMetadata = (output) => {
5523
- var _a, _b;
5524
- return ({
5525
- httpStatusCode: output.statusCode,
5526
- requestId: (_b = (_a = output.headers["x-amzn-requestid"]) !== null && _a !== void 0 ? _a : output.headers["x-amzn-request-id"]) !== null && _b !== void 0 ? _b : output.headers["x-amz-request-id"],
5527
- extendedRequestId: output.headers["x-amz-id-2"],
5528
- cfId: output.headers["x-amz-cf-id"],
5529
- });
5530
- };
5508
+ const deserializeMetadata = (output) => ({
5509
+ httpStatusCode: output.statusCode,
5510
+ requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
5511
+ extendedRequestId: output.headers["x-amz-id-2"],
5512
+ cfId: output.headers["x-amz-cf-id"],
5513
+ });
5531
5514
  const collectBody = (streamBody = new Uint8Array(), context) => {
5532
5515
  if (streamBody instanceof Uint8Array) {
5533
5516
  return Promise.resolve(streamBody);
@@ -5547,9 +5530,8 @@ const parseBody = (streamBody, context) => collectBodyString(streamBody, context
5547
5530
  return {};
5548
5531
  });
5549
5532
  const parseErrorBody = async (errorBody, context) => {
5550
- var _a;
5551
5533
  const value = await parseBody(errorBody, context);
5552
- value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
5534
+ value.message = value.message ?? value.Message;
5553
5535
  return value;
5554
5536
  };
5555
5537
  const loadRestJsonErrorCode = (output, data) => {
@@ -16,7 +16,6 @@ const runtimeConfig_shared_1 = require("./runtimeConfig.shared");
16
16
  const smithy_client_1 = require("@aws-sdk/smithy-client");
17
17
  const util_defaults_mode_browser_1 = require("@aws-sdk/util-defaults-mode-browser");
18
18
  const getRuntimeConfig = (config) => {
19
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
20
19
  const defaultsMode = (0, util_defaults_mode_browser_1.resolveDefaultsModeConfig)(config);
21
20
  const defaultConfigProvider = () => defaultsMode().then(smithy_client_1.loadConfigsForDefaultMode);
22
21
  const clientSharedValues = (0, runtimeConfig_shared_1.getRuntimeConfig)(config);
@@ -25,21 +24,22 @@ const getRuntimeConfig = (config) => {
25
24
  ...config,
26
25
  runtime: "browser",
27
26
  defaultsMode,
28
- base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : util_base64_browser_1.fromBase64,
29
- base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : util_base64_browser_1.toBase64,
30
- bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : util_body_length_browser_1.calculateBodyLength,
31
- credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : ((_) => () => Promise.reject(new Error("Credential is missing"))),
32
- defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : (0, util_user_agent_browser_1.defaultUserAgent)({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
33
- maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : middleware_retry_1.DEFAULT_MAX_ATTEMPTS,
34
- region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : (0, invalid_dependency_1.invalidProvider)("Region is missing"),
35
- requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new fetch_http_handler_1.FetchHttpHandler(defaultConfigProvider),
36
- retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE),
37
- sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : sha256_browser_1.Sha256,
38
- streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : fetch_http_handler_1.streamCollector,
39
- useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (() => Promise.resolve(config_resolver_1.DEFAULT_USE_DUALSTACK_ENDPOINT)),
40
- useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : (() => Promise.resolve(config_resolver_1.DEFAULT_USE_FIPS_ENDPOINT)),
41
- utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : util_utf8_browser_1.fromUtf8,
42
- utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : util_utf8_browser_1.toUtf8,
27
+ base64Decoder: config?.base64Decoder ?? util_base64_browser_1.fromBase64,
28
+ base64Encoder: config?.base64Encoder ?? util_base64_browser_1.toBase64,
29
+ bodyLengthChecker: config?.bodyLengthChecker ?? util_body_length_browser_1.calculateBodyLength,
30
+ credentialDefaultProvider: config?.credentialDefaultProvider ?? ((_) => () => Promise.reject(new Error("Credential is missing"))),
31
+ defaultUserAgentProvider: config?.defaultUserAgentProvider ??
32
+ (0, util_user_agent_browser_1.defaultUserAgent)({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
33
+ maxAttempts: config?.maxAttempts ?? middleware_retry_1.DEFAULT_MAX_ATTEMPTS,
34
+ region: config?.region ?? (0, invalid_dependency_1.invalidProvider)("Region is missing"),
35
+ requestHandler: config?.requestHandler ?? new fetch_http_handler_1.FetchHttpHandler(defaultConfigProvider),
36
+ retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE),
37
+ sha256: config?.sha256 ?? sha256_browser_1.Sha256,
38
+ streamCollector: config?.streamCollector ?? fetch_http_handler_1.streamCollector,
39
+ useDualstackEndpoint: config?.useDualstackEndpoint ?? (() => Promise.resolve(config_resolver_1.DEFAULT_USE_DUALSTACK_ENDPOINT)),
40
+ useFipsEndpoint: config?.useFipsEndpoint ?? (() => Promise.resolve(config_resolver_1.DEFAULT_USE_FIPS_ENDPOINT)),
41
+ utf8Decoder: config?.utf8Decoder ?? util_utf8_browser_1.fromUtf8,
42
+ utf8Encoder: config?.utf8Encoder ?? util_utf8_browser_1.toUtf8,
43
43
  };
44
44
  };
45
45
  exports.getRuntimeConfig = getRuntimeConfig;
@@ -19,7 +19,6 @@ const smithy_client_1 = require("@aws-sdk/smithy-client");
19
19
  const util_defaults_mode_node_1 = require("@aws-sdk/util-defaults-mode-node");
20
20
  const smithy_client_2 = require("@aws-sdk/smithy-client");
21
21
  const getRuntimeConfig = (config) => {
22
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
23
22
  (0, smithy_client_2.emitWarningIfUnsupportedVersion)(process.version);
24
23
  const defaultsMode = (0, util_defaults_mode_node_1.resolveDefaultsModeConfig)(config);
25
24
  const defaultConfigProvider = () => defaultsMode().then(smithy_client_1.loadConfigsForDefaultMode);
@@ -29,24 +28,26 @@ const getRuntimeConfig = (config) => {
29
28
  ...config,
30
29
  runtime: "node",
31
30
  defaultsMode,
32
- base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : util_base64_node_1.fromBase64,
33
- base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : util_base64_node_1.toBase64,
34
- bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : util_body_length_node_1.calculateBodyLength,
35
- credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (0, client_sts_1.decorateDefaultCredentialProvider)(credential_provider_node_1.defaultProvider),
36
- defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : (0, util_user_agent_node_1.defaultUserAgent)({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
37
- maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : (0, node_config_provider_1.loadConfig)(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS),
38
- region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : (0, node_config_provider_1.loadConfig)(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS),
39
- requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new node_http_handler_1.NodeHttpHandler(defaultConfigProvider),
40
- retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (0, node_config_provider_1.loadConfig)({
41
- ...middleware_retry_1.NODE_RETRY_MODE_CONFIG_OPTIONS,
42
- default: async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE,
43
- }),
44
- sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : hash_node_1.Hash.bind(null, "sha256"),
45
- streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : node_http_handler_1.streamCollector,
46
- useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (0, node_config_provider_1.loadConfig)(config_resolver_1.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS),
47
- useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : (0, node_config_provider_1.loadConfig)(config_resolver_1.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS),
48
- utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : util_utf8_node_1.fromUtf8,
49
- utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : util_utf8_node_1.toUtf8,
31
+ base64Decoder: config?.base64Decoder ?? util_base64_node_1.fromBase64,
32
+ base64Encoder: config?.base64Encoder ?? util_base64_node_1.toBase64,
33
+ bodyLengthChecker: config?.bodyLengthChecker ?? util_body_length_node_1.calculateBodyLength,
34
+ credentialDefaultProvider: config?.credentialDefaultProvider ?? (0, client_sts_1.decorateDefaultCredentialProvider)(credential_provider_node_1.defaultProvider),
35
+ defaultUserAgentProvider: config?.defaultUserAgentProvider ??
36
+ (0, util_user_agent_node_1.defaultUserAgent)({ serviceId: clientSharedValues.serviceId, clientVersion: package_json_1.default.version }),
37
+ maxAttempts: config?.maxAttempts ?? (0, node_config_provider_1.loadConfig)(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS),
38
+ region: config?.region ?? (0, node_config_provider_1.loadConfig)(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS),
39
+ requestHandler: config?.requestHandler ?? new node_http_handler_1.NodeHttpHandler(defaultConfigProvider),
40
+ retryMode: config?.retryMode ??
41
+ (0, node_config_provider_1.loadConfig)({
42
+ ...middleware_retry_1.NODE_RETRY_MODE_CONFIG_OPTIONS,
43
+ default: async () => (await defaultConfigProvider()).retryMode || middleware_retry_1.DEFAULT_RETRY_MODE,
44
+ }),
45
+ sha256: config?.sha256 ?? hash_node_1.Hash.bind(null, "sha256"),
46
+ streamCollector: config?.streamCollector ?? node_http_handler_1.streamCollector,
47
+ useDualstackEndpoint: config?.useDualstackEndpoint ?? (0, node_config_provider_1.loadConfig)(config_resolver_1.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS),
48
+ useFipsEndpoint: config?.useFipsEndpoint ?? (0, node_config_provider_1.loadConfig)(config_resolver_1.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS),
49
+ utf8Decoder: config?.utf8Decoder ?? util_utf8_node_1.fromUtf8,
50
+ utf8Encoder: config?.utf8Encoder ?? util_utf8_node_1.toUtf8,
50
51
  };
51
52
  };
52
53
  exports.getRuntimeConfig = getRuntimeConfig;
@@ -4,13 +4,12 @@ exports.getRuntimeConfig = void 0;
4
4
  const sha256_js_1 = require("@aws-crypto/sha256-js");
5
5
  const runtimeConfig_browser_1 = require("./runtimeConfig.browser");
6
6
  const getRuntimeConfig = (config) => {
7
- var _a;
8
7
  const browserDefaults = (0, runtimeConfig_browser_1.getRuntimeConfig)(config);
9
8
  return {
10
9
  ...browserDefaults,
11
10
  ...config,
12
11
  runtime: "react-native",
13
- sha256: (_a = config === null || config === void 0 ? void 0 : config.sha256) !== null && _a !== void 0 ? _a : sha256_js_1.Sha256,
12
+ sha256: config?.sha256 ?? sha256_js_1.Sha256,
14
13
  };
15
14
  };
16
15
  exports.getRuntimeConfig = getRuntimeConfig;
@@ -3,15 +3,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getRuntimeConfig = void 0;
4
4
  const url_parser_1 = require("@aws-sdk/url-parser");
5
5
  const endpointResolver_1 = require("./endpoint/endpointResolver");
6
- const getRuntimeConfig = (config) => {
7
- var _a, _b, _c, _d, _e;
8
- return ({
9
- apiVersion: "2019-12-02",
10
- disableHostPrefix: (_a = config === null || config === void 0 ? void 0 : config.disableHostPrefix) !== null && _a !== void 0 ? _a : false,
11
- endpointProvider: (_b = config === null || config === void 0 ? void 0 : config.endpointProvider) !== null && _b !== void 0 ? _b : endpointResolver_1.defaultEndpointResolver,
12
- logger: (_c = config === null || config === void 0 ? void 0 : config.logger) !== null && _c !== void 0 ? _c : {},
13
- serviceId: (_d = config === null || config === void 0 ? void 0 : config.serviceId) !== null && _d !== void 0 ? _d : "imagebuilder",
14
- urlParser: (_e = config === null || config === void 0 ? void 0 : config.urlParser) !== null && _e !== void 0 ? _e : url_parser_1.parseUrl,
15
- });
16
- };
6
+ const getRuntimeConfig = (config) => ({
7
+ apiVersion: "2019-12-02",
8
+ disableHostPrefix: config?.disableHostPrefix ?? false,
9
+ endpointProvider: config?.endpointProvider ?? endpointResolver_1.defaultEndpointResolver,
10
+ logger: config?.logger ?? {},
11
+ serviceId: config?.serviceId ?? "imagebuilder",
12
+ urlParser: config?.urlParser ?? url_parser_1.parseUrl,
13
+ });
17
14
  exports.getRuntimeConfig = getRuntimeConfig;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-imagebuilder",
3
3
  "description": "AWS SDK for JavaScript Imagebuilder Client for Node.js, Browser and React Native",
4
- "version": "3.200.0",
4
+ "version": "3.202.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -19,45 +19,45 @@
19
19
  "dependencies": {
20
20
  "@aws-crypto/sha256-browser": "2.0.0",
21
21
  "@aws-crypto/sha256-js": "2.0.0",
22
- "@aws-sdk/client-sts": "3.200.0",
23
- "@aws-sdk/config-resolver": "3.200.0",
24
- "@aws-sdk/credential-provider-node": "3.200.0",
25
- "@aws-sdk/fetch-http-handler": "3.200.0",
26
- "@aws-sdk/hash-node": "3.200.0",
27
- "@aws-sdk/invalid-dependency": "3.200.0",
28
- "@aws-sdk/middleware-content-length": "3.200.0",
29
- "@aws-sdk/middleware-endpoint": "3.200.0",
30
- "@aws-sdk/middleware-host-header": "3.200.0",
31
- "@aws-sdk/middleware-logger": "3.200.0",
32
- "@aws-sdk/middleware-recursion-detection": "3.200.0",
33
- "@aws-sdk/middleware-retry": "3.200.0",
34
- "@aws-sdk/middleware-serde": "3.200.0",
35
- "@aws-sdk/middleware-signing": "3.200.0",
36
- "@aws-sdk/middleware-stack": "3.200.0",
37
- "@aws-sdk/middleware-user-agent": "3.200.0",
38
- "@aws-sdk/node-config-provider": "3.200.0",
39
- "@aws-sdk/node-http-handler": "3.200.0",
40
- "@aws-sdk/protocol-http": "3.200.0",
41
- "@aws-sdk/smithy-client": "3.200.0",
42
- "@aws-sdk/types": "3.200.0",
43
- "@aws-sdk/url-parser": "3.200.0",
22
+ "@aws-sdk/client-sts": "3.202.0",
23
+ "@aws-sdk/config-resolver": "3.201.0",
24
+ "@aws-sdk/credential-provider-node": "3.202.0",
25
+ "@aws-sdk/fetch-http-handler": "3.201.0",
26
+ "@aws-sdk/hash-node": "3.201.0",
27
+ "@aws-sdk/invalid-dependency": "3.201.0",
28
+ "@aws-sdk/middleware-content-length": "3.201.0",
29
+ "@aws-sdk/middleware-endpoint": "3.201.0",
30
+ "@aws-sdk/middleware-host-header": "3.201.0",
31
+ "@aws-sdk/middleware-logger": "3.201.0",
32
+ "@aws-sdk/middleware-recursion-detection": "3.201.0",
33
+ "@aws-sdk/middleware-retry": "3.201.0",
34
+ "@aws-sdk/middleware-serde": "3.201.0",
35
+ "@aws-sdk/middleware-signing": "3.201.0",
36
+ "@aws-sdk/middleware-stack": "3.201.0",
37
+ "@aws-sdk/middleware-user-agent": "3.201.0",
38
+ "@aws-sdk/node-config-provider": "3.201.0",
39
+ "@aws-sdk/node-http-handler": "3.201.0",
40
+ "@aws-sdk/protocol-http": "3.201.0",
41
+ "@aws-sdk/smithy-client": "3.201.0",
42
+ "@aws-sdk/types": "3.201.0",
43
+ "@aws-sdk/url-parser": "3.201.0",
44
44
  "@aws-sdk/util-base64-browser": "3.188.0",
45
- "@aws-sdk/util-base64-node": "3.188.0",
45
+ "@aws-sdk/util-base64-node": "3.201.0",
46
46
  "@aws-sdk/util-body-length-browser": "3.188.0",
47
- "@aws-sdk/util-body-length-node": "3.188.0",
48
- "@aws-sdk/util-defaults-mode-browser": "3.200.0",
49
- "@aws-sdk/util-defaults-mode-node": "3.200.0",
50
- "@aws-sdk/util-endpoints": "3.200.0",
51
- "@aws-sdk/util-user-agent-browser": "3.200.0",
52
- "@aws-sdk/util-user-agent-node": "3.200.0",
47
+ "@aws-sdk/util-body-length-node": "3.201.0",
48
+ "@aws-sdk/util-defaults-mode-browser": "3.201.0",
49
+ "@aws-sdk/util-defaults-mode-node": "3.201.0",
50
+ "@aws-sdk/util-endpoints": "3.202.0",
51
+ "@aws-sdk/util-user-agent-browser": "3.201.0",
52
+ "@aws-sdk/util-user-agent-node": "3.201.0",
53
53
  "@aws-sdk/util-utf8-browser": "3.188.0",
54
- "@aws-sdk/util-utf8-node": "3.199.0",
54
+ "@aws-sdk/util-utf8-node": "3.201.0",
55
55
  "tslib": "^2.3.1",
56
56
  "uuid": "^8.3.2"
57
57
  },
58
58
  "devDependencies": {
59
59
  "@aws-sdk/service-client-documentation-generator": "3.188.0",
60
- "@tsconfig/recommended": "1.0.1",
60
+ "@tsconfig/node14": "1.0.3",
61
61
  "@types/node": "^12.7.5",
62
62
  "@types/uuid": "^8.3.0",
63
63
  "concurrently": "7.0.0",
@@ -72,7 +72,7 @@
72
72
  }
73
73
  },
74
74
  "engines": {
75
- "node": ">=12.0.0"
75
+ "node": ">=14.0.0"
76
76
  },
77
77
  "typesVersions": {
78
78
  "<4.0": {