@aws-sdk/client-direct-connect 3.37.0 → 3.41.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.
Files changed (112) hide show
  1. package/CHANGELOG.md +43 -0
  2. package/README.md +2 -2
  3. package/dist-cjs/DirectConnect.js +60 -0
  4. package/dist-cjs/commands/ConfirmCustomerAgreementCommand.js +36 -0
  5. package/dist-cjs/commands/DescribeCustomerMetadataCommand.js +36 -0
  6. package/dist-cjs/commands/DescribeRouterConfigurationCommand.js +36 -0
  7. package/dist-cjs/commands/UpdateDirectConnectGatewayCommand.js +36 -0
  8. package/dist-cjs/commands/index.js +66 -0
  9. package/dist-cjs/endpoints.js +137 -21
  10. package/dist-cjs/index.js +3 -61
  11. package/dist-cjs/models/models_0.js +63 -3
  12. package/dist-cjs/protocols/Aws_json1_1.js +339 -3
  13. package/dist-cjs/runtimeConfig.browser.js +6 -3
  14. package/dist-cjs/runtimeConfig.js +5 -3
  15. package/dist-es/DirectConnect.js +60 -0
  16. package/dist-es/commands/ConfirmCustomerAgreementCommand.js +39 -0
  17. package/dist-es/commands/DescribeCustomerMetadataCommand.js +39 -0
  18. package/dist-es/commands/DescribeRouterConfigurationCommand.js +39 -0
  19. package/dist-es/commands/UpdateDirectConnectGatewayCommand.js +39 -0
  20. package/dist-es/commands/index.js +63 -0
  21. package/dist-es/endpoints.js +137 -21
  22. package/dist-es/index.js +3 -61
  23. package/dist-es/models/models_0.js +42 -0
  24. package/dist-es/protocols/Aws_json1_1.js +369 -0
  25. package/dist-es/runtimeConfig.browser.js +3 -2
  26. package/dist-es/runtimeConfig.js +3 -3
  27. package/dist-types/DirectConnect.d.ts +51 -19
  28. package/dist-types/DirectConnectClient.d.ts +16 -4
  29. package/dist-types/commands/AcceptDirectConnectGatewayAssociationProposalCommand.d.ts +1 -1
  30. package/dist-types/commands/AllocateConnectionOnInterconnectCommand.d.ts +1 -1
  31. package/dist-types/commands/AllocateHostedConnectionCommand.d.ts +1 -1
  32. package/dist-types/commands/AllocatePrivateVirtualInterfaceCommand.d.ts +2 -2
  33. package/dist-types/commands/AllocatePublicVirtualInterfaceCommand.d.ts +3 -3
  34. package/dist-types/commands/AllocateTransitVirtualInterfaceCommand.d.ts +3 -3
  35. package/dist-types/commands/AssociateConnectionWithLagCommand.d.ts +1 -1
  36. package/dist-types/commands/AssociateHostedConnectionCommand.d.ts +1 -1
  37. package/dist-types/commands/AssociateMacSecKeyCommand.d.ts +1 -1
  38. package/dist-types/commands/AssociateVirtualInterfaceCommand.d.ts +1 -1
  39. package/dist-types/commands/ConfirmConnectionCommand.d.ts +1 -1
  40. package/dist-types/commands/ConfirmCustomerAgreementCommand.d.ts +37 -0
  41. package/dist-types/commands/ConfirmPrivateVirtualInterfaceCommand.d.ts +2 -2
  42. package/dist-types/commands/ConfirmPublicVirtualInterfaceCommand.d.ts +2 -2
  43. package/dist-types/commands/ConfirmTransitVirtualInterfaceCommand.d.ts +2 -2
  44. package/dist-types/commands/CreateBGPPeerCommand.d.ts +1 -1
  45. package/dist-types/commands/CreateConnectionCommand.d.ts +1 -1
  46. package/dist-types/commands/CreateDirectConnectGatewayAssociationCommand.d.ts +1 -1
  47. package/dist-types/commands/CreateDirectConnectGatewayAssociationProposalCommand.d.ts +2 -2
  48. package/dist-types/commands/CreateDirectConnectGatewayCommand.d.ts +3 -3
  49. package/dist-types/commands/CreateInterconnectCommand.d.ts +1 -1
  50. package/dist-types/commands/CreateLagCommand.d.ts +2 -2
  51. package/dist-types/commands/CreatePrivateVirtualInterfaceCommand.d.ts +2 -2
  52. package/dist-types/commands/CreatePublicVirtualInterfaceCommand.d.ts +1 -1
  53. package/dist-types/commands/CreateTransitVirtualInterfaceCommand.d.ts +1 -1
  54. package/dist-types/commands/DeleteBGPPeerCommand.d.ts +1 -1
  55. package/dist-types/commands/DeleteConnectionCommand.d.ts +1 -1
  56. package/dist-types/commands/DeleteDirectConnectGatewayAssociationCommand.d.ts +1 -1
  57. package/dist-types/commands/DeleteDirectConnectGatewayAssociationProposalCommand.d.ts +1 -1
  58. package/dist-types/commands/DeleteDirectConnectGatewayCommand.d.ts +1 -1
  59. package/dist-types/commands/DeleteInterconnectCommand.d.ts +1 -1
  60. package/dist-types/commands/DeleteLagCommand.d.ts +1 -1
  61. package/dist-types/commands/DeleteVirtualInterfaceCommand.d.ts +1 -1
  62. package/dist-types/commands/DescribeConnectionLoaCommand.d.ts +1 -1
  63. package/dist-types/commands/DescribeConnectionsCommand.d.ts +1 -1
  64. package/dist-types/commands/DescribeConnectionsOnInterconnectCommand.d.ts +1 -1
  65. package/dist-types/commands/DescribeCustomerMetadataCommand.d.ts +35 -0
  66. package/dist-types/commands/DescribeDirectConnectGatewayAssociationProposalsCommand.d.ts +1 -1
  67. package/dist-types/commands/DescribeDirectConnectGatewayAssociationsCommand.d.ts +1 -1
  68. package/dist-types/commands/DescribeDirectConnectGatewayAttachmentsCommand.d.ts +1 -1
  69. package/dist-types/commands/DescribeDirectConnectGatewaysCommand.d.ts +1 -1
  70. package/dist-types/commands/DescribeHostedConnectionsCommand.d.ts +1 -1
  71. package/dist-types/commands/DescribeInterconnectLoaCommand.d.ts +1 -1
  72. package/dist-types/commands/DescribeInterconnectsCommand.d.ts +2 -2
  73. package/dist-types/commands/DescribeLagsCommand.d.ts +1 -1
  74. package/dist-types/commands/DescribeLoaCommand.d.ts +1 -1
  75. package/dist-types/commands/DescribeLocationsCommand.d.ts +2 -2
  76. package/dist-types/commands/DescribeRouterConfigurationCommand.d.ts +37 -0
  77. package/dist-types/commands/DescribeTagsCommand.d.ts +1 -1
  78. package/dist-types/commands/DescribeVirtualGatewaysCommand.d.ts +2 -2
  79. package/dist-types/commands/DescribeVirtualInterfacesCommand.d.ts +2 -2
  80. package/dist-types/commands/DisassociateConnectionFromLagCommand.d.ts +1 -1
  81. package/dist-types/commands/DisassociateMacSecKeyCommand.d.ts +1 -1
  82. package/dist-types/commands/ListVirtualInterfaceTestHistoryCommand.d.ts +1 -1
  83. package/dist-types/commands/StartBgpFailoverTestCommand.d.ts +1 -1
  84. package/dist-types/commands/StopBgpFailoverTestCommand.d.ts +1 -1
  85. package/dist-types/commands/TagResourceCommand.d.ts +1 -1
  86. package/dist-types/commands/UntagResourceCommand.d.ts +1 -1
  87. package/dist-types/commands/UpdateConnectionCommand.d.ts +1 -1
  88. package/dist-types/commands/UpdateDirectConnectGatewayAssociationCommand.d.ts +1 -1
  89. package/dist-types/commands/UpdateDirectConnectGatewayCommand.d.ts +35 -0
  90. package/dist-types/commands/UpdateLagCommand.d.ts +1 -1
  91. package/dist-types/commands/UpdateVirtualInterfaceAttributesCommand.d.ts +1 -1
  92. package/dist-types/commands/index.d.ts +63 -0
  93. package/dist-types/index.d.ts +3 -61
  94. package/dist-types/models/models_0.d.ts +209 -23
  95. package/dist-types/protocols/Aws_json1_1.d.ts +12 -0
  96. package/dist-types/runtimeConfig.browser.d.ts +2 -0
  97. package/dist-types/runtimeConfig.d.ts +2 -0
  98. package/dist-types/runtimeConfig.native.d.ts +2 -0
  99. package/dist-types/ts3.4/DirectConnect.d.ts +20 -0
  100. package/dist-types/ts3.4/DirectConnectClient.d.ts +10 -2
  101. package/dist-types/ts3.4/commands/ConfirmCustomerAgreementCommand.d.ts +17 -0
  102. package/dist-types/ts3.4/commands/DescribeCustomerMetadataCommand.d.ts +17 -0
  103. package/dist-types/ts3.4/commands/DescribeRouterConfigurationCommand.d.ts +17 -0
  104. package/dist-types/ts3.4/commands/UpdateDirectConnectGatewayCommand.d.ts +17 -0
  105. package/dist-types/ts3.4/commands/index.d.ts +63 -0
  106. package/dist-types/ts3.4/index.d.ts +3 -61
  107. package/dist-types/ts3.4/models/models_0.d.ts +104 -0
  108. package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +12 -0
  109. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +2 -0
  110. package/dist-types/ts3.4/runtimeConfig.d.ts +2 -0
  111. package/dist-types/ts3.4/runtimeConfig.native.d.ts +2 -0
  112. package/package.json +26 -26
@@ -37,6 +37,10 @@ export var AddressFamily;
37
37
  AddressFamily["IPv4"] = "ipv4";
38
38
  AddressFamily["IPv6"] = "ipv6";
39
39
  })(AddressFamily || (AddressFamily = {}));
40
+ export var CustomerAgreement;
41
+ (function (CustomerAgreement) {
42
+ CustomerAgreement.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
43
+ })(CustomerAgreement || (CustomerAgreement = {}));
40
44
  export var AllocateConnectionOnInterconnectRequest;
41
45
  (function (AllocateConnectionOnInterconnectRequest) {
42
46
  AllocateConnectionOnInterconnectRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -149,6 +153,14 @@ export var ConfirmConnectionResponse;
149
153
  (function (ConfirmConnectionResponse) {
150
154
  ConfirmConnectionResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
151
155
  })(ConfirmConnectionResponse || (ConfirmConnectionResponse = {}));
156
+ export var ConfirmCustomerAgreementRequest;
157
+ (function (ConfirmCustomerAgreementRequest) {
158
+ ConfirmCustomerAgreementRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
159
+ })(ConfirmCustomerAgreementRequest || (ConfirmCustomerAgreementRequest = {}));
160
+ export var ConfirmCustomerAgreementResponse;
161
+ (function (ConfirmCustomerAgreementResponse) {
162
+ ConfirmCustomerAgreementResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
163
+ })(ConfirmCustomerAgreementResponse || (ConfirmCustomerAgreementResponse = {}));
152
164
  export var ConfirmPrivateVirtualInterfaceRequest;
153
165
  (function (ConfirmPrivateVirtualInterfaceRequest) {
154
166
  ConfirmPrivateVirtualInterfaceRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -349,6 +361,16 @@ export var DescribeConnectionsOnInterconnectRequest;
349
361
  (function (DescribeConnectionsOnInterconnectRequest) {
350
362
  DescribeConnectionsOnInterconnectRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
351
363
  })(DescribeConnectionsOnInterconnectRequest || (DescribeConnectionsOnInterconnectRequest = {}));
364
+ export var NniPartnerType;
365
+ (function (NniPartnerType) {
366
+ NniPartnerType["NonPartner"] = "nonPartner";
367
+ NniPartnerType["V1"] = "v1";
368
+ NniPartnerType["V2"] = "v2";
369
+ })(NniPartnerType || (NniPartnerType = {}));
370
+ export var DescribeCustomerMetadataResponse;
371
+ (function (DescribeCustomerMetadataResponse) {
372
+ DescribeCustomerMetadataResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
373
+ })(DescribeCustomerMetadataResponse || (DescribeCustomerMetadataResponse = {}));
352
374
  export var DescribeDirectConnectGatewayAssociationProposalsRequest;
353
375
  (function (DescribeDirectConnectGatewayAssociationProposalsRequest) {
354
376
  DescribeDirectConnectGatewayAssociationProposalsRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -425,6 +447,18 @@ export var Locations;
425
447
  (function (Locations) {
426
448
  Locations.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
427
449
  })(Locations || (Locations = {}));
450
+ export var DescribeRouterConfigurationRequest;
451
+ (function (DescribeRouterConfigurationRequest) {
452
+ DescribeRouterConfigurationRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
453
+ })(DescribeRouterConfigurationRequest || (DescribeRouterConfigurationRequest = {}));
454
+ export var RouterType;
455
+ (function (RouterType) {
456
+ RouterType.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
457
+ })(RouterType || (RouterType = {}));
458
+ export var DescribeRouterConfigurationResponse;
459
+ (function (DescribeRouterConfigurationResponse) {
460
+ DescribeRouterConfigurationResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
461
+ })(DescribeRouterConfigurationResponse || (DescribeRouterConfigurationResponse = {}));
428
462
  export var DescribeTagsRequest;
429
463
  (function (DescribeTagsRequest) {
430
464
  DescribeTagsRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -513,6 +547,14 @@ export var UpdateConnectionRequest;
513
547
  (function (UpdateConnectionRequest) {
514
548
  UpdateConnectionRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
515
549
  })(UpdateConnectionRequest || (UpdateConnectionRequest = {}));
550
+ export var UpdateDirectConnectGatewayRequest;
551
+ (function (UpdateDirectConnectGatewayRequest) {
552
+ UpdateDirectConnectGatewayRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
553
+ })(UpdateDirectConnectGatewayRequest || (UpdateDirectConnectGatewayRequest = {}));
554
+ export var UpdateDirectConnectGatewayResponse;
555
+ (function (UpdateDirectConnectGatewayResponse) {
556
+ UpdateDirectConnectGatewayResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
557
+ })(UpdateDirectConnectGatewayResponse || (UpdateDirectConnectGatewayResponse = {}));
516
558
  export var UpdateDirectConnectGatewayAssociationRequest;
517
559
  (function (UpdateDirectConnectGatewayAssociationRequest) {
518
560
  UpdateDirectConnectGatewayAssociationRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -122,6 +122,17 @@ export var serializeAws_json1_1ConfirmConnectionCommand = function (input, conte
122
122
  return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
123
123
  });
124
124
  }); };
125
+ export var serializeAws_json1_1ConfirmCustomerAgreementCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
126
+ var headers, body;
127
+ return __generator(this, function (_a) {
128
+ headers = {
129
+ "content-type": "application/x-amz-json-1.1",
130
+ "x-amz-target": "OvertureService.ConfirmCustomerAgreement",
131
+ };
132
+ body = JSON.stringify(serializeAws_json1_1ConfirmCustomerAgreementRequest(input, context));
133
+ return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
134
+ });
135
+ }); };
125
136
  export var serializeAws_json1_1ConfirmPrivateVirtualInterfaceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
126
137
  var headers, body;
127
138
  return __generator(this, function (_a) {
@@ -386,6 +397,17 @@ export var serializeAws_json1_1DescribeConnectionsOnInterconnectCommand = functi
386
397
  return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
387
398
  });
388
399
  }); };
400
+ export var serializeAws_json1_1DescribeCustomerMetadataCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
401
+ var headers, body;
402
+ return __generator(this, function (_a) {
403
+ headers = {
404
+ "content-type": "application/x-amz-json-1.1",
405
+ "x-amz-target": "OvertureService.DescribeCustomerMetadata",
406
+ };
407
+ body = "{}";
408
+ return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
409
+ });
410
+ }); };
389
411
  export var serializeAws_json1_1DescribeDirectConnectGatewayAssociationProposalsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
390
412
  var headers, body;
391
413
  return __generator(this, function (_a) {
@@ -496,6 +518,17 @@ export var serializeAws_json1_1DescribeLocationsCommand = function (input, conte
496
518
  return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
497
519
  });
498
520
  }); };
521
+ export var serializeAws_json1_1DescribeRouterConfigurationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
522
+ var headers, body;
523
+ return __generator(this, function (_a) {
524
+ headers = {
525
+ "content-type": "application/x-amz-json-1.1",
526
+ "x-amz-target": "OvertureService.DescribeRouterConfiguration",
527
+ };
528
+ body = JSON.stringify(serializeAws_json1_1DescribeRouterConfigurationRequest(input, context));
529
+ return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
530
+ });
531
+ }); };
499
532
  export var serializeAws_json1_1DescribeTagsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
500
533
  var headers, body;
501
534
  return __generator(this, function (_a) {
@@ -617,6 +650,17 @@ export var serializeAws_json1_1UpdateConnectionCommand = function (input, contex
617
650
  return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
618
651
  });
619
652
  }); };
653
+ export var serializeAws_json1_1UpdateDirectConnectGatewayCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
654
+ var headers, body;
655
+ return __generator(this, function (_a) {
656
+ headers = {
657
+ "content-type": "application/x-amz-json-1.1",
658
+ "x-amz-target": "OvertureService.UpdateDirectConnectGateway",
659
+ };
660
+ body = JSON.stringify(serializeAws_json1_1UpdateDirectConnectGatewayRequest(input, context));
661
+ return [2, buildHttpRpcRequest(context, headers, "/", undefined, body)];
662
+ });
663
+ }); };
620
664
  export var serializeAws_json1_1UpdateDirectConnectGatewayAssociationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
621
665
  var headers, body;
622
666
  return __generator(this, function (_a) {
@@ -1418,6 +1462,70 @@ var deserializeAws_json1_1ConfirmConnectionCommandError = function (output, cont
1418
1462
  }
1419
1463
  });
1420
1464
  }); };
1465
+ export var deserializeAws_json1_1ConfirmCustomerAgreementCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1466
+ var data, contents, response;
1467
+ return __generator(this, function (_a) {
1468
+ switch (_a.label) {
1469
+ case 0:
1470
+ if (output.statusCode >= 300) {
1471
+ return [2, deserializeAws_json1_1ConfirmCustomerAgreementCommandError(output, context)];
1472
+ }
1473
+ return [4, parseBody(output.body, context)];
1474
+ case 1:
1475
+ data = _a.sent();
1476
+ contents = {};
1477
+ contents = deserializeAws_json1_1ConfirmCustomerAgreementResponse(data, context);
1478
+ response = __assign({ $metadata: deserializeMetadata(output) }, contents);
1479
+ return [2, Promise.resolve(response)];
1480
+ }
1481
+ });
1482
+ }); };
1483
+ var deserializeAws_json1_1ConfirmCustomerAgreementCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1484
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, parsedBody, message;
1485
+ var _e;
1486
+ return __generator(this, function (_f) {
1487
+ switch (_f.label) {
1488
+ case 0:
1489
+ _a = [__assign({}, output)];
1490
+ _e = {};
1491
+ return [4, parseBody(output.body, context)];
1492
+ case 1:
1493
+ parsedOutput = __assign.apply(void 0, _a.concat([(_e.body = _f.sent(), _e)]));
1494
+ errorCode = "UnknownError";
1495
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1496
+ _b = errorCode;
1497
+ switch (_b) {
1498
+ case "DirectConnectClientException": return [3, 2];
1499
+ case "com.amazonaws.directconnect#DirectConnectClientException": return [3, 2];
1500
+ case "DirectConnectServerException": return [3, 4];
1501
+ case "com.amazonaws.directconnect#DirectConnectServerException": return [3, 4];
1502
+ }
1503
+ return [3, 6];
1504
+ case 2:
1505
+ _c = [{}];
1506
+ return [4, deserializeAws_json1_1DirectConnectClientExceptionResponse(parsedOutput, context)];
1507
+ case 3:
1508
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1509
+ return [3, 7];
1510
+ case 4:
1511
+ _d = [{}];
1512
+ return [4, deserializeAws_json1_1DirectConnectServerExceptionResponse(parsedOutput, context)];
1513
+ case 5:
1514
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
1515
+ return [3, 7];
1516
+ case 6:
1517
+ parsedBody = parsedOutput.body;
1518
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
1519
+ response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
1520
+ _f.label = 7;
1521
+ case 7:
1522
+ message = response.message || response.Message || errorCode;
1523
+ response.message = message;
1524
+ delete response.Message;
1525
+ return [2, Promise.reject(Object.assign(new Error(message), response))];
1526
+ }
1527
+ });
1528
+ }); };
1421
1529
  export var deserializeAws_json1_1ConfirmPrivateVirtualInterfaceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
1422
1530
  var data, contents, response;
1423
1531
  return __generator(this, function (_a) {
@@ -3050,6 +3158,70 @@ var deserializeAws_json1_1DescribeConnectionsOnInterconnectCommandError = functi
3050
3158
  }
3051
3159
  });
3052
3160
  }); };
3161
+ export var deserializeAws_json1_1DescribeCustomerMetadataCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
3162
+ var data, contents, response;
3163
+ return __generator(this, function (_a) {
3164
+ switch (_a.label) {
3165
+ case 0:
3166
+ if (output.statusCode >= 300) {
3167
+ return [2, deserializeAws_json1_1DescribeCustomerMetadataCommandError(output, context)];
3168
+ }
3169
+ return [4, parseBody(output.body, context)];
3170
+ case 1:
3171
+ data = _a.sent();
3172
+ contents = {};
3173
+ contents = deserializeAws_json1_1DescribeCustomerMetadataResponse(data, context);
3174
+ response = __assign({ $metadata: deserializeMetadata(output) }, contents);
3175
+ return [2, Promise.resolve(response)];
3176
+ }
3177
+ });
3178
+ }); };
3179
+ var deserializeAws_json1_1DescribeCustomerMetadataCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
3180
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, parsedBody, message;
3181
+ var _e;
3182
+ return __generator(this, function (_f) {
3183
+ switch (_f.label) {
3184
+ case 0:
3185
+ _a = [__assign({}, output)];
3186
+ _e = {};
3187
+ return [4, parseBody(output.body, context)];
3188
+ case 1:
3189
+ parsedOutput = __assign.apply(void 0, _a.concat([(_e.body = _f.sent(), _e)]));
3190
+ errorCode = "UnknownError";
3191
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3192
+ _b = errorCode;
3193
+ switch (_b) {
3194
+ case "DirectConnectClientException": return [3, 2];
3195
+ case "com.amazonaws.directconnect#DirectConnectClientException": return [3, 2];
3196
+ case "DirectConnectServerException": return [3, 4];
3197
+ case "com.amazonaws.directconnect#DirectConnectServerException": return [3, 4];
3198
+ }
3199
+ return [3, 6];
3200
+ case 2:
3201
+ _c = [{}];
3202
+ return [4, deserializeAws_json1_1DirectConnectClientExceptionResponse(parsedOutput, context)];
3203
+ case 3:
3204
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
3205
+ return [3, 7];
3206
+ case 4:
3207
+ _d = [{}];
3208
+ return [4, deserializeAws_json1_1DirectConnectServerExceptionResponse(parsedOutput, context)];
3209
+ case 5:
3210
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
3211
+ return [3, 7];
3212
+ case 6:
3213
+ parsedBody = parsedOutput.body;
3214
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
3215
+ response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
3216
+ _f.label = 7;
3217
+ case 7:
3218
+ message = response.message || response.Message || errorCode;
3219
+ response.message = message;
3220
+ delete response.Message;
3221
+ return [2, Promise.reject(Object.assign(new Error(message), response))];
3222
+ }
3223
+ });
3224
+ }); };
3053
3225
  export var deserializeAws_json1_1DescribeDirectConnectGatewayAssociationProposalsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
3054
3226
  var data, contents, response;
3055
3227
  return __generator(this, function (_a) {
@@ -3690,6 +3862,70 @@ var deserializeAws_json1_1DescribeLocationsCommandError = function (output, cont
3690
3862
  }
3691
3863
  });
3692
3864
  }); };
3865
+ export var deserializeAws_json1_1DescribeRouterConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
3866
+ var data, contents, response;
3867
+ return __generator(this, function (_a) {
3868
+ switch (_a.label) {
3869
+ case 0:
3870
+ if (output.statusCode >= 300) {
3871
+ return [2, deserializeAws_json1_1DescribeRouterConfigurationCommandError(output, context)];
3872
+ }
3873
+ return [4, parseBody(output.body, context)];
3874
+ case 1:
3875
+ data = _a.sent();
3876
+ contents = {};
3877
+ contents = deserializeAws_json1_1DescribeRouterConfigurationResponse(data, context);
3878
+ response = __assign({ $metadata: deserializeMetadata(output) }, contents);
3879
+ return [2, Promise.resolve(response)];
3880
+ }
3881
+ });
3882
+ }); };
3883
+ var deserializeAws_json1_1DescribeRouterConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
3884
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, parsedBody, message;
3885
+ var _e;
3886
+ return __generator(this, function (_f) {
3887
+ switch (_f.label) {
3888
+ case 0:
3889
+ _a = [__assign({}, output)];
3890
+ _e = {};
3891
+ return [4, parseBody(output.body, context)];
3892
+ case 1:
3893
+ parsedOutput = __assign.apply(void 0, _a.concat([(_e.body = _f.sent(), _e)]));
3894
+ errorCode = "UnknownError";
3895
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3896
+ _b = errorCode;
3897
+ switch (_b) {
3898
+ case "DirectConnectClientException": return [3, 2];
3899
+ case "com.amazonaws.directconnect#DirectConnectClientException": return [3, 2];
3900
+ case "DirectConnectServerException": return [3, 4];
3901
+ case "com.amazonaws.directconnect#DirectConnectServerException": return [3, 4];
3902
+ }
3903
+ return [3, 6];
3904
+ case 2:
3905
+ _c = [{}];
3906
+ return [4, deserializeAws_json1_1DirectConnectClientExceptionResponse(parsedOutput, context)];
3907
+ case 3:
3908
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
3909
+ return [3, 7];
3910
+ case 4:
3911
+ _d = [{}];
3912
+ return [4, deserializeAws_json1_1DirectConnectServerExceptionResponse(parsedOutput, context)];
3913
+ case 5:
3914
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
3915
+ return [3, 7];
3916
+ case 6:
3917
+ parsedBody = parsedOutput.body;
3918
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
3919
+ response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
3920
+ _f.label = 7;
3921
+ case 7:
3922
+ message = response.message || response.Message || errorCode;
3923
+ response.message = message;
3924
+ delete response.Message;
3925
+ return [2, Promise.reject(Object.assign(new Error(message), response))];
3926
+ }
3927
+ });
3928
+ }); };
3693
3929
  export var deserializeAws_json1_1DescribeTagsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
3694
3930
  var data, contents, response;
3695
3931
  return __generator(this, function (_a) {
@@ -4410,6 +4646,70 @@ var deserializeAws_json1_1UpdateConnectionCommandError = function (output, conte
4410
4646
  }
4411
4647
  });
4412
4648
  }); };
4649
+ export var deserializeAws_json1_1UpdateDirectConnectGatewayCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
4650
+ var data, contents, response;
4651
+ return __generator(this, function (_a) {
4652
+ switch (_a.label) {
4653
+ case 0:
4654
+ if (output.statusCode >= 300) {
4655
+ return [2, deserializeAws_json1_1UpdateDirectConnectGatewayCommandError(output, context)];
4656
+ }
4657
+ return [4, parseBody(output.body, context)];
4658
+ case 1:
4659
+ data = _a.sent();
4660
+ contents = {};
4661
+ contents = deserializeAws_json1_1UpdateDirectConnectGatewayResponse(data, context);
4662
+ response = __assign({ $metadata: deserializeMetadata(output) }, contents);
4663
+ return [2, Promise.resolve(response)];
4664
+ }
4665
+ });
4666
+ }); };
4667
+ var deserializeAws_json1_1UpdateDirectConnectGatewayCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
4668
+ var parsedOutput, _a, response, errorCode, _b, _c, _d, parsedBody, message;
4669
+ var _e;
4670
+ return __generator(this, function (_f) {
4671
+ switch (_f.label) {
4672
+ case 0:
4673
+ _a = [__assign({}, output)];
4674
+ _e = {};
4675
+ return [4, parseBody(output.body, context)];
4676
+ case 1:
4677
+ parsedOutput = __assign.apply(void 0, _a.concat([(_e.body = _f.sent(), _e)]));
4678
+ errorCode = "UnknownError";
4679
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4680
+ _b = errorCode;
4681
+ switch (_b) {
4682
+ case "DirectConnectClientException": return [3, 2];
4683
+ case "com.amazonaws.directconnect#DirectConnectClientException": return [3, 2];
4684
+ case "DirectConnectServerException": return [3, 4];
4685
+ case "com.amazonaws.directconnect#DirectConnectServerException": return [3, 4];
4686
+ }
4687
+ return [3, 6];
4688
+ case 2:
4689
+ _c = [{}];
4690
+ return [4, deserializeAws_json1_1DirectConnectClientExceptionResponse(parsedOutput, context)];
4691
+ case 3:
4692
+ response = __assign.apply(void 0, [__assign.apply(void 0, _c.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
4693
+ return [3, 7];
4694
+ case 4:
4695
+ _d = [{}];
4696
+ return [4, deserializeAws_json1_1DirectConnectServerExceptionResponse(parsedOutput, context)];
4697
+ case 5:
4698
+ response = __assign.apply(void 0, [__assign.apply(void 0, _d.concat([(_f.sent())])), { name: errorCode, $metadata: deserializeMetadata(output) }]);
4699
+ return [3, 7];
4700
+ case 6:
4701
+ parsedBody = parsedOutput.body;
4702
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
4703
+ response = __assign(__assign({}, parsedBody), { name: "" + errorCode, message: parsedBody.message || parsedBody.Message || errorCode, $fault: "client", $metadata: deserializeMetadata(output) });
4704
+ _f.label = 7;
4705
+ case 7:
4706
+ message = response.message || response.Message || errorCode;
4707
+ response.message = message;
4708
+ delete response.Message;
4709
+ return [2, Promise.reject(Object.assign(new Error(message), response))];
4710
+ }
4711
+ });
4712
+ }); };
4413
4713
  export var deserializeAws_json1_1UpdateDirectConnectGatewayAssociationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
4414
4714
  var data, contents, response;
4415
4715
  return __generator(this, function (_a) {
@@ -4702,6 +5002,9 @@ var serializeAws_json1_1BGPPeerIdList = function (input, context) {
4702
5002
  var serializeAws_json1_1ConfirmConnectionRequest = function (input, context) {
4703
5003
  return __assign({}, (input.connectionId !== undefined && input.connectionId !== null && { connectionId: input.connectionId }));
4704
5004
  };
5005
+ var serializeAws_json1_1ConfirmCustomerAgreementRequest = function (input, context) {
5006
+ return __assign({}, (input.agreementName !== undefined && input.agreementName !== null && { agreementName: input.agreementName }));
5007
+ };
4705
5008
  var serializeAws_json1_1ConfirmPrivateVirtualInterfaceRequest = function (input, context) {
4706
5009
  return __assign(__assign(__assign({}, (input.directConnectGatewayId !== undefined &&
4707
5010
  input.directConnectGatewayId !== null && { directConnectGatewayId: input.directConnectGatewayId })), (input.virtualGatewayId !== undefined &&
@@ -4862,6 +5165,11 @@ var serializeAws_json1_1DescribeLoaRequest = function (input, context) {
4862
5165
  return __assign(__assign(__assign({}, (input.connectionId !== undefined && input.connectionId !== null && { connectionId: input.connectionId })), (input.loaContentType !== undefined &&
4863
5166
  input.loaContentType !== null && { loaContentType: input.loaContentType })), (input.providerName !== undefined && input.providerName !== null && { providerName: input.providerName }));
4864
5167
  };
5168
+ var serializeAws_json1_1DescribeRouterConfigurationRequest = function (input, context) {
5169
+ return __assign(__assign({}, (input.routerTypeIdentifier !== undefined &&
5170
+ input.routerTypeIdentifier !== null && { routerTypeIdentifier: input.routerTypeIdentifier })), (input.virtualInterfaceId !== undefined &&
5171
+ input.virtualInterfaceId !== null && { virtualInterfaceId: input.virtualInterfaceId }));
5172
+ };
4865
5173
  var serializeAws_json1_1DescribeTagsRequest = function (input, context) {
4866
5174
  return __assign({}, (input.resourceArns !== undefined &&
4867
5175
  input.resourceArns !== null && {
@@ -5003,6 +5311,11 @@ var serializeAws_json1_1UpdateDirectConnectGatewayAssociationRequest = function
5003
5311
  removeAllowedPrefixesToDirectConnectGateway: serializeAws_json1_1RouteFilterPrefixList(input.removeAllowedPrefixesToDirectConnectGateway, context),
5004
5312
  }));
5005
5313
  };
5314
+ var serializeAws_json1_1UpdateDirectConnectGatewayRequest = function (input, context) {
5315
+ return __assign(__assign({}, (input.directConnectGatewayId !== undefined &&
5316
+ input.directConnectGatewayId !== null && { directConnectGatewayId: input.directConnectGatewayId })), (input.newDirectConnectGatewayName !== undefined &&
5317
+ input.newDirectConnectGatewayName !== null && { newDirectConnectGatewayName: input.newDirectConnectGatewayName }));
5318
+ };
5006
5319
  var serializeAws_json1_1UpdateLagRequest = function (input, context) {
5007
5320
  return __assign(__assign(__assign(__assign({}, (input.encryptionMode !== undefined &&
5008
5321
  input.encryptionMode !== null && { encryptionMode: input.encryptionMode })), (input.lagId !== undefined && input.lagId !== null && { lagId: input.lagId })), (input.lagName !== undefined && input.lagName !== null && { lagName: input.lagName })), (input.minimumLinks !== undefined && input.minimumLinks !== null && { minimumLinks: input.minimumLinks }));
@@ -5018,6 +5331,16 @@ var deserializeAws_json1_1AcceptDirectConnectGatewayAssociationProposalResult =
5018
5331
  : undefined,
5019
5332
  };
5020
5333
  };
5334
+ var deserializeAws_json1_1AgreementList = function (output, context) {
5335
+ return (output || [])
5336
+ .filter(function (e) { return e != null; })
5337
+ .map(function (entry) {
5338
+ if (entry === null) {
5339
+ return null;
5340
+ }
5341
+ return deserializeAws_json1_1CustomerAgreement(entry, context);
5342
+ });
5343
+ };
5021
5344
  var deserializeAws_json1_1AllocateTransitVirtualInterfaceResult = function (output, context) {
5022
5345
  return {
5023
5346
  virtualInterface: output.virtualInterface !== undefined && output.virtualInterface !== null
@@ -5100,6 +5423,11 @@ var deserializeAws_json1_1ConfirmConnectionResponse = function (output, context)
5100
5423
  connectionState: __expectString(output.connectionState),
5101
5424
  };
5102
5425
  };
5426
+ var deserializeAws_json1_1ConfirmCustomerAgreementResponse = function (output, context) {
5427
+ return {
5428
+ status: __expectString(output.status),
5429
+ };
5430
+ };
5103
5431
  var deserializeAws_json1_1ConfirmPrivateVirtualInterfaceResponse = function (output, context) {
5104
5432
  return {
5105
5433
  virtualInterfaceState: __expectString(output.virtualInterfaceState),
@@ -5200,6 +5528,12 @@ var deserializeAws_json1_1CreateTransitVirtualInterfaceResult = function (output
5200
5528
  : undefined,
5201
5529
  };
5202
5530
  };
5531
+ var deserializeAws_json1_1CustomerAgreement = function (output, context) {
5532
+ return {
5533
+ agreementName: __expectString(output.agreementName),
5534
+ status: __expectString(output.status),
5535
+ };
5536
+ };
5203
5537
  var deserializeAws_json1_1DeleteBGPPeerResponse = function (output, context) {
5204
5538
  return {
5205
5539
  virtualInterface: output.virtualInterface !== undefined && output.virtualInterface !== null
@@ -5244,6 +5578,14 @@ var deserializeAws_json1_1DescribeConnectionLoaResponse = function (output, cont
5244
5578
  loa: output.loa !== undefined && output.loa !== null ? deserializeAws_json1_1Loa(output.loa, context) : undefined,
5245
5579
  };
5246
5580
  };
5581
+ var deserializeAws_json1_1DescribeCustomerMetadataResponse = function (output, context) {
5582
+ return {
5583
+ agreements: output.agreements !== undefined && output.agreements !== null
5584
+ ? deserializeAws_json1_1AgreementList(output.agreements, context)
5585
+ : undefined,
5586
+ nniPartnerType: __expectString(output.nniPartnerType),
5587
+ };
5588
+ };
5247
5589
  var deserializeAws_json1_1DescribeDirectConnectGatewayAssociationProposalsResult = function (output, context) {
5248
5590
  return {
5249
5591
  directConnectGatewayAssociationProposals: output.directConnectGatewayAssociationProposals !== undefined &&
@@ -5282,6 +5624,16 @@ var deserializeAws_json1_1DescribeInterconnectLoaResponse = function (output, co
5282
5624
  loa: output.loa !== undefined && output.loa !== null ? deserializeAws_json1_1Loa(output.loa, context) : undefined,
5283
5625
  };
5284
5626
  };
5627
+ var deserializeAws_json1_1DescribeRouterConfigurationResponse = function (output, context) {
5628
+ return {
5629
+ customerRouterConfig: __expectString(output.customerRouterConfig),
5630
+ router: output.router !== undefined && output.router !== null
5631
+ ? deserializeAws_json1_1RouterType(output.router, context)
5632
+ : undefined,
5633
+ virtualInterfaceId: __expectString(output.virtualInterfaceId),
5634
+ virtualInterfaceName: __expectString(output.virtualInterfaceName),
5635
+ };
5636
+ };
5285
5637
  var deserializeAws_json1_1DescribeTagsResponse = function (output, context) {
5286
5638
  return {
5287
5639
  resourceTags: output.resourceTags !== undefined && output.resourceTags !== null
@@ -5609,6 +5961,16 @@ var deserializeAws_json1_1RouteFilterPrefixList = function (output, context) {
5609
5961
  return deserializeAws_json1_1RouteFilterPrefix(entry, context);
5610
5962
  });
5611
5963
  };
5964
+ var deserializeAws_json1_1RouterType = function (output, context) {
5965
+ return {
5966
+ platform: __expectString(output.platform),
5967
+ routerTypeIdentifier: __expectString(output.routerTypeIdentifier),
5968
+ software: __expectString(output.software),
5969
+ vendor: __expectString(output.vendor),
5970
+ xsltTemplateName: __expectString(output.xsltTemplateName),
5971
+ xsltTemplateNameForMacSec: __expectString(output.xsltTemplateNameForMacSec),
5972
+ };
5973
+ };
5612
5974
  var deserializeAws_json1_1StartBgpFailoverTestResponse = function (output, context) {
5613
5975
  return {
5614
5976
  virtualInterfaceTest: output.virtualInterfaceTest !== undefined && output.virtualInterfaceTest !== null
@@ -5657,6 +6019,13 @@ var deserializeAws_json1_1UpdateDirectConnectGatewayAssociationResult = function
5657
6019
  : undefined,
5658
6020
  };
5659
6021
  };
6022
+ var deserializeAws_json1_1UpdateDirectConnectGatewayResponse = function (output, context) {
6023
+ return {
6024
+ directConnectGateway: output.directConnectGateway !== undefined && output.directConnectGateway !== null
6025
+ ? deserializeAws_json1_1DirectConnectGateway(output.directConnectGateway, context)
6026
+ : undefined,
6027
+ };
6028
+ };
5660
6029
  var deserializeAws_json1_1VirtualGateway = function (output, context) {
5661
6030
  return {
5662
6031
  virtualGatewayId: __expectString(output.virtualGatewayId),
@@ -1,6 +1,7 @@
1
1
  import { __assign } from "tslib";
2
2
  import packageInfo from "../package.json";
3
3
  import { Sha256 } from "@aws-crypto/sha256-browser";
4
+ import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@aws-sdk/config-resolver";
4
5
  import { FetchHttpHandler, streamCollector } from "@aws-sdk/fetch-http-handler";
5
6
  import { invalidProvider } from "@aws-sdk/invalid-dependency";
6
7
  import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@aws-sdk/middleware-retry";
@@ -10,7 +11,7 @@ import { defaultUserAgent } from "@aws-sdk/util-user-agent-browser";
10
11
  import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-browser";
11
12
  import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
12
13
  export var getRuntimeConfig = function (config) {
13
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
14
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
14
15
  var clientSharedValues = getSharedRuntimeConfig(config);
15
- return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new FetchHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (function () { return Promise.resolve(DEFAULT_RETRY_MODE); }), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Sha256, streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, utf8Decoder: (_m = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _m !== void 0 ? _m : fromUtf8, utf8Encoder: (_o = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _o !== void 0 ? _o : toUtf8 });
16
+ return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "browser", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : (function (_) { return function () { return Promise.reject(new Error("Credential is missing")); }; }), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : DEFAULT_MAX_ATTEMPTS, region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : invalidProvider("Region is missing"), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new FetchHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : (function () { return Promise.resolve(DEFAULT_RETRY_MODE); }), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Sha256, streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : (function () { return Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT); }), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : (function () { return Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT); }), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
16
17
  };
@@ -1,7 +1,7 @@
1
1
  import { __assign } from "tslib";
2
2
  import packageInfo from "../package.json";
3
3
  import { decorateDefaultCredentialProvider } from "@aws-sdk/client-sts";
4
- import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS } from "@aws-sdk/config-resolver";
4
+ import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, } from "@aws-sdk/config-resolver";
5
5
  import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
6
6
  import { Hash } from "@aws-sdk/hash-node";
7
7
  import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@aws-sdk/middleware-retry";
@@ -14,8 +14,8 @@ import { fromUtf8, toUtf8 } from "@aws-sdk/util-utf8-node";
14
14
  import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
15
15
  import { emitWarningIfUnsupportedVersion } from "@aws-sdk/smithy-client";
16
16
  export var getRuntimeConfig = function (config) {
17
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
17
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
18
18
  emitWarningIfUnsupportedVersion(process.version);
19
19
  var clientSharedValues = getSharedRuntimeConfig(config);
20
- return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new NodeHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : loadNodeConfig(NODE_RETRY_MODE_CONFIG_OPTIONS), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Hash.bind(null, "sha256"), streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, utf8Decoder: (_m = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _m !== void 0 ? _m : fromUtf8, utf8Encoder: (_o = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _o !== void 0 ? _o : toUtf8 });
20
+ return __assign(__assign(__assign({}, clientSharedValues), config), { runtime: "node", base64Decoder: (_a = config === null || config === void 0 ? void 0 : config.base64Decoder) !== null && _a !== void 0 ? _a : fromBase64, base64Encoder: (_b = config === null || config === void 0 ? void 0 : config.base64Encoder) !== null && _b !== void 0 ? _b : toBase64, bodyLengthChecker: (_c = config === null || config === void 0 ? void 0 : config.bodyLengthChecker) !== null && _c !== void 0 ? _c : calculateBodyLength, credentialDefaultProvider: (_d = config === null || config === void 0 ? void 0 : config.credentialDefaultProvider) !== null && _d !== void 0 ? _d : decorateDefaultCredentialProvider(credentialDefaultProvider), defaultUserAgentProvider: (_e = config === null || config === void 0 ? void 0 : config.defaultUserAgentProvider) !== null && _e !== void 0 ? _e : defaultUserAgent({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), maxAttempts: (_f = config === null || config === void 0 ? void 0 : config.maxAttempts) !== null && _f !== void 0 ? _f : loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS), region: (_g = config === null || config === void 0 ? void 0 : config.region) !== null && _g !== void 0 ? _g : loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS), requestHandler: (_h = config === null || config === void 0 ? void 0 : config.requestHandler) !== null && _h !== void 0 ? _h : new NodeHttpHandler(), retryMode: (_j = config === null || config === void 0 ? void 0 : config.retryMode) !== null && _j !== void 0 ? _j : loadNodeConfig(NODE_RETRY_MODE_CONFIG_OPTIONS), sha256: (_k = config === null || config === void 0 ? void 0 : config.sha256) !== null && _k !== void 0 ? _k : Hash.bind(null, "sha256"), streamCollector: (_l = config === null || config === void 0 ? void 0 : config.streamCollector) !== null && _l !== void 0 ? _l : streamCollector, useDualstackEndpoint: (_m = config === null || config === void 0 ? void 0 : config.useDualstackEndpoint) !== null && _m !== void 0 ? _m : loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS), useFipsEndpoint: (_o = config === null || config === void 0 ? void 0 : config.useFipsEndpoint) !== null && _o !== void 0 ? _o : loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS), utf8Decoder: (_p = config === null || config === void 0 ? void 0 : config.utf8Decoder) !== null && _p !== void 0 ? _p : fromUtf8, utf8Encoder: (_q = config === null || config === void 0 ? void 0 : config.utf8Encoder) !== null && _q !== void 0 ? _q : toUtf8 });
21
21
  };