@aws-sdk/client-greengrassv2 3.28.0 → 3.32.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,6 +1,6 @@
1
1
  import { __assign, __awaiter, __generator, __read } from "tslib";
2
2
  import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
3
- import { expectBoolean as __expectBoolean, expectInt as __expectInt, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, limitedParseFloat as __limitedParseFloat, serializeFloat as __serializeFloat, strictParseInt as __strictParseInt, } from "@aws-sdk/smithy-client";
3
+ import { expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, limitedParseDouble as __limitedParseDouble, parseEpochTimestamp as __parseEpochTimestamp, serializeFloat as __serializeFloat, strictParseInt32 as __strictParseInt32, } from "@aws-sdk/smithy-client";
4
4
  import { v4 as generateIdempotencyToken } from "uuid";
5
5
  export var serializeAws_restJson1BatchAssociateClientDeviceWithCoreDeviceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
6
6
  var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
@@ -740,9 +740,9 @@ export var serializeAws_restJson1UntagResourceCommand = function (input, context
740
740
  });
741
741
  }); };
742
742
  export var deserializeAws_restJson1BatchAssociateClientDeviceWithCoreDeviceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
743
- var contents, data;
744
- return __generator(this, function (_a) {
745
- switch (_a.label) {
743
+ var contents, data, _a, _b;
744
+ return __generator(this, function (_c) {
745
+ switch (_c.label) {
746
746
  case 0:
747
747
  if (output.statusCode !== 200 && output.statusCode >= 300) {
748
748
  return [2 /*return*/, deserializeAws_restJson1BatchAssociateClientDeviceWithCoreDeviceCommandError(output, context)];
@@ -751,9 +751,11 @@ export var deserializeAws_restJson1BatchAssociateClientDeviceWithCoreDeviceComma
751
751
  $metadata: deserializeMetadata(output),
752
752
  errorEntries: undefined,
753
753
  };
754
+ _a = __expectNonNull;
755
+ _b = __expectObject;
754
756
  return [4 /*yield*/, parseBody(output.body, context)];
755
757
  case 1:
756
- data = _a.sent();
758
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
757
759
  if (data.errorEntries !== undefined && data.errorEntries !== null) {
758
760
  contents.errorEntries = deserializeAws_restJson1AssociateClientDeviceWithCoreDeviceErrorList(data.errorEntries, context);
759
761
  }
@@ -832,9 +834,9 @@ var deserializeAws_restJson1BatchAssociateClientDeviceWithCoreDeviceCommandError
832
834
  });
833
835
  }); };
834
836
  export var deserializeAws_restJson1BatchDisassociateClientDeviceFromCoreDeviceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
835
- var contents, data;
836
- return __generator(this, function (_a) {
837
- switch (_a.label) {
837
+ var contents, data, _a, _b;
838
+ return __generator(this, function (_c) {
839
+ switch (_c.label) {
838
840
  case 0:
839
841
  if (output.statusCode !== 200 && output.statusCode >= 300) {
840
842
  return [2 /*return*/, deserializeAws_restJson1BatchDisassociateClientDeviceFromCoreDeviceCommandError(output, context)];
@@ -843,9 +845,11 @@ export var deserializeAws_restJson1BatchDisassociateClientDeviceFromCoreDeviceCo
843
845
  $metadata: deserializeMetadata(output),
844
846
  errorEntries: undefined,
845
847
  };
848
+ _a = __expectNonNull;
849
+ _b = __expectObject;
846
850
  return [4 /*yield*/, parseBody(output.body, context)];
847
851
  case 1:
848
- data = _a.sent();
852
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
849
853
  if (data.errorEntries !== undefined && data.errorEntries !== null) {
850
854
  contents.errorEntries = deserializeAws_restJson1DisassociateClientDeviceFromCoreDeviceErrorList(data.errorEntries, context);
851
855
  }
@@ -924,9 +928,9 @@ var deserializeAws_restJson1BatchDisassociateClientDeviceFromCoreDeviceCommandEr
924
928
  });
925
929
  }); };
926
930
  export var deserializeAws_restJson1CancelDeploymentCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
927
- var contents, data;
928
- return __generator(this, function (_a) {
929
- switch (_a.label) {
931
+ var contents, data, _a, _b;
932
+ return __generator(this, function (_c) {
933
+ switch (_c.label) {
930
934
  case 0:
931
935
  if (output.statusCode !== 200 && output.statusCode >= 300) {
932
936
  return [2 /*return*/, deserializeAws_restJson1CancelDeploymentCommandError(output, context)];
@@ -935,9 +939,11 @@ export var deserializeAws_restJson1CancelDeploymentCommand = function (output, c
935
939
  $metadata: deserializeMetadata(output),
936
940
  message: undefined,
937
941
  };
942
+ _a = __expectNonNull;
943
+ _b = __expectObject;
938
944
  return [4 /*yield*/, parseBody(output.body, context)];
939
945
  case 1:
940
- data = _a.sent();
946
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
941
947
  if (data.message !== undefined && data.message !== null) {
942
948
  contents.message = __expectString(data.message);
943
949
  }
@@ -1024,9 +1030,9 @@ var deserializeAws_restJson1CancelDeploymentCommandError = function (output, con
1024
1030
  });
1025
1031
  }); };
1026
1032
  export var deserializeAws_restJson1CreateComponentVersionCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1027
- var contents, data;
1028
- return __generator(this, function (_a) {
1029
- switch (_a.label) {
1033
+ var contents, data, _a, _b;
1034
+ return __generator(this, function (_c) {
1035
+ switch (_c.label) {
1030
1036
  case 0:
1031
1037
  if (output.statusCode !== 201 && output.statusCode >= 300) {
1032
1038
  return [2 /*return*/, deserializeAws_restJson1CreateComponentVersionCommandError(output, context)];
@@ -1039,9 +1045,11 @@ export var deserializeAws_restJson1CreateComponentVersionCommand = function (out
1039
1045
  creationTimestamp: undefined,
1040
1046
  status: undefined,
1041
1047
  };
1048
+ _a = __expectNonNull;
1049
+ _b = __expectObject;
1042
1050
  return [4 /*yield*/, parseBody(output.body, context)];
1043
1051
  case 1:
1044
- data = _a.sent();
1052
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1045
1053
  if (data.arn !== undefined && data.arn !== null) {
1046
1054
  contents.arn = __expectString(data.arn);
1047
1055
  }
@@ -1052,7 +1060,7 @@ export var deserializeAws_restJson1CreateComponentVersionCommand = function (out
1052
1060
  contents.componentVersion = __expectString(data.componentVersion);
1053
1061
  }
1054
1062
  if (data.creationTimestamp !== undefined && data.creationTimestamp !== null) {
1055
- contents.creationTimestamp = new Date(Math.round(data.creationTimestamp * 1000));
1063
+ contents.creationTimestamp = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.creationTimestamp)));
1056
1064
  }
1057
1065
  if (data.status !== undefined && data.status !== null) {
1058
1066
  contents.status = deserializeAws_restJson1CloudComponentStatus(data.status, context);
@@ -1148,9 +1156,9 @@ var deserializeAws_restJson1CreateComponentVersionCommandError = function (outpu
1148
1156
  });
1149
1157
  }); };
1150
1158
  export var deserializeAws_restJson1CreateDeploymentCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1151
- var contents, data;
1152
- return __generator(this, function (_a) {
1153
- switch (_a.label) {
1159
+ var contents, data, _a, _b;
1160
+ return __generator(this, function (_c) {
1161
+ switch (_c.label) {
1154
1162
  case 0:
1155
1163
  if (output.statusCode !== 201 && output.statusCode >= 300) {
1156
1164
  return [2 /*return*/, deserializeAws_restJson1CreateDeploymentCommandError(output, context)];
@@ -1161,9 +1169,11 @@ export var deserializeAws_restJson1CreateDeploymentCommand = function (output, c
1161
1169
  iotJobArn: undefined,
1162
1170
  iotJobId: undefined,
1163
1171
  };
1172
+ _a = __expectNonNull;
1173
+ _b = __expectObject;
1164
1174
  return [4 /*yield*/, parseBody(output.body, context)];
1165
1175
  case 1:
1166
- data = _a.sent();
1176
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1167
1177
  if (data.deploymentId !== undefined && data.deploymentId !== null) {
1168
1178
  contents.deploymentId = __expectString(data.deploymentId);
1169
1179
  }
@@ -1448,9 +1458,9 @@ var deserializeAws_restJson1DeleteCoreDeviceCommandError = function (output, con
1448
1458
  });
1449
1459
  }); };
1450
1460
  export var deserializeAws_restJson1DescribeComponentCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1451
- var contents, data;
1452
- return __generator(this, function (_a) {
1453
- switch (_a.label) {
1461
+ var contents, data, _a, _b;
1462
+ return __generator(this, function (_c) {
1463
+ switch (_c.label) {
1454
1464
  case 0:
1455
1465
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1456
1466
  return [2 /*return*/, deserializeAws_restJson1DescribeComponentCommandError(output, context)];
@@ -1467,9 +1477,11 @@ export var deserializeAws_restJson1DescribeComponentCommand = function (output,
1467
1477
  status: undefined,
1468
1478
  tags: undefined,
1469
1479
  };
1480
+ _a = __expectNonNull;
1481
+ _b = __expectObject;
1470
1482
  return [4 /*yield*/, parseBody(output.body, context)];
1471
1483
  case 1:
1472
- data = _a.sent();
1484
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1473
1485
  if (data.arn !== undefined && data.arn !== null) {
1474
1486
  contents.arn = __expectString(data.arn);
1475
1487
  }
@@ -1480,7 +1492,7 @@ export var deserializeAws_restJson1DescribeComponentCommand = function (output,
1480
1492
  contents.componentVersion = __expectString(data.componentVersion);
1481
1493
  }
1482
1494
  if (data.creationTimestamp !== undefined && data.creationTimestamp !== null) {
1483
- contents.creationTimestamp = new Date(Math.round(data.creationTimestamp * 1000));
1495
+ contents.creationTimestamp = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.creationTimestamp)));
1484
1496
  }
1485
1497
  if (data.description !== undefined && data.description !== null) {
1486
1498
  contents.description = __expectString(data.description);
@@ -1572,9 +1584,9 @@ var deserializeAws_restJson1DescribeComponentCommandError = function (output, co
1572
1584
  });
1573
1585
  }); };
1574
1586
  export var deserializeAws_restJson1GetComponentCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1575
- var contents, data;
1576
- return __generator(this, function (_a) {
1577
- switch (_a.label) {
1587
+ var contents, data, _a, _b;
1588
+ return __generator(this, function (_c) {
1589
+ switch (_c.label) {
1578
1590
  case 0:
1579
1591
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1580
1592
  return [2 /*return*/, deserializeAws_restJson1GetComponentCommandError(output, context)];
@@ -1585,9 +1597,11 @@ export var deserializeAws_restJson1GetComponentCommand = function (output, conte
1585
1597
  recipeOutputFormat: undefined,
1586
1598
  tags: undefined,
1587
1599
  };
1600
+ _a = __expectNonNull;
1601
+ _b = __expectObject;
1588
1602
  return [4 /*yield*/, parseBody(output.body, context)];
1589
1603
  case 1:
1590
- data = _a.sent();
1604
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1591
1605
  if (data.recipe !== undefined && data.recipe !== null) {
1592
1606
  contents.recipe = context.base64Decoder(data.recipe);
1593
1607
  }
@@ -1672,9 +1686,9 @@ var deserializeAws_restJson1GetComponentCommandError = function (output, context
1672
1686
  });
1673
1687
  }); };
1674
1688
  export var deserializeAws_restJson1GetComponentVersionArtifactCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1675
- var contents, data;
1676
- return __generator(this, function (_a) {
1677
- switch (_a.label) {
1689
+ var contents, data, _a, _b;
1690
+ return __generator(this, function (_c) {
1691
+ switch (_c.label) {
1678
1692
  case 0:
1679
1693
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1680
1694
  return [2 /*return*/, deserializeAws_restJson1GetComponentVersionArtifactCommandError(output, context)];
@@ -1683,9 +1697,11 @@ export var deserializeAws_restJson1GetComponentVersionArtifactCommand = function
1683
1697
  $metadata: deserializeMetadata(output),
1684
1698
  preSignedUrl: undefined,
1685
1699
  };
1700
+ _a = __expectNonNull;
1701
+ _b = __expectObject;
1686
1702
  return [4 /*yield*/, parseBody(output.body, context)];
1687
1703
  case 1:
1688
- data = _a.sent();
1704
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1689
1705
  if (data.preSignedUrl !== undefined && data.preSignedUrl !== null) {
1690
1706
  contents.preSignedUrl = __expectString(data.preSignedUrl);
1691
1707
  }
@@ -1764,9 +1780,9 @@ var deserializeAws_restJson1GetComponentVersionArtifactCommandError = function (
1764
1780
  });
1765
1781
  }); };
1766
1782
  export var deserializeAws_restJson1GetCoreDeviceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1767
- var contents, data;
1768
- return __generator(this, function (_a) {
1769
- switch (_a.label) {
1783
+ var contents, data, _a, _b;
1784
+ return __generator(this, function (_c) {
1785
+ switch (_c.label) {
1770
1786
  case 0:
1771
1787
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1772
1788
  return [2 /*return*/, deserializeAws_restJson1GetCoreDeviceCommandError(output, context)];
@@ -1781,9 +1797,11 @@ export var deserializeAws_restJson1GetCoreDeviceCommand = function (output, cont
1781
1797
  status: undefined,
1782
1798
  tags: undefined,
1783
1799
  };
1800
+ _a = __expectNonNull;
1801
+ _b = __expectObject;
1784
1802
  return [4 /*yield*/, parseBody(output.body, context)];
1785
1803
  case 1:
1786
- data = _a.sent();
1804
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1787
1805
  if (data.architecture !== undefined && data.architecture !== null) {
1788
1806
  contents.architecture = __expectString(data.architecture);
1789
1807
  }
@@ -1794,7 +1812,7 @@ export var deserializeAws_restJson1GetCoreDeviceCommand = function (output, cont
1794
1812
  contents.coreVersion = __expectString(data.coreVersion);
1795
1813
  }
1796
1814
  if (data.lastStatusUpdateTimestamp !== undefined && data.lastStatusUpdateTimestamp !== null) {
1797
- contents.lastStatusUpdateTimestamp = new Date(Math.round(data.lastStatusUpdateTimestamp * 1000));
1815
+ contents.lastStatusUpdateTimestamp = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.lastStatusUpdateTimestamp)));
1798
1816
  }
1799
1817
  if (data.platform !== undefined && data.platform !== null) {
1800
1818
  contents.platform = __expectString(data.platform);
@@ -1880,9 +1898,9 @@ var deserializeAws_restJson1GetCoreDeviceCommandError = function (output, contex
1880
1898
  });
1881
1899
  }); };
1882
1900
  export var deserializeAws_restJson1GetDeploymentCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1883
- var contents, data;
1884
- return __generator(this, function (_a) {
1885
- switch (_a.label) {
1901
+ var contents, data, _a, _b;
1902
+ return __generator(this, function (_c) {
1903
+ switch (_c.label) {
1886
1904
  case 0:
1887
1905
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1888
1906
  return [2 /*return*/, deserializeAws_restJson1GetDeploymentCommandError(output, context)];
@@ -1903,14 +1921,16 @@ export var deserializeAws_restJson1GetDeploymentCommand = function (output, cont
1903
1921
  tags: undefined,
1904
1922
  targetArn: undefined,
1905
1923
  };
1924
+ _a = __expectNonNull;
1925
+ _b = __expectObject;
1906
1926
  return [4 /*yield*/, parseBody(output.body, context)];
1907
1927
  case 1:
1908
- data = _a.sent();
1928
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
1909
1929
  if (data.components !== undefined && data.components !== null) {
1910
1930
  contents.components = deserializeAws_restJson1ComponentDeploymentSpecifications(data.components, context);
1911
1931
  }
1912
1932
  if (data.creationTimestamp !== undefined && data.creationTimestamp !== null) {
1913
- contents.creationTimestamp = new Date(Math.round(data.creationTimestamp * 1000));
1933
+ contents.creationTimestamp = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.creationTimestamp)));
1914
1934
  }
1915
1935
  if (data.deploymentId !== undefined && data.deploymentId !== null) {
1916
1936
  contents.deploymentId = __expectString(data.deploymentId);
@@ -2020,9 +2040,9 @@ var deserializeAws_restJson1GetDeploymentCommandError = function (output, contex
2020
2040
  });
2021
2041
  }); };
2022
2042
  export var deserializeAws_restJson1ListClientDevicesAssociatedWithCoreDeviceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2023
- var contents, data;
2024
- return __generator(this, function (_a) {
2025
- switch (_a.label) {
2043
+ var contents, data, _a, _b;
2044
+ return __generator(this, function (_c) {
2045
+ switch (_c.label) {
2026
2046
  case 0:
2027
2047
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2028
2048
  return [2 /*return*/, deserializeAws_restJson1ListClientDevicesAssociatedWithCoreDeviceCommandError(output, context)];
@@ -2032,9 +2052,11 @@ export var deserializeAws_restJson1ListClientDevicesAssociatedWithCoreDeviceComm
2032
2052
  associatedClientDevices: undefined,
2033
2053
  nextToken: undefined,
2034
2054
  };
2055
+ _a = __expectNonNull;
2056
+ _b = __expectObject;
2035
2057
  return [4 /*yield*/, parseBody(output.body, context)];
2036
2058
  case 1:
2037
- data = _a.sent();
2059
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2038
2060
  if (data.associatedClientDevices !== undefined && data.associatedClientDevices !== null) {
2039
2061
  contents.associatedClientDevices = deserializeAws_restJson1AssociatedClientDeviceList(data.associatedClientDevices, context);
2040
2062
  }
@@ -2116,9 +2138,9 @@ var deserializeAws_restJson1ListClientDevicesAssociatedWithCoreDeviceCommandErro
2116
2138
  });
2117
2139
  }); };
2118
2140
  export var deserializeAws_restJson1ListComponentsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2119
- var contents, data;
2120
- return __generator(this, function (_a) {
2121
- switch (_a.label) {
2141
+ var contents, data, _a, _b;
2142
+ return __generator(this, function (_c) {
2143
+ switch (_c.label) {
2122
2144
  case 0:
2123
2145
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2124
2146
  return [2 /*return*/, deserializeAws_restJson1ListComponentsCommandError(output, context)];
@@ -2128,9 +2150,11 @@ export var deserializeAws_restJson1ListComponentsCommand = function (output, con
2128
2150
  components: undefined,
2129
2151
  nextToken: undefined,
2130
2152
  };
2153
+ _a = __expectNonNull;
2154
+ _b = __expectObject;
2131
2155
  return [4 /*yield*/, parseBody(output.body, context)];
2132
2156
  case 1:
2133
- data = _a.sent();
2157
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2134
2158
  if (data.components !== undefined && data.components !== null) {
2135
2159
  contents.components = deserializeAws_restJson1ComponentList(data.components, context);
2136
2160
  }
@@ -2204,9 +2228,9 @@ var deserializeAws_restJson1ListComponentsCommandError = function (output, conte
2204
2228
  });
2205
2229
  }); };
2206
2230
  export var deserializeAws_restJson1ListComponentVersionsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2207
- var contents, data;
2208
- return __generator(this, function (_a) {
2209
- switch (_a.label) {
2231
+ var contents, data, _a, _b;
2232
+ return __generator(this, function (_c) {
2233
+ switch (_c.label) {
2210
2234
  case 0:
2211
2235
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2212
2236
  return [2 /*return*/, deserializeAws_restJson1ListComponentVersionsCommandError(output, context)];
@@ -2216,9 +2240,11 @@ export var deserializeAws_restJson1ListComponentVersionsCommand = function (outp
2216
2240
  componentVersions: undefined,
2217
2241
  nextToken: undefined,
2218
2242
  };
2243
+ _a = __expectNonNull;
2244
+ _b = __expectObject;
2219
2245
  return [4 /*yield*/, parseBody(output.body, context)];
2220
2246
  case 1:
2221
- data = _a.sent();
2247
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2222
2248
  if (data.componentVersions !== undefined && data.componentVersions !== null) {
2223
2249
  contents.componentVersions = deserializeAws_restJson1ComponentVersionList(data.componentVersions, context);
2224
2250
  }
@@ -2300,9 +2326,9 @@ var deserializeAws_restJson1ListComponentVersionsCommandError = function (output
2300
2326
  });
2301
2327
  }); };
2302
2328
  export var deserializeAws_restJson1ListCoreDevicesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2303
- var contents, data;
2304
- return __generator(this, function (_a) {
2305
- switch (_a.label) {
2329
+ var contents, data, _a, _b;
2330
+ return __generator(this, function (_c) {
2331
+ switch (_c.label) {
2306
2332
  case 0:
2307
2333
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2308
2334
  return [2 /*return*/, deserializeAws_restJson1ListCoreDevicesCommandError(output, context)];
@@ -2312,9 +2338,11 @@ export var deserializeAws_restJson1ListCoreDevicesCommand = function (output, co
2312
2338
  coreDevices: undefined,
2313
2339
  nextToken: undefined,
2314
2340
  };
2341
+ _a = __expectNonNull;
2342
+ _b = __expectObject;
2315
2343
  return [4 /*yield*/, parseBody(output.body, context)];
2316
2344
  case 1:
2317
- data = _a.sent();
2345
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2318
2346
  if (data.coreDevices !== undefined && data.coreDevices !== null) {
2319
2347
  contents.coreDevices = deserializeAws_restJson1CoreDevicesList(data.coreDevices, context);
2320
2348
  }
@@ -2388,9 +2416,9 @@ var deserializeAws_restJson1ListCoreDevicesCommandError = function (output, cont
2388
2416
  });
2389
2417
  }); };
2390
2418
  export var deserializeAws_restJson1ListDeploymentsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2391
- var contents, data;
2392
- return __generator(this, function (_a) {
2393
- switch (_a.label) {
2419
+ var contents, data, _a, _b;
2420
+ return __generator(this, function (_c) {
2421
+ switch (_c.label) {
2394
2422
  case 0:
2395
2423
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2396
2424
  return [2 /*return*/, deserializeAws_restJson1ListDeploymentsCommandError(output, context)];
@@ -2400,9 +2428,11 @@ export var deserializeAws_restJson1ListDeploymentsCommand = function (output, co
2400
2428
  deployments: undefined,
2401
2429
  nextToken: undefined,
2402
2430
  };
2431
+ _a = __expectNonNull;
2432
+ _b = __expectObject;
2403
2433
  return [4 /*yield*/, parseBody(output.body, context)];
2404
2434
  case 1:
2405
- data = _a.sent();
2435
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2406
2436
  if (data.deployments !== undefined && data.deployments !== null) {
2407
2437
  contents.deployments = deserializeAws_restJson1DeploymentList(data.deployments, context);
2408
2438
  }
@@ -2476,9 +2506,9 @@ var deserializeAws_restJson1ListDeploymentsCommandError = function (output, cont
2476
2506
  });
2477
2507
  }); };
2478
2508
  export var deserializeAws_restJson1ListEffectiveDeploymentsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2479
- var contents, data;
2480
- return __generator(this, function (_a) {
2481
- switch (_a.label) {
2509
+ var contents, data, _a, _b;
2510
+ return __generator(this, function (_c) {
2511
+ switch (_c.label) {
2482
2512
  case 0:
2483
2513
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2484
2514
  return [2 /*return*/, deserializeAws_restJson1ListEffectiveDeploymentsCommandError(output, context)];
@@ -2488,9 +2518,11 @@ export var deserializeAws_restJson1ListEffectiveDeploymentsCommand = function (o
2488
2518
  effectiveDeployments: undefined,
2489
2519
  nextToken: undefined,
2490
2520
  };
2521
+ _a = __expectNonNull;
2522
+ _b = __expectObject;
2491
2523
  return [4 /*yield*/, parseBody(output.body, context)];
2492
2524
  case 1:
2493
- data = _a.sent();
2525
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2494
2526
  if (data.effectiveDeployments !== undefined && data.effectiveDeployments !== null) {
2495
2527
  contents.effectiveDeployments = deserializeAws_restJson1EffectiveDeploymentsList(data.effectiveDeployments, context);
2496
2528
  }
@@ -2572,9 +2604,9 @@ var deserializeAws_restJson1ListEffectiveDeploymentsCommandError = function (out
2572
2604
  });
2573
2605
  }); };
2574
2606
  export var deserializeAws_restJson1ListInstalledComponentsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2575
- var contents, data;
2576
- return __generator(this, function (_a) {
2577
- switch (_a.label) {
2607
+ var contents, data, _a, _b;
2608
+ return __generator(this, function (_c) {
2609
+ switch (_c.label) {
2578
2610
  case 0:
2579
2611
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2580
2612
  return [2 /*return*/, deserializeAws_restJson1ListInstalledComponentsCommandError(output, context)];
@@ -2584,9 +2616,11 @@ export var deserializeAws_restJson1ListInstalledComponentsCommand = function (ou
2584
2616
  installedComponents: undefined,
2585
2617
  nextToken: undefined,
2586
2618
  };
2619
+ _a = __expectNonNull;
2620
+ _b = __expectObject;
2587
2621
  return [4 /*yield*/, parseBody(output.body, context)];
2588
2622
  case 1:
2589
- data = _a.sent();
2623
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2590
2624
  if (data.installedComponents !== undefined && data.installedComponents !== null) {
2591
2625
  contents.installedComponents = deserializeAws_restJson1InstalledComponentList(data.installedComponents, context);
2592
2626
  }
@@ -2668,9 +2702,9 @@ var deserializeAws_restJson1ListInstalledComponentsCommandError = function (outp
2668
2702
  });
2669
2703
  }); };
2670
2704
  export var deserializeAws_restJson1ListTagsForResourceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2671
- var contents, data;
2672
- return __generator(this, function (_a) {
2673
- switch (_a.label) {
2705
+ var contents, data, _a, _b;
2706
+ return __generator(this, function (_c) {
2707
+ switch (_c.label) {
2674
2708
  case 0:
2675
2709
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2676
2710
  return [2 /*return*/, deserializeAws_restJson1ListTagsForResourceCommandError(output, context)];
@@ -2679,9 +2713,11 @@ export var deserializeAws_restJson1ListTagsForResourceCommand = function (output
2679
2713
  $metadata: deserializeMetadata(output),
2680
2714
  tags: undefined,
2681
2715
  };
2716
+ _a = __expectNonNull;
2717
+ _b = __expectObject;
2682
2718
  return [4 /*yield*/, parseBody(output.body, context)];
2683
2719
  case 1:
2684
- data = _a.sent();
2720
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2685
2721
  if (data.tags !== undefined && data.tags !== null) {
2686
2722
  contents.tags = deserializeAws_restJson1TagMap(data.tags, context);
2687
2723
  }
@@ -2744,9 +2780,9 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
2744
2780
  });
2745
2781
  }); };
2746
2782
  export var deserializeAws_restJson1ResolveComponentCandidatesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
2747
- var contents, data;
2748
- return __generator(this, function (_a) {
2749
- switch (_a.label) {
2783
+ var contents, data, _a, _b;
2784
+ return __generator(this, function (_c) {
2785
+ switch (_c.label) {
2750
2786
  case 0:
2751
2787
  if (output.statusCode !== 200 && output.statusCode >= 300) {
2752
2788
  return [2 /*return*/, deserializeAws_restJson1ResolveComponentCandidatesCommandError(output, context)];
@@ -2755,9 +2791,11 @@ export var deserializeAws_restJson1ResolveComponentCandidatesCommand = function
2755
2791
  $metadata: deserializeMetadata(output),
2756
2792
  resolvedComponentVersions: undefined,
2757
2793
  };
2794
+ _a = __expectNonNull;
2795
+ _b = __expectObject;
2758
2796
  return [4 /*yield*/, parseBody(output.body, context)];
2759
2797
  case 1:
2760
- data = _a.sent();
2798
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
2761
2799
  if (data.resolvedComponentVersions !== undefined && data.resolvedComponentVersions !== null) {
2762
2800
  contents.resolvedComponentVersions = deserializeAws_restJson1ResolvedComponentVersionsList(data.resolvedComponentVersions, context);
2763
2801
  }
@@ -3038,7 +3076,7 @@ var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOu
3038
3076
  retryAfterSeconds: undefined,
3039
3077
  };
3040
3078
  if (parsedOutput.headers["retry-after"] !== undefined) {
3041
- contents.retryAfterSeconds = __strictParseInt(parsedOutput.headers["retry-after"]);
3079
+ contents.retryAfterSeconds = __strictParseInt32(parsedOutput.headers["retry-after"]);
3042
3080
  }
3043
3081
  data = parsedOutput.body;
3044
3082
  if (data.message !== undefined && data.message !== null) {
@@ -3132,7 +3170,7 @@ var deserializeAws_restJson1ThrottlingExceptionResponse = function (parsedOutput
3132
3170
  serviceCode: undefined,
3133
3171
  };
3134
3172
  if (parsedOutput.headers["retry-after"] !== undefined) {
3135
- contents.retryAfterSeconds = __strictParseInt(parsedOutput.headers["retry-after"]);
3173
+ contents.retryAfterSeconds = __strictParseInt32(parsedOutput.headers["retry-after"]);
3136
3174
  }
3137
3175
  data = parsedOutput.body;
3138
3176
  if (data.message !== undefined && data.message !== null) {
@@ -3514,7 +3552,7 @@ var deserializeAws_restJson1AssociateClientDeviceWithCoreDeviceErrorList = funct
3514
3552
  var deserializeAws_restJson1AssociatedClientDevice = function (output, context) {
3515
3553
  return {
3516
3554
  associationTimestamp: output.associationTimestamp !== undefined && output.associationTimestamp !== null
3517
- ? new Date(Math.round(output.associationTimestamp * 1000))
3555
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.associationTimestamp)))
3518
3556
  : undefined,
3519
3557
  thingName: __expectString(output.thingName),
3520
3558
  };
@@ -3591,7 +3629,7 @@ var deserializeAws_restJson1ComponentLatestVersion = function (output, context)
3591
3629
  arn: __expectString(output.arn),
3592
3630
  componentVersion: __expectString(output.componentVersion),
3593
3631
  creationTimestamp: output.creationTimestamp !== undefined && output.creationTimestamp !== null
3594
- ? new Date(Math.round(output.creationTimestamp * 1000))
3632
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.creationTimestamp)))
3595
3633
  : undefined,
3596
3634
  description: __expectString(output.description),
3597
3635
  platforms: output.platforms !== undefined && output.platforms !== null
@@ -3657,7 +3695,7 @@ var deserializeAws_restJson1CoreDevice = function (output, context) {
3657
3695
  return {
3658
3696
  coreDeviceThingName: __expectString(output.coreDeviceThingName),
3659
3697
  lastStatusUpdateTimestamp: output.lastStatusUpdateTimestamp !== undefined && output.lastStatusUpdateTimestamp !== null
3660
- ? new Date(Math.round(output.lastStatusUpdateTimestamp * 1000))
3698
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.lastStatusUpdateTimestamp)))
3661
3699
  : undefined,
3662
3700
  status: __expectString(output.status),
3663
3701
  };
@@ -3675,7 +3713,7 @@ var deserializeAws_restJson1CoreDevicesList = function (output, context) {
3675
3713
  var deserializeAws_restJson1Deployment = function (output, context) {
3676
3714
  return {
3677
3715
  creationTimestamp: output.creationTimestamp !== undefined && output.creationTimestamp !== null
3678
- ? new Date(Math.round(output.creationTimestamp * 1000))
3716
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.creationTimestamp)))
3679
3717
  : undefined,
3680
3718
  deploymentId: __expectString(output.deploymentId),
3681
3719
  deploymentName: __expectString(output.deploymentName),
@@ -3688,12 +3726,12 @@ var deserializeAws_restJson1Deployment = function (output, context) {
3688
3726
  var deserializeAws_restJson1DeploymentComponentUpdatePolicy = function (output, context) {
3689
3727
  return {
3690
3728
  action: __expectString(output.action),
3691
- timeoutInSeconds: __expectInt(output.timeoutInSeconds),
3729
+ timeoutInSeconds: __expectInt32(output.timeoutInSeconds),
3692
3730
  };
3693
3731
  };
3694
3732
  var deserializeAws_restJson1DeploymentConfigurationValidationPolicy = function (output, context) {
3695
3733
  return {
3696
- timeoutInSeconds: __expectInt(output.timeoutInSeconds),
3734
+ timeoutInSeconds: __expectInt32(output.timeoutInSeconds),
3697
3735
  };
3698
3736
  };
3699
3737
  var deserializeAws_restJson1DeploymentIoTJobConfiguration = function (output, context) {
@@ -3751,7 +3789,7 @@ var deserializeAws_restJson1EffectiveDeployment = function (output, context) {
3751
3789
  return {
3752
3790
  coreDeviceExecutionStatus: __expectString(output.coreDeviceExecutionStatus),
3753
3791
  creationTimestamp: output.creationTimestamp !== undefined && output.creationTimestamp !== null
3754
- ? new Date(Math.round(output.creationTimestamp * 1000))
3792
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.creationTimestamp)))
3755
3793
  : undefined,
3756
3794
  deploymentId: __expectString(output.deploymentId),
3757
3795
  deploymentName: __expectString(output.deploymentName),
@@ -3759,7 +3797,7 @@ var deserializeAws_restJson1EffectiveDeployment = function (output, context) {
3759
3797
  iotJobArn: __expectString(output.iotJobArn),
3760
3798
  iotJobId: __expectString(output.iotJobId),
3761
3799
  modifiedTimestamp: output.modifiedTimestamp !== undefined && output.modifiedTimestamp !== null
3762
- ? new Date(Math.round(output.modifiedTimestamp * 1000))
3800
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.modifiedTimestamp)))
3763
3801
  : undefined,
3764
3802
  reason: __expectString(output.reason),
3765
3803
  targetArn: __expectString(output.targetArn),
@@ -3805,8 +3843,8 @@ var deserializeAws_restJson1IoTJobAbortCriteria = function (output, context) {
3805
3843
  return {
3806
3844
  action: __expectString(output.action),
3807
3845
  failureType: __expectString(output.failureType),
3808
- minNumberOfExecutedThings: __expectInt(output.minNumberOfExecutedThings),
3809
- thresholdPercentage: __limitedParseFloat(output.thresholdPercentage),
3846
+ minNumberOfExecutedThings: __expectInt32(output.minNumberOfExecutedThings),
3847
+ thresholdPercentage: __limitedParseDouble(output.thresholdPercentage),
3810
3848
  };
3811
3849
  };
3812
3850
  var deserializeAws_restJson1IoTJobAbortCriteriaList = function (output, context) {
@@ -3824,13 +3862,13 @@ var deserializeAws_restJson1IoTJobExecutionsRolloutConfig = function (output, co
3824
3862
  exponentialRate: output.exponentialRate !== undefined && output.exponentialRate !== null
3825
3863
  ? deserializeAws_restJson1IoTJobExponentialRolloutRate(output.exponentialRate, context)
3826
3864
  : undefined,
3827
- maximumPerMinute: __expectInt(output.maximumPerMinute),
3865
+ maximumPerMinute: __expectInt32(output.maximumPerMinute),
3828
3866
  };
3829
3867
  };
3830
3868
  var deserializeAws_restJson1IoTJobExponentialRolloutRate = function (output, context) {
3831
3869
  return {
3832
- baseRatePerMinute: __expectInt(output.baseRatePerMinute),
3833
- incrementFactor: __limitedParseFloat(output.incrementFactor),
3870
+ baseRatePerMinute: __expectInt32(output.baseRatePerMinute),
3871
+ incrementFactor: __limitedParseDouble(output.incrementFactor),
3834
3872
  rateIncreaseCriteria: output.rateIncreaseCriteria !== undefined && output.rateIncreaseCriteria !== null
3835
3873
  ? deserializeAws_restJson1IoTJobRateIncreaseCriteria(output.rateIncreaseCriteria, context)
3836
3874
  : undefined,
@@ -3838,13 +3876,13 @@ var deserializeAws_restJson1IoTJobExponentialRolloutRate = function (output, con
3838
3876
  };
3839
3877
  var deserializeAws_restJson1IoTJobRateIncreaseCriteria = function (output, context) {
3840
3878
  return {
3841
- numberOfNotifiedThings: __expectInt(output.numberOfNotifiedThings),
3842
- numberOfSucceededThings: __expectInt(output.numberOfSucceededThings),
3879
+ numberOfNotifiedThings: __expectInt32(output.numberOfNotifiedThings),
3880
+ numberOfSucceededThings: __expectInt32(output.numberOfSucceededThings),
3843
3881
  };
3844
3882
  };
3845
3883
  var deserializeAws_restJson1IoTJobTimeoutConfig = function (output, context) {
3846
3884
  return {
3847
- inProgressTimeoutInMinutes: __expectInt(output.inProgressTimeoutInMinutes),
3885
+ inProgressTimeoutInMinutes: __expectLong(output.inProgressTimeoutInMinutes),
3848
3886
  };
3849
3887
  };
3850
3888
  var deserializeAws_restJson1PlatformAttributesMap = function (output, context) {
@@ -3887,8 +3925,8 @@ var deserializeAws_restJson1StringMap = function (output, context) {
3887
3925
  };
3888
3926
  var deserializeAws_restJson1SystemResourceLimits = function (output, context) {
3889
3927
  return {
3890
- cpus: __limitedParseFloat(output.cpus),
3891
- memory: __expectInt(output.memory),
3928
+ cpus: __limitedParseDouble(output.cpus),
3929
+ memory: __expectLong(output.memory),
3892
3930
  };
3893
3931
  };
3894
3932
  var deserializeAws_restJson1TagMap = function (output, context) {