@aws-sdk/client-iot-jobs-data-plane 3.121.0 → 3.130.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,33 @@
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.130.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.129.0...v3.130.0) (2022-07-14)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **codegen:** fix error code parsing when it's a number ([#3371](https://github.com/aws/aws-sdk-js-v3/issues/3371)) ([c2d8522](https://github.com/aws/aws-sdk-js-v3/commit/c2d852279a3d23958521a6ceb4f4c642b0cb1848))
12
+
13
+
14
+
15
+
16
+
17
+ # [3.128.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.127.0...v3.128.0) (2022-07-12)
18
+
19
+ **Note:** Version bump only for package @aws-sdk/client-iot-jobs-data-plane
20
+
21
+
22
+
23
+
24
+
25
+ # [3.127.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.126.0...v3.127.0) (2022-07-11)
26
+
27
+ **Note:** Version bump only for package @aws-sdk/client-iot-jobs-data-plane
28
+
29
+
30
+
31
+
32
+
6
33
  # [3.121.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.120.0...v3.121.0) (2022-06-30)
7
34
 
8
35
 
@@ -90,12 +90,10 @@ const serializeAws_restJson1StartNextPendingJobExecutionCommand = async (input,
90
90
  }
91
91
  let body;
92
92
  body = JSON.stringify({
93
- ...(input.statusDetails !== undefined &&
94
- input.statusDetails !== null && {
93
+ ...(input.statusDetails != null && {
95
94
  statusDetails: serializeAws_restJson1DetailsMap(input.statusDetails, context),
96
95
  }),
97
- ...(input.stepTimeoutInMinutes !== undefined &&
98
- input.stepTimeoutInMinutes !== null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes }),
96
+ ...(input.stepTimeoutInMinutes != null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes }),
99
97
  });
100
98
  return new protocol_http_1.HttpRequest({
101
99
  protocol,
@@ -136,21 +134,15 @@ const serializeAws_restJson1UpdateJobExecutionCommand = async (input, context) =
136
134
  }
137
135
  let body;
138
136
  body = JSON.stringify({
139
- ...(input.executionNumber !== undefined &&
140
- input.executionNumber !== null && { executionNumber: input.executionNumber }),
141
- ...(input.expectedVersion !== undefined &&
142
- input.expectedVersion !== null && { expectedVersion: input.expectedVersion }),
143
- ...(input.includeJobDocument !== undefined &&
144
- input.includeJobDocument !== null && { includeJobDocument: input.includeJobDocument }),
145
- ...(input.includeJobExecutionState !== undefined &&
146
- input.includeJobExecutionState !== null && { includeJobExecutionState: input.includeJobExecutionState }),
147
- ...(input.status !== undefined && input.status !== null && { status: input.status }),
148
- ...(input.statusDetails !== undefined &&
149
- input.statusDetails !== null && {
137
+ ...(input.executionNumber != null && { executionNumber: input.executionNumber }),
138
+ ...(input.expectedVersion != null && { expectedVersion: input.expectedVersion }),
139
+ ...(input.includeJobDocument != null && { includeJobDocument: input.includeJobDocument }),
140
+ ...(input.includeJobExecutionState != null && { includeJobExecutionState: input.includeJobExecutionState }),
141
+ ...(input.status != null && { status: input.status }),
142
+ ...(input.statusDetails != null && {
150
143
  statusDetails: serializeAws_restJson1DetailsMap(input.statusDetails, context),
151
144
  }),
152
- ...(input.stepTimeoutInMinutes !== undefined &&
153
- input.stepTimeoutInMinutes !== null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes }),
145
+ ...(input.stepTimeoutInMinutes != null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes }),
154
146
  });
155
147
  return new protocol_http_1.HttpRequest({
156
148
  protocol,
@@ -496,9 +488,7 @@ const deserializeAws_restJson1JobExecution = (output, context) => {
496
488
  queuedAt: (0, smithy_client_1.expectLong)(output.queuedAt),
497
489
  startedAt: (0, smithy_client_1.expectLong)(output.startedAt),
498
490
  status: (0, smithy_client_1.expectString)(output.status),
499
- statusDetails: output.statusDetails !== undefined && output.statusDetails !== null
500
- ? deserializeAws_restJson1DetailsMap(output.statusDetails, context)
501
- : undefined,
491
+ statusDetails: output.statusDetails != null ? deserializeAws_restJson1DetailsMap(output.statusDetails, context) : undefined,
502
492
  thingName: (0, smithy_client_1.expectString)(output.thingName),
503
493
  versionNumber: (0, smithy_client_1.expectLong)(output.versionNumber),
504
494
  };
@@ -506,9 +496,7 @@ const deserializeAws_restJson1JobExecution = (output, context) => {
506
496
  const deserializeAws_restJson1JobExecutionState = (output, context) => {
507
497
  return {
508
498
  status: (0, smithy_client_1.expectString)(output.status),
509
- statusDetails: output.statusDetails !== undefined && output.statusDetails !== null
510
- ? deserializeAws_restJson1DetailsMap(output.statusDetails, context)
511
- : undefined,
499
+ statusDetails: output.statusDetails != null ? deserializeAws_restJson1DetailsMap(output.statusDetails, context) : undefined,
512
500
  versionNumber: (0, smithy_client_1.expectLong)(output.versionNumber),
513
501
  };
514
502
  };
@@ -564,6 +552,9 @@ const loadRestJsonErrorCode = (output, data) => {
564
552
  const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
565
553
  const sanitizeErrorCode = (rawValue) => {
566
554
  let cleanValue = rawValue;
555
+ if (typeof cleanValue === "number") {
556
+ cleanValue = cleanValue.toString();
557
+ }
567
558
  if (cleanValue.indexOf(":") >= 0) {
568
559
  cleanValue = cleanValue.split(":")[0];
569
560
  }
@@ -98,11 +98,9 @@ export var serializeAws_restJson1StartNextPendingJobExecutionCommand = function
98
98
  else {
99
99
  throw new Error("No value provided for input HTTP label: thingName.");
100
100
  }
101
- body = JSON.stringify(__assign(__assign({}, (input.statusDetails !== undefined &&
102
- input.statusDetails !== null && {
101
+ body = JSON.stringify(__assign(__assign({}, (input.statusDetails != null && {
103
102
  statusDetails: serializeAws_restJson1DetailsMap(input.statusDetails, context),
104
- })), (input.stepTimeoutInMinutes !== undefined &&
105
- input.stepTimeoutInMinutes !== null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes })));
103
+ })), (input.stepTimeoutInMinutes != null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes })));
106
104
  return [2, new __HttpRequest({
107
105
  protocol: protocol,
108
106
  hostname: hostname,
@@ -146,15 +144,9 @@ export var serializeAws_restJson1UpdateJobExecutionCommand = function (input, co
146
144
  else {
147
145
  throw new Error("No value provided for input HTTP label: thingName.");
148
146
  }
149
- body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.executionNumber !== undefined &&
150
- input.executionNumber !== null && { executionNumber: input.executionNumber })), (input.expectedVersion !== undefined &&
151
- input.expectedVersion !== null && { expectedVersion: input.expectedVersion })), (input.includeJobDocument !== undefined &&
152
- input.includeJobDocument !== null && { includeJobDocument: input.includeJobDocument })), (input.includeJobExecutionState !== undefined &&
153
- input.includeJobExecutionState !== null && { includeJobExecutionState: input.includeJobExecutionState })), (input.status !== undefined && input.status !== null && { status: input.status })), (input.statusDetails !== undefined &&
154
- input.statusDetails !== null && {
147
+ body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.executionNumber != null && { executionNumber: input.executionNumber })), (input.expectedVersion != null && { expectedVersion: input.expectedVersion })), (input.includeJobDocument != null && { includeJobDocument: input.includeJobDocument })), (input.includeJobExecutionState != null && { includeJobExecutionState: input.includeJobExecutionState })), (input.status != null && { status: input.status })), (input.statusDetails != null && {
155
148
  statusDetails: serializeAws_restJson1DetailsMap(input.statusDetails, context),
156
- })), (input.stepTimeoutInMinutes !== undefined &&
157
- input.stepTimeoutInMinutes !== null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes })));
149
+ })), (input.stepTimeoutInMinutes != null && { stepTimeoutInMinutes: input.stepTimeoutInMinutes })));
158
150
  return [2, new __HttpRequest({
159
151
  protocol: protocol,
160
152
  hostname: hostname,
@@ -592,9 +584,7 @@ var deserializeAws_restJson1JobExecution = function (output, context) {
592
584
  queuedAt: __expectLong(output.queuedAt),
593
585
  startedAt: __expectLong(output.startedAt),
594
586
  status: __expectString(output.status),
595
- statusDetails: output.statusDetails !== undefined && output.statusDetails !== null
596
- ? deserializeAws_restJson1DetailsMap(output.statusDetails, context)
597
- : undefined,
587
+ statusDetails: output.statusDetails != null ? deserializeAws_restJson1DetailsMap(output.statusDetails, context) : undefined,
598
588
  thingName: __expectString(output.thingName),
599
589
  versionNumber: __expectLong(output.versionNumber),
600
590
  };
@@ -602,9 +592,7 @@ var deserializeAws_restJson1JobExecution = function (output, context) {
602
592
  var deserializeAws_restJson1JobExecutionState = function (output, context) {
603
593
  return {
604
594
  status: __expectString(output.status),
605
- statusDetails: output.statusDetails !== undefined && output.statusDetails !== null
606
- ? deserializeAws_restJson1DetailsMap(output.statusDetails, context)
607
- : undefined,
595
+ statusDetails: output.statusDetails != null ? deserializeAws_restJson1DetailsMap(output.statusDetails, context) : undefined,
608
596
  versionNumber: __expectLong(output.versionNumber),
609
597
  };
610
598
  };
@@ -667,6 +655,9 @@ var loadRestJsonErrorCode = function (output, data) {
667
655
  var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
668
656
  var sanitizeErrorCode = function (rawValue) {
669
657
  var cleanValue = rawValue;
658
+ if (typeof cleanValue === "number") {
659
+ cleanValue = cleanValue.toString();
660
+ }
670
661
  if (cleanValue.indexOf(":") >= 0) {
671
662
  cleanValue = cleanValue.split(":")[0];
672
663
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-iot-jobs-data-plane",
3
3
  "description": "AWS SDK for JavaScript Iot Jobs Data Plane Client for Node.js, Browser and React Native",
4
- "version": "3.121.0",
4
+ "version": "3.130.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",
@@ -18,35 +18,35 @@
18
18
  "dependencies": {
19
19
  "@aws-crypto/sha256-browser": "2.0.0",
20
20
  "@aws-crypto/sha256-js": "2.0.0",
21
- "@aws-sdk/client-sts": "3.121.0",
22
- "@aws-sdk/config-resolver": "3.110.0",
23
- "@aws-sdk/credential-provider-node": "3.121.0",
24
- "@aws-sdk/fetch-http-handler": "3.110.0",
25
- "@aws-sdk/hash-node": "3.110.0",
26
- "@aws-sdk/invalid-dependency": "3.110.0",
27
- "@aws-sdk/middleware-content-length": "3.110.0",
28
- "@aws-sdk/middleware-host-header": "3.110.0",
29
- "@aws-sdk/middleware-logger": "3.110.0",
30
- "@aws-sdk/middleware-recursion-detection": "3.110.0",
31
- "@aws-sdk/middleware-retry": "3.118.1",
32
- "@aws-sdk/middleware-serde": "3.110.0",
33
- "@aws-sdk/middleware-signing": "3.110.0",
34
- "@aws-sdk/middleware-stack": "3.110.0",
35
- "@aws-sdk/middleware-user-agent": "3.110.0",
36
- "@aws-sdk/node-config-provider": "3.110.0",
37
- "@aws-sdk/node-http-handler": "3.118.1",
38
- "@aws-sdk/protocol-http": "3.110.0",
39
- "@aws-sdk/smithy-client": "3.110.0",
40
- "@aws-sdk/types": "3.110.0",
41
- "@aws-sdk/url-parser": "3.110.0",
21
+ "@aws-sdk/client-sts": "3.130.0",
22
+ "@aws-sdk/config-resolver": "3.130.0",
23
+ "@aws-sdk/credential-provider-node": "3.130.0",
24
+ "@aws-sdk/fetch-http-handler": "3.127.0",
25
+ "@aws-sdk/hash-node": "3.127.0",
26
+ "@aws-sdk/invalid-dependency": "3.127.0",
27
+ "@aws-sdk/middleware-content-length": "3.127.0",
28
+ "@aws-sdk/middleware-host-header": "3.127.0",
29
+ "@aws-sdk/middleware-logger": "3.127.0",
30
+ "@aws-sdk/middleware-recursion-detection": "3.127.0",
31
+ "@aws-sdk/middleware-retry": "3.127.0",
32
+ "@aws-sdk/middleware-serde": "3.127.0",
33
+ "@aws-sdk/middleware-signing": "3.130.0",
34
+ "@aws-sdk/middleware-stack": "3.127.0",
35
+ "@aws-sdk/middleware-user-agent": "3.127.0",
36
+ "@aws-sdk/node-config-provider": "3.127.0",
37
+ "@aws-sdk/node-http-handler": "3.127.0",
38
+ "@aws-sdk/protocol-http": "3.127.0",
39
+ "@aws-sdk/smithy-client": "3.127.0",
40
+ "@aws-sdk/types": "3.127.0",
41
+ "@aws-sdk/url-parser": "3.127.0",
42
42
  "@aws-sdk/util-base64-browser": "3.109.0",
43
43
  "@aws-sdk/util-base64-node": "3.55.0",
44
44
  "@aws-sdk/util-body-length-browser": "3.55.0",
45
45
  "@aws-sdk/util-body-length-node": "3.55.0",
46
- "@aws-sdk/util-defaults-mode-browser": "3.110.0",
47
- "@aws-sdk/util-defaults-mode-node": "3.110.0",
48
- "@aws-sdk/util-user-agent-browser": "3.110.0",
49
- "@aws-sdk/util-user-agent-node": "3.118.0",
46
+ "@aws-sdk/util-defaults-mode-browser": "3.127.0",
47
+ "@aws-sdk/util-defaults-mode-node": "3.130.0",
48
+ "@aws-sdk/util-user-agent-browser": "3.127.0",
49
+ "@aws-sdk/util-user-agent-node": "3.127.0",
50
50
  "@aws-sdk/util-utf8-browser": "3.109.0",
51
51
  "@aws-sdk/util-utf8-node": "3.109.0",
52
52
  "tslib": "^2.3.1"