@aws-sdk/client-connect 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, } from "@aws-sdk/smithy-client";
3
+ import { expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, limitedParseDouble as __limitedParseDouble, parseEpochTimestamp as __parseEpochTimestamp, serializeFloat as __serializeFloat, } from "@aws-sdk/smithy-client";
4
4
  import { v4 as generateIdempotencyToken } from "uuid";
5
5
  export var serializeAws_restJson1AssociateApprovedOriginCommand = 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;
@@ -4403,9 +4403,9 @@ var deserializeAws_restJson1AssociateBotCommandError = function (output, context
4403
4403
  });
4404
4404
  }); };
4405
4405
  export var deserializeAws_restJson1AssociateInstanceStorageConfigCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
4406
- var contents, data;
4407
- return __generator(this, function (_a) {
4408
- switch (_a.label) {
4406
+ var contents, data, _a, _b;
4407
+ return __generator(this, function (_c) {
4408
+ switch (_c.label) {
4409
4409
  case 0:
4410
4410
  if (output.statusCode !== 200 && output.statusCode >= 300) {
4411
4411
  return [2 /*return*/, deserializeAws_restJson1AssociateInstanceStorageConfigCommandError(output, context)];
@@ -4414,9 +4414,11 @@ export var deserializeAws_restJson1AssociateInstanceStorageConfigCommand = funct
4414
4414
  $metadata: deserializeMetadata(output),
4415
4415
  AssociationId: undefined,
4416
4416
  };
4417
+ _a = __expectNonNull;
4418
+ _b = __expectObject;
4417
4419
  return [4 /*yield*/, parseBody(output.body, context)];
4418
4420
  case 1:
4419
- data = _a.sent();
4421
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
4420
4422
  if (data.AssociationId !== undefined && data.AssociationId !== null) {
4421
4423
  contents.AssociationId = __expectString(data.AssociationId);
4422
4424
  }
@@ -4895,9 +4897,9 @@ var deserializeAws_restJson1AssociateRoutingProfileQueuesCommandError = function
4895
4897
  });
4896
4898
  }); };
4897
4899
  export var deserializeAws_restJson1AssociateSecurityKeyCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
4898
- var contents, data;
4899
- return __generator(this, function (_a) {
4900
- switch (_a.label) {
4900
+ var contents, data, _a, _b;
4901
+ return __generator(this, function (_c) {
4902
+ switch (_c.label) {
4901
4903
  case 0:
4902
4904
  if (output.statusCode !== 200 && output.statusCode >= 300) {
4903
4905
  return [2 /*return*/, deserializeAws_restJson1AssociateSecurityKeyCommandError(output, context)];
@@ -4906,9 +4908,11 @@ export var deserializeAws_restJson1AssociateSecurityKeyCommand = function (outpu
4906
4908
  $metadata: deserializeMetadata(output),
4907
4909
  AssociationId: undefined,
4908
4910
  };
4911
+ _a = __expectNonNull;
4912
+ _b = __expectObject;
4909
4913
  return [4 /*yield*/, parseBody(output.body, context)];
4910
4914
  case 1:
4911
- data = _a.sent();
4915
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
4912
4916
  if (data.AssociationId !== undefined && data.AssociationId !== null) {
4913
4917
  contents.AssociationId = __expectString(data.AssociationId);
4914
4918
  }
@@ -5003,9 +5007,9 @@ var deserializeAws_restJson1AssociateSecurityKeyCommandError = function (output,
5003
5007
  });
5004
5008
  }); };
5005
5009
  export var deserializeAws_restJson1CreateAgentStatusCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5006
- var contents, data;
5007
- return __generator(this, function (_a) {
5008
- switch (_a.label) {
5010
+ var contents, data, _a, _b;
5011
+ return __generator(this, function (_c) {
5012
+ switch (_c.label) {
5009
5013
  case 0:
5010
5014
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5011
5015
  return [2 /*return*/, deserializeAws_restJson1CreateAgentStatusCommandError(output, context)];
@@ -5015,9 +5019,11 @@ export var deserializeAws_restJson1CreateAgentStatusCommand = function (output,
5015
5019
  AgentStatusARN: undefined,
5016
5020
  AgentStatusId: undefined,
5017
5021
  };
5022
+ _a = __expectNonNull;
5023
+ _b = __expectObject;
5018
5024
  return [4 /*yield*/, parseBody(output.body, context)];
5019
5025
  case 1:
5020
- data = _a.sent();
5026
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5021
5027
  if (data.AgentStatusARN !== undefined && data.AgentStatusARN !== null) {
5022
5028
  contents.AgentStatusARN = __expectString(data.AgentStatusARN);
5023
5029
  }
@@ -5115,9 +5121,9 @@ var deserializeAws_restJson1CreateAgentStatusCommandError = function (output, co
5115
5121
  });
5116
5122
  }); };
5117
5123
  export var deserializeAws_restJson1CreateContactFlowCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5118
- var contents, data;
5119
- return __generator(this, function (_a) {
5120
- switch (_a.label) {
5124
+ var contents, data, _a, _b;
5125
+ return __generator(this, function (_c) {
5126
+ switch (_c.label) {
5121
5127
  case 0:
5122
5128
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5123
5129
  return [2 /*return*/, deserializeAws_restJson1CreateContactFlowCommandError(output, context)];
@@ -5127,9 +5133,11 @@ export var deserializeAws_restJson1CreateContactFlowCommand = function (output,
5127
5133
  ContactFlowArn: undefined,
5128
5134
  ContactFlowId: undefined,
5129
5135
  };
5136
+ _a = __expectNonNull;
5137
+ _b = __expectObject;
5130
5138
  return [4 /*yield*/, parseBody(output.body, context)];
5131
5139
  case 1:
5132
- data = _a.sent();
5140
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5133
5141
  if (data.ContactFlowArn !== undefined && data.ContactFlowArn !== null) {
5134
5142
  contents.ContactFlowArn = __expectString(data.ContactFlowArn);
5135
5143
  }
@@ -5235,9 +5243,9 @@ var deserializeAws_restJson1CreateContactFlowCommandError = function (output, co
5235
5243
  });
5236
5244
  }); };
5237
5245
  export var deserializeAws_restJson1CreateHoursOfOperationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5238
- var contents, data;
5239
- return __generator(this, function (_a) {
5240
- switch (_a.label) {
5246
+ var contents, data, _a, _b;
5247
+ return __generator(this, function (_c) {
5248
+ switch (_c.label) {
5241
5249
  case 0:
5242
5250
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5243
5251
  return [2 /*return*/, deserializeAws_restJson1CreateHoursOfOperationCommandError(output, context)];
@@ -5247,9 +5255,11 @@ export var deserializeAws_restJson1CreateHoursOfOperationCommand = function (out
5247
5255
  HoursOfOperationArn: undefined,
5248
5256
  HoursOfOperationId: undefined,
5249
5257
  };
5258
+ _a = __expectNonNull;
5259
+ _b = __expectObject;
5250
5260
  return [4 /*yield*/, parseBody(output.body, context)];
5251
5261
  case 1:
5252
- data = _a.sent();
5262
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5253
5263
  if (data.HoursOfOperationArn !== undefined && data.HoursOfOperationArn !== null) {
5254
5264
  contents.HoursOfOperationArn = __expectString(data.HoursOfOperationArn);
5255
5265
  }
@@ -5347,9 +5357,9 @@ var deserializeAws_restJson1CreateHoursOfOperationCommandError = function (outpu
5347
5357
  });
5348
5358
  }); };
5349
5359
  export var deserializeAws_restJson1CreateInstanceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5350
- var contents, data;
5351
- return __generator(this, function (_a) {
5352
- switch (_a.label) {
5360
+ var contents, data, _a, _b;
5361
+ return __generator(this, function (_c) {
5362
+ switch (_c.label) {
5353
5363
  case 0:
5354
5364
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5355
5365
  return [2 /*return*/, deserializeAws_restJson1CreateInstanceCommandError(output, context)];
@@ -5359,9 +5369,11 @@ export var deserializeAws_restJson1CreateInstanceCommand = function (output, con
5359
5369
  Arn: undefined,
5360
5370
  Id: undefined,
5361
5371
  };
5372
+ _a = __expectNonNull;
5373
+ _b = __expectObject;
5362
5374
  return [4 /*yield*/, parseBody(output.body, context)];
5363
5375
  case 1:
5364
- data = _a.sent();
5376
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5365
5377
  if (data.Arn !== undefined && data.Arn !== null) {
5366
5378
  contents.Arn = __expectString(data.Arn);
5367
5379
  }
@@ -5443,9 +5455,9 @@ var deserializeAws_restJson1CreateInstanceCommandError = function (output, conte
5443
5455
  });
5444
5456
  }); };
5445
5457
  export var deserializeAws_restJson1CreateIntegrationAssociationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5446
- var contents, data;
5447
- return __generator(this, function (_a) {
5448
- switch (_a.label) {
5458
+ var contents, data, _a, _b;
5459
+ return __generator(this, function (_c) {
5460
+ switch (_c.label) {
5449
5461
  case 0:
5450
5462
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5451
5463
  return [2 /*return*/, deserializeAws_restJson1CreateIntegrationAssociationCommandError(output, context)];
@@ -5455,9 +5467,11 @@ export var deserializeAws_restJson1CreateIntegrationAssociationCommand = functio
5455
5467
  IntegrationAssociationArn: undefined,
5456
5468
  IntegrationAssociationId: undefined,
5457
5469
  };
5470
+ _a = __expectNonNull;
5471
+ _b = __expectObject;
5458
5472
  return [4 /*yield*/, parseBody(output.body, context)];
5459
5473
  case 1:
5460
- data = _a.sent();
5474
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5461
5475
  if (data.IntegrationAssociationArn !== undefined && data.IntegrationAssociationArn !== null) {
5462
5476
  contents.IntegrationAssociationArn = __expectString(data.IntegrationAssociationArn);
5463
5477
  }
@@ -5539,9 +5553,9 @@ var deserializeAws_restJson1CreateIntegrationAssociationCommandError = function
5539
5553
  });
5540
5554
  }); };
5541
5555
  export var deserializeAws_restJson1CreateQueueCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5542
- var contents, data;
5543
- return __generator(this, function (_a) {
5544
- switch (_a.label) {
5556
+ var contents, data, _a, _b;
5557
+ return __generator(this, function (_c) {
5558
+ switch (_c.label) {
5545
5559
  case 0:
5546
5560
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5547
5561
  return [2 /*return*/, deserializeAws_restJson1CreateQueueCommandError(output, context)];
@@ -5551,9 +5565,11 @@ export var deserializeAws_restJson1CreateQueueCommand = function (output, contex
5551
5565
  QueueArn: undefined,
5552
5566
  QueueId: undefined,
5553
5567
  };
5568
+ _a = __expectNonNull;
5569
+ _b = __expectObject;
5554
5570
  return [4 /*yield*/, parseBody(output.body, context)];
5555
5571
  case 1:
5556
- data = _a.sent();
5572
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5557
5573
  if (data.QueueArn !== undefined && data.QueueArn !== null) {
5558
5574
  contents.QueueArn = __expectString(data.QueueArn);
5559
5575
  }
@@ -5651,9 +5667,9 @@ var deserializeAws_restJson1CreateQueueCommandError = function (output, context)
5651
5667
  });
5652
5668
  }); };
5653
5669
  export var deserializeAws_restJson1CreateQuickConnectCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5654
- var contents, data;
5655
- return __generator(this, function (_a) {
5656
- switch (_a.label) {
5670
+ var contents, data, _a, _b;
5671
+ return __generator(this, function (_c) {
5672
+ switch (_c.label) {
5657
5673
  case 0:
5658
5674
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5659
5675
  return [2 /*return*/, deserializeAws_restJson1CreateQuickConnectCommandError(output, context)];
@@ -5663,9 +5679,11 @@ export var deserializeAws_restJson1CreateQuickConnectCommand = function (output,
5663
5679
  QuickConnectARN: undefined,
5664
5680
  QuickConnectId: undefined,
5665
5681
  };
5682
+ _a = __expectNonNull;
5683
+ _b = __expectObject;
5666
5684
  return [4 /*yield*/, parseBody(output.body, context)];
5667
5685
  case 1:
5668
- data = _a.sent();
5686
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5669
5687
  if (data.QuickConnectARN !== undefined && data.QuickConnectARN !== null) {
5670
5688
  contents.QuickConnectARN = __expectString(data.QuickConnectARN);
5671
5689
  }
@@ -5763,9 +5781,9 @@ var deserializeAws_restJson1CreateQuickConnectCommandError = function (output, c
5763
5781
  });
5764
5782
  }); };
5765
5783
  export var deserializeAws_restJson1CreateRoutingProfileCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5766
- var contents, data;
5767
- return __generator(this, function (_a) {
5768
- switch (_a.label) {
5784
+ var contents, data, _a, _b;
5785
+ return __generator(this, function (_c) {
5786
+ switch (_c.label) {
5769
5787
  case 0:
5770
5788
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5771
5789
  return [2 /*return*/, deserializeAws_restJson1CreateRoutingProfileCommandError(output, context)];
@@ -5775,9 +5793,11 @@ export var deserializeAws_restJson1CreateRoutingProfileCommand = function (outpu
5775
5793
  RoutingProfileArn: undefined,
5776
5794
  RoutingProfileId: undefined,
5777
5795
  };
5796
+ _a = __expectNonNull;
5797
+ _b = __expectObject;
5778
5798
  return [4 /*yield*/, parseBody(output.body, context)];
5779
5799
  case 1:
5780
- data = _a.sent();
5800
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5781
5801
  if (data.RoutingProfileArn !== undefined && data.RoutingProfileArn !== null) {
5782
5802
  contents.RoutingProfileArn = __expectString(data.RoutingProfileArn);
5783
5803
  }
@@ -5875,9 +5895,9 @@ var deserializeAws_restJson1CreateRoutingProfileCommandError = function (output,
5875
5895
  });
5876
5896
  }); };
5877
5897
  export var deserializeAws_restJson1CreateUseCaseCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5878
- var contents, data;
5879
- return __generator(this, function (_a) {
5880
- switch (_a.label) {
5898
+ var contents, data, _a, _b;
5899
+ return __generator(this, function (_c) {
5900
+ switch (_c.label) {
5881
5901
  case 0:
5882
5902
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5883
5903
  return [2 /*return*/, deserializeAws_restJson1CreateUseCaseCommandError(output, context)];
@@ -5887,9 +5907,11 @@ export var deserializeAws_restJson1CreateUseCaseCommand = function (output, cont
5887
5907
  UseCaseArn: undefined,
5888
5908
  UseCaseId: undefined,
5889
5909
  };
5910
+ _a = __expectNonNull;
5911
+ _b = __expectObject;
5890
5912
  return [4 /*yield*/, parseBody(output.body, context)];
5891
5913
  case 1:
5892
- data = _a.sent();
5914
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5893
5915
  if (data.UseCaseArn !== undefined && data.UseCaseArn !== null) {
5894
5916
  contents.UseCaseArn = __expectString(data.UseCaseArn);
5895
5917
  }
@@ -5971,9 +5993,9 @@ var deserializeAws_restJson1CreateUseCaseCommandError = function (output, contex
5971
5993
  });
5972
5994
  }); };
5973
5995
  export var deserializeAws_restJson1CreateUserCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
5974
- var contents, data;
5975
- return __generator(this, function (_a) {
5976
- switch (_a.label) {
5996
+ var contents, data, _a, _b;
5997
+ return __generator(this, function (_c) {
5998
+ switch (_c.label) {
5977
5999
  case 0:
5978
6000
  if (output.statusCode !== 200 && output.statusCode >= 300) {
5979
6001
  return [2 /*return*/, deserializeAws_restJson1CreateUserCommandError(output, context)];
@@ -5983,9 +6005,11 @@ export var deserializeAws_restJson1CreateUserCommand = function (output, context
5983
6005
  UserArn: undefined,
5984
6006
  UserId: undefined,
5985
6007
  };
6008
+ _a = __expectNonNull;
6009
+ _b = __expectObject;
5986
6010
  return [4 /*yield*/, parseBody(output.body, context)];
5987
6011
  case 1:
5988
- data = _a.sent();
6012
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
5989
6013
  if (data.UserArn !== undefined && data.UserArn !== null) {
5990
6014
  contents.UserArn = __expectString(data.UserArn);
5991
6015
  }
@@ -6083,9 +6107,9 @@ var deserializeAws_restJson1CreateUserCommandError = function (output, context)
6083
6107
  });
6084
6108
  }); };
6085
6109
  export var deserializeAws_restJson1CreateUserHierarchyGroupCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
6086
- var contents, data;
6087
- return __generator(this, function (_a) {
6088
- switch (_a.label) {
6110
+ var contents, data, _a, _b;
6111
+ return __generator(this, function (_c) {
6112
+ switch (_c.label) {
6089
6113
  case 0:
6090
6114
  if (output.statusCode !== 200 && output.statusCode >= 300) {
6091
6115
  return [2 /*return*/, deserializeAws_restJson1CreateUserHierarchyGroupCommandError(output, context)];
@@ -6095,9 +6119,11 @@ export var deserializeAws_restJson1CreateUserHierarchyGroupCommand = function (o
6095
6119
  HierarchyGroupArn: undefined,
6096
6120
  HierarchyGroupId: undefined,
6097
6121
  };
6122
+ _a = __expectNonNull;
6123
+ _b = __expectObject;
6098
6124
  return [4 /*yield*/, parseBody(output.body, context)];
6099
6125
  case 1:
6100
- data = _a.sent();
6126
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
6101
6127
  if (data.HierarchyGroupArn !== undefined && data.HierarchyGroupArn !== null) {
6102
6128
  contents.HierarchyGroupArn = __expectString(data.HierarchyGroupArn);
6103
6129
  }
@@ -6787,9 +6813,9 @@ var deserializeAws_restJson1DeleteUserHierarchyGroupCommandError = function (out
6787
6813
  });
6788
6814
  }); };
6789
6815
  export var deserializeAws_restJson1DescribeAgentStatusCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
6790
- var contents, data;
6791
- return __generator(this, function (_a) {
6792
- switch (_a.label) {
6816
+ var contents, data, _a, _b;
6817
+ return __generator(this, function (_c) {
6818
+ switch (_c.label) {
6793
6819
  case 0:
6794
6820
  if (output.statusCode !== 200 && output.statusCode >= 300) {
6795
6821
  return [2 /*return*/, deserializeAws_restJson1DescribeAgentStatusCommandError(output, context)];
@@ -6798,9 +6824,11 @@ export var deserializeAws_restJson1DescribeAgentStatusCommand = function (output
6798
6824
  $metadata: deserializeMetadata(output),
6799
6825
  AgentStatus: undefined,
6800
6826
  };
6827
+ _a = __expectNonNull;
6828
+ _b = __expectObject;
6801
6829
  return [4 /*yield*/, parseBody(output.body, context)];
6802
6830
  case 1:
6803
- data = _a.sent();
6831
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
6804
6832
  if (data.AgentStatus !== undefined && data.AgentStatus !== null) {
6805
6833
  contents.AgentStatus = deserializeAws_restJson1AgentStatus(data.AgentStatus, context);
6806
6834
  }
@@ -6879,9 +6907,9 @@ var deserializeAws_restJson1DescribeAgentStatusCommandError = function (output,
6879
6907
  });
6880
6908
  }); };
6881
6909
  export var deserializeAws_restJson1DescribeContactFlowCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
6882
- var contents, data;
6883
- return __generator(this, function (_a) {
6884
- switch (_a.label) {
6910
+ var contents, data, _a, _b;
6911
+ return __generator(this, function (_c) {
6912
+ switch (_c.label) {
6885
6913
  case 0:
6886
6914
  if (output.statusCode !== 200 && output.statusCode >= 300) {
6887
6915
  return [2 /*return*/, deserializeAws_restJson1DescribeContactFlowCommandError(output, context)];
@@ -6890,9 +6918,11 @@ export var deserializeAws_restJson1DescribeContactFlowCommand = function (output
6890
6918
  $metadata: deserializeMetadata(output),
6891
6919
  ContactFlow: undefined,
6892
6920
  };
6921
+ _a = __expectNonNull;
6922
+ _b = __expectObject;
6893
6923
  return [4 /*yield*/, parseBody(output.body, context)];
6894
6924
  case 1:
6895
- data = _a.sent();
6925
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
6896
6926
  if (data.ContactFlow !== undefined && data.ContactFlow !== null) {
6897
6927
  contents.ContactFlow = deserializeAws_restJson1ContactFlow(data.ContactFlow, context);
6898
6928
  }
@@ -6979,9 +7009,9 @@ var deserializeAws_restJson1DescribeContactFlowCommandError = function (output,
6979
7009
  });
6980
7010
  }); };
6981
7011
  export var deserializeAws_restJson1DescribeHoursOfOperationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
6982
- var contents, data;
6983
- return __generator(this, function (_a) {
6984
- switch (_a.label) {
7012
+ var contents, data, _a, _b;
7013
+ return __generator(this, function (_c) {
7014
+ switch (_c.label) {
6985
7015
  case 0:
6986
7016
  if (output.statusCode !== 200 && output.statusCode >= 300) {
6987
7017
  return [2 /*return*/, deserializeAws_restJson1DescribeHoursOfOperationCommandError(output, context)];
@@ -6990,9 +7020,11 @@ export var deserializeAws_restJson1DescribeHoursOfOperationCommand = function (o
6990
7020
  $metadata: deserializeMetadata(output),
6991
7021
  HoursOfOperation: undefined,
6992
7022
  };
7023
+ _a = __expectNonNull;
7024
+ _b = __expectObject;
6993
7025
  return [4 /*yield*/, parseBody(output.body, context)];
6994
7026
  case 1:
6995
- data = _a.sent();
7027
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
6996
7028
  if (data.HoursOfOperation !== undefined && data.HoursOfOperation !== null) {
6997
7029
  contents.HoursOfOperation = deserializeAws_restJson1HoursOfOperation(data.HoursOfOperation, context);
6998
7030
  }
@@ -7071,9 +7103,9 @@ var deserializeAws_restJson1DescribeHoursOfOperationCommandError = function (out
7071
7103
  });
7072
7104
  }); };
7073
7105
  export var deserializeAws_restJson1DescribeInstanceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7074
- var contents, data;
7075
- return __generator(this, function (_a) {
7076
- switch (_a.label) {
7106
+ var contents, data, _a, _b;
7107
+ return __generator(this, function (_c) {
7108
+ switch (_c.label) {
7077
7109
  case 0:
7078
7110
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7079
7111
  return [2 /*return*/, deserializeAws_restJson1DescribeInstanceCommandError(output, context)];
@@ -7082,9 +7114,11 @@ export var deserializeAws_restJson1DescribeInstanceCommand = function (output, c
7082
7114
  $metadata: deserializeMetadata(output),
7083
7115
  Instance: undefined,
7084
7116
  };
7117
+ _a = __expectNonNull;
7118
+ _b = __expectObject;
7085
7119
  return [4 /*yield*/, parseBody(output.body, context)];
7086
7120
  case 1:
7087
- data = _a.sent();
7121
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7088
7122
  if (data.Instance !== undefined && data.Instance !== null) {
7089
7123
  contents.Instance = deserializeAws_restJson1Instance(data.Instance, context);
7090
7124
  }
@@ -7147,9 +7181,9 @@ var deserializeAws_restJson1DescribeInstanceCommandError = function (output, con
7147
7181
  });
7148
7182
  }); };
7149
7183
  export var deserializeAws_restJson1DescribeInstanceAttributeCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7150
- var contents, data;
7151
- return __generator(this, function (_a) {
7152
- switch (_a.label) {
7184
+ var contents, data, _a, _b;
7185
+ return __generator(this, function (_c) {
7186
+ switch (_c.label) {
7153
7187
  case 0:
7154
7188
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7155
7189
  return [2 /*return*/, deserializeAws_restJson1DescribeInstanceAttributeCommandError(output, context)];
@@ -7158,9 +7192,11 @@ export var deserializeAws_restJson1DescribeInstanceAttributeCommand = function (
7158
7192
  $metadata: deserializeMetadata(output),
7159
7193
  Attribute: undefined,
7160
7194
  };
7195
+ _a = __expectNonNull;
7196
+ _b = __expectObject;
7161
7197
  return [4 /*yield*/, parseBody(output.body, context)];
7162
7198
  case 1:
7163
- data = _a.sent();
7199
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7164
7200
  if (data.Attribute !== undefined && data.Attribute !== null) {
7165
7201
  contents.Attribute = deserializeAws_restJson1Attribute(data.Attribute, context);
7166
7202
  }
@@ -7239,9 +7275,9 @@ var deserializeAws_restJson1DescribeInstanceAttributeCommandError = function (ou
7239
7275
  });
7240
7276
  }); };
7241
7277
  export var deserializeAws_restJson1DescribeInstanceStorageConfigCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7242
- var contents, data;
7243
- return __generator(this, function (_a) {
7244
- switch (_a.label) {
7278
+ var contents, data, _a, _b;
7279
+ return __generator(this, function (_c) {
7280
+ switch (_c.label) {
7245
7281
  case 0:
7246
7282
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7247
7283
  return [2 /*return*/, deserializeAws_restJson1DescribeInstanceStorageConfigCommandError(output, context)];
@@ -7250,9 +7286,11 @@ export var deserializeAws_restJson1DescribeInstanceStorageConfigCommand = functi
7250
7286
  $metadata: deserializeMetadata(output),
7251
7287
  StorageConfig: undefined,
7252
7288
  };
7289
+ _a = __expectNonNull;
7290
+ _b = __expectObject;
7253
7291
  return [4 /*yield*/, parseBody(output.body, context)];
7254
7292
  case 1:
7255
- data = _a.sent();
7293
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7256
7294
  if (data.StorageConfig !== undefined && data.StorageConfig !== null) {
7257
7295
  contents.StorageConfig = deserializeAws_restJson1InstanceStorageConfig(data.StorageConfig, context);
7258
7296
  }
@@ -7331,9 +7369,9 @@ var deserializeAws_restJson1DescribeInstanceStorageConfigCommandError = function
7331
7369
  });
7332
7370
  }); };
7333
7371
  export var deserializeAws_restJson1DescribeQueueCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7334
- var contents, data;
7335
- return __generator(this, function (_a) {
7336
- switch (_a.label) {
7372
+ var contents, data, _a, _b;
7373
+ return __generator(this, function (_c) {
7374
+ switch (_c.label) {
7337
7375
  case 0:
7338
7376
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7339
7377
  return [2 /*return*/, deserializeAws_restJson1DescribeQueueCommandError(output, context)];
@@ -7342,9 +7380,11 @@ export var deserializeAws_restJson1DescribeQueueCommand = function (output, cont
7342
7380
  $metadata: deserializeMetadata(output),
7343
7381
  Queue: undefined,
7344
7382
  };
7383
+ _a = __expectNonNull;
7384
+ _b = __expectObject;
7345
7385
  return [4 /*yield*/, parseBody(output.body, context)];
7346
7386
  case 1:
7347
- data = _a.sent();
7387
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7348
7388
  if (data.Queue !== undefined && data.Queue !== null) {
7349
7389
  contents.Queue = deserializeAws_restJson1Queue(data.Queue, context);
7350
7390
  }
@@ -7423,9 +7463,9 @@ var deserializeAws_restJson1DescribeQueueCommandError = function (output, contex
7423
7463
  });
7424
7464
  }); };
7425
7465
  export var deserializeAws_restJson1DescribeQuickConnectCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7426
- var contents, data;
7427
- return __generator(this, function (_a) {
7428
- switch (_a.label) {
7466
+ var contents, data, _a, _b;
7467
+ return __generator(this, function (_c) {
7468
+ switch (_c.label) {
7429
7469
  case 0:
7430
7470
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7431
7471
  return [2 /*return*/, deserializeAws_restJson1DescribeQuickConnectCommandError(output, context)];
@@ -7434,9 +7474,11 @@ export var deserializeAws_restJson1DescribeQuickConnectCommand = function (outpu
7434
7474
  $metadata: deserializeMetadata(output),
7435
7475
  QuickConnect: undefined,
7436
7476
  };
7477
+ _a = __expectNonNull;
7478
+ _b = __expectObject;
7437
7479
  return [4 /*yield*/, parseBody(output.body, context)];
7438
7480
  case 1:
7439
- data = _a.sent();
7481
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7440
7482
  if (data.QuickConnect !== undefined && data.QuickConnect !== null) {
7441
7483
  contents.QuickConnect = deserializeAws_restJson1QuickConnect(data.QuickConnect, context);
7442
7484
  }
@@ -7515,9 +7557,9 @@ var deserializeAws_restJson1DescribeQuickConnectCommandError = function (output,
7515
7557
  });
7516
7558
  }); };
7517
7559
  export var deserializeAws_restJson1DescribeRoutingProfileCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7518
- var contents, data;
7519
- return __generator(this, function (_a) {
7520
- switch (_a.label) {
7560
+ var contents, data, _a, _b;
7561
+ return __generator(this, function (_c) {
7562
+ switch (_c.label) {
7521
7563
  case 0:
7522
7564
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7523
7565
  return [2 /*return*/, deserializeAws_restJson1DescribeRoutingProfileCommandError(output, context)];
@@ -7526,9 +7568,11 @@ export var deserializeAws_restJson1DescribeRoutingProfileCommand = function (out
7526
7568
  $metadata: deserializeMetadata(output),
7527
7569
  RoutingProfile: undefined,
7528
7570
  };
7571
+ _a = __expectNonNull;
7572
+ _b = __expectObject;
7529
7573
  return [4 /*yield*/, parseBody(output.body, context)];
7530
7574
  case 1:
7531
- data = _a.sent();
7575
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7532
7576
  if (data.RoutingProfile !== undefined && data.RoutingProfile !== null) {
7533
7577
  contents.RoutingProfile = deserializeAws_restJson1RoutingProfile(data.RoutingProfile, context);
7534
7578
  }
@@ -7607,9 +7651,9 @@ var deserializeAws_restJson1DescribeRoutingProfileCommandError = function (outpu
7607
7651
  });
7608
7652
  }); };
7609
7653
  export var deserializeAws_restJson1DescribeUserCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7610
- var contents, data;
7611
- return __generator(this, function (_a) {
7612
- switch (_a.label) {
7654
+ var contents, data, _a, _b;
7655
+ return __generator(this, function (_c) {
7656
+ switch (_c.label) {
7613
7657
  case 0:
7614
7658
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7615
7659
  return [2 /*return*/, deserializeAws_restJson1DescribeUserCommandError(output, context)];
@@ -7618,9 +7662,11 @@ export var deserializeAws_restJson1DescribeUserCommand = function (output, conte
7618
7662
  $metadata: deserializeMetadata(output),
7619
7663
  User: undefined,
7620
7664
  };
7665
+ _a = __expectNonNull;
7666
+ _b = __expectObject;
7621
7667
  return [4 /*yield*/, parseBody(output.body, context)];
7622
7668
  case 1:
7623
- data = _a.sent();
7669
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7624
7670
  if (data.User !== undefined && data.User !== null) {
7625
7671
  contents.User = deserializeAws_restJson1User(data.User, context);
7626
7672
  }
@@ -7699,9 +7745,9 @@ var deserializeAws_restJson1DescribeUserCommandError = function (output, context
7699
7745
  });
7700
7746
  }); };
7701
7747
  export var deserializeAws_restJson1DescribeUserHierarchyGroupCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7702
- var contents, data;
7703
- return __generator(this, function (_a) {
7704
- switch (_a.label) {
7748
+ var contents, data, _a, _b;
7749
+ return __generator(this, function (_c) {
7750
+ switch (_c.label) {
7705
7751
  case 0:
7706
7752
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7707
7753
  return [2 /*return*/, deserializeAws_restJson1DescribeUserHierarchyGroupCommandError(output, context)];
@@ -7710,9 +7756,11 @@ export var deserializeAws_restJson1DescribeUserHierarchyGroupCommand = function
7710
7756
  $metadata: deserializeMetadata(output),
7711
7757
  HierarchyGroup: undefined,
7712
7758
  };
7759
+ _a = __expectNonNull;
7760
+ _b = __expectObject;
7713
7761
  return [4 /*yield*/, parseBody(output.body, context)];
7714
7762
  case 1:
7715
- data = _a.sent();
7763
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7716
7764
  if (data.HierarchyGroup !== undefined && data.HierarchyGroup !== null) {
7717
7765
  contents.HierarchyGroup = deserializeAws_restJson1HierarchyGroup(data.HierarchyGroup, context);
7718
7766
  }
@@ -7791,9 +7839,9 @@ var deserializeAws_restJson1DescribeUserHierarchyGroupCommandError = function (o
7791
7839
  });
7792
7840
  }); };
7793
7841
  export var deserializeAws_restJson1DescribeUserHierarchyStructureCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
7794
- var contents, data;
7795
- return __generator(this, function (_a) {
7796
- switch (_a.label) {
7842
+ var contents, data, _a, _b;
7843
+ return __generator(this, function (_c) {
7844
+ switch (_c.label) {
7797
7845
  case 0:
7798
7846
  if (output.statusCode !== 200 && output.statusCode >= 300) {
7799
7847
  return [2 /*return*/, deserializeAws_restJson1DescribeUserHierarchyStructureCommandError(output, context)];
@@ -7802,9 +7850,11 @@ export var deserializeAws_restJson1DescribeUserHierarchyStructureCommand = funct
7802
7850
  $metadata: deserializeMetadata(output),
7803
7851
  HierarchyStructure: undefined,
7804
7852
  };
7853
+ _a = __expectNonNull;
7854
+ _b = __expectObject;
7805
7855
  return [4 /*yield*/, parseBody(output.body, context)];
7806
7856
  case 1:
7807
- data = _a.sent();
7857
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
7808
7858
  if (data.HierarchyStructure !== undefined && data.HierarchyStructure !== null) {
7809
7859
  contents.HierarchyStructure = deserializeAws_restJson1HierarchyStructure(data.HierarchyStructure, context);
7810
7860
  }
@@ -8579,9 +8629,9 @@ var deserializeAws_restJson1DisassociateSecurityKeyCommandError = function (outp
8579
8629
  });
8580
8630
  }); };
8581
8631
  export var deserializeAws_restJson1GetContactAttributesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
8582
- var contents, data;
8583
- return __generator(this, function (_a) {
8584
- switch (_a.label) {
8632
+ var contents, data, _a, _b;
8633
+ return __generator(this, function (_c) {
8634
+ switch (_c.label) {
8585
8635
  case 0:
8586
8636
  if (output.statusCode !== 200 && output.statusCode >= 300) {
8587
8637
  return [2 /*return*/, deserializeAws_restJson1GetContactAttributesCommandError(output, context)];
@@ -8590,9 +8640,11 @@ export var deserializeAws_restJson1GetContactAttributesCommand = function (outpu
8590
8640
  $metadata: deserializeMetadata(output),
8591
8641
  Attributes: undefined,
8592
8642
  };
8643
+ _a = __expectNonNull;
8644
+ _b = __expectObject;
8593
8645
  return [4 /*yield*/, parseBody(output.body, context)];
8594
8646
  case 1:
8595
- data = _a.sent();
8647
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
8596
8648
  if (data.Attributes !== undefined && data.Attributes !== null) {
8597
8649
  contents.Attributes = deserializeAws_restJson1Attributes(data.Attributes, context);
8598
8650
  }
@@ -8655,9 +8707,9 @@ var deserializeAws_restJson1GetContactAttributesCommandError = function (output,
8655
8707
  });
8656
8708
  }); };
8657
8709
  export var deserializeAws_restJson1GetCurrentMetricDataCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
8658
- var contents, data;
8659
- return __generator(this, function (_a) {
8660
- switch (_a.label) {
8710
+ var contents, data, _a, _b;
8711
+ return __generator(this, function (_c) {
8712
+ switch (_c.label) {
8661
8713
  case 0:
8662
8714
  if (output.statusCode !== 200 && output.statusCode >= 300) {
8663
8715
  return [2 /*return*/, deserializeAws_restJson1GetCurrentMetricDataCommandError(output, context)];
@@ -8668,11 +8720,13 @@ export var deserializeAws_restJson1GetCurrentMetricDataCommand = function (outpu
8668
8720
  MetricResults: undefined,
8669
8721
  NextToken: undefined,
8670
8722
  };
8723
+ _a = __expectNonNull;
8724
+ _b = __expectObject;
8671
8725
  return [4 /*yield*/, parseBody(output.body, context)];
8672
8726
  case 1:
8673
- data = _a.sent();
8727
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
8674
8728
  if (data.DataSnapshotTime !== undefined && data.DataSnapshotTime !== null) {
8675
- contents.DataSnapshotTime = new Date(Math.round(data.DataSnapshotTime * 1000));
8729
+ contents.DataSnapshotTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.DataSnapshotTime)));
8676
8730
  }
8677
8731
  if (data.MetricResults !== undefined && data.MetricResults !== null) {
8678
8732
  contents.MetricResults = deserializeAws_restJson1CurrentMetricResults(data.MetricResults, context);
@@ -8755,9 +8809,9 @@ var deserializeAws_restJson1GetCurrentMetricDataCommandError = function (output,
8755
8809
  });
8756
8810
  }); };
8757
8811
  export var deserializeAws_restJson1GetFederationTokenCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
8758
- var contents, data;
8759
- return __generator(this, function (_a) {
8760
- switch (_a.label) {
8812
+ var contents, data, _a, _b;
8813
+ return __generator(this, function (_c) {
8814
+ switch (_c.label) {
8761
8815
  case 0:
8762
8816
  if (output.statusCode !== 200 && output.statusCode >= 300) {
8763
8817
  return [2 /*return*/, deserializeAws_restJson1GetFederationTokenCommandError(output, context)];
@@ -8766,9 +8820,11 @@ export var deserializeAws_restJson1GetFederationTokenCommand = function (output,
8766
8820
  $metadata: deserializeMetadata(output),
8767
8821
  Credentials: undefined,
8768
8822
  };
8823
+ _a = __expectNonNull;
8824
+ _b = __expectObject;
8769
8825
  return [4 /*yield*/, parseBody(output.body, context)];
8770
8826
  case 1:
8771
- data = _a.sent();
8827
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
8772
8828
  if (data.Credentials !== undefined && data.Credentials !== null) {
8773
8829
  contents.Credentials = deserializeAws_restJson1Credentials(data.Credentials, context);
8774
8830
  }
@@ -8855,9 +8911,9 @@ var deserializeAws_restJson1GetFederationTokenCommandError = function (output, c
8855
8911
  });
8856
8912
  }); };
8857
8913
  export var deserializeAws_restJson1GetMetricDataCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
8858
- var contents, data;
8859
- return __generator(this, function (_a) {
8860
- switch (_a.label) {
8914
+ var contents, data, _a, _b;
8915
+ return __generator(this, function (_c) {
8916
+ switch (_c.label) {
8861
8917
  case 0:
8862
8918
  if (output.statusCode !== 200 && output.statusCode >= 300) {
8863
8919
  return [2 /*return*/, deserializeAws_restJson1GetMetricDataCommandError(output, context)];
@@ -8867,9 +8923,11 @@ export var deserializeAws_restJson1GetMetricDataCommand = function (output, cont
8867
8923
  MetricResults: undefined,
8868
8924
  NextToken: undefined,
8869
8925
  };
8926
+ _a = __expectNonNull;
8927
+ _b = __expectObject;
8870
8928
  return [4 /*yield*/, parseBody(output.body, context)];
8871
8929
  case 1:
8872
- data = _a.sent();
8930
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
8873
8931
  if (data.MetricResults !== undefined && data.MetricResults !== null) {
8874
8932
  contents.MetricResults = deserializeAws_restJson1HistoricalMetricResults(data.MetricResults, context);
8875
8933
  }
@@ -8951,9 +9009,9 @@ var deserializeAws_restJson1GetMetricDataCommandError = function (output, contex
8951
9009
  });
8952
9010
  }); };
8953
9011
  export var deserializeAws_restJson1ListAgentStatusesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
8954
- var contents, data;
8955
- return __generator(this, function (_a) {
8956
- switch (_a.label) {
9012
+ var contents, data, _a, _b;
9013
+ return __generator(this, function (_c) {
9014
+ switch (_c.label) {
8957
9015
  case 0:
8958
9016
  if (output.statusCode !== 200 && output.statusCode >= 300) {
8959
9017
  return [2 /*return*/, deserializeAws_restJson1ListAgentStatusesCommandError(output, context)];
@@ -8963,9 +9021,11 @@ export var deserializeAws_restJson1ListAgentStatusesCommand = function (output,
8963
9021
  AgentStatusSummaryList: undefined,
8964
9022
  NextToken: undefined,
8965
9023
  };
9024
+ _a = __expectNonNull;
9025
+ _b = __expectObject;
8966
9026
  return [4 /*yield*/, parseBody(output.body, context)];
8967
9027
  case 1:
8968
- data = _a.sent();
9028
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
8969
9029
  if (data.AgentStatusSummaryList !== undefined && data.AgentStatusSummaryList !== null) {
8970
9030
  contents.AgentStatusSummaryList = deserializeAws_restJson1AgentStatusSummaryList(data.AgentStatusSummaryList, context);
8971
9031
  }
@@ -9047,9 +9107,9 @@ var deserializeAws_restJson1ListAgentStatusesCommandError = function (output, co
9047
9107
  });
9048
9108
  }); };
9049
9109
  export var deserializeAws_restJson1ListApprovedOriginsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9050
- var contents, data;
9051
- return __generator(this, function (_a) {
9052
- switch (_a.label) {
9110
+ var contents, data, _a, _b;
9111
+ return __generator(this, function (_c) {
9112
+ switch (_c.label) {
9053
9113
  case 0:
9054
9114
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9055
9115
  return [2 /*return*/, deserializeAws_restJson1ListApprovedOriginsCommandError(output, context)];
@@ -9059,9 +9119,11 @@ export var deserializeAws_restJson1ListApprovedOriginsCommand = function (output
9059
9119
  NextToken: undefined,
9060
9120
  Origins: undefined,
9061
9121
  };
9122
+ _a = __expectNonNull;
9123
+ _b = __expectObject;
9062
9124
  return [4 /*yield*/, parseBody(output.body, context)];
9063
9125
  case 1:
9064
- data = _a.sent();
9126
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9065
9127
  if (data.NextToken !== undefined && data.NextToken !== null) {
9066
9128
  contents.NextToken = __expectString(data.NextToken);
9067
9129
  }
@@ -9143,9 +9205,9 @@ var deserializeAws_restJson1ListApprovedOriginsCommandError = function (output,
9143
9205
  });
9144
9206
  }); };
9145
9207
  export var deserializeAws_restJson1ListBotsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9146
- var contents, data;
9147
- return __generator(this, function (_a) {
9148
- switch (_a.label) {
9208
+ var contents, data, _a, _b;
9209
+ return __generator(this, function (_c) {
9210
+ switch (_c.label) {
9149
9211
  case 0:
9150
9212
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9151
9213
  return [2 /*return*/, deserializeAws_restJson1ListBotsCommandError(output, context)];
@@ -9155,9 +9217,11 @@ export var deserializeAws_restJson1ListBotsCommand = function (output, context)
9155
9217
  LexBots: undefined,
9156
9218
  NextToken: undefined,
9157
9219
  };
9220
+ _a = __expectNonNull;
9221
+ _b = __expectObject;
9158
9222
  return [4 /*yield*/, parseBody(output.body, context)];
9159
9223
  case 1:
9160
- data = _a.sent();
9224
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9161
9225
  if (data.LexBots !== undefined && data.LexBots !== null) {
9162
9226
  contents.LexBots = deserializeAws_restJson1LexBotConfigList(data.LexBots, context);
9163
9227
  }
@@ -9231,9 +9295,9 @@ var deserializeAws_restJson1ListBotsCommandError = function (output, context) {
9231
9295
  });
9232
9296
  }); };
9233
9297
  export var deserializeAws_restJson1ListContactFlowsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9234
- var contents, data;
9235
- return __generator(this, function (_a) {
9236
- switch (_a.label) {
9298
+ var contents, data, _a, _b;
9299
+ return __generator(this, function (_c) {
9300
+ switch (_c.label) {
9237
9301
  case 0:
9238
9302
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9239
9303
  return [2 /*return*/, deserializeAws_restJson1ListContactFlowsCommandError(output, context)];
@@ -9243,9 +9307,11 @@ export var deserializeAws_restJson1ListContactFlowsCommand = function (output, c
9243
9307
  ContactFlowSummaryList: undefined,
9244
9308
  NextToken: undefined,
9245
9309
  };
9310
+ _a = __expectNonNull;
9311
+ _b = __expectObject;
9246
9312
  return [4 /*yield*/, parseBody(output.body, context)];
9247
9313
  case 1:
9248
- data = _a.sent();
9314
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9249
9315
  if (data.ContactFlowSummaryList !== undefined && data.ContactFlowSummaryList !== null) {
9250
9316
  contents.ContactFlowSummaryList = deserializeAws_restJson1ContactFlowSummaryList(data.ContactFlowSummaryList, context);
9251
9317
  }
@@ -9327,9 +9393,9 @@ var deserializeAws_restJson1ListContactFlowsCommandError = function (output, con
9327
9393
  });
9328
9394
  }); };
9329
9395
  export var deserializeAws_restJson1ListHoursOfOperationsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9330
- var contents, data;
9331
- return __generator(this, function (_a) {
9332
- switch (_a.label) {
9396
+ var contents, data, _a, _b;
9397
+ return __generator(this, function (_c) {
9398
+ switch (_c.label) {
9333
9399
  case 0:
9334
9400
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9335
9401
  return [2 /*return*/, deserializeAws_restJson1ListHoursOfOperationsCommandError(output, context)];
@@ -9339,9 +9405,11 @@ export var deserializeAws_restJson1ListHoursOfOperationsCommand = function (outp
9339
9405
  HoursOfOperationSummaryList: undefined,
9340
9406
  NextToken: undefined,
9341
9407
  };
9408
+ _a = __expectNonNull;
9409
+ _b = __expectObject;
9342
9410
  return [4 /*yield*/, parseBody(output.body, context)];
9343
9411
  case 1:
9344
- data = _a.sent();
9412
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9345
9413
  if (data.HoursOfOperationSummaryList !== undefined && data.HoursOfOperationSummaryList !== null) {
9346
9414
  contents.HoursOfOperationSummaryList = deserializeAws_restJson1HoursOfOperationSummaryList(data.HoursOfOperationSummaryList, context);
9347
9415
  }
@@ -9423,9 +9491,9 @@ var deserializeAws_restJson1ListHoursOfOperationsCommandError = function (output
9423
9491
  });
9424
9492
  }); };
9425
9493
  export var deserializeAws_restJson1ListInstanceAttributesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9426
- var contents, data;
9427
- return __generator(this, function (_a) {
9428
- switch (_a.label) {
9494
+ var contents, data, _a, _b;
9495
+ return __generator(this, function (_c) {
9496
+ switch (_c.label) {
9429
9497
  case 0:
9430
9498
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9431
9499
  return [2 /*return*/, deserializeAws_restJson1ListInstanceAttributesCommandError(output, context)];
@@ -9435,9 +9503,11 @@ export var deserializeAws_restJson1ListInstanceAttributesCommand = function (out
9435
9503
  Attributes: undefined,
9436
9504
  NextToken: undefined,
9437
9505
  };
9506
+ _a = __expectNonNull;
9507
+ _b = __expectObject;
9438
9508
  return [4 /*yield*/, parseBody(output.body, context)];
9439
9509
  case 1:
9440
- data = _a.sent();
9510
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9441
9511
  if (data.Attributes !== undefined && data.Attributes !== null) {
9442
9512
  contents.Attributes = deserializeAws_restJson1AttributesList(data.Attributes, context);
9443
9513
  }
@@ -9519,9 +9589,9 @@ var deserializeAws_restJson1ListInstanceAttributesCommandError = function (outpu
9519
9589
  });
9520
9590
  }); };
9521
9591
  export var deserializeAws_restJson1ListInstancesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9522
- var contents, data;
9523
- return __generator(this, function (_a) {
9524
- switch (_a.label) {
9592
+ var contents, data, _a, _b;
9593
+ return __generator(this, function (_c) {
9594
+ switch (_c.label) {
9525
9595
  case 0:
9526
9596
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9527
9597
  return [2 /*return*/, deserializeAws_restJson1ListInstancesCommandError(output, context)];
@@ -9531,9 +9601,11 @@ export var deserializeAws_restJson1ListInstancesCommand = function (output, cont
9531
9601
  InstanceSummaryList: undefined,
9532
9602
  NextToken: undefined,
9533
9603
  };
9604
+ _a = __expectNonNull;
9605
+ _b = __expectObject;
9534
9606
  return [4 /*yield*/, parseBody(output.body, context)];
9535
9607
  case 1:
9536
- data = _a.sent();
9608
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9537
9609
  if (data.InstanceSummaryList !== undefined && data.InstanceSummaryList !== null) {
9538
9610
  contents.InstanceSummaryList = deserializeAws_restJson1InstanceSummaryList(data.InstanceSummaryList, context);
9539
9611
  }
@@ -9591,9 +9663,9 @@ var deserializeAws_restJson1ListInstancesCommandError = function (output, contex
9591
9663
  });
9592
9664
  }); };
9593
9665
  export var deserializeAws_restJson1ListInstanceStorageConfigsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9594
- var contents, data;
9595
- return __generator(this, function (_a) {
9596
- switch (_a.label) {
9666
+ var contents, data, _a, _b;
9667
+ return __generator(this, function (_c) {
9668
+ switch (_c.label) {
9597
9669
  case 0:
9598
9670
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9599
9671
  return [2 /*return*/, deserializeAws_restJson1ListInstanceStorageConfigsCommandError(output, context)];
@@ -9603,9 +9675,11 @@ export var deserializeAws_restJson1ListInstanceStorageConfigsCommand = function
9603
9675
  NextToken: undefined,
9604
9676
  StorageConfigs: undefined,
9605
9677
  };
9678
+ _a = __expectNonNull;
9679
+ _b = __expectObject;
9606
9680
  return [4 /*yield*/, parseBody(output.body, context)];
9607
9681
  case 1:
9608
- data = _a.sent();
9682
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9609
9683
  if (data.NextToken !== undefined && data.NextToken !== null) {
9610
9684
  contents.NextToken = __expectString(data.NextToken);
9611
9685
  }
@@ -9687,9 +9761,9 @@ var deserializeAws_restJson1ListInstanceStorageConfigsCommandError = function (o
9687
9761
  });
9688
9762
  }); };
9689
9763
  export var deserializeAws_restJson1ListIntegrationAssociationsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9690
- var contents, data;
9691
- return __generator(this, function (_a) {
9692
- switch (_a.label) {
9764
+ var contents, data, _a, _b;
9765
+ return __generator(this, function (_c) {
9766
+ switch (_c.label) {
9693
9767
  case 0:
9694
9768
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9695
9769
  return [2 /*return*/, deserializeAws_restJson1ListIntegrationAssociationsCommandError(output, context)];
@@ -9699,9 +9773,11 @@ export var deserializeAws_restJson1ListIntegrationAssociationsCommand = function
9699
9773
  IntegrationAssociationSummaryList: undefined,
9700
9774
  NextToken: undefined,
9701
9775
  };
9776
+ _a = __expectNonNull;
9777
+ _b = __expectObject;
9702
9778
  return [4 /*yield*/, parseBody(output.body, context)];
9703
9779
  case 1:
9704
- data = _a.sent();
9780
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9705
9781
  if (data.IntegrationAssociationSummaryList !== undefined && data.IntegrationAssociationSummaryList !== null) {
9706
9782
  contents.IntegrationAssociationSummaryList = deserializeAws_restJson1IntegrationAssociationSummaryList(data.IntegrationAssociationSummaryList, context);
9707
9783
  }
@@ -9775,9 +9851,9 @@ var deserializeAws_restJson1ListIntegrationAssociationsCommandError = function (
9775
9851
  });
9776
9852
  }); };
9777
9853
  export var deserializeAws_restJson1ListLambdaFunctionsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9778
- var contents, data;
9779
- return __generator(this, function (_a) {
9780
- switch (_a.label) {
9854
+ var contents, data, _a, _b;
9855
+ return __generator(this, function (_c) {
9856
+ switch (_c.label) {
9781
9857
  case 0:
9782
9858
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9783
9859
  return [2 /*return*/, deserializeAws_restJson1ListLambdaFunctionsCommandError(output, context)];
@@ -9787,9 +9863,11 @@ export var deserializeAws_restJson1ListLambdaFunctionsCommand = function (output
9787
9863
  LambdaFunctions: undefined,
9788
9864
  NextToken: undefined,
9789
9865
  };
9866
+ _a = __expectNonNull;
9867
+ _b = __expectObject;
9790
9868
  return [4 /*yield*/, parseBody(output.body, context)];
9791
9869
  case 1:
9792
- data = _a.sent();
9870
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9793
9871
  if (data.LambdaFunctions !== undefined && data.LambdaFunctions !== null) {
9794
9872
  contents.LambdaFunctions = deserializeAws_restJson1FunctionArnsList(data.LambdaFunctions, context);
9795
9873
  }
@@ -9871,9 +9949,9 @@ var deserializeAws_restJson1ListLambdaFunctionsCommandError = function (output,
9871
9949
  });
9872
9950
  }); };
9873
9951
  export var deserializeAws_restJson1ListLexBotsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9874
- var contents, data;
9875
- return __generator(this, function (_a) {
9876
- switch (_a.label) {
9952
+ var contents, data, _a, _b;
9953
+ return __generator(this, function (_c) {
9954
+ switch (_c.label) {
9877
9955
  case 0:
9878
9956
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9879
9957
  return [2 /*return*/, deserializeAws_restJson1ListLexBotsCommandError(output, context)];
@@ -9883,9 +9961,11 @@ export var deserializeAws_restJson1ListLexBotsCommand = function (output, contex
9883
9961
  LexBots: undefined,
9884
9962
  NextToken: undefined,
9885
9963
  };
9964
+ _a = __expectNonNull;
9965
+ _b = __expectObject;
9886
9966
  return [4 /*yield*/, parseBody(output.body, context)];
9887
9967
  case 1:
9888
- data = _a.sent();
9968
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9889
9969
  if (data.LexBots !== undefined && data.LexBots !== null) {
9890
9970
  contents.LexBots = deserializeAws_restJson1LexBotsList(data.LexBots, context);
9891
9971
  }
@@ -9967,9 +10047,9 @@ var deserializeAws_restJson1ListLexBotsCommandError = function (output, context)
9967
10047
  });
9968
10048
  }); };
9969
10049
  export var deserializeAws_restJson1ListPhoneNumbersCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
9970
- var contents, data;
9971
- return __generator(this, function (_a) {
9972
- switch (_a.label) {
10050
+ var contents, data, _a, _b;
10051
+ return __generator(this, function (_c) {
10052
+ switch (_c.label) {
9973
10053
  case 0:
9974
10054
  if (output.statusCode !== 200 && output.statusCode >= 300) {
9975
10055
  return [2 /*return*/, deserializeAws_restJson1ListPhoneNumbersCommandError(output, context)];
@@ -9979,9 +10059,11 @@ export var deserializeAws_restJson1ListPhoneNumbersCommand = function (output, c
9979
10059
  NextToken: undefined,
9980
10060
  PhoneNumberSummaryList: undefined,
9981
10061
  };
10062
+ _a = __expectNonNull;
10063
+ _b = __expectObject;
9982
10064
  return [4 /*yield*/, parseBody(output.body, context)];
9983
10065
  case 1:
9984
- data = _a.sent();
10066
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
9985
10067
  if (data.NextToken !== undefined && data.NextToken !== null) {
9986
10068
  contents.NextToken = __expectString(data.NextToken);
9987
10069
  }
@@ -10063,9 +10145,9 @@ var deserializeAws_restJson1ListPhoneNumbersCommandError = function (output, con
10063
10145
  });
10064
10146
  }); };
10065
10147
  export var deserializeAws_restJson1ListPromptsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10066
- var contents, data;
10067
- return __generator(this, function (_a) {
10068
- switch (_a.label) {
10148
+ var contents, data, _a, _b;
10149
+ return __generator(this, function (_c) {
10150
+ switch (_c.label) {
10069
10151
  case 0:
10070
10152
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10071
10153
  return [2 /*return*/, deserializeAws_restJson1ListPromptsCommandError(output, context)];
@@ -10075,9 +10157,11 @@ export var deserializeAws_restJson1ListPromptsCommand = function (output, contex
10075
10157
  NextToken: undefined,
10076
10158
  PromptSummaryList: undefined,
10077
10159
  };
10160
+ _a = __expectNonNull;
10161
+ _b = __expectObject;
10078
10162
  return [4 /*yield*/, parseBody(output.body, context)];
10079
10163
  case 1:
10080
- data = _a.sent();
10164
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10081
10165
  if (data.NextToken !== undefined && data.NextToken !== null) {
10082
10166
  contents.NextToken = __expectString(data.NextToken);
10083
10167
  }
@@ -10159,9 +10243,9 @@ var deserializeAws_restJson1ListPromptsCommandError = function (output, context)
10159
10243
  });
10160
10244
  }); };
10161
10245
  export var deserializeAws_restJson1ListQueueQuickConnectsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10162
- var contents, data;
10163
- return __generator(this, function (_a) {
10164
- switch (_a.label) {
10246
+ var contents, data, _a, _b;
10247
+ return __generator(this, function (_c) {
10248
+ switch (_c.label) {
10165
10249
  case 0:
10166
10250
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10167
10251
  return [2 /*return*/, deserializeAws_restJson1ListQueueQuickConnectsCommandError(output, context)];
@@ -10171,9 +10255,11 @@ export var deserializeAws_restJson1ListQueueQuickConnectsCommand = function (out
10171
10255
  NextToken: undefined,
10172
10256
  QuickConnectSummaryList: undefined,
10173
10257
  };
10258
+ _a = __expectNonNull;
10259
+ _b = __expectObject;
10174
10260
  return [4 /*yield*/, parseBody(output.body, context)];
10175
10261
  case 1:
10176
- data = _a.sent();
10262
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10177
10263
  if (data.NextToken !== undefined && data.NextToken !== null) {
10178
10264
  contents.NextToken = __expectString(data.NextToken);
10179
10265
  }
@@ -10255,9 +10341,9 @@ var deserializeAws_restJson1ListQueueQuickConnectsCommandError = function (outpu
10255
10341
  });
10256
10342
  }); };
10257
10343
  export var deserializeAws_restJson1ListQueuesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10258
- var contents, data;
10259
- return __generator(this, function (_a) {
10260
- switch (_a.label) {
10344
+ var contents, data, _a, _b;
10345
+ return __generator(this, function (_c) {
10346
+ switch (_c.label) {
10261
10347
  case 0:
10262
10348
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10263
10349
  return [2 /*return*/, deserializeAws_restJson1ListQueuesCommandError(output, context)];
@@ -10267,9 +10353,11 @@ export var deserializeAws_restJson1ListQueuesCommand = function (output, context
10267
10353
  NextToken: undefined,
10268
10354
  QueueSummaryList: undefined,
10269
10355
  };
10356
+ _a = __expectNonNull;
10357
+ _b = __expectObject;
10270
10358
  return [4 /*yield*/, parseBody(output.body, context)];
10271
10359
  case 1:
10272
- data = _a.sent();
10360
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10273
10361
  if (data.NextToken !== undefined && data.NextToken !== null) {
10274
10362
  contents.NextToken = __expectString(data.NextToken);
10275
10363
  }
@@ -10351,9 +10439,9 @@ var deserializeAws_restJson1ListQueuesCommandError = function (output, context)
10351
10439
  });
10352
10440
  }); };
10353
10441
  export var deserializeAws_restJson1ListQuickConnectsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10354
- var contents, data;
10355
- return __generator(this, function (_a) {
10356
- switch (_a.label) {
10442
+ var contents, data, _a, _b;
10443
+ return __generator(this, function (_c) {
10444
+ switch (_c.label) {
10357
10445
  case 0:
10358
10446
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10359
10447
  return [2 /*return*/, deserializeAws_restJson1ListQuickConnectsCommandError(output, context)];
@@ -10363,9 +10451,11 @@ export var deserializeAws_restJson1ListQuickConnectsCommand = function (output,
10363
10451
  NextToken: undefined,
10364
10452
  QuickConnectSummaryList: undefined,
10365
10453
  };
10454
+ _a = __expectNonNull;
10455
+ _b = __expectObject;
10366
10456
  return [4 /*yield*/, parseBody(output.body, context)];
10367
10457
  case 1:
10368
- data = _a.sent();
10458
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10369
10459
  if (data.NextToken !== undefined && data.NextToken !== null) {
10370
10460
  contents.NextToken = __expectString(data.NextToken);
10371
10461
  }
@@ -10447,9 +10537,9 @@ var deserializeAws_restJson1ListQuickConnectsCommandError = function (output, co
10447
10537
  });
10448
10538
  }); };
10449
10539
  export var deserializeAws_restJson1ListRoutingProfileQueuesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10450
- var contents, data;
10451
- return __generator(this, function (_a) {
10452
- switch (_a.label) {
10540
+ var contents, data, _a, _b;
10541
+ return __generator(this, function (_c) {
10542
+ switch (_c.label) {
10453
10543
  case 0:
10454
10544
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10455
10545
  return [2 /*return*/, deserializeAws_restJson1ListRoutingProfileQueuesCommandError(output, context)];
@@ -10459,9 +10549,11 @@ export var deserializeAws_restJson1ListRoutingProfileQueuesCommand = function (o
10459
10549
  NextToken: undefined,
10460
10550
  RoutingProfileQueueConfigSummaryList: undefined,
10461
10551
  };
10552
+ _a = __expectNonNull;
10553
+ _b = __expectObject;
10462
10554
  return [4 /*yield*/, parseBody(output.body, context)];
10463
10555
  case 1:
10464
- data = _a.sent();
10556
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10465
10557
  if (data.NextToken !== undefined && data.NextToken !== null) {
10466
10558
  contents.NextToken = __expectString(data.NextToken);
10467
10559
  }
@@ -10543,9 +10635,9 @@ var deserializeAws_restJson1ListRoutingProfileQueuesCommandError = function (out
10543
10635
  });
10544
10636
  }); };
10545
10637
  export var deserializeAws_restJson1ListRoutingProfilesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10546
- var contents, data;
10547
- return __generator(this, function (_a) {
10548
- switch (_a.label) {
10638
+ var contents, data, _a, _b;
10639
+ return __generator(this, function (_c) {
10640
+ switch (_c.label) {
10549
10641
  case 0:
10550
10642
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10551
10643
  return [2 /*return*/, deserializeAws_restJson1ListRoutingProfilesCommandError(output, context)];
@@ -10555,9 +10647,11 @@ export var deserializeAws_restJson1ListRoutingProfilesCommand = function (output
10555
10647
  NextToken: undefined,
10556
10648
  RoutingProfileSummaryList: undefined,
10557
10649
  };
10650
+ _a = __expectNonNull;
10651
+ _b = __expectObject;
10558
10652
  return [4 /*yield*/, parseBody(output.body, context)];
10559
10653
  case 1:
10560
- data = _a.sent();
10654
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10561
10655
  if (data.NextToken !== undefined && data.NextToken !== null) {
10562
10656
  contents.NextToken = __expectString(data.NextToken);
10563
10657
  }
@@ -10639,9 +10733,9 @@ var deserializeAws_restJson1ListRoutingProfilesCommandError = function (output,
10639
10733
  });
10640
10734
  }); };
10641
10735
  export var deserializeAws_restJson1ListSecurityKeysCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10642
- var contents, data;
10643
- return __generator(this, function (_a) {
10644
- switch (_a.label) {
10736
+ var contents, data, _a, _b;
10737
+ return __generator(this, function (_c) {
10738
+ switch (_c.label) {
10645
10739
  case 0:
10646
10740
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10647
10741
  return [2 /*return*/, deserializeAws_restJson1ListSecurityKeysCommandError(output, context)];
@@ -10651,9 +10745,11 @@ export var deserializeAws_restJson1ListSecurityKeysCommand = function (output, c
10651
10745
  NextToken: undefined,
10652
10746
  SecurityKeys: undefined,
10653
10747
  };
10748
+ _a = __expectNonNull;
10749
+ _b = __expectObject;
10654
10750
  return [4 /*yield*/, parseBody(output.body, context)];
10655
10751
  case 1:
10656
- data = _a.sent();
10752
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10657
10753
  if (data.NextToken !== undefined && data.NextToken !== null) {
10658
10754
  contents.NextToken = __expectString(data.NextToken);
10659
10755
  }
@@ -10735,9 +10831,9 @@ var deserializeAws_restJson1ListSecurityKeysCommandError = function (output, con
10735
10831
  });
10736
10832
  }); };
10737
10833
  export var deserializeAws_restJson1ListSecurityProfilesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10738
- var contents, data;
10739
- return __generator(this, function (_a) {
10740
- switch (_a.label) {
10834
+ var contents, data, _a, _b;
10835
+ return __generator(this, function (_c) {
10836
+ switch (_c.label) {
10741
10837
  case 0:
10742
10838
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10743
10839
  return [2 /*return*/, deserializeAws_restJson1ListSecurityProfilesCommandError(output, context)];
@@ -10747,9 +10843,11 @@ export var deserializeAws_restJson1ListSecurityProfilesCommand = function (outpu
10747
10843
  NextToken: undefined,
10748
10844
  SecurityProfileSummaryList: undefined,
10749
10845
  };
10846
+ _a = __expectNonNull;
10847
+ _b = __expectObject;
10750
10848
  return [4 /*yield*/, parseBody(output.body, context)];
10751
10849
  case 1:
10752
- data = _a.sent();
10850
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10753
10851
  if (data.NextToken !== undefined && data.NextToken !== null) {
10754
10852
  contents.NextToken = __expectString(data.NextToken);
10755
10853
  }
@@ -10831,9 +10929,9 @@ var deserializeAws_restJson1ListSecurityProfilesCommandError = function (output,
10831
10929
  });
10832
10930
  }); };
10833
10931
  export var deserializeAws_restJson1ListTagsForResourceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10834
- var contents, data;
10835
- return __generator(this, function (_a) {
10836
- switch (_a.label) {
10932
+ var contents, data, _a, _b;
10933
+ return __generator(this, function (_c) {
10934
+ switch (_c.label) {
10837
10935
  case 0:
10838
10936
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10839
10937
  return [2 /*return*/, deserializeAws_restJson1ListTagsForResourceCommandError(output, context)];
@@ -10842,9 +10940,11 @@ export var deserializeAws_restJson1ListTagsForResourceCommand = function (output
10842
10940
  $metadata: deserializeMetadata(output),
10843
10941
  tags: undefined,
10844
10942
  };
10943
+ _a = __expectNonNull;
10944
+ _b = __expectObject;
10845
10945
  return [4 /*yield*/, parseBody(output.body, context)];
10846
10946
  case 1:
10847
- data = _a.sent();
10947
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10848
10948
  if (data.tags !== undefined && data.tags !== null) {
10849
10949
  contents.tags = deserializeAws_restJson1TagMap(data.tags, context);
10850
10950
  }
@@ -10923,9 +11023,9 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
10923
11023
  });
10924
11024
  }); };
10925
11025
  export var deserializeAws_restJson1ListUseCasesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
10926
- var contents, data;
10927
- return __generator(this, function (_a) {
10928
- switch (_a.label) {
11026
+ var contents, data, _a, _b;
11027
+ return __generator(this, function (_c) {
11028
+ switch (_c.label) {
10929
11029
  case 0:
10930
11030
  if (output.statusCode !== 200 && output.statusCode >= 300) {
10931
11031
  return [2 /*return*/, deserializeAws_restJson1ListUseCasesCommandError(output, context)];
@@ -10935,9 +11035,11 @@ export var deserializeAws_restJson1ListUseCasesCommand = function (output, conte
10935
11035
  NextToken: undefined,
10936
11036
  UseCaseSummaryList: undefined,
10937
11037
  };
11038
+ _a = __expectNonNull;
11039
+ _b = __expectObject;
10938
11040
  return [4 /*yield*/, parseBody(output.body, context)];
10939
11041
  case 1:
10940
- data = _a.sent();
11042
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
10941
11043
  if (data.NextToken !== undefined && data.NextToken !== null) {
10942
11044
  contents.NextToken = __expectString(data.NextToken);
10943
11045
  }
@@ -11011,9 +11113,9 @@ var deserializeAws_restJson1ListUseCasesCommandError = function (output, context
11011
11113
  });
11012
11114
  }); };
11013
11115
  export var deserializeAws_restJson1ListUserHierarchyGroupsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
11014
- var contents, data;
11015
- return __generator(this, function (_a) {
11016
- switch (_a.label) {
11116
+ var contents, data, _a, _b;
11117
+ return __generator(this, function (_c) {
11118
+ switch (_c.label) {
11017
11119
  case 0:
11018
11120
  if (output.statusCode !== 200 && output.statusCode >= 300) {
11019
11121
  return [2 /*return*/, deserializeAws_restJson1ListUserHierarchyGroupsCommandError(output, context)];
@@ -11023,9 +11125,11 @@ export var deserializeAws_restJson1ListUserHierarchyGroupsCommand = function (ou
11023
11125
  NextToken: undefined,
11024
11126
  UserHierarchyGroupSummaryList: undefined,
11025
11127
  };
11128
+ _a = __expectNonNull;
11129
+ _b = __expectObject;
11026
11130
  return [4 /*yield*/, parseBody(output.body, context)];
11027
11131
  case 1:
11028
- data = _a.sent();
11132
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
11029
11133
  if (data.NextToken !== undefined && data.NextToken !== null) {
11030
11134
  contents.NextToken = __expectString(data.NextToken);
11031
11135
  }
@@ -11107,9 +11211,9 @@ var deserializeAws_restJson1ListUserHierarchyGroupsCommandError = function (outp
11107
11211
  });
11108
11212
  }); };
11109
11213
  export var deserializeAws_restJson1ListUsersCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
11110
- var contents, data;
11111
- return __generator(this, function (_a) {
11112
- switch (_a.label) {
11214
+ var contents, data, _a, _b;
11215
+ return __generator(this, function (_c) {
11216
+ switch (_c.label) {
11113
11217
  case 0:
11114
11218
  if (output.statusCode !== 200 && output.statusCode >= 300) {
11115
11219
  return [2 /*return*/, deserializeAws_restJson1ListUsersCommandError(output, context)];
@@ -11119,9 +11223,11 @@ export var deserializeAws_restJson1ListUsersCommand = function (output, context)
11119
11223
  NextToken: undefined,
11120
11224
  UserSummaryList: undefined,
11121
11225
  };
11226
+ _a = __expectNonNull;
11227
+ _b = __expectObject;
11122
11228
  return [4 /*yield*/, parseBody(output.body, context)];
11123
11229
  case 1:
11124
- data = _a.sent();
11230
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
11125
11231
  if (data.NextToken !== undefined && data.NextToken !== null) {
11126
11232
  contents.NextToken = __expectString(data.NextToken);
11127
11233
  }
@@ -11275,9 +11381,9 @@ var deserializeAws_restJson1ResumeContactRecordingCommandError = function (outpu
11275
11381
  });
11276
11382
  }); };
11277
11383
  export var deserializeAws_restJson1StartChatContactCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
11278
- var contents, data;
11279
- return __generator(this, function (_a) {
11280
- switch (_a.label) {
11384
+ var contents, data, _a, _b;
11385
+ return __generator(this, function (_c) {
11386
+ switch (_c.label) {
11281
11387
  case 0:
11282
11388
  if (output.statusCode !== 200 && output.statusCode >= 300) {
11283
11389
  return [2 /*return*/, deserializeAws_restJson1StartChatContactCommandError(output, context)];
@@ -11288,9 +11394,11 @@ export var deserializeAws_restJson1StartChatContactCommand = function (output, c
11288
11394
  ParticipantId: undefined,
11289
11395
  ParticipantToken: undefined,
11290
11396
  };
11397
+ _a = __expectNonNull;
11398
+ _b = __expectObject;
11291
11399
  return [4 /*yield*/, parseBody(output.body, context)];
11292
11400
  case 1:
11293
- data = _a.sent();
11401
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
11294
11402
  if (data.ContactId !== undefined && data.ContactId !== null) {
11295
11403
  contents.ContactId = __expectString(data.ContactId);
11296
11404
  }
@@ -11455,9 +11563,9 @@ var deserializeAws_restJson1StartContactRecordingCommandError = function (output
11455
11563
  });
11456
11564
  }); };
11457
11565
  export var deserializeAws_restJson1StartOutboundVoiceContactCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
11458
- var contents, data;
11459
- return __generator(this, function (_a) {
11460
- switch (_a.label) {
11566
+ var contents, data, _a, _b;
11567
+ return __generator(this, function (_c) {
11568
+ switch (_c.label) {
11461
11569
  case 0:
11462
11570
  if (output.statusCode !== 200 && output.statusCode >= 300) {
11463
11571
  return [2 /*return*/, deserializeAws_restJson1StartOutboundVoiceContactCommandError(output, context)];
@@ -11466,9 +11574,11 @@ export var deserializeAws_restJson1StartOutboundVoiceContactCommand = function (
11466
11574
  $metadata: deserializeMetadata(output),
11467
11575
  ContactId: undefined,
11468
11576
  };
11577
+ _a = __expectNonNull;
11578
+ _b = __expectObject;
11469
11579
  return [4 /*yield*/, parseBody(output.body, context)];
11470
11580
  case 1:
11471
- data = _a.sent();
11581
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
11472
11582
  if (data.ContactId !== undefined && data.ContactId !== null) {
11473
11583
  contents.ContactId = __expectString(data.ContactId);
11474
11584
  }
@@ -11563,9 +11673,9 @@ var deserializeAws_restJson1StartOutboundVoiceContactCommandError = function (ou
11563
11673
  });
11564
11674
  }); };
11565
11675
  export var deserializeAws_restJson1StartTaskContactCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
11566
- var contents, data;
11567
- return __generator(this, function (_a) {
11568
- switch (_a.label) {
11676
+ var contents, data, _a, _b;
11677
+ return __generator(this, function (_c) {
11678
+ switch (_c.label) {
11569
11679
  case 0:
11570
11680
  if (output.statusCode !== 200 && output.statusCode >= 300) {
11571
11681
  return [2 /*return*/, deserializeAws_restJson1StartTaskContactCommandError(output, context)];
@@ -11574,9 +11684,11 @@ export var deserializeAws_restJson1StartTaskContactCommand = function (output, c
11574
11684
  $metadata: deserializeMetadata(output),
11575
11685
  ContactId: undefined,
11576
11686
  };
11687
+ _a = __expectNonNull;
11688
+ _b = __expectObject;
11577
11689
  return [4 /*yield*/, parseBody(output.body, context)];
11578
11690
  case 1:
11579
- data = _a.sent();
11691
+ data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
11580
11692
  if (data.ContactId !== undefined && data.ContactId !== null) {
11581
11693
  contents.ContactId = __expectString(data.ContactId);
11582
11694
  }
@@ -14885,7 +14997,7 @@ var deserializeAws_restJson1AgentStatus = function (output, context) {
14885
14997
  AgentStatusARN: __expectString(output.AgentStatusARN),
14886
14998
  AgentStatusId: __expectString(output.AgentStatusId),
14887
14999
  Description: __expectString(output.Description),
14888
- DisplayOrder: __expectInt(output.DisplayOrder),
15000
+ DisplayOrder: __expectInt32(output.DisplayOrder),
14889
15001
  Name: __expectString(output.Name),
14890
15002
  State: __expectString(output.State),
14891
15003
  Tags: output.Tags !== undefined && output.Tags !== null
@@ -14973,11 +15085,11 @@ var deserializeAws_restJson1Credentials = function (output, context) {
14973
15085
  return {
14974
15086
  AccessToken: __expectString(output.AccessToken),
14975
15087
  AccessTokenExpiration: output.AccessTokenExpiration !== undefined && output.AccessTokenExpiration !== null
14976
- ? new Date(Math.round(output.AccessTokenExpiration * 1000))
15088
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.AccessTokenExpiration)))
14977
15089
  : undefined,
14978
15090
  RefreshToken: __expectString(output.RefreshToken),
14979
15091
  RefreshTokenExpiration: output.RefreshTokenExpiration !== undefined && output.RefreshTokenExpiration !== null
14980
- ? new Date(Math.round(output.RefreshTokenExpiration * 1000))
15092
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.RefreshTokenExpiration)))
14981
15093
  : undefined,
14982
15094
  };
14983
15095
  };
@@ -14992,7 +15104,7 @@ var deserializeAws_restJson1CurrentMetricData = function (output, context) {
14992
15104
  Metric: output.Metric !== undefined && output.Metric !== null
14993
15105
  ? deserializeAws_restJson1CurrentMetric(output.Metric, context)
14994
15106
  : undefined,
14995
- Value: __limitedParseFloat(output.Value),
15107
+ Value: __limitedParseDouble(output.Value),
14996
15108
  };
14997
15109
  };
14998
15110
  var deserializeAws_restJson1CurrentMetricDataCollections = function (output, context) {
@@ -15137,7 +15249,7 @@ var deserializeAws_restJson1HistoricalMetricData = function (output, context) {
15137
15249
  Metric: output.Metric !== undefined && output.Metric !== null
15138
15250
  ? deserializeAws_restJson1HistoricalMetric(output.Metric, context)
15139
15251
  : undefined,
15140
- Value: __limitedParseFloat(output.Value),
15252
+ Value: __limitedParseDouble(output.Value),
15141
15253
  };
15142
15254
  };
15143
15255
  var deserializeAws_restJson1HistoricalMetricDataCollections = function (output, context) {
@@ -15225,15 +15337,15 @@ var deserializeAws_restJson1HoursOfOperationSummaryList = function (output, cont
15225
15337
  };
15226
15338
  var deserializeAws_restJson1HoursOfOperationTimeSlice = function (output, context) {
15227
15339
  return {
15228
- Hours: __expectInt(output.Hours),
15229
- Minutes: __expectInt(output.Minutes),
15340
+ Hours: __expectInt32(output.Hours),
15341
+ Minutes: __expectInt32(output.Minutes),
15230
15342
  };
15231
15343
  };
15232
15344
  var deserializeAws_restJson1Instance = function (output, context) {
15233
15345
  return {
15234
15346
  Arn: __expectString(output.Arn),
15235
15347
  CreatedTime: output.CreatedTime !== undefined && output.CreatedTime !== null
15236
- ? new Date(Math.round(output.CreatedTime * 1000))
15348
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedTime)))
15237
15349
  : undefined,
15238
15350
  Id: __expectString(output.Id),
15239
15351
  IdentityManagementType: __expectString(output.IdentityManagementType),
@@ -15284,7 +15396,7 @@ var deserializeAws_restJson1InstanceSummary = function (output, context) {
15284
15396
  return {
15285
15397
  Arn: __expectString(output.Arn),
15286
15398
  CreatedTime: output.CreatedTime !== undefined && output.CreatedTime !== null
15287
- ? new Date(Math.round(output.CreatedTime * 1000))
15399
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedTime)))
15288
15400
  : undefined,
15289
15401
  Id: __expectString(output.Id),
15290
15402
  IdentityManagementType: __expectString(output.IdentityManagementType),
@@ -15343,7 +15455,7 @@ var deserializeAws_restJson1KinesisVideoStreamConfig = function (output, context
15343
15455
  ? deserializeAws_restJson1EncryptionConfig(output.EncryptionConfig, context)
15344
15456
  : undefined,
15345
15457
  Prefix: __expectString(output.Prefix),
15346
- RetentionPeriodHours: __expectInt(output.RetentionPeriodHours),
15458
+ RetentionPeriodHours: __expectInt32(output.RetentionPeriodHours),
15347
15459
  };
15348
15460
  };
15349
15461
  var deserializeAws_restJson1LexBot = function (output, context) {
@@ -15400,7 +15512,7 @@ var deserializeAws_restJson1MediaConcurrencies = function (output, context) {
15400
15512
  var deserializeAws_restJson1MediaConcurrency = function (output, context) {
15401
15513
  return {
15402
15514
  Channel: __expectString(output.Channel),
15403
- Concurrency: __expectInt(output.Concurrency),
15515
+ Concurrency: __expectInt32(output.Concurrency),
15404
15516
  };
15405
15517
  };
15406
15518
  var deserializeAws_restJson1OriginsList = function (output, context) {
@@ -15480,7 +15592,7 @@ var deserializeAws_restJson1Queue = function (output, context) {
15480
15592
  return {
15481
15593
  Description: __expectString(output.Description),
15482
15594
  HoursOfOperationId: __expectString(output.HoursOfOperationId),
15483
- MaxContacts: __expectInt(output.MaxContacts),
15595
+ MaxContacts: __expectInt32(output.MaxContacts),
15484
15596
  Name: __expectString(output.Name),
15485
15597
  OutboundCallerConfig: output.OutboundCallerConfig !== undefined && output.OutboundCallerConfig !== null
15486
15598
  ? deserializeAws_restJson1OutboundCallerConfig(output.OutboundCallerConfig, context)
@@ -15588,8 +15700,8 @@ var deserializeAws_restJson1RoutingProfile = function (output, context) {
15588
15700
  var deserializeAws_restJson1RoutingProfileQueueConfigSummary = function (output, context) {
15589
15701
  return {
15590
15702
  Channel: __expectString(output.Channel),
15591
- Delay: __expectInt(output.Delay),
15592
- Priority: __expectInt(output.Priority),
15703
+ Delay: __expectInt32(output.Delay),
15704
+ Priority: __expectInt32(output.Priority),
15593
15705
  QueueArn: __expectString(output.QueueArn),
15594
15706
  QueueId: __expectString(output.QueueId),
15595
15707
  QueueName: __expectString(output.QueueName),
@@ -15635,7 +15747,7 @@ var deserializeAws_restJson1SecurityKey = function (output, context) {
15635
15747
  return {
15636
15748
  AssociationId: __expectString(output.AssociationId),
15637
15749
  CreationTime: output.CreationTime !== undefined && output.CreationTime !== null
15638
- ? new Date(Math.round(output.CreationTime * 1000))
15750
+ ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreationTime)))
15639
15751
  : undefined,
15640
15752
  Key: __expectString(output.Key),
15641
15753
  };
@@ -15690,7 +15802,7 @@ var deserializeAws_restJson1TagMap = function (output, context) {
15690
15802
  var deserializeAws_restJson1Threshold = function (output, context) {
15691
15803
  return {
15692
15804
  Comparison: __expectString(output.Comparison),
15693
- ThresholdValue: __limitedParseFloat(output.ThresholdValue),
15805
+ ThresholdValue: __limitedParseDouble(output.ThresholdValue),
15694
15806
  };
15695
15807
  };
15696
15808
  var deserializeAws_restJson1UseCase = function (output, context) {
@@ -15741,7 +15853,7 @@ var deserializeAws_restJson1UserIdentityInfo = function (output, context) {
15741
15853
  };
15742
15854
  var deserializeAws_restJson1UserPhoneConfig = function (output, context) {
15743
15855
  return {
15744
- AfterContactWorkTimeLimit: __expectInt(output.AfterContactWorkTimeLimit),
15856
+ AfterContactWorkTimeLimit: __expectInt32(output.AfterContactWorkTimeLimit),
15745
15857
  AutoAccept: __expectBoolean(output.AutoAccept),
15746
15858
  DeskPhoneNumber: __expectString(output.DeskPhoneNumber),
15747
15859
  PhoneType: __expectString(output.PhoneType),