@aws-sdk/client-kafka 3.29.0 → 3.33.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 (130) hide show
  1. package/CHANGELOG.md +35 -0
  2. package/Kafka.ts +37 -0
  3. package/KafkaClient.ts +5 -2
  4. package/commands/UpdateSecurityCommand.ts +94 -0
  5. package/dist/cjs/Kafka.js +15 -0
  6. package/dist/cjs/Kafka.js.map +1 -1
  7. package/dist/cjs/KafkaClient.js +13 -13
  8. package/dist/cjs/KafkaClient.js.map +1 -1
  9. package/dist/cjs/commands/BatchAssociateScramSecretCommand.js +3 -3
  10. package/dist/cjs/commands/BatchAssociateScramSecretCommand.js.map +1 -1
  11. package/dist/cjs/commands/BatchDisassociateScramSecretCommand.js +3 -3
  12. package/dist/cjs/commands/BatchDisassociateScramSecretCommand.js.map +1 -1
  13. package/dist/cjs/commands/CreateClusterCommand.js +3 -3
  14. package/dist/cjs/commands/CreateClusterCommand.js.map +1 -1
  15. package/dist/cjs/commands/CreateConfigurationCommand.js +3 -3
  16. package/dist/cjs/commands/CreateConfigurationCommand.js.map +1 -1
  17. package/dist/cjs/commands/DeleteClusterCommand.js +3 -3
  18. package/dist/cjs/commands/DeleteClusterCommand.js.map +1 -1
  19. package/dist/cjs/commands/DeleteConfigurationCommand.js +3 -3
  20. package/dist/cjs/commands/DeleteConfigurationCommand.js.map +1 -1
  21. package/dist/cjs/commands/DescribeClusterCommand.js +3 -3
  22. package/dist/cjs/commands/DescribeClusterCommand.js.map +1 -1
  23. package/dist/cjs/commands/DescribeClusterOperationCommand.js +3 -3
  24. package/dist/cjs/commands/DescribeClusterOperationCommand.js.map +1 -1
  25. package/dist/cjs/commands/DescribeConfigurationCommand.js +3 -3
  26. package/dist/cjs/commands/DescribeConfigurationCommand.js.map +1 -1
  27. package/dist/cjs/commands/DescribeConfigurationRevisionCommand.js +3 -3
  28. package/dist/cjs/commands/DescribeConfigurationRevisionCommand.js.map +1 -1
  29. package/dist/cjs/commands/GetBootstrapBrokersCommand.js +3 -3
  30. package/dist/cjs/commands/GetBootstrapBrokersCommand.js.map +1 -1
  31. package/dist/cjs/commands/GetCompatibleKafkaVersionsCommand.js +3 -3
  32. package/dist/cjs/commands/GetCompatibleKafkaVersionsCommand.js.map +1 -1
  33. package/dist/cjs/commands/ListClusterOperationsCommand.js +3 -3
  34. package/dist/cjs/commands/ListClusterOperationsCommand.js.map +1 -1
  35. package/dist/cjs/commands/ListClustersCommand.js +3 -3
  36. package/dist/cjs/commands/ListClustersCommand.js.map +1 -1
  37. package/dist/cjs/commands/ListConfigurationRevisionsCommand.js +3 -3
  38. package/dist/cjs/commands/ListConfigurationRevisionsCommand.js.map +1 -1
  39. package/dist/cjs/commands/ListConfigurationsCommand.js +3 -3
  40. package/dist/cjs/commands/ListConfigurationsCommand.js.map +1 -1
  41. package/dist/cjs/commands/ListKafkaVersionsCommand.js +3 -3
  42. package/dist/cjs/commands/ListKafkaVersionsCommand.js.map +1 -1
  43. package/dist/cjs/commands/ListNodesCommand.js +3 -3
  44. package/dist/cjs/commands/ListNodesCommand.js.map +1 -1
  45. package/dist/cjs/commands/ListScramSecretsCommand.js +3 -3
  46. package/dist/cjs/commands/ListScramSecretsCommand.js.map +1 -1
  47. package/dist/cjs/commands/ListTagsForResourceCommand.js +3 -3
  48. package/dist/cjs/commands/ListTagsForResourceCommand.js.map +1 -1
  49. package/dist/cjs/commands/RebootBrokerCommand.js +3 -3
  50. package/dist/cjs/commands/RebootBrokerCommand.js.map +1 -1
  51. package/dist/cjs/commands/TagResourceCommand.js +3 -3
  52. package/dist/cjs/commands/TagResourceCommand.js.map +1 -1
  53. package/dist/cjs/commands/UntagResourceCommand.js +3 -3
  54. package/dist/cjs/commands/UntagResourceCommand.js.map +1 -1
  55. package/dist/cjs/commands/UpdateBrokerCountCommand.js +3 -3
  56. package/dist/cjs/commands/UpdateBrokerCountCommand.js.map +1 -1
  57. package/dist/cjs/commands/UpdateBrokerStorageCommand.js +3 -3
  58. package/dist/cjs/commands/UpdateBrokerStorageCommand.js.map +1 -1
  59. package/dist/cjs/commands/UpdateBrokerTypeCommand.js +3 -3
  60. package/dist/cjs/commands/UpdateBrokerTypeCommand.js.map +1 -1
  61. package/dist/cjs/commands/UpdateClusterConfigurationCommand.js +3 -3
  62. package/dist/cjs/commands/UpdateClusterConfigurationCommand.js.map +1 -1
  63. package/dist/cjs/commands/UpdateClusterKafkaVersionCommand.js +3 -3
  64. package/dist/cjs/commands/UpdateClusterKafkaVersionCommand.js.map +1 -1
  65. package/dist/cjs/commands/UpdateConfigurationCommand.js +3 -3
  66. package/dist/cjs/commands/UpdateConfigurationCommand.js.map +1 -1
  67. package/dist/cjs/commands/UpdateMonitoringCommand.js +3 -3
  68. package/dist/cjs/commands/UpdateMonitoringCommand.js.map +1 -1
  69. package/dist/cjs/commands/UpdateSecurityCommand.js +61 -0
  70. package/dist/cjs/commands/UpdateSecurityCommand.js.map +1 -0
  71. package/dist/cjs/endpoints.js +1 -1
  72. package/dist/cjs/endpoints.js.map +1 -1
  73. package/dist/cjs/index.js +42 -41
  74. package/dist/cjs/index.js.map +1 -1
  75. package/dist/cjs/models/index.js +1 -1
  76. package/dist/cjs/models/index.js.map +1 -1
  77. package/dist/cjs/models/models_0.js +30 -3
  78. package/dist/cjs/models/models_0.js.map +1 -1
  79. package/dist/cjs/package.json +31 -31
  80. package/dist/cjs/protocols/Aws_restJson1.js +373 -198
  81. package/dist/cjs/protocols/Aws_restJson1.js.map +1 -1
  82. package/dist/cjs/runtimeConfig.browser.js +4 -4
  83. package/dist/cjs/runtimeConfig.browser.js.map +1 -1
  84. package/dist/cjs/runtimeConfig.js +8 -8
  85. package/dist/cjs/runtimeConfig.js.map +1 -1
  86. package/dist/cjs/runtimeConfig.native.js +1 -1
  87. package/dist/cjs/runtimeConfig.native.js.map +1 -1
  88. package/dist/es/Kafka.js +15 -0
  89. package/dist/es/Kafka.js.map +1 -1
  90. package/dist/es/KafkaClient.js.map +1 -1
  91. package/dist/es/commands/UpdateSecurityCommand.js +65 -0
  92. package/dist/es/commands/UpdateSecurityCommand.js.map +1 -0
  93. package/dist/es/index.js +1 -0
  94. package/dist/es/index.js.map +1 -1
  95. package/dist/es/models/models_0.js +21 -0
  96. package/dist/es/models/models_0.js.map +1 -1
  97. package/dist/es/package.json +31 -31
  98. package/dist/es/pagination/ListClusterOperationsPaginator.js +4 -4
  99. package/dist/es/pagination/ListClusterOperationsPaginator.js.map +1 -1
  100. package/dist/es/pagination/ListClustersPaginator.js +4 -4
  101. package/dist/es/pagination/ListClustersPaginator.js.map +1 -1
  102. package/dist/es/pagination/ListConfigurationRevisionsPaginator.js +4 -4
  103. package/dist/es/pagination/ListConfigurationRevisionsPaginator.js.map +1 -1
  104. package/dist/es/pagination/ListConfigurationsPaginator.js +4 -4
  105. package/dist/es/pagination/ListConfigurationsPaginator.js.map +1 -1
  106. package/dist/es/pagination/ListKafkaVersionsPaginator.js +4 -4
  107. package/dist/es/pagination/ListKafkaVersionsPaginator.js.map +1 -1
  108. package/dist/es/pagination/ListNodesPaginator.js +4 -4
  109. package/dist/es/pagination/ListNodesPaginator.js.map +1 -1
  110. package/dist/es/pagination/ListScramSecretsPaginator.js +4 -4
  111. package/dist/es/pagination/ListScramSecretsPaginator.js.map +1 -1
  112. package/dist/es/protocols/Aws_restJson1.js +198 -12
  113. package/dist/es/protocols/Aws_restJson1.js.map +1 -1
  114. package/dist/types/Kafka.d.ts +7 -0
  115. package/dist/types/KafkaClient.d.ts +3 -2
  116. package/dist/types/commands/UpdateSecurityCommand.d.ts +35 -0
  117. package/dist/types/index.d.ts +1 -0
  118. package/dist/types/models/models_0.d.ts +71 -0
  119. package/dist/types/protocols/Aws_restJson1.d.ts +3 -0
  120. package/dist/types/ts3.4/Kafka.d.ts +7 -0
  121. package/dist/types/ts3.4/KafkaClient.d.ts +3 -2
  122. package/dist/types/ts3.4/commands/UpdateSecurityCommand.d.ts +35 -0
  123. package/dist/types/ts3.4/index.d.ts +1 -0
  124. package/dist/types/ts3.4/models/models_0.d.ts +71 -0
  125. package/dist/types/ts3.4/protocols/Aws_restJson1.d.ts +3 -0
  126. package/index.ts +1 -0
  127. package/models/models_0.ts +92 -0
  128. package/package.json +31 -31
  129. package/protocols/Aws_restJson1.ts +202 -8
  130. package/tsconfig.json +1 -2
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-kafka",
3
3
  "description": "AWS SDK for JavaScript Kafka Client for Node.js, Browser and React Native",
4
- "version": "3.29.0",
4
+ "version": "3.33.0",
5
5
  "scripts": {
6
6
  "clean": "yarn remove-definitions && yarn remove-dist && yarn remove-documentation",
7
7
  "build-documentation": "yarn remove-documentation && typedoc ./",
@@ -27,45 +27,45 @@
27
27
  "dependencies": {
28
28
  "@aws-crypto/sha256-browser": "^1.0.0",
29
29
  "@aws-crypto/sha256-js": "^1.0.0",
30
- "@aws-sdk/client-sts": "3.29.0",
31
- "@aws-sdk/config-resolver": "3.29.0",
32
- "@aws-sdk/credential-provider-node": "3.29.0",
33
- "@aws-sdk/fetch-http-handler": "3.29.0",
34
- "@aws-sdk/hash-node": "3.29.0",
35
- "@aws-sdk/invalid-dependency": "3.29.0",
36
- "@aws-sdk/middleware-content-length": "3.29.0",
37
- "@aws-sdk/middleware-host-header": "3.29.0",
38
- "@aws-sdk/middleware-logger": "3.29.0",
39
- "@aws-sdk/middleware-retry": "3.29.0",
40
- "@aws-sdk/middleware-serde": "3.29.0",
41
- "@aws-sdk/middleware-signing": "3.29.0",
42
- "@aws-sdk/middleware-stack": "3.29.0",
43
- "@aws-sdk/middleware-user-agent": "3.29.0",
44
- "@aws-sdk/node-config-provider": "3.29.0",
45
- "@aws-sdk/node-http-handler": "3.29.0",
46
- "@aws-sdk/protocol-http": "3.29.0",
47
- "@aws-sdk/smithy-client": "3.29.0",
48
- "@aws-sdk/types": "3.29.0",
49
- "@aws-sdk/url-parser": "3.29.0",
50
- "@aws-sdk/util-base64-browser": "3.29.0",
51
- "@aws-sdk/util-base64-node": "3.29.0",
52
- "@aws-sdk/util-body-length-browser": "3.29.0",
53
- "@aws-sdk/util-body-length-node": "3.29.0",
54
- "@aws-sdk/util-user-agent-browser": "3.29.0",
55
- "@aws-sdk/util-user-agent-node": "3.29.0",
56
- "@aws-sdk/util-utf8-browser": "3.29.0",
57
- "@aws-sdk/util-utf8-node": "3.29.0",
30
+ "@aws-sdk/client-sts": "3.33.0",
31
+ "@aws-sdk/config-resolver": "3.33.0",
32
+ "@aws-sdk/credential-provider-node": "3.33.0",
33
+ "@aws-sdk/fetch-http-handler": "3.32.0",
34
+ "@aws-sdk/hash-node": "3.32.0",
35
+ "@aws-sdk/invalid-dependency": "3.32.0",
36
+ "@aws-sdk/middleware-content-length": "3.32.0",
37
+ "@aws-sdk/middleware-host-header": "3.32.0",
38
+ "@aws-sdk/middleware-logger": "3.32.0",
39
+ "@aws-sdk/middleware-retry": "3.32.0",
40
+ "@aws-sdk/middleware-serde": "3.32.0",
41
+ "@aws-sdk/middleware-signing": "3.33.0",
42
+ "@aws-sdk/middleware-stack": "3.32.0",
43
+ "@aws-sdk/middleware-user-agent": "3.32.0",
44
+ "@aws-sdk/node-config-provider": "3.32.0",
45
+ "@aws-sdk/node-http-handler": "3.32.0",
46
+ "@aws-sdk/protocol-http": "3.32.0",
47
+ "@aws-sdk/smithy-client": "3.32.0",
48
+ "@aws-sdk/types": "3.32.0",
49
+ "@aws-sdk/url-parser": "3.32.0",
50
+ "@aws-sdk/util-base64-browser": "3.32.0",
51
+ "@aws-sdk/util-base64-node": "3.32.0",
52
+ "@aws-sdk/util-body-length-browser": "3.32.0",
53
+ "@aws-sdk/util-body-length-node": "3.32.0",
54
+ "@aws-sdk/util-user-agent-browser": "3.32.0",
55
+ "@aws-sdk/util-user-agent-node": "3.33.0",
56
+ "@aws-sdk/util-utf8-browser": "3.32.0",
57
+ "@aws-sdk/util-utf8-node": "3.32.0",
58
58
  "tslib": "^2.3.0"
59
59
  },
60
60
  "devDependencies": {
61
- "@aws-sdk/client-documentation-generator": "3.29.0",
61
+ "@aws-sdk/client-documentation-generator": "3.32.0",
62
62
  "@types/node": "^12.7.5",
63
63
  "downlevel-dts": "0.7.0",
64
64
  "jest": "^26.1.0",
65
65
  "rimraf": "^3.0.0",
66
66
  "ts-jest": "^26.4.1",
67
67
  "typedoc": "^0.19.2",
68
- "typescript": "~4.4.2"
68
+ "typescript": "~4.3.5"
69
69
  },
70
70
  "engines": {
71
71
  "node": ">=10.0.0"
@@ -76,6 +76,7 @@ import {
76
76
  UpdateConfigurationCommandOutput,
77
77
  } from "../commands/UpdateConfigurationCommand";
78
78
  import { UpdateMonitoringCommandInput, UpdateMonitoringCommandOutput } from "../commands/UpdateMonitoringCommand";
79
+ import { UpdateSecurityCommandInput, UpdateSecurityCommandOutput } from "../commands/UpdateSecurityCommand";
79
80
  import {
80
81
  BadRequestException,
81
82
  BrokerEBSVolumeInfo,
@@ -124,6 +125,7 @@ import {
124
125
  StorageInfo,
125
126
  Tls,
126
127
  TooManyRequestsException,
128
+ Unauthenticated,
127
129
  UnauthorizedException,
128
130
  UnprocessedScramSecret,
129
131
  ZookeeperNodeInfo,
@@ -138,6 +140,7 @@ import {
138
140
  expectString as __expectString,
139
141
  extendedEncodeURIComponent as __extendedEncodeURIComponent,
140
142
  limitedParseDouble as __limitedParseDouble,
143
+ parseRfc3339DateTime as __parseRfc3339DateTime,
141
144
  } from "@aws-sdk/smithy-client";
142
145
  import {
143
146
  Endpoint as __Endpoint,
@@ -1157,6 +1160,49 @@ export const serializeAws_restJson1UpdateMonitoringCommand = async (
1157
1160
  });
1158
1161
  };
1159
1162
 
1163
+ export const serializeAws_restJson1UpdateSecurityCommand = async (
1164
+ input: UpdateSecurityCommandInput,
1165
+ context: __SerdeContext
1166
+ ): Promise<__HttpRequest> => {
1167
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1168
+ const headers: any = {
1169
+ "content-type": "application/json",
1170
+ };
1171
+ let resolvedPath =
1172
+ `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/clusters/{ClusterArn}/security";
1173
+ if (input.ClusterArn !== undefined) {
1174
+ const labelValue: string = input.ClusterArn;
1175
+ if (labelValue.length <= 0) {
1176
+ throw new Error("Empty value provided for input HTTP label: ClusterArn.");
1177
+ }
1178
+ resolvedPath = resolvedPath.replace("{ClusterArn}", __extendedEncodeURIComponent(labelValue));
1179
+ } else {
1180
+ throw new Error("No value provided for input HTTP label: ClusterArn.");
1181
+ }
1182
+ let body: any;
1183
+ body = JSON.stringify({
1184
+ ...(input.ClientAuthentication !== undefined &&
1185
+ input.ClientAuthentication !== null && {
1186
+ clientAuthentication: serializeAws_restJson1ClientAuthentication(input.ClientAuthentication, context),
1187
+ }),
1188
+ ...(input.CurrentVersion !== undefined &&
1189
+ input.CurrentVersion !== null && { currentVersion: input.CurrentVersion }),
1190
+ ...(input.EncryptionInfo !== undefined &&
1191
+ input.EncryptionInfo !== null && {
1192
+ encryptionInfo: serializeAws_restJson1EncryptionInfo(input.EncryptionInfo, context),
1193
+ }),
1194
+ });
1195
+ return new __HttpRequest({
1196
+ protocol,
1197
+ hostname,
1198
+ port,
1199
+ method: "PATCH",
1200
+ headers,
1201
+ path: resolvedPath,
1202
+ body,
1203
+ });
1204
+ };
1205
+
1160
1206
  export const deserializeAws_restJson1BatchAssociateScramSecretCommand = async (
1161
1207
  output: __HttpResponse,
1162
1208
  context: __SerdeContext
@@ -1508,7 +1554,7 @@ export const deserializeAws_restJson1CreateConfigurationCommand = async (
1508
1554
  contents.Arn = __expectString(data.arn);
1509
1555
  }
1510
1556
  if (data.creationTime !== undefined && data.creationTime !== null) {
1511
- contents.CreationTime = new Date(data.creationTime);
1557
+ contents.CreationTime = __expectNonNull(__parseRfc3339DateTime(data.creationTime));
1512
1558
  }
1513
1559
  if (data.latestRevision !== undefined && data.latestRevision !== null) {
1514
1560
  contents.LatestRevision = deserializeAws_restJson1ConfigurationRevision(data.latestRevision, context);
@@ -1969,7 +2015,7 @@ export const deserializeAws_restJson1DescribeConfigurationCommand = async (
1969
2015
  contents.Arn = __expectString(data.arn);
1970
2016
  }
1971
2017
  if (data.creationTime !== undefined && data.creationTime !== null) {
1972
- contents.CreationTime = new Date(data.creationTime);
2018
+ contents.CreationTime = __expectNonNull(__parseRfc3339DateTime(data.creationTime));
1973
2019
  }
1974
2020
  if (data.description !== undefined && data.description !== null) {
1975
2021
  contents.Description = __expectString(data.description);
@@ -2086,7 +2132,7 @@ export const deserializeAws_restJson1DescribeConfigurationRevisionCommand = asyn
2086
2132
  contents.Arn = __expectString(data.arn);
2087
2133
  }
2088
2134
  if (data.creationTime !== undefined && data.creationTime !== null) {
2089
- contents.CreationTime = new Date(data.creationTime);
2135
+ contents.CreationTime = __expectNonNull(__parseRfc3339DateTime(data.creationTime));
2090
2136
  }
2091
2137
  if (data.description !== undefined && data.description !== null) {
2092
2138
  contents.Description = __expectString(data.description);
@@ -4011,6 +4057,113 @@ const deserializeAws_restJson1UpdateMonitoringCommandError = async (
4011
4057
  return Promise.reject(Object.assign(new Error(message), response));
4012
4058
  };
4013
4059
 
4060
+ export const deserializeAws_restJson1UpdateSecurityCommand = async (
4061
+ output: __HttpResponse,
4062
+ context: __SerdeContext
4063
+ ): Promise<UpdateSecurityCommandOutput> => {
4064
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
4065
+ return deserializeAws_restJson1UpdateSecurityCommandError(output, context);
4066
+ }
4067
+ const contents: UpdateSecurityCommandOutput = {
4068
+ $metadata: deserializeMetadata(output),
4069
+ ClusterArn: undefined,
4070
+ ClusterOperationArn: undefined,
4071
+ };
4072
+ const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
4073
+ if (data.clusterArn !== undefined && data.clusterArn !== null) {
4074
+ contents.ClusterArn = __expectString(data.clusterArn);
4075
+ }
4076
+ if (data.clusterOperationArn !== undefined && data.clusterOperationArn !== null) {
4077
+ contents.ClusterOperationArn = __expectString(data.clusterOperationArn);
4078
+ }
4079
+ return Promise.resolve(contents);
4080
+ };
4081
+
4082
+ const deserializeAws_restJson1UpdateSecurityCommandError = async (
4083
+ output: __HttpResponse,
4084
+ context: __SerdeContext
4085
+ ): Promise<UpdateSecurityCommandOutput> => {
4086
+ const parsedOutput: any = {
4087
+ ...output,
4088
+ body: await parseBody(output.body, context),
4089
+ };
4090
+ let response: __SmithyException & __MetadataBearer & { [key: string]: any };
4091
+ let errorCode: string = "UnknownError";
4092
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4093
+ switch (errorCode) {
4094
+ case "BadRequestException":
4095
+ case "com.amazonaws.kafka#BadRequestException":
4096
+ response = {
4097
+ ...(await deserializeAws_restJson1BadRequestExceptionResponse(parsedOutput, context)),
4098
+ name: errorCode,
4099
+ $metadata: deserializeMetadata(output),
4100
+ };
4101
+ break;
4102
+ case "ForbiddenException":
4103
+ case "com.amazonaws.kafka#ForbiddenException":
4104
+ response = {
4105
+ ...(await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)),
4106
+ name: errorCode,
4107
+ $metadata: deserializeMetadata(output),
4108
+ };
4109
+ break;
4110
+ case "InternalServerErrorException":
4111
+ case "com.amazonaws.kafka#InternalServerErrorException":
4112
+ response = {
4113
+ ...(await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)),
4114
+ name: errorCode,
4115
+ $metadata: deserializeMetadata(output),
4116
+ };
4117
+ break;
4118
+ case "NotFoundException":
4119
+ case "com.amazonaws.kafka#NotFoundException":
4120
+ response = {
4121
+ ...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
4122
+ name: errorCode,
4123
+ $metadata: deserializeMetadata(output),
4124
+ };
4125
+ break;
4126
+ case "ServiceUnavailableException":
4127
+ case "com.amazonaws.kafka#ServiceUnavailableException":
4128
+ response = {
4129
+ ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)),
4130
+ name: errorCode,
4131
+ $metadata: deserializeMetadata(output),
4132
+ };
4133
+ break;
4134
+ case "TooManyRequestsException":
4135
+ case "com.amazonaws.kafka#TooManyRequestsException":
4136
+ response = {
4137
+ ...(await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)),
4138
+ name: errorCode,
4139
+ $metadata: deserializeMetadata(output),
4140
+ };
4141
+ break;
4142
+ case "UnauthorizedException":
4143
+ case "com.amazonaws.kafka#UnauthorizedException":
4144
+ response = {
4145
+ ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)),
4146
+ name: errorCode,
4147
+ $metadata: deserializeMetadata(output),
4148
+ };
4149
+ break;
4150
+ default:
4151
+ const parsedBody = parsedOutput.body;
4152
+ errorCode = parsedBody.code || parsedBody.Code || errorCode;
4153
+ response = {
4154
+ ...parsedBody,
4155
+ name: `${errorCode}`,
4156
+ message: parsedBody.message || parsedBody.Message || errorCode,
4157
+ $fault: "client",
4158
+ $metadata: deserializeMetadata(output),
4159
+ } as any;
4160
+ }
4161
+ const message = response.message || response.Message || errorCode;
4162
+ response.message = message;
4163
+ delete response.Message;
4164
+ return Promise.reject(Object.assign(new Error(message), response));
4165
+ };
4166
+
4014
4167
  const deserializeAws_restJson1BadRequestExceptionResponse = async (
4015
4168
  parsedOutput: any,
4016
4169
  context: __SerdeContext
@@ -4258,6 +4411,10 @@ const serializeAws_restJson1ClientAuthentication = (input: ClientAuthentication,
4258
4411
  return {
4259
4412
  ...(input.Sasl !== undefined && input.Sasl !== null && { sasl: serializeAws_restJson1Sasl(input.Sasl, context) }),
4260
4413
  ...(input.Tls !== undefined && input.Tls !== null && { tls: serializeAws_restJson1Tls(input.Tls, context) }),
4414
+ ...(input.Unauthenticated !== undefined &&
4415
+ input.Unauthenticated !== null && {
4416
+ unauthenticated: serializeAws_restJson1Unauthenticated(input.Unauthenticated, context),
4417
+ }),
4261
4418
  };
4262
4419
  };
4263
4420
 
@@ -4398,6 +4555,13 @@ const serializeAws_restJson1Tls = (input: Tls, context: __SerdeContext): any =>
4398
4555
  input.CertificateAuthorityArnList !== null && {
4399
4556
  certificateAuthorityArnList: serializeAws_restJson1__listOf__string(input.CertificateAuthorityArnList, context),
4400
4557
  }),
4558
+ ...(input.Enabled !== undefined && input.Enabled !== null && { enabled: input.Enabled }),
4559
+ };
4560
+ };
4561
+
4562
+ const serializeAws_restJson1Unauthenticated = (input: Unauthenticated, context: __SerdeContext): any => {
4563
+ return {
4564
+ ...(input.Enabled !== undefined && input.Enabled !== null && { enabled: input.Enabled }),
4401
4565
  };
4402
4566
  };
4403
4567
 
@@ -4624,6 +4788,10 @@ const deserializeAws_restJson1ClientAuthentication = (output: any, context: __Se
4624
4788
  ? deserializeAws_restJson1Sasl(output.sasl, context)
4625
4789
  : undefined,
4626
4790
  Tls: output.tls !== undefined && output.tls !== null ? deserializeAws_restJson1Tls(output.tls, context) : undefined,
4791
+ Unauthenticated:
4792
+ output.unauthenticated !== undefined && output.unauthenticated !== null
4793
+ ? deserializeAws_restJson1Unauthenticated(output.unauthenticated, context)
4794
+ : undefined,
4627
4795
  } as any;
4628
4796
  };
4629
4797
 
@@ -4648,7 +4816,9 @@ const deserializeAws_restJson1ClusterInfo = (output: any, context: __SerdeContex
4648
4816
  ClusterArn: __expectString(output.clusterArn),
4649
4817
  ClusterName: __expectString(output.clusterName),
4650
4818
  CreationTime:
4651
- output.creationTime !== undefined && output.creationTime !== null ? new Date(output.creationTime) : undefined,
4819
+ output.creationTime !== undefined && output.creationTime !== null
4820
+ ? __expectNonNull(__parseRfc3339DateTime(output.creationTime))
4821
+ : undefined,
4652
4822
  CurrentBrokerSoftwareInfo:
4653
4823
  output.currentBrokerSoftwareInfo !== undefined && output.currentBrokerSoftwareInfo !== null
4654
4824
  ? deserializeAws_restJson1BrokerSoftwareInfo(output.currentBrokerSoftwareInfo, context)
@@ -4687,8 +4857,13 @@ const deserializeAws_restJson1ClusterOperationInfo = (output: any, context: __Se
4687
4857
  ClientRequestId: __expectString(output.clientRequestId),
4688
4858
  ClusterArn: __expectString(output.clusterArn),
4689
4859
  CreationTime:
4690
- output.creationTime !== undefined && output.creationTime !== null ? new Date(output.creationTime) : undefined,
4691
- EndTime: output.endTime !== undefined && output.endTime !== null ? new Date(output.endTime) : undefined,
4860
+ output.creationTime !== undefined && output.creationTime !== null
4861
+ ? __expectNonNull(__parseRfc3339DateTime(output.creationTime))
4862
+ : undefined,
4863
+ EndTime:
4864
+ output.endTime !== undefined && output.endTime !== null
4865
+ ? __expectNonNull(__parseRfc3339DateTime(output.endTime))
4866
+ : undefined,
4692
4867
  ErrorInfo:
4693
4868
  output.errorInfo !== undefined && output.errorInfo !== null
4694
4869
  ? deserializeAws_restJson1ErrorInfo(output.errorInfo, context)
@@ -4747,7 +4922,9 @@ const deserializeAws_restJson1Configuration = (output: any, context: __SerdeCont
4747
4922
  return {
4748
4923
  Arn: __expectString(output.arn),
4749
4924
  CreationTime:
4750
- output.creationTime !== undefined && output.creationTime !== null ? new Date(output.creationTime) : undefined,
4925
+ output.creationTime !== undefined && output.creationTime !== null
4926
+ ? __expectNonNull(__parseRfc3339DateTime(output.creationTime))
4927
+ : undefined,
4751
4928
  Description: __expectString(output.description),
4752
4929
  KafkaVersions:
4753
4930
  output.kafkaVersions !== undefined && output.kafkaVersions !== null
@@ -4772,7 +4949,9 @@ const deserializeAws_restJson1ConfigurationInfo = (output: any, context: __Serde
4772
4949
  const deserializeAws_restJson1ConfigurationRevision = (output: any, context: __SerdeContext): ConfigurationRevision => {
4773
4950
  return {
4774
4951
  CreationTime:
4775
- output.creationTime !== undefined && output.creationTime !== null ? new Date(output.creationTime) : undefined,
4952
+ output.creationTime !== undefined && output.creationTime !== null
4953
+ ? __expectNonNull(__parseRfc3339DateTime(output.creationTime))
4954
+ : undefined,
4776
4955
  Description: __expectString(output.description),
4777
4956
  Revision: __expectLong(output.revision),
4778
4957
  } as any;
@@ -4858,10 +5037,18 @@ const deserializeAws_restJson1MutableClusterInfo = (output: any, context: __Serd
4858
5037
  output.brokerEBSVolumeInfo !== undefined && output.brokerEBSVolumeInfo !== null
4859
5038
  ? deserializeAws_restJson1__listOfBrokerEBSVolumeInfo(output.brokerEBSVolumeInfo, context)
4860
5039
  : undefined,
5040
+ ClientAuthentication:
5041
+ output.clientAuthentication !== undefined && output.clientAuthentication !== null
5042
+ ? deserializeAws_restJson1ClientAuthentication(output.clientAuthentication, context)
5043
+ : undefined,
4861
5044
  ConfigurationInfo:
4862
5045
  output.configurationInfo !== undefined && output.configurationInfo !== null
4863
5046
  ? deserializeAws_restJson1ConfigurationInfo(output.configurationInfo, context)
4864
5047
  : undefined,
5048
+ EncryptionInfo:
5049
+ output.encryptionInfo !== undefined && output.encryptionInfo !== null
5050
+ ? deserializeAws_restJson1EncryptionInfo(output.encryptionInfo, context)
5051
+ : undefined,
4865
5052
  EnhancedMonitoring: __expectString(output.enhancedMonitoring),
4866
5053
  InstanceType: __expectString(output.instanceType),
4867
5054
  KafkaVersion: __expectString(output.kafkaVersion),
@@ -4968,6 +5155,13 @@ const deserializeAws_restJson1Tls = (output: any, context: __SerdeContext): Tls
4968
5155
  output.certificateAuthorityArnList !== undefined && output.certificateAuthorityArnList !== null
4969
5156
  ? deserializeAws_restJson1__listOf__string(output.certificateAuthorityArnList, context)
4970
5157
  : undefined,
5158
+ Enabled: __expectBoolean(output.enabled),
5159
+ } as any;
5160
+ };
5161
+
5162
+ const deserializeAws_restJson1Unauthenticated = (output: any, context: __SerdeContext): Unauthenticated => {
5163
+ return {
5164
+ Enabled: __expectBoolean(output.enabled),
4971
5165
  } as any;
4972
5166
  };
4973
5167
 
package/tsconfig.json CHANGED
@@ -13,8 +13,7 @@
13
13
  "resolveJsonModule": true,
14
14
  "esModuleInterop": true,
15
15
  "declarationDir": "./dist/types",
16
- "outDir": "dist/cjs",
17
- "useUnknownInCatchVariables": false
16
+ "outDir": "dist/cjs"
18
17
  },
19
18
  "typedocOptions": {
20
19
  "exclude": ["**/node_modules/**", "**/*.spec.ts", "**/protocols/*.ts", "**/e2e/*.ts", "**/endpoints.ts"],