@aws-sdk/client-firehose 3.32.0 → 3.36.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 (176) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/{dist/cjs → dist-cjs}/Firehose.js +1 -2
  3. package/{dist/cjs → dist-cjs}/FirehoseClient.js +8 -9
  4. package/{dist/cjs → dist-cjs}/commands/CreateDeliveryStreamCommand.js +2 -3
  5. package/{dist/cjs → dist-cjs}/commands/DeleteDeliveryStreamCommand.js +2 -3
  6. package/{dist/cjs → dist-cjs}/commands/DescribeDeliveryStreamCommand.js +2 -3
  7. package/{dist/cjs → dist-cjs}/commands/ListDeliveryStreamsCommand.js +2 -3
  8. package/{dist/cjs → dist-cjs}/commands/ListTagsForDeliveryStreamCommand.js +2 -3
  9. package/{dist/cjs → dist-cjs}/commands/PutRecordBatchCommand.js +2 -3
  10. package/{dist/cjs → dist-cjs}/commands/PutRecordCommand.js +2 -3
  11. package/{dist/cjs → dist-cjs}/commands/StartDeliveryStreamEncryptionCommand.js +2 -3
  12. package/{dist/cjs → dist-cjs}/commands/StopDeliveryStreamEncryptionCommand.js +2 -3
  13. package/{dist/cjs → dist-cjs}/commands/TagDeliveryStreamCommand.js +2 -3
  14. package/{dist/cjs → dist-cjs}/commands/UntagDeliveryStreamCommand.js +2 -3
  15. package/{dist/cjs → dist-cjs}/commands/UpdateDestinationCommand.js +2 -3
  16. package/{dist/cjs → dist-cjs}/endpoints.js +0 -1
  17. package/{dist/cjs → dist-cjs}/index.js +0 -1
  18. package/{dist/cjs → dist-cjs}/models/index.js +0 -1
  19. package/{dist/cjs → dist-cjs}/models/models_0.js +150 -93
  20. package/{dist/cjs → dist-cjs}/protocols/Aws_json1_1.js +132 -1
  21. package/{dist/cjs → dist-cjs}/runtimeConfig.browser.js +2 -2
  22. package/{dist/cjs → dist-cjs}/runtimeConfig.js +2 -2
  23. package/{dist/cjs → dist-cjs}/runtimeConfig.native.js +0 -1
  24. package/{dist/cjs → dist-cjs}/runtimeConfig.shared.js +1 -2
  25. package/{dist/es → dist-es}/Firehose.js +2 -9
  26. package/{dist/es → dist-es}/FirehoseClient.js +2 -14
  27. package/dist-es/commands/CreateDeliveryStreamCommand.js +39 -0
  28. package/dist-es/commands/DeleteDeliveryStreamCommand.js +39 -0
  29. package/{dist/es → dist-es}/commands/DescribeDeliveryStreamCommand.js +4 -36
  30. package/{dist/es → dist-es}/commands/ListDeliveryStreamsCommand.js +4 -37
  31. package/{dist/es → dist-es}/commands/ListTagsForDeliveryStreamCommand.js +4 -31
  32. package/dist-es/commands/PutRecordBatchCommand.js +39 -0
  33. package/dist-es/commands/PutRecordCommand.js +39 -0
  34. package/dist-es/commands/StartDeliveryStreamEncryptionCommand.js +39 -0
  35. package/dist-es/commands/StopDeliveryStreamEncryptionCommand.js +39 -0
  36. package/dist-es/commands/TagDeliveryStreamCommand.js +39 -0
  37. package/{dist/es → dist-es}/commands/UntagDeliveryStreamCommand.js +4 -33
  38. package/dist-es/commands/UpdateDestinationCommand.js +39 -0
  39. package/{dist/es → dist-es}/endpoints.js +1 -2
  40. package/{dist/types/index.d.ts → dist-es/index.js} +0 -0
  41. package/{dist/types/models/index.d.ts → dist-es/models/index.js} +0 -0
  42. package/{dist/es → dist-es}/models/models_0.js +87 -331
  43. package/{dist/es → dist-es}/protocols/Aws_json1_1.js +349 -256
  44. package/{dist/es → dist-es}/runtimeConfig.browser.js +1 -5
  45. package/{dist/es → dist-es}/runtimeConfig.js +1 -5
  46. package/{dist/es → dist-es}/runtimeConfig.native.js +0 -4
  47. package/{dist/es → dist-es}/runtimeConfig.shared.js +1 -5
  48. package/{dist/types → dist-types}/Firehose.d.ts +2 -2
  49. package/{dist/types → dist-types}/FirehoseClient.d.ts +8 -8
  50. package/{dist/types → dist-types}/commands/CreateDeliveryStreamCommand.d.ts +2 -2
  51. package/{dist/types → dist-types}/commands/DeleteDeliveryStreamCommand.d.ts +2 -2
  52. package/{dist/types → dist-types}/commands/DescribeDeliveryStreamCommand.d.ts +2 -2
  53. package/{dist/types → dist-types}/commands/ListDeliveryStreamsCommand.d.ts +2 -2
  54. package/{dist/types → dist-types}/commands/ListTagsForDeliveryStreamCommand.d.ts +2 -2
  55. package/{dist/types → dist-types}/commands/PutRecordBatchCommand.d.ts +2 -2
  56. package/{dist/types → dist-types}/commands/PutRecordCommand.d.ts +2 -2
  57. package/{dist/types → dist-types}/commands/StartDeliveryStreamEncryptionCommand.d.ts +2 -2
  58. package/{dist/types → dist-types}/commands/StopDeliveryStreamEncryptionCommand.d.ts +2 -2
  59. package/{dist/types → dist-types}/commands/TagDeliveryStreamCommand.d.ts +2 -2
  60. package/{dist/types → dist-types}/commands/UntagDeliveryStreamCommand.d.ts +2 -2
  61. package/{dist/types → dist-types}/commands/UpdateDestinationCommand.d.ts +2 -2
  62. package/{dist/types → dist-types}/endpoints.d.ts +0 -0
  63. package/{index.ts → dist-types/index.d.ts} +0 -0
  64. package/{models/index.ts → dist-types/models/index.d.ts} +0 -0
  65. package/{dist/types → dist-types}/models/models_0.d.ts +524 -397
  66. package/{dist/types → dist-types}/protocols/Aws_json1_1.d.ts +2 -2
  67. package/{dist/types/ts3.4 → dist-types}/runtimeConfig.browser.d.ts +37 -36
  68. package/{dist/types/ts3.4 → dist-types}/runtimeConfig.d.ts +37 -36
  69. package/{dist/types → dist-types}/runtimeConfig.native.d.ts +1 -0
  70. package/{dist/types → dist-types}/runtimeConfig.shared.d.ts +0 -0
  71. package/{dist/types → dist-types}/ts3.4/Firehose.d.ts +2 -2
  72. package/{dist/types → dist-types}/ts3.4/FirehoseClient.d.ts +8 -8
  73. package/{dist/types → dist-types}/ts3.4/commands/CreateDeliveryStreamCommand.d.ts +2 -2
  74. package/{dist/types → dist-types}/ts3.4/commands/DeleteDeliveryStreamCommand.d.ts +2 -2
  75. package/{dist/types → dist-types}/ts3.4/commands/DescribeDeliveryStreamCommand.d.ts +2 -2
  76. package/{dist/types → dist-types}/ts3.4/commands/ListDeliveryStreamsCommand.d.ts +2 -2
  77. package/{dist/types → dist-types}/ts3.4/commands/ListTagsForDeliveryStreamCommand.d.ts +2 -2
  78. package/{dist/types → dist-types}/ts3.4/commands/PutRecordBatchCommand.d.ts +2 -2
  79. package/{dist/types → dist-types}/ts3.4/commands/PutRecordCommand.d.ts +2 -2
  80. package/{dist/types → dist-types}/ts3.4/commands/StartDeliveryStreamEncryptionCommand.d.ts +2 -2
  81. package/{dist/types → dist-types}/ts3.4/commands/StopDeliveryStreamEncryptionCommand.d.ts +2 -2
  82. package/{dist/types → dist-types}/ts3.4/commands/TagDeliveryStreamCommand.d.ts +2 -2
  83. package/{dist/types → dist-types}/ts3.4/commands/UntagDeliveryStreamCommand.d.ts +2 -2
  84. package/{dist/types → dist-types}/ts3.4/commands/UpdateDestinationCommand.d.ts +2 -2
  85. package/{dist/types → dist-types}/ts3.4/endpoints.d.ts +0 -0
  86. package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
  87. package/{dist/types → dist-types}/ts3.4/models/index.d.ts +0 -0
  88. package/{dist/types → dist-types}/ts3.4/models/models_0.d.ts +524 -397
  89. package/{dist/types → dist-types}/ts3.4/protocols/Aws_json1_1.d.ts +2 -2
  90. package/{dist/types → dist-types/ts3.4}/runtimeConfig.browser.d.ts +37 -36
  91. package/{dist/types → dist-types/ts3.4}/runtimeConfig.d.ts +37 -36
  92. package/{dist/types → dist-types}/ts3.4/runtimeConfig.native.d.ts +1 -0
  93. package/{dist/types → dist-types}/ts3.4/runtimeConfig.shared.d.ts +0 -0
  94. package/package.json +52 -49
  95. package/Firehose.ts +0 -704
  96. package/FirehoseClient.ts +0 -298
  97. package/commands/CreateDeliveryStreamCommand.ts +0 -162
  98. package/commands/DeleteDeliveryStreamCommand.ts +0 -103
  99. package/commands/DescribeDeliveryStreamCommand.ts +0 -100
  100. package/commands/ListDeliveryStreamsCommand.ts +0 -101
  101. package/commands/ListTagsForDeliveryStreamCommand.ts +0 -98
  102. package/commands/PutRecordBatchCommand.ts +0 -144
  103. package/commands/PutRecordCommand.ts +0 -122
  104. package/commands/StartDeliveryStreamEncryptionCommand.ts +0 -134
  105. package/commands/StopDeliveryStreamEncryptionCommand.ts +0 -118
  106. package/commands/TagDeliveryStreamCommand.ts +0 -102
  107. package/commands/UntagDeliveryStreamCommand.ts +0 -97
  108. package/commands/UpdateDestinationCommand.ts +0 -117
  109. package/dist/cjs/Firehose.js.map +0 -1
  110. package/dist/cjs/FirehoseClient.js.map +0 -1
  111. package/dist/cjs/commands/CreateDeliveryStreamCommand.js.map +0 -1
  112. package/dist/cjs/commands/DeleteDeliveryStreamCommand.js.map +0 -1
  113. package/dist/cjs/commands/DescribeDeliveryStreamCommand.js.map +0 -1
  114. package/dist/cjs/commands/ListDeliveryStreamsCommand.js.map +0 -1
  115. package/dist/cjs/commands/ListTagsForDeliveryStreamCommand.js.map +0 -1
  116. package/dist/cjs/commands/PutRecordBatchCommand.js.map +0 -1
  117. package/dist/cjs/commands/PutRecordCommand.js.map +0 -1
  118. package/dist/cjs/commands/StartDeliveryStreamEncryptionCommand.js.map +0 -1
  119. package/dist/cjs/commands/StopDeliveryStreamEncryptionCommand.js.map +0 -1
  120. package/dist/cjs/commands/TagDeliveryStreamCommand.js.map +0 -1
  121. package/dist/cjs/commands/UntagDeliveryStreamCommand.js.map +0 -1
  122. package/dist/cjs/commands/UpdateDestinationCommand.js.map +0 -1
  123. package/dist/cjs/endpoints.js.map +0 -1
  124. package/dist/cjs/index.js.map +0 -1
  125. package/dist/cjs/models/index.js.map +0 -1
  126. package/dist/cjs/models/models_0.js.map +0 -1
  127. package/dist/cjs/package.json +0 -91
  128. package/dist/cjs/protocols/Aws_json1_1.js.map +0 -1
  129. package/dist/cjs/runtimeConfig.browser.js.map +0 -1
  130. package/dist/cjs/runtimeConfig.js.map +0 -1
  131. package/dist/cjs/runtimeConfig.native.js.map +0 -1
  132. package/dist/cjs/runtimeConfig.shared.js.map +0 -1
  133. package/dist/es/Firehose.js.map +0 -1
  134. package/dist/es/FirehoseClient.js.map +0 -1
  135. package/dist/es/commands/CreateDeliveryStreamCommand.js +0 -133
  136. package/dist/es/commands/CreateDeliveryStreamCommand.js.map +0 -1
  137. package/dist/es/commands/DeleteDeliveryStreamCommand.js +0 -74
  138. package/dist/es/commands/DeleteDeliveryStreamCommand.js.map +0 -1
  139. package/dist/es/commands/DescribeDeliveryStreamCommand.js.map +0 -1
  140. package/dist/es/commands/ListDeliveryStreamsCommand.js.map +0 -1
  141. package/dist/es/commands/ListTagsForDeliveryStreamCommand.js.map +0 -1
  142. package/dist/es/commands/PutRecordBatchCommand.js +0 -115
  143. package/dist/es/commands/PutRecordBatchCommand.js.map +0 -1
  144. package/dist/es/commands/PutRecordCommand.js +0 -96
  145. package/dist/es/commands/PutRecordCommand.js.map +0 -1
  146. package/dist/es/commands/StartDeliveryStreamEncryptionCommand.js +0 -100
  147. package/dist/es/commands/StartDeliveryStreamEncryptionCommand.js.map +0 -1
  148. package/dist/es/commands/StopDeliveryStreamEncryptionCommand.js +0 -84
  149. package/dist/es/commands/StopDeliveryStreamEncryptionCommand.js.map +0 -1
  150. package/dist/es/commands/TagDeliveryStreamCommand.js +0 -73
  151. package/dist/es/commands/TagDeliveryStreamCommand.js.map +0 -1
  152. package/dist/es/commands/UntagDeliveryStreamCommand.js.map +0 -1
  153. package/dist/es/commands/UpdateDestinationCommand.js +0 -88
  154. package/dist/es/commands/UpdateDestinationCommand.js.map +0 -1
  155. package/dist/es/endpoints.js.map +0 -1
  156. package/dist/es/index.js +0 -16
  157. package/dist/es/index.js.map +0 -1
  158. package/dist/es/models/index.js +0 -2
  159. package/dist/es/models/index.js.map +0 -1
  160. package/dist/es/models/models_0.js.map +0 -1
  161. package/dist/es/package.json +0 -91
  162. package/dist/es/protocols/Aws_json1_1.js.map +0 -1
  163. package/dist/es/runtimeConfig.browser.js.map +0 -1
  164. package/dist/es/runtimeConfig.js.map +0 -1
  165. package/dist/es/runtimeConfig.native.js.map +0 -1
  166. package/dist/es/runtimeConfig.shared.js.map +0 -1
  167. package/endpoints.ts +0 -86
  168. package/jest.config.js +0 -4
  169. package/models/models_0.ts +0 -3952
  170. package/protocols/Aws_json1_1.ts +0 -3513
  171. package/runtimeConfig.browser.ts +0 -40
  172. package/runtimeConfig.native.ts +0 -16
  173. package/runtimeConfig.shared.ts +0 -16
  174. package/runtimeConfig.ts +0 -45
  175. package/tsconfig.es.json +0 -12
  176. package/tsconfig.json +0 -32
@@ -1,3513 +0,0 @@
1
- import {
2
- CreateDeliveryStreamCommandInput,
3
- CreateDeliveryStreamCommandOutput,
4
- } from "../commands/CreateDeliveryStreamCommand";
5
- import {
6
- DeleteDeliveryStreamCommandInput,
7
- DeleteDeliveryStreamCommandOutput,
8
- } from "../commands/DeleteDeliveryStreamCommand";
9
- import {
10
- DescribeDeliveryStreamCommandInput,
11
- DescribeDeliveryStreamCommandOutput,
12
- } from "../commands/DescribeDeliveryStreamCommand";
13
- import {
14
- ListDeliveryStreamsCommandInput,
15
- ListDeliveryStreamsCommandOutput,
16
- } from "../commands/ListDeliveryStreamsCommand";
17
- import {
18
- ListTagsForDeliveryStreamCommandInput,
19
- ListTagsForDeliveryStreamCommandOutput,
20
- } from "../commands/ListTagsForDeliveryStreamCommand";
21
- import { PutRecordBatchCommandInput, PutRecordBatchCommandOutput } from "../commands/PutRecordBatchCommand";
22
- import { PutRecordCommandInput, PutRecordCommandOutput } from "../commands/PutRecordCommand";
23
- import {
24
- StartDeliveryStreamEncryptionCommandInput,
25
- StartDeliveryStreamEncryptionCommandOutput,
26
- } from "../commands/StartDeliveryStreamEncryptionCommand";
27
- import {
28
- StopDeliveryStreamEncryptionCommandInput,
29
- StopDeliveryStreamEncryptionCommandOutput,
30
- } from "../commands/StopDeliveryStreamEncryptionCommand";
31
- import { TagDeliveryStreamCommandInput, TagDeliveryStreamCommandOutput } from "../commands/TagDeliveryStreamCommand";
32
- import {
33
- UntagDeliveryStreamCommandInput,
34
- UntagDeliveryStreamCommandOutput,
35
- } from "../commands/UntagDeliveryStreamCommand";
36
- import { UpdateDestinationCommandInput, UpdateDestinationCommandOutput } from "../commands/UpdateDestinationCommand";
37
- import {
38
- BufferingHints,
39
- CloudWatchLoggingOptions,
40
- ConcurrentModificationException,
41
- CopyCommand,
42
- CreateDeliveryStreamInput,
43
- CreateDeliveryStreamOutput,
44
- DataFormatConversionConfiguration,
45
- DeleteDeliveryStreamInput,
46
- DeleteDeliveryStreamOutput,
47
- DeliveryStreamDescription,
48
- DeliveryStreamEncryptionConfiguration,
49
- DeliveryStreamEncryptionConfigurationInput,
50
- DescribeDeliveryStreamInput,
51
- DescribeDeliveryStreamOutput,
52
- Deserializer,
53
- DestinationDescription,
54
- DynamicPartitioningConfiguration,
55
- ElasticsearchBufferingHints,
56
- ElasticsearchDestinationConfiguration,
57
- ElasticsearchDestinationDescription,
58
- ElasticsearchDestinationUpdate,
59
- ElasticsearchRetryOptions,
60
- EncryptionConfiguration,
61
- ExtendedS3DestinationConfiguration,
62
- ExtendedS3DestinationDescription,
63
- ExtendedS3DestinationUpdate,
64
- FailureDescription,
65
- HiveJsonSerDe,
66
- HttpEndpointBufferingHints,
67
- HttpEndpointCommonAttribute,
68
- HttpEndpointConfiguration,
69
- HttpEndpointDescription,
70
- HttpEndpointDestinationConfiguration,
71
- HttpEndpointDestinationDescription,
72
- HttpEndpointDestinationUpdate,
73
- HttpEndpointRequestConfiguration,
74
- HttpEndpointRetryOptions,
75
- InputFormatConfiguration,
76
- InvalidArgumentException,
77
- InvalidKMSResourceException,
78
- KMSEncryptionConfig,
79
- KinesisStreamSourceConfiguration,
80
- KinesisStreamSourceDescription,
81
- LimitExceededException,
82
- ListDeliveryStreamsInput,
83
- ListDeliveryStreamsOutput,
84
- ListTagsForDeliveryStreamInput,
85
- ListTagsForDeliveryStreamOutput,
86
- OpenXJsonSerDe,
87
- OrcSerDe,
88
- OutputFormatConfiguration,
89
- ParquetSerDe,
90
- ProcessingConfiguration,
91
- Processor,
92
- ProcessorParameter,
93
- PutRecordBatchInput,
94
- PutRecordBatchOutput,
95
- PutRecordBatchResponseEntry,
96
- PutRecordInput,
97
- PutRecordOutput,
98
- RedshiftDestinationConfiguration,
99
- RedshiftDestinationDescription,
100
- RedshiftDestinationUpdate,
101
- RedshiftRetryOptions,
102
- ResourceInUseException,
103
- ResourceNotFoundException,
104
- RetryOptions,
105
- S3DestinationConfiguration,
106
- S3DestinationDescription,
107
- S3DestinationUpdate,
108
- SchemaConfiguration,
109
- Serializer,
110
- ServiceUnavailableException,
111
- SourceDescription,
112
- SplunkDestinationConfiguration,
113
- SplunkDestinationDescription,
114
- SplunkDestinationUpdate,
115
- SplunkRetryOptions,
116
- StartDeliveryStreamEncryptionInput,
117
- StartDeliveryStreamEncryptionOutput,
118
- StopDeliveryStreamEncryptionInput,
119
- StopDeliveryStreamEncryptionOutput,
120
- Tag,
121
- TagDeliveryStreamInput,
122
- TagDeliveryStreamOutput,
123
- UntagDeliveryStreamInput,
124
- UntagDeliveryStreamOutput,
125
- UpdateDestinationInput,
126
- UpdateDestinationOutput,
127
- VpcConfiguration,
128
- VpcConfigurationDescription,
129
- _Record,
130
- } from "../models/models_0";
131
- import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
132
- import {
133
- expectBoolean as __expectBoolean,
134
- expectInt32 as __expectInt32,
135
- expectNonNull as __expectNonNull,
136
- expectNumber as __expectNumber,
137
- expectString as __expectString,
138
- limitedParseDouble as __limitedParseDouble,
139
- parseEpochTimestamp as __parseEpochTimestamp,
140
- serializeFloat as __serializeFloat,
141
- } from "@aws-sdk/smithy-client";
142
- import {
143
- Endpoint as __Endpoint,
144
- HeaderBag as __HeaderBag,
145
- MetadataBearer as __MetadataBearer,
146
- ResponseMetadata as __ResponseMetadata,
147
- SerdeContext as __SerdeContext,
148
- SmithyException as __SmithyException,
149
- } from "@aws-sdk/types";
150
-
151
- export const serializeAws_json1_1CreateDeliveryStreamCommand = async (
152
- input: CreateDeliveryStreamCommandInput,
153
- context: __SerdeContext
154
- ): Promise<__HttpRequest> => {
155
- const headers: __HeaderBag = {
156
- "content-type": "application/x-amz-json-1.1",
157
- "x-amz-target": "Firehose_20150804.CreateDeliveryStream",
158
- };
159
- let body: any;
160
- body = JSON.stringify(serializeAws_json1_1CreateDeliveryStreamInput(input, context));
161
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
162
- };
163
-
164
- export const serializeAws_json1_1DeleteDeliveryStreamCommand = async (
165
- input: DeleteDeliveryStreamCommandInput,
166
- context: __SerdeContext
167
- ): Promise<__HttpRequest> => {
168
- const headers: __HeaderBag = {
169
- "content-type": "application/x-amz-json-1.1",
170
- "x-amz-target": "Firehose_20150804.DeleteDeliveryStream",
171
- };
172
- let body: any;
173
- body = JSON.stringify(serializeAws_json1_1DeleteDeliveryStreamInput(input, context));
174
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
175
- };
176
-
177
- export const serializeAws_json1_1DescribeDeliveryStreamCommand = async (
178
- input: DescribeDeliveryStreamCommandInput,
179
- context: __SerdeContext
180
- ): Promise<__HttpRequest> => {
181
- const headers: __HeaderBag = {
182
- "content-type": "application/x-amz-json-1.1",
183
- "x-amz-target": "Firehose_20150804.DescribeDeliveryStream",
184
- };
185
- let body: any;
186
- body = JSON.stringify(serializeAws_json1_1DescribeDeliveryStreamInput(input, context));
187
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
188
- };
189
-
190
- export const serializeAws_json1_1ListDeliveryStreamsCommand = async (
191
- input: ListDeliveryStreamsCommandInput,
192
- context: __SerdeContext
193
- ): Promise<__HttpRequest> => {
194
- const headers: __HeaderBag = {
195
- "content-type": "application/x-amz-json-1.1",
196
- "x-amz-target": "Firehose_20150804.ListDeliveryStreams",
197
- };
198
- let body: any;
199
- body = JSON.stringify(serializeAws_json1_1ListDeliveryStreamsInput(input, context));
200
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
201
- };
202
-
203
- export const serializeAws_json1_1ListTagsForDeliveryStreamCommand = async (
204
- input: ListTagsForDeliveryStreamCommandInput,
205
- context: __SerdeContext
206
- ): Promise<__HttpRequest> => {
207
- const headers: __HeaderBag = {
208
- "content-type": "application/x-amz-json-1.1",
209
- "x-amz-target": "Firehose_20150804.ListTagsForDeliveryStream",
210
- };
211
- let body: any;
212
- body = JSON.stringify(serializeAws_json1_1ListTagsForDeliveryStreamInput(input, context));
213
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
214
- };
215
-
216
- export const serializeAws_json1_1PutRecordCommand = async (
217
- input: PutRecordCommandInput,
218
- context: __SerdeContext
219
- ): Promise<__HttpRequest> => {
220
- const headers: __HeaderBag = {
221
- "content-type": "application/x-amz-json-1.1",
222
- "x-amz-target": "Firehose_20150804.PutRecord",
223
- };
224
- let body: any;
225
- body = JSON.stringify(serializeAws_json1_1PutRecordInput(input, context));
226
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
227
- };
228
-
229
- export const serializeAws_json1_1PutRecordBatchCommand = async (
230
- input: PutRecordBatchCommandInput,
231
- context: __SerdeContext
232
- ): Promise<__HttpRequest> => {
233
- const headers: __HeaderBag = {
234
- "content-type": "application/x-amz-json-1.1",
235
- "x-amz-target": "Firehose_20150804.PutRecordBatch",
236
- };
237
- let body: any;
238
- body = JSON.stringify(serializeAws_json1_1PutRecordBatchInput(input, context));
239
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
240
- };
241
-
242
- export const serializeAws_json1_1StartDeliveryStreamEncryptionCommand = async (
243
- input: StartDeliveryStreamEncryptionCommandInput,
244
- context: __SerdeContext
245
- ): Promise<__HttpRequest> => {
246
- const headers: __HeaderBag = {
247
- "content-type": "application/x-amz-json-1.1",
248
- "x-amz-target": "Firehose_20150804.StartDeliveryStreamEncryption",
249
- };
250
- let body: any;
251
- body = JSON.stringify(serializeAws_json1_1StartDeliveryStreamEncryptionInput(input, context));
252
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
253
- };
254
-
255
- export const serializeAws_json1_1StopDeliveryStreamEncryptionCommand = async (
256
- input: StopDeliveryStreamEncryptionCommandInput,
257
- context: __SerdeContext
258
- ): Promise<__HttpRequest> => {
259
- const headers: __HeaderBag = {
260
- "content-type": "application/x-amz-json-1.1",
261
- "x-amz-target": "Firehose_20150804.StopDeliveryStreamEncryption",
262
- };
263
- let body: any;
264
- body = JSON.stringify(serializeAws_json1_1StopDeliveryStreamEncryptionInput(input, context));
265
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
266
- };
267
-
268
- export const serializeAws_json1_1TagDeliveryStreamCommand = async (
269
- input: TagDeliveryStreamCommandInput,
270
- context: __SerdeContext
271
- ): Promise<__HttpRequest> => {
272
- const headers: __HeaderBag = {
273
- "content-type": "application/x-amz-json-1.1",
274
- "x-amz-target": "Firehose_20150804.TagDeliveryStream",
275
- };
276
- let body: any;
277
- body = JSON.stringify(serializeAws_json1_1TagDeliveryStreamInput(input, context));
278
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
279
- };
280
-
281
- export const serializeAws_json1_1UntagDeliveryStreamCommand = async (
282
- input: UntagDeliveryStreamCommandInput,
283
- context: __SerdeContext
284
- ): Promise<__HttpRequest> => {
285
- const headers: __HeaderBag = {
286
- "content-type": "application/x-amz-json-1.1",
287
- "x-amz-target": "Firehose_20150804.UntagDeliveryStream",
288
- };
289
- let body: any;
290
- body = JSON.stringify(serializeAws_json1_1UntagDeliveryStreamInput(input, context));
291
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
292
- };
293
-
294
- export const serializeAws_json1_1UpdateDestinationCommand = async (
295
- input: UpdateDestinationCommandInput,
296
- context: __SerdeContext
297
- ): Promise<__HttpRequest> => {
298
- const headers: __HeaderBag = {
299
- "content-type": "application/x-amz-json-1.1",
300
- "x-amz-target": "Firehose_20150804.UpdateDestination",
301
- };
302
- let body: any;
303
- body = JSON.stringify(serializeAws_json1_1UpdateDestinationInput(input, context));
304
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
305
- };
306
-
307
- export const deserializeAws_json1_1CreateDeliveryStreamCommand = async (
308
- output: __HttpResponse,
309
- context: __SerdeContext
310
- ): Promise<CreateDeliveryStreamCommandOutput> => {
311
- if (output.statusCode >= 300) {
312
- return deserializeAws_json1_1CreateDeliveryStreamCommandError(output, context);
313
- }
314
- const data: any = await parseBody(output.body, context);
315
- let contents: any = {};
316
- contents = deserializeAws_json1_1CreateDeliveryStreamOutput(data, context);
317
- const response: CreateDeliveryStreamCommandOutput = {
318
- $metadata: deserializeMetadata(output),
319
- ...contents,
320
- };
321
- return Promise.resolve(response);
322
- };
323
-
324
- const deserializeAws_json1_1CreateDeliveryStreamCommandError = async (
325
- output: __HttpResponse,
326
- context: __SerdeContext
327
- ): Promise<CreateDeliveryStreamCommandOutput> => {
328
- const parsedOutput: any = {
329
- ...output,
330
- body: await parseBody(output.body, context),
331
- };
332
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
333
- let errorCode: string = "UnknownError";
334
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
335
- switch (errorCode) {
336
- case "InvalidArgumentException":
337
- case "com.amazonaws.firehose#InvalidArgumentException":
338
- response = {
339
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
340
- name: errorCode,
341
- $metadata: deserializeMetadata(output),
342
- };
343
- break;
344
- case "InvalidKMSResourceException":
345
- case "com.amazonaws.firehose#InvalidKMSResourceException":
346
- response = {
347
- ...(await deserializeAws_json1_1InvalidKMSResourceExceptionResponse(parsedOutput, context)),
348
- name: errorCode,
349
- $metadata: deserializeMetadata(output),
350
- };
351
- break;
352
- case "LimitExceededException":
353
- case "com.amazonaws.firehose#LimitExceededException":
354
- response = {
355
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
356
- name: errorCode,
357
- $metadata: deserializeMetadata(output),
358
- };
359
- break;
360
- case "ResourceInUseException":
361
- case "com.amazonaws.firehose#ResourceInUseException":
362
- response = {
363
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
364
- name: errorCode,
365
- $metadata: deserializeMetadata(output),
366
- };
367
- break;
368
- default:
369
- const parsedBody = parsedOutput.body;
370
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
371
- response = {
372
- ...parsedBody,
373
- name: `${errorCode}`,
374
- message: parsedBody.message || parsedBody.Message || errorCode,
375
- $fault: "client",
376
- $metadata: deserializeMetadata(output),
377
- } as any;
378
- }
379
- const message = response.message || response.Message || errorCode;
380
- response.message = message;
381
- delete response.Message;
382
- return Promise.reject(Object.assign(new Error(message), response));
383
- };
384
-
385
- export const deserializeAws_json1_1DeleteDeliveryStreamCommand = async (
386
- output: __HttpResponse,
387
- context: __SerdeContext
388
- ): Promise<DeleteDeliveryStreamCommandOutput> => {
389
- if (output.statusCode >= 300) {
390
- return deserializeAws_json1_1DeleteDeliveryStreamCommandError(output, context);
391
- }
392
- const data: any = await parseBody(output.body, context);
393
- let contents: any = {};
394
- contents = deserializeAws_json1_1DeleteDeliveryStreamOutput(data, context);
395
- const response: DeleteDeliveryStreamCommandOutput = {
396
- $metadata: deserializeMetadata(output),
397
- ...contents,
398
- };
399
- return Promise.resolve(response);
400
- };
401
-
402
- const deserializeAws_json1_1DeleteDeliveryStreamCommandError = async (
403
- output: __HttpResponse,
404
- context: __SerdeContext
405
- ): Promise<DeleteDeliveryStreamCommandOutput> => {
406
- const parsedOutput: any = {
407
- ...output,
408
- body: await parseBody(output.body, context),
409
- };
410
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
411
- let errorCode: string = "UnknownError";
412
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
413
- switch (errorCode) {
414
- case "ResourceInUseException":
415
- case "com.amazonaws.firehose#ResourceInUseException":
416
- response = {
417
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
418
- name: errorCode,
419
- $metadata: deserializeMetadata(output),
420
- };
421
- break;
422
- case "ResourceNotFoundException":
423
- case "com.amazonaws.firehose#ResourceNotFoundException":
424
- response = {
425
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
426
- name: errorCode,
427
- $metadata: deserializeMetadata(output),
428
- };
429
- break;
430
- default:
431
- const parsedBody = parsedOutput.body;
432
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
433
- response = {
434
- ...parsedBody,
435
- name: `${errorCode}`,
436
- message: parsedBody.message || parsedBody.Message || errorCode,
437
- $fault: "client",
438
- $metadata: deserializeMetadata(output),
439
- } as any;
440
- }
441
- const message = response.message || response.Message || errorCode;
442
- response.message = message;
443
- delete response.Message;
444
- return Promise.reject(Object.assign(new Error(message), response));
445
- };
446
-
447
- export const deserializeAws_json1_1DescribeDeliveryStreamCommand = async (
448
- output: __HttpResponse,
449
- context: __SerdeContext
450
- ): Promise<DescribeDeliveryStreamCommandOutput> => {
451
- if (output.statusCode >= 300) {
452
- return deserializeAws_json1_1DescribeDeliveryStreamCommandError(output, context);
453
- }
454
- const data: any = await parseBody(output.body, context);
455
- let contents: any = {};
456
- contents = deserializeAws_json1_1DescribeDeliveryStreamOutput(data, context);
457
- const response: DescribeDeliveryStreamCommandOutput = {
458
- $metadata: deserializeMetadata(output),
459
- ...contents,
460
- };
461
- return Promise.resolve(response);
462
- };
463
-
464
- const deserializeAws_json1_1DescribeDeliveryStreamCommandError = async (
465
- output: __HttpResponse,
466
- context: __SerdeContext
467
- ): Promise<DescribeDeliveryStreamCommandOutput> => {
468
- const parsedOutput: any = {
469
- ...output,
470
- body: await parseBody(output.body, context),
471
- };
472
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
473
- let errorCode: string = "UnknownError";
474
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
475
- switch (errorCode) {
476
- case "ResourceNotFoundException":
477
- case "com.amazonaws.firehose#ResourceNotFoundException":
478
- response = {
479
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
480
- name: errorCode,
481
- $metadata: deserializeMetadata(output),
482
- };
483
- break;
484
- default:
485
- const parsedBody = parsedOutput.body;
486
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
487
- response = {
488
- ...parsedBody,
489
- name: `${errorCode}`,
490
- message: parsedBody.message || parsedBody.Message || errorCode,
491
- $fault: "client",
492
- $metadata: deserializeMetadata(output),
493
- } as any;
494
- }
495
- const message = response.message || response.Message || errorCode;
496
- response.message = message;
497
- delete response.Message;
498
- return Promise.reject(Object.assign(new Error(message), response));
499
- };
500
-
501
- export const deserializeAws_json1_1ListDeliveryStreamsCommand = async (
502
- output: __HttpResponse,
503
- context: __SerdeContext
504
- ): Promise<ListDeliveryStreamsCommandOutput> => {
505
- if (output.statusCode >= 300) {
506
- return deserializeAws_json1_1ListDeliveryStreamsCommandError(output, context);
507
- }
508
- const data: any = await parseBody(output.body, context);
509
- let contents: any = {};
510
- contents = deserializeAws_json1_1ListDeliveryStreamsOutput(data, context);
511
- const response: ListDeliveryStreamsCommandOutput = {
512
- $metadata: deserializeMetadata(output),
513
- ...contents,
514
- };
515
- return Promise.resolve(response);
516
- };
517
-
518
- const deserializeAws_json1_1ListDeliveryStreamsCommandError = async (
519
- output: __HttpResponse,
520
- context: __SerdeContext
521
- ): Promise<ListDeliveryStreamsCommandOutput> => {
522
- const parsedOutput: any = {
523
- ...output,
524
- body: await parseBody(output.body, context),
525
- };
526
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
527
- let errorCode: string = "UnknownError";
528
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
529
- switch (errorCode) {
530
- default:
531
- const parsedBody = parsedOutput.body;
532
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
533
- response = {
534
- ...parsedBody,
535
- name: `${errorCode}`,
536
- message: parsedBody.message || parsedBody.Message || errorCode,
537
- $fault: "client",
538
- $metadata: deserializeMetadata(output),
539
- } as any;
540
- }
541
- const message = response.message || response.Message || errorCode;
542
- response.message = message;
543
- delete response.Message;
544
- return Promise.reject(Object.assign(new Error(message), response));
545
- };
546
-
547
- export const deserializeAws_json1_1ListTagsForDeliveryStreamCommand = async (
548
- output: __HttpResponse,
549
- context: __SerdeContext
550
- ): Promise<ListTagsForDeliveryStreamCommandOutput> => {
551
- if (output.statusCode >= 300) {
552
- return deserializeAws_json1_1ListTagsForDeliveryStreamCommandError(output, context);
553
- }
554
- const data: any = await parseBody(output.body, context);
555
- let contents: any = {};
556
- contents = deserializeAws_json1_1ListTagsForDeliveryStreamOutput(data, context);
557
- const response: ListTagsForDeliveryStreamCommandOutput = {
558
- $metadata: deserializeMetadata(output),
559
- ...contents,
560
- };
561
- return Promise.resolve(response);
562
- };
563
-
564
- const deserializeAws_json1_1ListTagsForDeliveryStreamCommandError = async (
565
- output: __HttpResponse,
566
- context: __SerdeContext
567
- ): Promise<ListTagsForDeliveryStreamCommandOutput> => {
568
- const parsedOutput: any = {
569
- ...output,
570
- body: await parseBody(output.body, context),
571
- };
572
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
573
- let errorCode: string = "UnknownError";
574
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
575
- switch (errorCode) {
576
- case "InvalidArgumentException":
577
- case "com.amazonaws.firehose#InvalidArgumentException":
578
- response = {
579
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
580
- name: errorCode,
581
- $metadata: deserializeMetadata(output),
582
- };
583
- break;
584
- case "LimitExceededException":
585
- case "com.amazonaws.firehose#LimitExceededException":
586
- response = {
587
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
588
- name: errorCode,
589
- $metadata: deserializeMetadata(output),
590
- };
591
- break;
592
- case "ResourceNotFoundException":
593
- case "com.amazonaws.firehose#ResourceNotFoundException":
594
- response = {
595
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
596
- name: errorCode,
597
- $metadata: deserializeMetadata(output),
598
- };
599
- break;
600
- default:
601
- const parsedBody = parsedOutput.body;
602
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
603
- response = {
604
- ...parsedBody,
605
- name: `${errorCode}`,
606
- message: parsedBody.message || parsedBody.Message || errorCode,
607
- $fault: "client",
608
- $metadata: deserializeMetadata(output),
609
- } as any;
610
- }
611
- const message = response.message || response.Message || errorCode;
612
- response.message = message;
613
- delete response.Message;
614
- return Promise.reject(Object.assign(new Error(message), response));
615
- };
616
-
617
- export const deserializeAws_json1_1PutRecordCommand = async (
618
- output: __HttpResponse,
619
- context: __SerdeContext
620
- ): Promise<PutRecordCommandOutput> => {
621
- if (output.statusCode >= 300) {
622
- return deserializeAws_json1_1PutRecordCommandError(output, context);
623
- }
624
- const data: any = await parseBody(output.body, context);
625
- let contents: any = {};
626
- contents = deserializeAws_json1_1PutRecordOutput(data, context);
627
- const response: PutRecordCommandOutput = {
628
- $metadata: deserializeMetadata(output),
629
- ...contents,
630
- };
631
- return Promise.resolve(response);
632
- };
633
-
634
- const deserializeAws_json1_1PutRecordCommandError = async (
635
- output: __HttpResponse,
636
- context: __SerdeContext
637
- ): Promise<PutRecordCommandOutput> => {
638
- const parsedOutput: any = {
639
- ...output,
640
- body: await parseBody(output.body, context),
641
- };
642
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
643
- let errorCode: string = "UnknownError";
644
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
645
- switch (errorCode) {
646
- case "InvalidArgumentException":
647
- case "com.amazonaws.firehose#InvalidArgumentException":
648
- response = {
649
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
650
- name: errorCode,
651
- $metadata: deserializeMetadata(output),
652
- };
653
- break;
654
- case "InvalidKMSResourceException":
655
- case "com.amazonaws.firehose#InvalidKMSResourceException":
656
- response = {
657
- ...(await deserializeAws_json1_1InvalidKMSResourceExceptionResponse(parsedOutput, context)),
658
- name: errorCode,
659
- $metadata: deserializeMetadata(output),
660
- };
661
- break;
662
- case "ResourceNotFoundException":
663
- case "com.amazonaws.firehose#ResourceNotFoundException":
664
- response = {
665
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
666
- name: errorCode,
667
- $metadata: deserializeMetadata(output),
668
- };
669
- break;
670
- case "ServiceUnavailableException":
671
- case "com.amazonaws.firehose#ServiceUnavailableException":
672
- response = {
673
- ...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
674
- name: errorCode,
675
- $metadata: deserializeMetadata(output),
676
- };
677
- break;
678
- default:
679
- const parsedBody = parsedOutput.body;
680
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
681
- response = {
682
- ...parsedBody,
683
- name: `${errorCode}`,
684
- message: parsedBody.message || parsedBody.Message || errorCode,
685
- $fault: "client",
686
- $metadata: deserializeMetadata(output),
687
- } as any;
688
- }
689
- const message = response.message || response.Message || errorCode;
690
- response.message = message;
691
- delete response.Message;
692
- return Promise.reject(Object.assign(new Error(message), response));
693
- };
694
-
695
- export const deserializeAws_json1_1PutRecordBatchCommand = async (
696
- output: __HttpResponse,
697
- context: __SerdeContext
698
- ): Promise<PutRecordBatchCommandOutput> => {
699
- if (output.statusCode >= 300) {
700
- return deserializeAws_json1_1PutRecordBatchCommandError(output, context);
701
- }
702
- const data: any = await parseBody(output.body, context);
703
- let contents: any = {};
704
- contents = deserializeAws_json1_1PutRecordBatchOutput(data, context);
705
- const response: PutRecordBatchCommandOutput = {
706
- $metadata: deserializeMetadata(output),
707
- ...contents,
708
- };
709
- return Promise.resolve(response);
710
- };
711
-
712
- const deserializeAws_json1_1PutRecordBatchCommandError = async (
713
- output: __HttpResponse,
714
- context: __SerdeContext
715
- ): Promise<PutRecordBatchCommandOutput> => {
716
- const parsedOutput: any = {
717
- ...output,
718
- body: await parseBody(output.body, context),
719
- };
720
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
721
- let errorCode: string = "UnknownError";
722
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
723
- switch (errorCode) {
724
- case "InvalidArgumentException":
725
- case "com.amazonaws.firehose#InvalidArgumentException":
726
- response = {
727
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
728
- name: errorCode,
729
- $metadata: deserializeMetadata(output),
730
- };
731
- break;
732
- case "InvalidKMSResourceException":
733
- case "com.amazonaws.firehose#InvalidKMSResourceException":
734
- response = {
735
- ...(await deserializeAws_json1_1InvalidKMSResourceExceptionResponse(parsedOutput, context)),
736
- name: errorCode,
737
- $metadata: deserializeMetadata(output),
738
- };
739
- break;
740
- case "ResourceNotFoundException":
741
- case "com.amazonaws.firehose#ResourceNotFoundException":
742
- response = {
743
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
744
- name: errorCode,
745
- $metadata: deserializeMetadata(output),
746
- };
747
- break;
748
- case "ServiceUnavailableException":
749
- case "com.amazonaws.firehose#ServiceUnavailableException":
750
- response = {
751
- ...(await deserializeAws_json1_1ServiceUnavailableExceptionResponse(parsedOutput, context)),
752
- name: errorCode,
753
- $metadata: deserializeMetadata(output),
754
- };
755
- break;
756
- default:
757
- const parsedBody = parsedOutput.body;
758
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
759
- response = {
760
- ...parsedBody,
761
- name: `${errorCode}`,
762
- message: parsedBody.message || parsedBody.Message || errorCode,
763
- $fault: "client",
764
- $metadata: deserializeMetadata(output),
765
- } as any;
766
- }
767
- const message = response.message || response.Message || errorCode;
768
- response.message = message;
769
- delete response.Message;
770
- return Promise.reject(Object.assign(new Error(message), response));
771
- };
772
-
773
- export const deserializeAws_json1_1StartDeliveryStreamEncryptionCommand = async (
774
- output: __HttpResponse,
775
- context: __SerdeContext
776
- ): Promise<StartDeliveryStreamEncryptionCommandOutput> => {
777
- if (output.statusCode >= 300) {
778
- return deserializeAws_json1_1StartDeliveryStreamEncryptionCommandError(output, context);
779
- }
780
- const data: any = await parseBody(output.body, context);
781
- let contents: any = {};
782
- contents = deserializeAws_json1_1StartDeliveryStreamEncryptionOutput(data, context);
783
- const response: StartDeliveryStreamEncryptionCommandOutput = {
784
- $metadata: deserializeMetadata(output),
785
- ...contents,
786
- };
787
- return Promise.resolve(response);
788
- };
789
-
790
- const deserializeAws_json1_1StartDeliveryStreamEncryptionCommandError = async (
791
- output: __HttpResponse,
792
- context: __SerdeContext
793
- ): Promise<StartDeliveryStreamEncryptionCommandOutput> => {
794
- const parsedOutput: any = {
795
- ...output,
796
- body: await parseBody(output.body, context),
797
- };
798
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
799
- let errorCode: string = "UnknownError";
800
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
801
- switch (errorCode) {
802
- case "InvalidArgumentException":
803
- case "com.amazonaws.firehose#InvalidArgumentException":
804
- response = {
805
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
806
- name: errorCode,
807
- $metadata: deserializeMetadata(output),
808
- };
809
- break;
810
- case "InvalidKMSResourceException":
811
- case "com.amazonaws.firehose#InvalidKMSResourceException":
812
- response = {
813
- ...(await deserializeAws_json1_1InvalidKMSResourceExceptionResponse(parsedOutput, context)),
814
- name: errorCode,
815
- $metadata: deserializeMetadata(output),
816
- };
817
- break;
818
- case "LimitExceededException":
819
- case "com.amazonaws.firehose#LimitExceededException":
820
- response = {
821
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
822
- name: errorCode,
823
- $metadata: deserializeMetadata(output),
824
- };
825
- break;
826
- case "ResourceInUseException":
827
- case "com.amazonaws.firehose#ResourceInUseException":
828
- response = {
829
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
830
- name: errorCode,
831
- $metadata: deserializeMetadata(output),
832
- };
833
- break;
834
- case "ResourceNotFoundException":
835
- case "com.amazonaws.firehose#ResourceNotFoundException":
836
- response = {
837
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
838
- name: errorCode,
839
- $metadata: deserializeMetadata(output),
840
- };
841
- break;
842
- default:
843
- const parsedBody = parsedOutput.body;
844
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
845
- response = {
846
- ...parsedBody,
847
- name: `${errorCode}`,
848
- message: parsedBody.message || parsedBody.Message || errorCode,
849
- $fault: "client",
850
- $metadata: deserializeMetadata(output),
851
- } as any;
852
- }
853
- const message = response.message || response.Message || errorCode;
854
- response.message = message;
855
- delete response.Message;
856
- return Promise.reject(Object.assign(new Error(message), response));
857
- };
858
-
859
- export const deserializeAws_json1_1StopDeliveryStreamEncryptionCommand = async (
860
- output: __HttpResponse,
861
- context: __SerdeContext
862
- ): Promise<StopDeliveryStreamEncryptionCommandOutput> => {
863
- if (output.statusCode >= 300) {
864
- return deserializeAws_json1_1StopDeliveryStreamEncryptionCommandError(output, context);
865
- }
866
- const data: any = await parseBody(output.body, context);
867
- let contents: any = {};
868
- contents = deserializeAws_json1_1StopDeliveryStreamEncryptionOutput(data, context);
869
- const response: StopDeliveryStreamEncryptionCommandOutput = {
870
- $metadata: deserializeMetadata(output),
871
- ...contents,
872
- };
873
- return Promise.resolve(response);
874
- };
875
-
876
- const deserializeAws_json1_1StopDeliveryStreamEncryptionCommandError = async (
877
- output: __HttpResponse,
878
- context: __SerdeContext
879
- ): Promise<StopDeliveryStreamEncryptionCommandOutput> => {
880
- const parsedOutput: any = {
881
- ...output,
882
- body: await parseBody(output.body, context),
883
- };
884
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
885
- let errorCode: string = "UnknownError";
886
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
887
- switch (errorCode) {
888
- case "InvalidArgumentException":
889
- case "com.amazonaws.firehose#InvalidArgumentException":
890
- response = {
891
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
892
- name: errorCode,
893
- $metadata: deserializeMetadata(output),
894
- };
895
- break;
896
- case "LimitExceededException":
897
- case "com.amazonaws.firehose#LimitExceededException":
898
- response = {
899
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
900
- name: errorCode,
901
- $metadata: deserializeMetadata(output),
902
- };
903
- break;
904
- case "ResourceInUseException":
905
- case "com.amazonaws.firehose#ResourceInUseException":
906
- response = {
907
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
908
- name: errorCode,
909
- $metadata: deserializeMetadata(output),
910
- };
911
- break;
912
- case "ResourceNotFoundException":
913
- case "com.amazonaws.firehose#ResourceNotFoundException":
914
- response = {
915
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
916
- name: errorCode,
917
- $metadata: deserializeMetadata(output),
918
- };
919
- break;
920
- default:
921
- const parsedBody = parsedOutput.body;
922
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
923
- response = {
924
- ...parsedBody,
925
- name: `${errorCode}`,
926
- message: parsedBody.message || parsedBody.Message || errorCode,
927
- $fault: "client",
928
- $metadata: deserializeMetadata(output),
929
- } as any;
930
- }
931
- const message = response.message || response.Message || errorCode;
932
- response.message = message;
933
- delete response.Message;
934
- return Promise.reject(Object.assign(new Error(message), response));
935
- };
936
-
937
- export const deserializeAws_json1_1TagDeliveryStreamCommand = async (
938
- output: __HttpResponse,
939
- context: __SerdeContext
940
- ): Promise<TagDeliveryStreamCommandOutput> => {
941
- if (output.statusCode >= 300) {
942
- return deserializeAws_json1_1TagDeliveryStreamCommandError(output, context);
943
- }
944
- const data: any = await parseBody(output.body, context);
945
- let contents: any = {};
946
- contents = deserializeAws_json1_1TagDeliveryStreamOutput(data, context);
947
- const response: TagDeliveryStreamCommandOutput = {
948
- $metadata: deserializeMetadata(output),
949
- ...contents,
950
- };
951
- return Promise.resolve(response);
952
- };
953
-
954
- const deserializeAws_json1_1TagDeliveryStreamCommandError = async (
955
- output: __HttpResponse,
956
- context: __SerdeContext
957
- ): Promise<TagDeliveryStreamCommandOutput> => {
958
- const parsedOutput: any = {
959
- ...output,
960
- body: await parseBody(output.body, context),
961
- };
962
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
963
- let errorCode: string = "UnknownError";
964
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
965
- switch (errorCode) {
966
- case "InvalidArgumentException":
967
- case "com.amazonaws.firehose#InvalidArgumentException":
968
- response = {
969
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
970
- name: errorCode,
971
- $metadata: deserializeMetadata(output),
972
- };
973
- break;
974
- case "LimitExceededException":
975
- case "com.amazonaws.firehose#LimitExceededException":
976
- response = {
977
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
978
- name: errorCode,
979
- $metadata: deserializeMetadata(output),
980
- };
981
- break;
982
- case "ResourceInUseException":
983
- case "com.amazonaws.firehose#ResourceInUseException":
984
- response = {
985
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
986
- name: errorCode,
987
- $metadata: deserializeMetadata(output),
988
- };
989
- break;
990
- case "ResourceNotFoundException":
991
- case "com.amazonaws.firehose#ResourceNotFoundException":
992
- response = {
993
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
994
- name: errorCode,
995
- $metadata: deserializeMetadata(output),
996
- };
997
- break;
998
- default:
999
- const parsedBody = parsedOutput.body;
1000
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
1001
- response = {
1002
- ...parsedBody,
1003
- name: `${errorCode}`,
1004
- message: parsedBody.message || parsedBody.Message || errorCode,
1005
- $fault: "client",
1006
- $metadata: deserializeMetadata(output),
1007
- } as any;
1008
- }
1009
- const message = response.message || response.Message || errorCode;
1010
- response.message = message;
1011
- delete response.Message;
1012
- return Promise.reject(Object.assign(new Error(message), response));
1013
- };
1014
-
1015
- export const deserializeAws_json1_1UntagDeliveryStreamCommand = async (
1016
- output: __HttpResponse,
1017
- context: __SerdeContext
1018
- ): Promise<UntagDeliveryStreamCommandOutput> => {
1019
- if (output.statusCode >= 300) {
1020
- return deserializeAws_json1_1UntagDeliveryStreamCommandError(output, context);
1021
- }
1022
- const data: any = await parseBody(output.body, context);
1023
- let contents: any = {};
1024
- contents = deserializeAws_json1_1UntagDeliveryStreamOutput(data, context);
1025
- const response: UntagDeliveryStreamCommandOutput = {
1026
- $metadata: deserializeMetadata(output),
1027
- ...contents,
1028
- };
1029
- return Promise.resolve(response);
1030
- };
1031
-
1032
- const deserializeAws_json1_1UntagDeliveryStreamCommandError = async (
1033
- output: __HttpResponse,
1034
- context: __SerdeContext
1035
- ): Promise<UntagDeliveryStreamCommandOutput> => {
1036
- const parsedOutput: any = {
1037
- ...output,
1038
- body: await parseBody(output.body, context),
1039
- };
1040
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
1041
- let errorCode: string = "UnknownError";
1042
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1043
- switch (errorCode) {
1044
- case "InvalidArgumentException":
1045
- case "com.amazonaws.firehose#InvalidArgumentException":
1046
- response = {
1047
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
1048
- name: errorCode,
1049
- $metadata: deserializeMetadata(output),
1050
- };
1051
- break;
1052
- case "LimitExceededException":
1053
- case "com.amazonaws.firehose#LimitExceededException":
1054
- response = {
1055
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
1056
- name: errorCode,
1057
- $metadata: deserializeMetadata(output),
1058
- };
1059
- break;
1060
- case "ResourceInUseException":
1061
- case "com.amazonaws.firehose#ResourceInUseException":
1062
- response = {
1063
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
1064
- name: errorCode,
1065
- $metadata: deserializeMetadata(output),
1066
- };
1067
- break;
1068
- case "ResourceNotFoundException":
1069
- case "com.amazonaws.firehose#ResourceNotFoundException":
1070
- response = {
1071
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
1072
- name: errorCode,
1073
- $metadata: deserializeMetadata(output),
1074
- };
1075
- break;
1076
- default:
1077
- const parsedBody = parsedOutput.body;
1078
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
1079
- response = {
1080
- ...parsedBody,
1081
- name: `${errorCode}`,
1082
- message: parsedBody.message || parsedBody.Message || errorCode,
1083
- $fault: "client",
1084
- $metadata: deserializeMetadata(output),
1085
- } as any;
1086
- }
1087
- const message = response.message || response.Message || errorCode;
1088
- response.message = message;
1089
- delete response.Message;
1090
- return Promise.reject(Object.assign(new Error(message), response));
1091
- };
1092
-
1093
- export const deserializeAws_json1_1UpdateDestinationCommand = async (
1094
- output: __HttpResponse,
1095
- context: __SerdeContext
1096
- ): Promise<UpdateDestinationCommandOutput> => {
1097
- if (output.statusCode >= 300) {
1098
- return deserializeAws_json1_1UpdateDestinationCommandError(output, context);
1099
- }
1100
- const data: any = await parseBody(output.body, context);
1101
- let contents: any = {};
1102
- contents = deserializeAws_json1_1UpdateDestinationOutput(data, context);
1103
- const response: UpdateDestinationCommandOutput = {
1104
- $metadata: deserializeMetadata(output),
1105
- ...contents,
1106
- };
1107
- return Promise.resolve(response);
1108
- };
1109
-
1110
- const deserializeAws_json1_1UpdateDestinationCommandError = async (
1111
- output: __HttpResponse,
1112
- context: __SerdeContext
1113
- ): Promise<UpdateDestinationCommandOutput> => {
1114
- const parsedOutput: any = {
1115
- ...output,
1116
- body: await parseBody(output.body, context),
1117
- };
1118
- let response: __SmithyException & __MetadataBearer & { [key: string]: any };
1119
- let errorCode: string = "UnknownError";
1120
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1121
- switch (errorCode) {
1122
- case "ConcurrentModificationException":
1123
- case "com.amazonaws.firehose#ConcurrentModificationException":
1124
- response = {
1125
- ...(await deserializeAws_json1_1ConcurrentModificationExceptionResponse(parsedOutput, context)),
1126
- name: errorCode,
1127
- $metadata: deserializeMetadata(output),
1128
- };
1129
- break;
1130
- case "InvalidArgumentException":
1131
- case "com.amazonaws.firehose#InvalidArgumentException":
1132
- response = {
1133
- ...(await deserializeAws_json1_1InvalidArgumentExceptionResponse(parsedOutput, context)),
1134
- name: errorCode,
1135
- $metadata: deserializeMetadata(output),
1136
- };
1137
- break;
1138
- case "ResourceInUseException":
1139
- case "com.amazonaws.firehose#ResourceInUseException":
1140
- response = {
1141
- ...(await deserializeAws_json1_1ResourceInUseExceptionResponse(parsedOutput, context)),
1142
- name: errorCode,
1143
- $metadata: deserializeMetadata(output),
1144
- };
1145
- break;
1146
- case "ResourceNotFoundException":
1147
- case "com.amazonaws.firehose#ResourceNotFoundException":
1148
- response = {
1149
- ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)),
1150
- name: errorCode,
1151
- $metadata: deserializeMetadata(output),
1152
- };
1153
- break;
1154
- default:
1155
- const parsedBody = parsedOutput.body;
1156
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
1157
- response = {
1158
- ...parsedBody,
1159
- name: `${errorCode}`,
1160
- message: parsedBody.message || parsedBody.Message || errorCode,
1161
- $fault: "client",
1162
- $metadata: deserializeMetadata(output),
1163
- } as any;
1164
- }
1165
- const message = response.message || response.Message || errorCode;
1166
- response.message = message;
1167
- delete response.Message;
1168
- return Promise.reject(Object.assign(new Error(message), response));
1169
- };
1170
-
1171
- const deserializeAws_json1_1ConcurrentModificationExceptionResponse = async (
1172
- parsedOutput: any,
1173
- context: __SerdeContext
1174
- ): Promise<ConcurrentModificationException> => {
1175
- const body = parsedOutput.body;
1176
- const deserialized: any = deserializeAws_json1_1ConcurrentModificationException(body, context);
1177
- const contents: ConcurrentModificationException = {
1178
- name: "ConcurrentModificationException",
1179
- $fault: "client",
1180
- $metadata: deserializeMetadata(parsedOutput),
1181
- ...deserialized,
1182
- };
1183
- return contents;
1184
- };
1185
-
1186
- const deserializeAws_json1_1InvalidArgumentExceptionResponse = async (
1187
- parsedOutput: any,
1188
- context: __SerdeContext
1189
- ): Promise<InvalidArgumentException> => {
1190
- const body = parsedOutput.body;
1191
- const deserialized: any = deserializeAws_json1_1InvalidArgumentException(body, context);
1192
- const contents: InvalidArgumentException = {
1193
- name: "InvalidArgumentException",
1194
- $fault: "client",
1195
- $metadata: deserializeMetadata(parsedOutput),
1196
- ...deserialized,
1197
- };
1198
- return contents;
1199
- };
1200
-
1201
- const deserializeAws_json1_1InvalidKMSResourceExceptionResponse = async (
1202
- parsedOutput: any,
1203
- context: __SerdeContext
1204
- ): Promise<InvalidKMSResourceException> => {
1205
- const body = parsedOutput.body;
1206
- const deserialized: any = deserializeAws_json1_1InvalidKMSResourceException(body, context);
1207
- const contents: InvalidKMSResourceException = {
1208
- name: "InvalidKMSResourceException",
1209
- $fault: "client",
1210
- $metadata: deserializeMetadata(parsedOutput),
1211
- ...deserialized,
1212
- };
1213
- return contents;
1214
- };
1215
-
1216
- const deserializeAws_json1_1LimitExceededExceptionResponse = async (
1217
- parsedOutput: any,
1218
- context: __SerdeContext
1219
- ): Promise<LimitExceededException> => {
1220
- const body = parsedOutput.body;
1221
- const deserialized: any = deserializeAws_json1_1LimitExceededException(body, context);
1222
- const contents: LimitExceededException = {
1223
- name: "LimitExceededException",
1224
- $fault: "client",
1225
- $metadata: deserializeMetadata(parsedOutput),
1226
- ...deserialized,
1227
- };
1228
- return contents;
1229
- };
1230
-
1231
- const deserializeAws_json1_1ResourceInUseExceptionResponse = async (
1232
- parsedOutput: any,
1233
- context: __SerdeContext
1234
- ): Promise<ResourceInUseException> => {
1235
- const body = parsedOutput.body;
1236
- const deserialized: any = deserializeAws_json1_1ResourceInUseException(body, context);
1237
- const contents: ResourceInUseException = {
1238
- name: "ResourceInUseException",
1239
- $fault: "client",
1240
- $metadata: deserializeMetadata(parsedOutput),
1241
- ...deserialized,
1242
- };
1243
- return contents;
1244
- };
1245
-
1246
- const deserializeAws_json1_1ResourceNotFoundExceptionResponse = async (
1247
- parsedOutput: any,
1248
- context: __SerdeContext
1249
- ): Promise<ResourceNotFoundException> => {
1250
- const body = parsedOutput.body;
1251
- const deserialized: any = deserializeAws_json1_1ResourceNotFoundException(body, context);
1252
- const contents: ResourceNotFoundException = {
1253
- name: "ResourceNotFoundException",
1254
- $fault: "client",
1255
- $metadata: deserializeMetadata(parsedOutput),
1256
- ...deserialized,
1257
- };
1258
- return contents;
1259
- };
1260
-
1261
- const deserializeAws_json1_1ServiceUnavailableExceptionResponse = async (
1262
- parsedOutput: any,
1263
- context: __SerdeContext
1264
- ): Promise<ServiceUnavailableException> => {
1265
- const body = parsedOutput.body;
1266
- const deserialized: any = deserializeAws_json1_1ServiceUnavailableException(body, context);
1267
- const contents: ServiceUnavailableException = {
1268
- name: "ServiceUnavailableException",
1269
- $fault: "server",
1270
- $metadata: deserializeMetadata(parsedOutput),
1271
- ...deserialized,
1272
- };
1273
- return contents;
1274
- };
1275
-
1276
- const serializeAws_json1_1BufferingHints = (input: BufferingHints, context: __SerdeContext): any => {
1277
- return {
1278
- ...(input.IntervalInSeconds !== undefined &&
1279
- input.IntervalInSeconds !== null && { IntervalInSeconds: input.IntervalInSeconds }),
1280
- ...(input.SizeInMBs !== undefined && input.SizeInMBs !== null && { SizeInMBs: input.SizeInMBs }),
1281
- };
1282
- };
1283
-
1284
- const serializeAws_json1_1CloudWatchLoggingOptions = (
1285
- input: CloudWatchLoggingOptions,
1286
- context: __SerdeContext
1287
- ): any => {
1288
- return {
1289
- ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }),
1290
- ...(input.LogGroupName !== undefined && input.LogGroupName !== null && { LogGroupName: input.LogGroupName }),
1291
- ...(input.LogStreamName !== undefined && input.LogStreamName !== null && { LogStreamName: input.LogStreamName }),
1292
- };
1293
- };
1294
-
1295
- const serializeAws_json1_1ColumnToJsonKeyMappings = (
1296
- input: { [key: string]: string },
1297
- context: __SerdeContext
1298
- ): any => {
1299
- return Object.entries(input).reduce((acc: { [key: string]: any }, [key, value]: [string, any]) => {
1300
- if (value === null) {
1301
- return acc;
1302
- }
1303
- return {
1304
- ...acc,
1305
- [key]: value,
1306
- };
1307
- }, {});
1308
- };
1309
-
1310
- const serializeAws_json1_1CopyCommand = (input: CopyCommand, context: __SerdeContext): any => {
1311
- return {
1312
- ...(input.CopyOptions !== undefined && input.CopyOptions !== null && { CopyOptions: input.CopyOptions }),
1313
- ...(input.DataTableColumns !== undefined &&
1314
- input.DataTableColumns !== null && { DataTableColumns: input.DataTableColumns }),
1315
- ...(input.DataTableName !== undefined && input.DataTableName !== null && { DataTableName: input.DataTableName }),
1316
- };
1317
- };
1318
-
1319
- const serializeAws_json1_1CreateDeliveryStreamInput = (
1320
- input: CreateDeliveryStreamInput,
1321
- context: __SerdeContext
1322
- ): any => {
1323
- return {
1324
- ...(input.DeliveryStreamEncryptionConfigurationInput !== undefined &&
1325
- input.DeliveryStreamEncryptionConfigurationInput !== null && {
1326
- DeliveryStreamEncryptionConfigurationInput: serializeAws_json1_1DeliveryStreamEncryptionConfigurationInput(
1327
- input.DeliveryStreamEncryptionConfigurationInput,
1328
- context
1329
- ),
1330
- }),
1331
- ...(input.DeliveryStreamName !== undefined &&
1332
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
1333
- ...(input.DeliveryStreamType !== undefined &&
1334
- input.DeliveryStreamType !== null && { DeliveryStreamType: input.DeliveryStreamType }),
1335
- ...(input.ElasticsearchDestinationConfiguration !== undefined &&
1336
- input.ElasticsearchDestinationConfiguration !== null && {
1337
- ElasticsearchDestinationConfiguration: serializeAws_json1_1ElasticsearchDestinationConfiguration(
1338
- input.ElasticsearchDestinationConfiguration,
1339
- context
1340
- ),
1341
- }),
1342
- ...(input.ExtendedS3DestinationConfiguration !== undefined &&
1343
- input.ExtendedS3DestinationConfiguration !== null && {
1344
- ExtendedS3DestinationConfiguration: serializeAws_json1_1ExtendedS3DestinationConfiguration(
1345
- input.ExtendedS3DestinationConfiguration,
1346
- context
1347
- ),
1348
- }),
1349
- ...(input.HttpEndpointDestinationConfiguration !== undefined &&
1350
- input.HttpEndpointDestinationConfiguration !== null && {
1351
- HttpEndpointDestinationConfiguration: serializeAws_json1_1HttpEndpointDestinationConfiguration(
1352
- input.HttpEndpointDestinationConfiguration,
1353
- context
1354
- ),
1355
- }),
1356
- ...(input.KinesisStreamSourceConfiguration !== undefined &&
1357
- input.KinesisStreamSourceConfiguration !== null && {
1358
- KinesisStreamSourceConfiguration: serializeAws_json1_1KinesisStreamSourceConfiguration(
1359
- input.KinesisStreamSourceConfiguration,
1360
- context
1361
- ),
1362
- }),
1363
- ...(input.RedshiftDestinationConfiguration !== undefined &&
1364
- input.RedshiftDestinationConfiguration !== null && {
1365
- RedshiftDestinationConfiguration: serializeAws_json1_1RedshiftDestinationConfiguration(
1366
- input.RedshiftDestinationConfiguration,
1367
- context
1368
- ),
1369
- }),
1370
- ...(input.S3DestinationConfiguration !== undefined &&
1371
- input.S3DestinationConfiguration !== null && {
1372
- S3DestinationConfiguration: serializeAws_json1_1S3DestinationConfiguration(
1373
- input.S3DestinationConfiguration,
1374
- context
1375
- ),
1376
- }),
1377
- ...(input.SplunkDestinationConfiguration !== undefined &&
1378
- input.SplunkDestinationConfiguration !== null && {
1379
- SplunkDestinationConfiguration: serializeAws_json1_1SplunkDestinationConfiguration(
1380
- input.SplunkDestinationConfiguration,
1381
- context
1382
- ),
1383
- }),
1384
- ...(input.Tags !== undefined &&
1385
- input.Tags !== null && { Tags: serializeAws_json1_1TagDeliveryStreamInputTagList(input.Tags, context) }),
1386
- };
1387
- };
1388
-
1389
- const serializeAws_json1_1DataFormatConversionConfiguration = (
1390
- input: DataFormatConversionConfiguration,
1391
- context: __SerdeContext
1392
- ): any => {
1393
- return {
1394
- ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }),
1395
- ...(input.InputFormatConfiguration !== undefined &&
1396
- input.InputFormatConfiguration !== null && {
1397
- InputFormatConfiguration: serializeAws_json1_1InputFormatConfiguration(input.InputFormatConfiguration, context),
1398
- }),
1399
- ...(input.OutputFormatConfiguration !== undefined &&
1400
- input.OutputFormatConfiguration !== null && {
1401
- OutputFormatConfiguration: serializeAws_json1_1OutputFormatConfiguration(
1402
- input.OutputFormatConfiguration,
1403
- context
1404
- ),
1405
- }),
1406
- ...(input.SchemaConfiguration !== undefined &&
1407
- input.SchemaConfiguration !== null && {
1408
- SchemaConfiguration: serializeAws_json1_1SchemaConfiguration(input.SchemaConfiguration, context),
1409
- }),
1410
- };
1411
- };
1412
-
1413
- const serializeAws_json1_1DeleteDeliveryStreamInput = (
1414
- input: DeleteDeliveryStreamInput,
1415
- context: __SerdeContext
1416
- ): any => {
1417
- return {
1418
- ...(input.AllowForceDelete !== undefined &&
1419
- input.AllowForceDelete !== null && { AllowForceDelete: input.AllowForceDelete }),
1420
- ...(input.DeliveryStreamName !== undefined &&
1421
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
1422
- };
1423
- };
1424
-
1425
- const serializeAws_json1_1DeliveryStreamEncryptionConfigurationInput = (
1426
- input: DeliveryStreamEncryptionConfigurationInput,
1427
- context: __SerdeContext
1428
- ): any => {
1429
- return {
1430
- ...(input.KeyARN !== undefined && input.KeyARN !== null && { KeyARN: input.KeyARN }),
1431
- ...(input.KeyType !== undefined && input.KeyType !== null && { KeyType: input.KeyType }),
1432
- };
1433
- };
1434
-
1435
- const serializeAws_json1_1DescribeDeliveryStreamInput = (
1436
- input: DescribeDeliveryStreamInput,
1437
- context: __SerdeContext
1438
- ): any => {
1439
- return {
1440
- ...(input.DeliveryStreamName !== undefined &&
1441
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
1442
- ...(input.ExclusiveStartDestinationId !== undefined &&
1443
- input.ExclusiveStartDestinationId !== null && { ExclusiveStartDestinationId: input.ExclusiveStartDestinationId }),
1444
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
1445
- };
1446
- };
1447
-
1448
- const serializeAws_json1_1Deserializer = (input: Deserializer, context: __SerdeContext): any => {
1449
- return {
1450
- ...(input.HiveJsonSerDe !== undefined &&
1451
- input.HiveJsonSerDe !== null && {
1452
- HiveJsonSerDe: serializeAws_json1_1HiveJsonSerDe(input.HiveJsonSerDe, context),
1453
- }),
1454
- ...(input.OpenXJsonSerDe !== undefined &&
1455
- input.OpenXJsonSerDe !== null && {
1456
- OpenXJsonSerDe: serializeAws_json1_1OpenXJsonSerDe(input.OpenXJsonSerDe, context),
1457
- }),
1458
- };
1459
- };
1460
-
1461
- const serializeAws_json1_1DynamicPartitioningConfiguration = (
1462
- input: DynamicPartitioningConfiguration,
1463
- context: __SerdeContext
1464
- ): any => {
1465
- return {
1466
- ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }),
1467
- ...(input.RetryOptions !== undefined &&
1468
- input.RetryOptions !== null && { RetryOptions: serializeAws_json1_1RetryOptions(input.RetryOptions, context) }),
1469
- };
1470
- };
1471
-
1472
- const serializeAws_json1_1ElasticsearchBufferingHints = (
1473
- input: ElasticsearchBufferingHints,
1474
- context: __SerdeContext
1475
- ): any => {
1476
- return {
1477
- ...(input.IntervalInSeconds !== undefined &&
1478
- input.IntervalInSeconds !== null && { IntervalInSeconds: input.IntervalInSeconds }),
1479
- ...(input.SizeInMBs !== undefined && input.SizeInMBs !== null && { SizeInMBs: input.SizeInMBs }),
1480
- };
1481
- };
1482
-
1483
- const serializeAws_json1_1ElasticsearchDestinationConfiguration = (
1484
- input: ElasticsearchDestinationConfiguration,
1485
- context: __SerdeContext
1486
- ): any => {
1487
- return {
1488
- ...(input.BufferingHints !== undefined &&
1489
- input.BufferingHints !== null && {
1490
- BufferingHints: serializeAws_json1_1ElasticsearchBufferingHints(input.BufferingHints, context),
1491
- }),
1492
- ...(input.CloudWatchLoggingOptions !== undefined &&
1493
- input.CloudWatchLoggingOptions !== null && {
1494
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
1495
- }),
1496
- ...(input.ClusterEndpoint !== undefined &&
1497
- input.ClusterEndpoint !== null && { ClusterEndpoint: input.ClusterEndpoint }),
1498
- ...(input.DomainARN !== undefined && input.DomainARN !== null && { DomainARN: input.DomainARN }),
1499
- ...(input.IndexName !== undefined && input.IndexName !== null && { IndexName: input.IndexName }),
1500
- ...(input.IndexRotationPeriod !== undefined &&
1501
- input.IndexRotationPeriod !== null && { IndexRotationPeriod: input.IndexRotationPeriod }),
1502
- ...(input.ProcessingConfiguration !== undefined &&
1503
- input.ProcessingConfiguration !== null && {
1504
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
1505
- }),
1506
- ...(input.RetryOptions !== undefined &&
1507
- input.RetryOptions !== null && {
1508
- RetryOptions: serializeAws_json1_1ElasticsearchRetryOptions(input.RetryOptions, context),
1509
- }),
1510
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1511
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
1512
- ...(input.S3Configuration !== undefined &&
1513
- input.S3Configuration !== null && {
1514
- S3Configuration: serializeAws_json1_1S3DestinationConfiguration(input.S3Configuration, context),
1515
- }),
1516
- ...(input.TypeName !== undefined && input.TypeName !== null && { TypeName: input.TypeName }),
1517
- ...(input.VpcConfiguration !== undefined &&
1518
- input.VpcConfiguration !== null && {
1519
- VpcConfiguration: serializeAws_json1_1VpcConfiguration(input.VpcConfiguration, context),
1520
- }),
1521
- };
1522
- };
1523
-
1524
- const serializeAws_json1_1ElasticsearchDestinationUpdate = (
1525
- input: ElasticsearchDestinationUpdate,
1526
- context: __SerdeContext
1527
- ): any => {
1528
- return {
1529
- ...(input.BufferingHints !== undefined &&
1530
- input.BufferingHints !== null && {
1531
- BufferingHints: serializeAws_json1_1ElasticsearchBufferingHints(input.BufferingHints, context),
1532
- }),
1533
- ...(input.CloudWatchLoggingOptions !== undefined &&
1534
- input.CloudWatchLoggingOptions !== null && {
1535
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
1536
- }),
1537
- ...(input.ClusterEndpoint !== undefined &&
1538
- input.ClusterEndpoint !== null && { ClusterEndpoint: input.ClusterEndpoint }),
1539
- ...(input.DomainARN !== undefined && input.DomainARN !== null && { DomainARN: input.DomainARN }),
1540
- ...(input.IndexName !== undefined && input.IndexName !== null && { IndexName: input.IndexName }),
1541
- ...(input.IndexRotationPeriod !== undefined &&
1542
- input.IndexRotationPeriod !== null && { IndexRotationPeriod: input.IndexRotationPeriod }),
1543
- ...(input.ProcessingConfiguration !== undefined &&
1544
- input.ProcessingConfiguration !== null && {
1545
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
1546
- }),
1547
- ...(input.RetryOptions !== undefined &&
1548
- input.RetryOptions !== null && {
1549
- RetryOptions: serializeAws_json1_1ElasticsearchRetryOptions(input.RetryOptions, context),
1550
- }),
1551
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1552
- ...(input.S3Update !== undefined &&
1553
- input.S3Update !== null && { S3Update: serializeAws_json1_1S3DestinationUpdate(input.S3Update, context) }),
1554
- ...(input.TypeName !== undefined && input.TypeName !== null && { TypeName: input.TypeName }),
1555
- };
1556
- };
1557
-
1558
- const serializeAws_json1_1ElasticsearchRetryOptions = (
1559
- input: ElasticsearchRetryOptions,
1560
- context: __SerdeContext
1561
- ): any => {
1562
- return {
1563
- ...(input.DurationInSeconds !== undefined &&
1564
- input.DurationInSeconds !== null && { DurationInSeconds: input.DurationInSeconds }),
1565
- };
1566
- };
1567
-
1568
- const serializeAws_json1_1EncryptionConfiguration = (input: EncryptionConfiguration, context: __SerdeContext): any => {
1569
- return {
1570
- ...(input.KMSEncryptionConfig !== undefined &&
1571
- input.KMSEncryptionConfig !== null && {
1572
- KMSEncryptionConfig: serializeAws_json1_1KMSEncryptionConfig(input.KMSEncryptionConfig, context),
1573
- }),
1574
- ...(input.NoEncryptionConfig !== undefined &&
1575
- input.NoEncryptionConfig !== null && { NoEncryptionConfig: input.NoEncryptionConfig }),
1576
- };
1577
- };
1578
-
1579
- const serializeAws_json1_1ExtendedS3DestinationConfiguration = (
1580
- input: ExtendedS3DestinationConfiguration,
1581
- context: __SerdeContext
1582
- ): any => {
1583
- return {
1584
- ...(input.BucketARN !== undefined && input.BucketARN !== null && { BucketARN: input.BucketARN }),
1585
- ...(input.BufferingHints !== undefined &&
1586
- input.BufferingHints !== null && {
1587
- BufferingHints: serializeAws_json1_1BufferingHints(input.BufferingHints, context),
1588
- }),
1589
- ...(input.CloudWatchLoggingOptions !== undefined &&
1590
- input.CloudWatchLoggingOptions !== null && {
1591
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
1592
- }),
1593
- ...(input.CompressionFormat !== undefined &&
1594
- input.CompressionFormat !== null && { CompressionFormat: input.CompressionFormat }),
1595
- ...(input.DataFormatConversionConfiguration !== undefined &&
1596
- input.DataFormatConversionConfiguration !== null && {
1597
- DataFormatConversionConfiguration: serializeAws_json1_1DataFormatConversionConfiguration(
1598
- input.DataFormatConversionConfiguration,
1599
- context
1600
- ),
1601
- }),
1602
- ...(input.DynamicPartitioningConfiguration !== undefined &&
1603
- input.DynamicPartitioningConfiguration !== null && {
1604
- DynamicPartitioningConfiguration: serializeAws_json1_1DynamicPartitioningConfiguration(
1605
- input.DynamicPartitioningConfiguration,
1606
- context
1607
- ),
1608
- }),
1609
- ...(input.EncryptionConfiguration !== undefined &&
1610
- input.EncryptionConfiguration !== null && {
1611
- EncryptionConfiguration: serializeAws_json1_1EncryptionConfiguration(input.EncryptionConfiguration, context),
1612
- }),
1613
- ...(input.ErrorOutputPrefix !== undefined &&
1614
- input.ErrorOutputPrefix !== null && { ErrorOutputPrefix: input.ErrorOutputPrefix }),
1615
- ...(input.Prefix !== undefined && input.Prefix !== null && { Prefix: input.Prefix }),
1616
- ...(input.ProcessingConfiguration !== undefined &&
1617
- input.ProcessingConfiguration !== null && {
1618
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
1619
- }),
1620
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1621
- ...(input.S3BackupConfiguration !== undefined &&
1622
- input.S3BackupConfiguration !== null && {
1623
- S3BackupConfiguration: serializeAws_json1_1S3DestinationConfiguration(input.S3BackupConfiguration, context),
1624
- }),
1625
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
1626
- };
1627
- };
1628
-
1629
- const serializeAws_json1_1ExtendedS3DestinationUpdate = (
1630
- input: ExtendedS3DestinationUpdate,
1631
- context: __SerdeContext
1632
- ): any => {
1633
- return {
1634
- ...(input.BucketARN !== undefined && input.BucketARN !== null && { BucketARN: input.BucketARN }),
1635
- ...(input.BufferingHints !== undefined &&
1636
- input.BufferingHints !== null && {
1637
- BufferingHints: serializeAws_json1_1BufferingHints(input.BufferingHints, context),
1638
- }),
1639
- ...(input.CloudWatchLoggingOptions !== undefined &&
1640
- input.CloudWatchLoggingOptions !== null && {
1641
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
1642
- }),
1643
- ...(input.CompressionFormat !== undefined &&
1644
- input.CompressionFormat !== null && { CompressionFormat: input.CompressionFormat }),
1645
- ...(input.DataFormatConversionConfiguration !== undefined &&
1646
- input.DataFormatConversionConfiguration !== null && {
1647
- DataFormatConversionConfiguration: serializeAws_json1_1DataFormatConversionConfiguration(
1648
- input.DataFormatConversionConfiguration,
1649
- context
1650
- ),
1651
- }),
1652
- ...(input.DynamicPartitioningConfiguration !== undefined &&
1653
- input.DynamicPartitioningConfiguration !== null && {
1654
- DynamicPartitioningConfiguration: serializeAws_json1_1DynamicPartitioningConfiguration(
1655
- input.DynamicPartitioningConfiguration,
1656
- context
1657
- ),
1658
- }),
1659
- ...(input.EncryptionConfiguration !== undefined &&
1660
- input.EncryptionConfiguration !== null && {
1661
- EncryptionConfiguration: serializeAws_json1_1EncryptionConfiguration(input.EncryptionConfiguration, context),
1662
- }),
1663
- ...(input.ErrorOutputPrefix !== undefined &&
1664
- input.ErrorOutputPrefix !== null && { ErrorOutputPrefix: input.ErrorOutputPrefix }),
1665
- ...(input.Prefix !== undefined && input.Prefix !== null && { Prefix: input.Prefix }),
1666
- ...(input.ProcessingConfiguration !== undefined &&
1667
- input.ProcessingConfiguration !== null && {
1668
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
1669
- }),
1670
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1671
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
1672
- ...(input.S3BackupUpdate !== undefined &&
1673
- input.S3BackupUpdate !== null && {
1674
- S3BackupUpdate: serializeAws_json1_1S3DestinationUpdate(input.S3BackupUpdate, context),
1675
- }),
1676
- };
1677
- };
1678
-
1679
- const serializeAws_json1_1HiveJsonSerDe = (input: HiveJsonSerDe, context: __SerdeContext): any => {
1680
- return {
1681
- ...(input.TimestampFormats !== undefined &&
1682
- input.TimestampFormats !== null && {
1683
- TimestampFormats: serializeAws_json1_1ListOfNonEmptyStrings(input.TimestampFormats, context),
1684
- }),
1685
- };
1686
- };
1687
-
1688
- const serializeAws_json1_1HttpEndpointBufferingHints = (
1689
- input: HttpEndpointBufferingHints,
1690
- context: __SerdeContext
1691
- ): any => {
1692
- return {
1693
- ...(input.IntervalInSeconds !== undefined &&
1694
- input.IntervalInSeconds !== null && { IntervalInSeconds: input.IntervalInSeconds }),
1695
- ...(input.SizeInMBs !== undefined && input.SizeInMBs !== null && { SizeInMBs: input.SizeInMBs }),
1696
- };
1697
- };
1698
-
1699
- const serializeAws_json1_1HttpEndpointCommonAttribute = (
1700
- input: HttpEndpointCommonAttribute,
1701
- context: __SerdeContext
1702
- ): any => {
1703
- return {
1704
- ...(input.AttributeName !== undefined && input.AttributeName !== null && { AttributeName: input.AttributeName }),
1705
- ...(input.AttributeValue !== undefined &&
1706
- input.AttributeValue !== null && { AttributeValue: input.AttributeValue }),
1707
- };
1708
- };
1709
-
1710
- const serializeAws_json1_1HttpEndpointCommonAttributesList = (
1711
- input: HttpEndpointCommonAttribute[],
1712
- context: __SerdeContext
1713
- ): any => {
1714
- return input
1715
- .filter((e: any) => e != null)
1716
- .map((entry) => {
1717
- if (entry === null) {
1718
- return null as any;
1719
- }
1720
- return serializeAws_json1_1HttpEndpointCommonAttribute(entry, context);
1721
- });
1722
- };
1723
-
1724
- const serializeAws_json1_1HttpEndpointConfiguration = (
1725
- input: HttpEndpointConfiguration,
1726
- context: __SerdeContext
1727
- ): any => {
1728
- return {
1729
- ...(input.AccessKey !== undefined && input.AccessKey !== null && { AccessKey: input.AccessKey }),
1730
- ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
1731
- ...(input.Url !== undefined && input.Url !== null && { Url: input.Url }),
1732
- };
1733
- };
1734
-
1735
- const serializeAws_json1_1HttpEndpointDestinationConfiguration = (
1736
- input: HttpEndpointDestinationConfiguration,
1737
- context: __SerdeContext
1738
- ): any => {
1739
- return {
1740
- ...(input.BufferingHints !== undefined &&
1741
- input.BufferingHints !== null && {
1742
- BufferingHints: serializeAws_json1_1HttpEndpointBufferingHints(input.BufferingHints, context),
1743
- }),
1744
- ...(input.CloudWatchLoggingOptions !== undefined &&
1745
- input.CloudWatchLoggingOptions !== null && {
1746
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
1747
- }),
1748
- ...(input.EndpointConfiguration !== undefined &&
1749
- input.EndpointConfiguration !== null && {
1750
- EndpointConfiguration: serializeAws_json1_1HttpEndpointConfiguration(input.EndpointConfiguration, context),
1751
- }),
1752
- ...(input.ProcessingConfiguration !== undefined &&
1753
- input.ProcessingConfiguration !== null && {
1754
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
1755
- }),
1756
- ...(input.RequestConfiguration !== undefined &&
1757
- input.RequestConfiguration !== null && {
1758
- RequestConfiguration: serializeAws_json1_1HttpEndpointRequestConfiguration(input.RequestConfiguration, context),
1759
- }),
1760
- ...(input.RetryOptions !== undefined &&
1761
- input.RetryOptions !== null && {
1762
- RetryOptions: serializeAws_json1_1HttpEndpointRetryOptions(input.RetryOptions, context),
1763
- }),
1764
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1765
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
1766
- ...(input.S3Configuration !== undefined &&
1767
- input.S3Configuration !== null && {
1768
- S3Configuration: serializeAws_json1_1S3DestinationConfiguration(input.S3Configuration, context),
1769
- }),
1770
- };
1771
- };
1772
-
1773
- const serializeAws_json1_1HttpEndpointDestinationUpdate = (
1774
- input: HttpEndpointDestinationUpdate,
1775
- context: __SerdeContext
1776
- ): any => {
1777
- return {
1778
- ...(input.BufferingHints !== undefined &&
1779
- input.BufferingHints !== null && {
1780
- BufferingHints: serializeAws_json1_1HttpEndpointBufferingHints(input.BufferingHints, context),
1781
- }),
1782
- ...(input.CloudWatchLoggingOptions !== undefined &&
1783
- input.CloudWatchLoggingOptions !== null && {
1784
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
1785
- }),
1786
- ...(input.EndpointConfiguration !== undefined &&
1787
- input.EndpointConfiguration !== null && {
1788
- EndpointConfiguration: serializeAws_json1_1HttpEndpointConfiguration(input.EndpointConfiguration, context),
1789
- }),
1790
- ...(input.ProcessingConfiguration !== undefined &&
1791
- input.ProcessingConfiguration !== null && {
1792
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
1793
- }),
1794
- ...(input.RequestConfiguration !== undefined &&
1795
- input.RequestConfiguration !== null && {
1796
- RequestConfiguration: serializeAws_json1_1HttpEndpointRequestConfiguration(input.RequestConfiguration, context),
1797
- }),
1798
- ...(input.RetryOptions !== undefined &&
1799
- input.RetryOptions !== null && {
1800
- RetryOptions: serializeAws_json1_1HttpEndpointRetryOptions(input.RetryOptions, context),
1801
- }),
1802
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1803
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
1804
- ...(input.S3Update !== undefined &&
1805
- input.S3Update !== null && { S3Update: serializeAws_json1_1S3DestinationUpdate(input.S3Update, context) }),
1806
- };
1807
- };
1808
-
1809
- const serializeAws_json1_1HttpEndpointRequestConfiguration = (
1810
- input: HttpEndpointRequestConfiguration,
1811
- context: __SerdeContext
1812
- ): any => {
1813
- return {
1814
- ...(input.CommonAttributes !== undefined &&
1815
- input.CommonAttributes !== null && {
1816
- CommonAttributes: serializeAws_json1_1HttpEndpointCommonAttributesList(input.CommonAttributes, context),
1817
- }),
1818
- ...(input.ContentEncoding !== undefined &&
1819
- input.ContentEncoding !== null && { ContentEncoding: input.ContentEncoding }),
1820
- };
1821
- };
1822
-
1823
- const serializeAws_json1_1HttpEndpointRetryOptions = (
1824
- input: HttpEndpointRetryOptions,
1825
- context: __SerdeContext
1826
- ): any => {
1827
- return {
1828
- ...(input.DurationInSeconds !== undefined &&
1829
- input.DurationInSeconds !== null && { DurationInSeconds: input.DurationInSeconds }),
1830
- };
1831
- };
1832
-
1833
- const serializeAws_json1_1InputFormatConfiguration = (
1834
- input: InputFormatConfiguration,
1835
- context: __SerdeContext
1836
- ): any => {
1837
- return {
1838
- ...(input.Deserializer !== undefined &&
1839
- input.Deserializer !== null && { Deserializer: serializeAws_json1_1Deserializer(input.Deserializer, context) }),
1840
- };
1841
- };
1842
-
1843
- const serializeAws_json1_1KinesisStreamSourceConfiguration = (
1844
- input: KinesisStreamSourceConfiguration,
1845
- context: __SerdeContext
1846
- ): any => {
1847
- return {
1848
- ...(input.KinesisStreamARN !== undefined &&
1849
- input.KinesisStreamARN !== null && { KinesisStreamARN: input.KinesisStreamARN }),
1850
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
1851
- };
1852
- };
1853
-
1854
- const serializeAws_json1_1KMSEncryptionConfig = (input: KMSEncryptionConfig, context: __SerdeContext): any => {
1855
- return {
1856
- ...(input.AWSKMSKeyARN !== undefined && input.AWSKMSKeyARN !== null && { AWSKMSKeyARN: input.AWSKMSKeyARN }),
1857
- };
1858
- };
1859
-
1860
- const serializeAws_json1_1ListDeliveryStreamsInput = (
1861
- input: ListDeliveryStreamsInput,
1862
- context: __SerdeContext
1863
- ): any => {
1864
- return {
1865
- ...(input.DeliveryStreamType !== undefined &&
1866
- input.DeliveryStreamType !== null && { DeliveryStreamType: input.DeliveryStreamType }),
1867
- ...(input.ExclusiveStartDeliveryStreamName !== undefined &&
1868
- input.ExclusiveStartDeliveryStreamName !== null && {
1869
- ExclusiveStartDeliveryStreamName: input.ExclusiveStartDeliveryStreamName,
1870
- }),
1871
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
1872
- };
1873
- };
1874
-
1875
- const serializeAws_json1_1ListOfNonEmptyStrings = (input: string[], context: __SerdeContext): any => {
1876
- return input
1877
- .filter((e: any) => e != null)
1878
- .map((entry) => {
1879
- if (entry === null) {
1880
- return null as any;
1881
- }
1882
- return entry;
1883
- });
1884
- };
1885
-
1886
- const serializeAws_json1_1ListOfNonEmptyStringsWithoutWhitespace = (input: string[], context: __SerdeContext): any => {
1887
- return input
1888
- .filter((e: any) => e != null)
1889
- .map((entry) => {
1890
- if (entry === null) {
1891
- return null as any;
1892
- }
1893
- return entry;
1894
- });
1895
- };
1896
-
1897
- const serializeAws_json1_1ListTagsForDeliveryStreamInput = (
1898
- input: ListTagsForDeliveryStreamInput,
1899
- context: __SerdeContext
1900
- ): any => {
1901
- return {
1902
- ...(input.DeliveryStreamName !== undefined &&
1903
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
1904
- ...(input.ExclusiveStartTagKey !== undefined &&
1905
- input.ExclusiveStartTagKey !== null && { ExclusiveStartTagKey: input.ExclusiveStartTagKey }),
1906
- ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }),
1907
- };
1908
- };
1909
-
1910
- const serializeAws_json1_1OpenXJsonSerDe = (input: OpenXJsonSerDe, context: __SerdeContext): any => {
1911
- return {
1912
- ...(input.CaseInsensitive !== undefined &&
1913
- input.CaseInsensitive !== null && { CaseInsensitive: input.CaseInsensitive }),
1914
- ...(input.ColumnToJsonKeyMappings !== undefined &&
1915
- input.ColumnToJsonKeyMappings !== null && {
1916
- ColumnToJsonKeyMappings: serializeAws_json1_1ColumnToJsonKeyMappings(input.ColumnToJsonKeyMappings, context),
1917
- }),
1918
- ...(input.ConvertDotsInJsonKeysToUnderscores !== undefined &&
1919
- input.ConvertDotsInJsonKeysToUnderscores !== null && {
1920
- ConvertDotsInJsonKeysToUnderscores: input.ConvertDotsInJsonKeysToUnderscores,
1921
- }),
1922
- };
1923
- };
1924
-
1925
- const serializeAws_json1_1OrcSerDe = (input: OrcSerDe, context: __SerdeContext): any => {
1926
- return {
1927
- ...(input.BlockSizeBytes !== undefined &&
1928
- input.BlockSizeBytes !== null && { BlockSizeBytes: input.BlockSizeBytes }),
1929
- ...(input.BloomFilterColumns !== undefined &&
1930
- input.BloomFilterColumns !== null && {
1931
- BloomFilterColumns: serializeAws_json1_1ListOfNonEmptyStringsWithoutWhitespace(
1932
- input.BloomFilterColumns,
1933
- context
1934
- ),
1935
- }),
1936
- ...(input.BloomFilterFalsePositiveProbability !== undefined &&
1937
- input.BloomFilterFalsePositiveProbability !== null && {
1938
- BloomFilterFalsePositiveProbability: __serializeFloat(input.BloomFilterFalsePositiveProbability),
1939
- }),
1940
- ...(input.Compression !== undefined && input.Compression !== null && { Compression: input.Compression }),
1941
- ...(input.DictionaryKeyThreshold !== undefined &&
1942
- input.DictionaryKeyThreshold !== null && {
1943
- DictionaryKeyThreshold: __serializeFloat(input.DictionaryKeyThreshold),
1944
- }),
1945
- ...(input.EnablePadding !== undefined && input.EnablePadding !== null && { EnablePadding: input.EnablePadding }),
1946
- ...(input.FormatVersion !== undefined && input.FormatVersion !== null && { FormatVersion: input.FormatVersion }),
1947
- ...(input.PaddingTolerance !== undefined &&
1948
- input.PaddingTolerance !== null && { PaddingTolerance: __serializeFloat(input.PaddingTolerance) }),
1949
- ...(input.RowIndexStride !== undefined &&
1950
- input.RowIndexStride !== null && { RowIndexStride: input.RowIndexStride }),
1951
- ...(input.StripeSizeBytes !== undefined &&
1952
- input.StripeSizeBytes !== null && { StripeSizeBytes: input.StripeSizeBytes }),
1953
- };
1954
- };
1955
-
1956
- const serializeAws_json1_1OutputFormatConfiguration = (
1957
- input: OutputFormatConfiguration,
1958
- context: __SerdeContext
1959
- ): any => {
1960
- return {
1961
- ...(input.Serializer !== undefined &&
1962
- input.Serializer !== null && { Serializer: serializeAws_json1_1Serializer(input.Serializer, context) }),
1963
- };
1964
- };
1965
-
1966
- const serializeAws_json1_1ParquetSerDe = (input: ParquetSerDe, context: __SerdeContext): any => {
1967
- return {
1968
- ...(input.BlockSizeBytes !== undefined &&
1969
- input.BlockSizeBytes !== null && { BlockSizeBytes: input.BlockSizeBytes }),
1970
- ...(input.Compression !== undefined && input.Compression !== null && { Compression: input.Compression }),
1971
- ...(input.EnableDictionaryCompression !== undefined &&
1972
- input.EnableDictionaryCompression !== null && { EnableDictionaryCompression: input.EnableDictionaryCompression }),
1973
- ...(input.MaxPaddingBytes !== undefined &&
1974
- input.MaxPaddingBytes !== null && { MaxPaddingBytes: input.MaxPaddingBytes }),
1975
- ...(input.PageSizeBytes !== undefined && input.PageSizeBytes !== null && { PageSizeBytes: input.PageSizeBytes }),
1976
- ...(input.WriterVersion !== undefined && input.WriterVersion !== null && { WriterVersion: input.WriterVersion }),
1977
- };
1978
- };
1979
-
1980
- const serializeAws_json1_1ProcessingConfiguration = (input: ProcessingConfiguration, context: __SerdeContext): any => {
1981
- return {
1982
- ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }),
1983
- ...(input.Processors !== undefined &&
1984
- input.Processors !== null && { Processors: serializeAws_json1_1ProcessorList(input.Processors, context) }),
1985
- };
1986
- };
1987
-
1988
- const serializeAws_json1_1Processor = (input: Processor, context: __SerdeContext): any => {
1989
- return {
1990
- ...(input.Parameters !== undefined &&
1991
- input.Parameters !== null && {
1992
- Parameters: serializeAws_json1_1ProcessorParameterList(input.Parameters, context),
1993
- }),
1994
- ...(input.Type !== undefined && input.Type !== null && { Type: input.Type }),
1995
- };
1996
- };
1997
-
1998
- const serializeAws_json1_1ProcessorList = (input: Processor[], context: __SerdeContext): any => {
1999
- return input
2000
- .filter((e: any) => e != null)
2001
- .map((entry) => {
2002
- if (entry === null) {
2003
- return null as any;
2004
- }
2005
- return serializeAws_json1_1Processor(entry, context);
2006
- });
2007
- };
2008
-
2009
- const serializeAws_json1_1ProcessorParameter = (input: ProcessorParameter, context: __SerdeContext): any => {
2010
- return {
2011
- ...(input.ParameterName !== undefined && input.ParameterName !== null && { ParameterName: input.ParameterName }),
2012
- ...(input.ParameterValue !== undefined &&
2013
- input.ParameterValue !== null && { ParameterValue: input.ParameterValue }),
2014
- };
2015
- };
2016
-
2017
- const serializeAws_json1_1ProcessorParameterList = (input: ProcessorParameter[], context: __SerdeContext): any => {
2018
- return input
2019
- .filter((e: any) => e != null)
2020
- .map((entry) => {
2021
- if (entry === null) {
2022
- return null as any;
2023
- }
2024
- return serializeAws_json1_1ProcessorParameter(entry, context);
2025
- });
2026
- };
2027
-
2028
- const serializeAws_json1_1PutRecordBatchInput = (input: PutRecordBatchInput, context: __SerdeContext): any => {
2029
- return {
2030
- ...(input.DeliveryStreamName !== undefined &&
2031
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2032
- ...(input.Records !== undefined &&
2033
- input.Records !== null && {
2034
- Records: serializeAws_json1_1PutRecordBatchRequestEntryList(input.Records, context),
2035
- }),
2036
- };
2037
- };
2038
-
2039
- const serializeAws_json1_1PutRecordBatchRequestEntryList = (input: _Record[], context: __SerdeContext): any => {
2040
- return input
2041
- .filter((e: any) => e != null)
2042
- .map((entry) => {
2043
- if (entry === null) {
2044
- return null as any;
2045
- }
2046
- return serializeAws_json1_1_Record(entry, context);
2047
- });
2048
- };
2049
-
2050
- const serializeAws_json1_1PutRecordInput = (input: PutRecordInput, context: __SerdeContext): any => {
2051
- return {
2052
- ...(input.DeliveryStreamName !== undefined &&
2053
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2054
- ...(input.Record !== undefined &&
2055
- input.Record !== null && { Record: serializeAws_json1_1_Record(input.Record, context) }),
2056
- };
2057
- };
2058
-
2059
- const serializeAws_json1_1_Record = (input: _Record, context: __SerdeContext): any => {
2060
- return {
2061
- ...(input.Data !== undefined && input.Data !== null && { Data: context.base64Encoder(input.Data) }),
2062
- };
2063
- };
2064
-
2065
- const serializeAws_json1_1RedshiftDestinationConfiguration = (
2066
- input: RedshiftDestinationConfiguration,
2067
- context: __SerdeContext
2068
- ): any => {
2069
- return {
2070
- ...(input.CloudWatchLoggingOptions !== undefined &&
2071
- input.CloudWatchLoggingOptions !== null && {
2072
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
2073
- }),
2074
- ...(input.ClusterJDBCURL !== undefined &&
2075
- input.ClusterJDBCURL !== null && { ClusterJDBCURL: input.ClusterJDBCURL }),
2076
- ...(input.CopyCommand !== undefined &&
2077
- input.CopyCommand !== null && { CopyCommand: serializeAws_json1_1CopyCommand(input.CopyCommand, context) }),
2078
- ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }),
2079
- ...(input.ProcessingConfiguration !== undefined &&
2080
- input.ProcessingConfiguration !== null && {
2081
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
2082
- }),
2083
- ...(input.RetryOptions !== undefined &&
2084
- input.RetryOptions !== null && {
2085
- RetryOptions: serializeAws_json1_1RedshiftRetryOptions(input.RetryOptions, context),
2086
- }),
2087
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
2088
- ...(input.S3BackupConfiguration !== undefined &&
2089
- input.S3BackupConfiguration !== null && {
2090
- S3BackupConfiguration: serializeAws_json1_1S3DestinationConfiguration(input.S3BackupConfiguration, context),
2091
- }),
2092
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
2093
- ...(input.S3Configuration !== undefined &&
2094
- input.S3Configuration !== null && {
2095
- S3Configuration: serializeAws_json1_1S3DestinationConfiguration(input.S3Configuration, context),
2096
- }),
2097
- ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }),
2098
- };
2099
- };
2100
-
2101
- const serializeAws_json1_1RedshiftDestinationUpdate = (
2102
- input: RedshiftDestinationUpdate,
2103
- context: __SerdeContext
2104
- ): any => {
2105
- return {
2106
- ...(input.CloudWatchLoggingOptions !== undefined &&
2107
- input.CloudWatchLoggingOptions !== null && {
2108
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
2109
- }),
2110
- ...(input.ClusterJDBCURL !== undefined &&
2111
- input.ClusterJDBCURL !== null && { ClusterJDBCURL: input.ClusterJDBCURL }),
2112
- ...(input.CopyCommand !== undefined &&
2113
- input.CopyCommand !== null && { CopyCommand: serializeAws_json1_1CopyCommand(input.CopyCommand, context) }),
2114
- ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }),
2115
- ...(input.ProcessingConfiguration !== undefined &&
2116
- input.ProcessingConfiguration !== null && {
2117
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
2118
- }),
2119
- ...(input.RetryOptions !== undefined &&
2120
- input.RetryOptions !== null && {
2121
- RetryOptions: serializeAws_json1_1RedshiftRetryOptions(input.RetryOptions, context),
2122
- }),
2123
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
2124
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
2125
- ...(input.S3BackupUpdate !== undefined &&
2126
- input.S3BackupUpdate !== null && {
2127
- S3BackupUpdate: serializeAws_json1_1S3DestinationUpdate(input.S3BackupUpdate, context),
2128
- }),
2129
- ...(input.S3Update !== undefined &&
2130
- input.S3Update !== null && { S3Update: serializeAws_json1_1S3DestinationUpdate(input.S3Update, context) }),
2131
- ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }),
2132
- };
2133
- };
2134
-
2135
- const serializeAws_json1_1RedshiftRetryOptions = (input: RedshiftRetryOptions, context: __SerdeContext): any => {
2136
- return {
2137
- ...(input.DurationInSeconds !== undefined &&
2138
- input.DurationInSeconds !== null && { DurationInSeconds: input.DurationInSeconds }),
2139
- };
2140
- };
2141
-
2142
- const serializeAws_json1_1RetryOptions = (input: RetryOptions, context: __SerdeContext): any => {
2143
- return {
2144
- ...(input.DurationInSeconds !== undefined &&
2145
- input.DurationInSeconds !== null && { DurationInSeconds: input.DurationInSeconds }),
2146
- };
2147
- };
2148
-
2149
- const serializeAws_json1_1S3DestinationConfiguration = (
2150
- input: S3DestinationConfiguration,
2151
- context: __SerdeContext
2152
- ): any => {
2153
- return {
2154
- ...(input.BucketARN !== undefined && input.BucketARN !== null && { BucketARN: input.BucketARN }),
2155
- ...(input.BufferingHints !== undefined &&
2156
- input.BufferingHints !== null && {
2157
- BufferingHints: serializeAws_json1_1BufferingHints(input.BufferingHints, context),
2158
- }),
2159
- ...(input.CloudWatchLoggingOptions !== undefined &&
2160
- input.CloudWatchLoggingOptions !== null && {
2161
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
2162
- }),
2163
- ...(input.CompressionFormat !== undefined &&
2164
- input.CompressionFormat !== null && { CompressionFormat: input.CompressionFormat }),
2165
- ...(input.EncryptionConfiguration !== undefined &&
2166
- input.EncryptionConfiguration !== null && {
2167
- EncryptionConfiguration: serializeAws_json1_1EncryptionConfiguration(input.EncryptionConfiguration, context),
2168
- }),
2169
- ...(input.ErrorOutputPrefix !== undefined &&
2170
- input.ErrorOutputPrefix !== null && { ErrorOutputPrefix: input.ErrorOutputPrefix }),
2171
- ...(input.Prefix !== undefined && input.Prefix !== null && { Prefix: input.Prefix }),
2172
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
2173
- };
2174
- };
2175
-
2176
- const serializeAws_json1_1S3DestinationUpdate = (input: S3DestinationUpdate, context: __SerdeContext): any => {
2177
- return {
2178
- ...(input.BucketARN !== undefined && input.BucketARN !== null && { BucketARN: input.BucketARN }),
2179
- ...(input.BufferingHints !== undefined &&
2180
- input.BufferingHints !== null && {
2181
- BufferingHints: serializeAws_json1_1BufferingHints(input.BufferingHints, context),
2182
- }),
2183
- ...(input.CloudWatchLoggingOptions !== undefined &&
2184
- input.CloudWatchLoggingOptions !== null && {
2185
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
2186
- }),
2187
- ...(input.CompressionFormat !== undefined &&
2188
- input.CompressionFormat !== null && { CompressionFormat: input.CompressionFormat }),
2189
- ...(input.EncryptionConfiguration !== undefined &&
2190
- input.EncryptionConfiguration !== null && {
2191
- EncryptionConfiguration: serializeAws_json1_1EncryptionConfiguration(input.EncryptionConfiguration, context),
2192
- }),
2193
- ...(input.ErrorOutputPrefix !== undefined &&
2194
- input.ErrorOutputPrefix !== null && { ErrorOutputPrefix: input.ErrorOutputPrefix }),
2195
- ...(input.Prefix !== undefined && input.Prefix !== null && { Prefix: input.Prefix }),
2196
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
2197
- };
2198
- };
2199
-
2200
- const serializeAws_json1_1SchemaConfiguration = (input: SchemaConfiguration, context: __SerdeContext): any => {
2201
- return {
2202
- ...(input.CatalogId !== undefined && input.CatalogId !== null && { CatalogId: input.CatalogId }),
2203
- ...(input.DatabaseName !== undefined && input.DatabaseName !== null && { DatabaseName: input.DatabaseName }),
2204
- ...(input.Region !== undefined && input.Region !== null && { Region: input.Region }),
2205
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
2206
- ...(input.TableName !== undefined && input.TableName !== null && { TableName: input.TableName }),
2207
- ...(input.VersionId !== undefined && input.VersionId !== null && { VersionId: input.VersionId }),
2208
- };
2209
- };
2210
-
2211
- const serializeAws_json1_1SecurityGroupIdList = (input: string[], context: __SerdeContext): any => {
2212
- return input
2213
- .filter((e: any) => e != null)
2214
- .map((entry) => {
2215
- if (entry === null) {
2216
- return null as any;
2217
- }
2218
- return entry;
2219
- });
2220
- };
2221
-
2222
- const serializeAws_json1_1Serializer = (input: Serializer, context: __SerdeContext): any => {
2223
- return {
2224
- ...(input.OrcSerDe !== undefined &&
2225
- input.OrcSerDe !== null && { OrcSerDe: serializeAws_json1_1OrcSerDe(input.OrcSerDe, context) }),
2226
- ...(input.ParquetSerDe !== undefined &&
2227
- input.ParquetSerDe !== null && { ParquetSerDe: serializeAws_json1_1ParquetSerDe(input.ParquetSerDe, context) }),
2228
- };
2229
- };
2230
-
2231
- const serializeAws_json1_1SplunkDestinationConfiguration = (
2232
- input: SplunkDestinationConfiguration,
2233
- context: __SerdeContext
2234
- ): any => {
2235
- return {
2236
- ...(input.CloudWatchLoggingOptions !== undefined &&
2237
- input.CloudWatchLoggingOptions !== null && {
2238
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
2239
- }),
2240
- ...(input.HECAcknowledgmentTimeoutInSeconds !== undefined &&
2241
- input.HECAcknowledgmentTimeoutInSeconds !== null && {
2242
- HECAcknowledgmentTimeoutInSeconds: input.HECAcknowledgmentTimeoutInSeconds,
2243
- }),
2244
- ...(input.HECEndpoint !== undefined && input.HECEndpoint !== null && { HECEndpoint: input.HECEndpoint }),
2245
- ...(input.HECEndpointType !== undefined &&
2246
- input.HECEndpointType !== null && { HECEndpointType: input.HECEndpointType }),
2247
- ...(input.HECToken !== undefined && input.HECToken !== null && { HECToken: input.HECToken }),
2248
- ...(input.ProcessingConfiguration !== undefined &&
2249
- input.ProcessingConfiguration !== null && {
2250
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
2251
- }),
2252
- ...(input.RetryOptions !== undefined &&
2253
- input.RetryOptions !== null && {
2254
- RetryOptions: serializeAws_json1_1SplunkRetryOptions(input.RetryOptions, context),
2255
- }),
2256
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
2257
- ...(input.S3Configuration !== undefined &&
2258
- input.S3Configuration !== null && {
2259
- S3Configuration: serializeAws_json1_1S3DestinationConfiguration(input.S3Configuration, context),
2260
- }),
2261
- };
2262
- };
2263
-
2264
- const serializeAws_json1_1SplunkDestinationUpdate = (input: SplunkDestinationUpdate, context: __SerdeContext): any => {
2265
- return {
2266
- ...(input.CloudWatchLoggingOptions !== undefined &&
2267
- input.CloudWatchLoggingOptions !== null && {
2268
- CloudWatchLoggingOptions: serializeAws_json1_1CloudWatchLoggingOptions(input.CloudWatchLoggingOptions, context),
2269
- }),
2270
- ...(input.HECAcknowledgmentTimeoutInSeconds !== undefined &&
2271
- input.HECAcknowledgmentTimeoutInSeconds !== null && {
2272
- HECAcknowledgmentTimeoutInSeconds: input.HECAcknowledgmentTimeoutInSeconds,
2273
- }),
2274
- ...(input.HECEndpoint !== undefined && input.HECEndpoint !== null && { HECEndpoint: input.HECEndpoint }),
2275
- ...(input.HECEndpointType !== undefined &&
2276
- input.HECEndpointType !== null && { HECEndpointType: input.HECEndpointType }),
2277
- ...(input.HECToken !== undefined && input.HECToken !== null && { HECToken: input.HECToken }),
2278
- ...(input.ProcessingConfiguration !== undefined &&
2279
- input.ProcessingConfiguration !== null && {
2280
- ProcessingConfiguration: serializeAws_json1_1ProcessingConfiguration(input.ProcessingConfiguration, context),
2281
- }),
2282
- ...(input.RetryOptions !== undefined &&
2283
- input.RetryOptions !== null && {
2284
- RetryOptions: serializeAws_json1_1SplunkRetryOptions(input.RetryOptions, context),
2285
- }),
2286
- ...(input.S3BackupMode !== undefined && input.S3BackupMode !== null && { S3BackupMode: input.S3BackupMode }),
2287
- ...(input.S3Update !== undefined &&
2288
- input.S3Update !== null && { S3Update: serializeAws_json1_1S3DestinationUpdate(input.S3Update, context) }),
2289
- };
2290
- };
2291
-
2292
- const serializeAws_json1_1SplunkRetryOptions = (input: SplunkRetryOptions, context: __SerdeContext): any => {
2293
- return {
2294
- ...(input.DurationInSeconds !== undefined &&
2295
- input.DurationInSeconds !== null && { DurationInSeconds: input.DurationInSeconds }),
2296
- };
2297
- };
2298
-
2299
- const serializeAws_json1_1StartDeliveryStreamEncryptionInput = (
2300
- input: StartDeliveryStreamEncryptionInput,
2301
- context: __SerdeContext
2302
- ): any => {
2303
- return {
2304
- ...(input.DeliveryStreamEncryptionConfigurationInput !== undefined &&
2305
- input.DeliveryStreamEncryptionConfigurationInput !== null && {
2306
- DeliveryStreamEncryptionConfigurationInput: serializeAws_json1_1DeliveryStreamEncryptionConfigurationInput(
2307
- input.DeliveryStreamEncryptionConfigurationInput,
2308
- context
2309
- ),
2310
- }),
2311
- ...(input.DeliveryStreamName !== undefined &&
2312
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2313
- };
2314
- };
2315
-
2316
- const serializeAws_json1_1StopDeliveryStreamEncryptionInput = (
2317
- input: StopDeliveryStreamEncryptionInput,
2318
- context: __SerdeContext
2319
- ): any => {
2320
- return {
2321
- ...(input.DeliveryStreamName !== undefined &&
2322
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2323
- };
2324
- };
2325
-
2326
- const serializeAws_json1_1SubnetIdList = (input: string[], context: __SerdeContext): any => {
2327
- return input
2328
- .filter((e: any) => e != null)
2329
- .map((entry) => {
2330
- if (entry === null) {
2331
- return null as any;
2332
- }
2333
- return entry;
2334
- });
2335
- };
2336
-
2337
- const serializeAws_json1_1Tag = (input: Tag, context: __SerdeContext): any => {
2338
- return {
2339
- ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
2340
- ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
2341
- };
2342
- };
2343
-
2344
- const serializeAws_json1_1TagDeliveryStreamInput = (input: TagDeliveryStreamInput, context: __SerdeContext): any => {
2345
- return {
2346
- ...(input.DeliveryStreamName !== undefined &&
2347
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2348
- ...(input.Tags !== undefined &&
2349
- input.Tags !== null && { Tags: serializeAws_json1_1TagDeliveryStreamInputTagList(input.Tags, context) }),
2350
- };
2351
- };
2352
-
2353
- const serializeAws_json1_1TagDeliveryStreamInputTagList = (input: Tag[], context: __SerdeContext): any => {
2354
- return input
2355
- .filter((e: any) => e != null)
2356
- .map((entry) => {
2357
- if (entry === null) {
2358
- return null as any;
2359
- }
2360
- return serializeAws_json1_1Tag(entry, context);
2361
- });
2362
- };
2363
-
2364
- const serializeAws_json1_1TagKeyList = (input: string[], context: __SerdeContext): any => {
2365
- return input
2366
- .filter((e: any) => e != null)
2367
- .map((entry) => {
2368
- if (entry === null) {
2369
- return null as any;
2370
- }
2371
- return entry;
2372
- });
2373
- };
2374
-
2375
- const serializeAws_json1_1UntagDeliveryStreamInput = (
2376
- input: UntagDeliveryStreamInput,
2377
- context: __SerdeContext
2378
- ): any => {
2379
- return {
2380
- ...(input.DeliveryStreamName !== undefined &&
2381
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2382
- ...(input.TagKeys !== undefined &&
2383
- input.TagKeys !== null && { TagKeys: serializeAws_json1_1TagKeyList(input.TagKeys, context) }),
2384
- };
2385
- };
2386
-
2387
- const serializeAws_json1_1UpdateDestinationInput = (input: UpdateDestinationInput, context: __SerdeContext): any => {
2388
- return {
2389
- ...(input.CurrentDeliveryStreamVersionId !== undefined &&
2390
- input.CurrentDeliveryStreamVersionId !== null && {
2391
- CurrentDeliveryStreamVersionId: input.CurrentDeliveryStreamVersionId,
2392
- }),
2393
- ...(input.DeliveryStreamName !== undefined &&
2394
- input.DeliveryStreamName !== null && { DeliveryStreamName: input.DeliveryStreamName }),
2395
- ...(input.DestinationId !== undefined && input.DestinationId !== null && { DestinationId: input.DestinationId }),
2396
- ...(input.ElasticsearchDestinationUpdate !== undefined &&
2397
- input.ElasticsearchDestinationUpdate !== null && {
2398
- ElasticsearchDestinationUpdate: serializeAws_json1_1ElasticsearchDestinationUpdate(
2399
- input.ElasticsearchDestinationUpdate,
2400
- context
2401
- ),
2402
- }),
2403
- ...(input.ExtendedS3DestinationUpdate !== undefined &&
2404
- input.ExtendedS3DestinationUpdate !== null && {
2405
- ExtendedS3DestinationUpdate: serializeAws_json1_1ExtendedS3DestinationUpdate(
2406
- input.ExtendedS3DestinationUpdate,
2407
- context
2408
- ),
2409
- }),
2410
- ...(input.HttpEndpointDestinationUpdate !== undefined &&
2411
- input.HttpEndpointDestinationUpdate !== null && {
2412
- HttpEndpointDestinationUpdate: serializeAws_json1_1HttpEndpointDestinationUpdate(
2413
- input.HttpEndpointDestinationUpdate,
2414
- context
2415
- ),
2416
- }),
2417
- ...(input.RedshiftDestinationUpdate !== undefined &&
2418
- input.RedshiftDestinationUpdate !== null && {
2419
- RedshiftDestinationUpdate: serializeAws_json1_1RedshiftDestinationUpdate(
2420
- input.RedshiftDestinationUpdate,
2421
- context
2422
- ),
2423
- }),
2424
- ...(input.S3DestinationUpdate !== undefined &&
2425
- input.S3DestinationUpdate !== null && {
2426
- S3DestinationUpdate: serializeAws_json1_1S3DestinationUpdate(input.S3DestinationUpdate, context),
2427
- }),
2428
- ...(input.SplunkDestinationUpdate !== undefined &&
2429
- input.SplunkDestinationUpdate !== null && {
2430
- SplunkDestinationUpdate: serializeAws_json1_1SplunkDestinationUpdate(input.SplunkDestinationUpdate, context),
2431
- }),
2432
- };
2433
- };
2434
-
2435
- const serializeAws_json1_1VpcConfiguration = (input: VpcConfiguration, context: __SerdeContext): any => {
2436
- return {
2437
- ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }),
2438
- ...(input.SecurityGroupIds !== undefined &&
2439
- input.SecurityGroupIds !== null && {
2440
- SecurityGroupIds: serializeAws_json1_1SecurityGroupIdList(input.SecurityGroupIds, context),
2441
- }),
2442
- ...(input.SubnetIds !== undefined &&
2443
- input.SubnetIds !== null && { SubnetIds: serializeAws_json1_1SubnetIdList(input.SubnetIds, context) }),
2444
- };
2445
- };
2446
-
2447
- const deserializeAws_json1_1BufferingHints = (output: any, context: __SerdeContext): BufferingHints => {
2448
- return {
2449
- IntervalInSeconds: __expectInt32(output.IntervalInSeconds),
2450
- SizeInMBs: __expectInt32(output.SizeInMBs),
2451
- } as any;
2452
- };
2453
-
2454
- const deserializeAws_json1_1CloudWatchLoggingOptions = (
2455
- output: any,
2456
- context: __SerdeContext
2457
- ): CloudWatchLoggingOptions => {
2458
- return {
2459
- Enabled: __expectBoolean(output.Enabled),
2460
- LogGroupName: __expectString(output.LogGroupName),
2461
- LogStreamName: __expectString(output.LogStreamName),
2462
- } as any;
2463
- };
2464
-
2465
- const deserializeAws_json1_1ColumnToJsonKeyMappings = (
2466
- output: any,
2467
- context: __SerdeContext
2468
- ): { [key: string]: string } => {
2469
- return Object.entries(output).reduce((acc: { [key: string]: string }, [key, value]: [string, any]) => {
2470
- if (value === null) {
2471
- return acc;
2472
- }
2473
- return {
2474
- ...acc,
2475
- [key]: __expectString(value) as any,
2476
- };
2477
- }, {});
2478
- };
2479
-
2480
- const deserializeAws_json1_1ConcurrentModificationException = (
2481
- output: any,
2482
- context: __SerdeContext
2483
- ): ConcurrentModificationException => {
2484
- return {
2485
- message: __expectString(output.message),
2486
- } as any;
2487
- };
2488
-
2489
- const deserializeAws_json1_1CopyCommand = (output: any, context: __SerdeContext): CopyCommand => {
2490
- return {
2491
- CopyOptions: __expectString(output.CopyOptions),
2492
- DataTableColumns: __expectString(output.DataTableColumns),
2493
- DataTableName: __expectString(output.DataTableName),
2494
- } as any;
2495
- };
2496
-
2497
- const deserializeAws_json1_1CreateDeliveryStreamOutput = (
2498
- output: any,
2499
- context: __SerdeContext
2500
- ): CreateDeliveryStreamOutput => {
2501
- return {
2502
- DeliveryStreamARN: __expectString(output.DeliveryStreamARN),
2503
- } as any;
2504
- };
2505
-
2506
- const deserializeAws_json1_1DataFormatConversionConfiguration = (
2507
- output: any,
2508
- context: __SerdeContext
2509
- ): DataFormatConversionConfiguration => {
2510
- return {
2511
- Enabled: __expectBoolean(output.Enabled),
2512
- InputFormatConfiguration:
2513
- output.InputFormatConfiguration !== undefined && output.InputFormatConfiguration !== null
2514
- ? deserializeAws_json1_1InputFormatConfiguration(output.InputFormatConfiguration, context)
2515
- : undefined,
2516
- OutputFormatConfiguration:
2517
- output.OutputFormatConfiguration !== undefined && output.OutputFormatConfiguration !== null
2518
- ? deserializeAws_json1_1OutputFormatConfiguration(output.OutputFormatConfiguration, context)
2519
- : undefined,
2520
- SchemaConfiguration:
2521
- output.SchemaConfiguration !== undefined && output.SchemaConfiguration !== null
2522
- ? deserializeAws_json1_1SchemaConfiguration(output.SchemaConfiguration, context)
2523
- : undefined,
2524
- } as any;
2525
- };
2526
-
2527
- const deserializeAws_json1_1DeleteDeliveryStreamOutput = (
2528
- output: any,
2529
- context: __SerdeContext
2530
- ): DeleteDeliveryStreamOutput => {
2531
- return {} as any;
2532
- };
2533
-
2534
- const deserializeAws_json1_1DeliveryStreamDescription = (
2535
- output: any,
2536
- context: __SerdeContext
2537
- ): DeliveryStreamDescription => {
2538
- return {
2539
- CreateTimestamp:
2540
- output.CreateTimestamp !== undefined && output.CreateTimestamp !== null
2541
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreateTimestamp)))
2542
- : undefined,
2543
- DeliveryStreamARN: __expectString(output.DeliveryStreamARN),
2544
- DeliveryStreamEncryptionConfiguration:
2545
- output.DeliveryStreamEncryptionConfiguration !== undefined &&
2546
- output.DeliveryStreamEncryptionConfiguration !== null
2547
- ? deserializeAws_json1_1DeliveryStreamEncryptionConfiguration(
2548
- output.DeliveryStreamEncryptionConfiguration,
2549
- context
2550
- )
2551
- : undefined,
2552
- DeliveryStreamName: __expectString(output.DeliveryStreamName),
2553
- DeliveryStreamStatus: __expectString(output.DeliveryStreamStatus),
2554
- DeliveryStreamType: __expectString(output.DeliveryStreamType),
2555
- Destinations:
2556
- output.Destinations !== undefined && output.Destinations !== null
2557
- ? deserializeAws_json1_1DestinationDescriptionList(output.Destinations, context)
2558
- : undefined,
2559
- FailureDescription:
2560
- output.FailureDescription !== undefined && output.FailureDescription !== null
2561
- ? deserializeAws_json1_1FailureDescription(output.FailureDescription, context)
2562
- : undefined,
2563
- HasMoreDestinations: __expectBoolean(output.HasMoreDestinations),
2564
- LastUpdateTimestamp:
2565
- output.LastUpdateTimestamp !== undefined && output.LastUpdateTimestamp !== null
2566
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastUpdateTimestamp)))
2567
- : undefined,
2568
- Source:
2569
- output.Source !== undefined && output.Source !== null
2570
- ? deserializeAws_json1_1SourceDescription(output.Source, context)
2571
- : undefined,
2572
- VersionId: __expectString(output.VersionId),
2573
- } as any;
2574
- };
2575
-
2576
- const deserializeAws_json1_1DeliveryStreamEncryptionConfiguration = (
2577
- output: any,
2578
- context: __SerdeContext
2579
- ): DeliveryStreamEncryptionConfiguration => {
2580
- return {
2581
- FailureDescription:
2582
- output.FailureDescription !== undefined && output.FailureDescription !== null
2583
- ? deserializeAws_json1_1FailureDescription(output.FailureDescription, context)
2584
- : undefined,
2585
- KeyARN: __expectString(output.KeyARN),
2586
- KeyType: __expectString(output.KeyType),
2587
- Status: __expectString(output.Status),
2588
- } as any;
2589
- };
2590
-
2591
- const deserializeAws_json1_1DeliveryStreamNameList = (output: any, context: __SerdeContext): string[] => {
2592
- return (output || [])
2593
- .filter((e: any) => e != null)
2594
- .map((entry: any) => {
2595
- if (entry === null) {
2596
- return null as any;
2597
- }
2598
- return __expectString(entry) as any;
2599
- });
2600
- };
2601
-
2602
- const deserializeAws_json1_1DescribeDeliveryStreamOutput = (
2603
- output: any,
2604
- context: __SerdeContext
2605
- ): DescribeDeliveryStreamOutput => {
2606
- return {
2607
- DeliveryStreamDescription:
2608
- output.DeliveryStreamDescription !== undefined && output.DeliveryStreamDescription !== null
2609
- ? deserializeAws_json1_1DeliveryStreamDescription(output.DeliveryStreamDescription, context)
2610
- : undefined,
2611
- } as any;
2612
- };
2613
-
2614
- const deserializeAws_json1_1Deserializer = (output: any, context: __SerdeContext): Deserializer => {
2615
- return {
2616
- HiveJsonSerDe:
2617
- output.HiveJsonSerDe !== undefined && output.HiveJsonSerDe !== null
2618
- ? deserializeAws_json1_1HiveJsonSerDe(output.HiveJsonSerDe, context)
2619
- : undefined,
2620
- OpenXJsonSerDe:
2621
- output.OpenXJsonSerDe !== undefined && output.OpenXJsonSerDe !== null
2622
- ? deserializeAws_json1_1OpenXJsonSerDe(output.OpenXJsonSerDe, context)
2623
- : undefined,
2624
- } as any;
2625
- };
2626
-
2627
- const deserializeAws_json1_1DestinationDescription = (output: any, context: __SerdeContext): DestinationDescription => {
2628
- return {
2629
- DestinationId: __expectString(output.DestinationId),
2630
- ElasticsearchDestinationDescription:
2631
- output.ElasticsearchDestinationDescription !== undefined && output.ElasticsearchDestinationDescription !== null
2632
- ? deserializeAws_json1_1ElasticsearchDestinationDescription(output.ElasticsearchDestinationDescription, context)
2633
- : undefined,
2634
- ExtendedS3DestinationDescription:
2635
- output.ExtendedS3DestinationDescription !== undefined && output.ExtendedS3DestinationDescription !== null
2636
- ? deserializeAws_json1_1ExtendedS3DestinationDescription(output.ExtendedS3DestinationDescription, context)
2637
- : undefined,
2638
- HttpEndpointDestinationDescription:
2639
- output.HttpEndpointDestinationDescription !== undefined && output.HttpEndpointDestinationDescription !== null
2640
- ? deserializeAws_json1_1HttpEndpointDestinationDescription(output.HttpEndpointDestinationDescription, context)
2641
- : undefined,
2642
- RedshiftDestinationDescription:
2643
- output.RedshiftDestinationDescription !== undefined && output.RedshiftDestinationDescription !== null
2644
- ? deserializeAws_json1_1RedshiftDestinationDescription(output.RedshiftDestinationDescription, context)
2645
- : undefined,
2646
- S3DestinationDescription:
2647
- output.S3DestinationDescription !== undefined && output.S3DestinationDescription !== null
2648
- ? deserializeAws_json1_1S3DestinationDescription(output.S3DestinationDescription, context)
2649
- : undefined,
2650
- SplunkDestinationDescription:
2651
- output.SplunkDestinationDescription !== undefined && output.SplunkDestinationDescription !== null
2652
- ? deserializeAws_json1_1SplunkDestinationDescription(output.SplunkDestinationDescription, context)
2653
- : undefined,
2654
- } as any;
2655
- };
2656
-
2657
- const deserializeAws_json1_1DestinationDescriptionList = (
2658
- output: any,
2659
- context: __SerdeContext
2660
- ): DestinationDescription[] => {
2661
- return (output || [])
2662
- .filter((e: any) => e != null)
2663
- .map((entry: any) => {
2664
- if (entry === null) {
2665
- return null as any;
2666
- }
2667
- return deserializeAws_json1_1DestinationDescription(entry, context);
2668
- });
2669
- };
2670
-
2671
- const deserializeAws_json1_1DynamicPartitioningConfiguration = (
2672
- output: any,
2673
- context: __SerdeContext
2674
- ): DynamicPartitioningConfiguration => {
2675
- return {
2676
- Enabled: __expectBoolean(output.Enabled),
2677
- RetryOptions:
2678
- output.RetryOptions !== undefined && output.RetryOptions !== null
2679
- ? deserializeAws_json1_1RetryOptions(output.RetryOptions, context)
2680
- : undefined,
2681
- } as any;
2682
- };
2683
-
2684
- const deserializeAws_json1_1ElasticsearchBufferingHints = (
2685
- output: any,
2686
- context: __SerdeContext
2687
- ): ElasticsearchBufferingHints => {
2688
- return {
2689
- IntervalInSeconds: __expectInt32(output.IntervalInSeconds),
2690
- SizeInMBs: __expectInt32(output.SizeInMBs),
2691
- } as any;
2692
- };
2693
-
2694
- const deserializeAws_json1_1ElasticsearchDestinationDescription = (
2695
- output: any,
2696
- context: __SerdeContext
2697
- ): ElasticsearchDestinationDescription => {
2698
- return {
2699
- BufferingHints:
2700
- output.BufferingHints !== undefined && output.BufferingHints !== null
2701
- ? deserializeAws_json1_1ElasticsearchBufferingHints(output.BufferingHints, context)
2702
- : undefined,
2703
- CloudWatchLoggingOptions:
2704
- output.CloudWatchLoggingOptions !== undefined && output.CloudWatchLoggingOptions !== null
2705
- ? deserializeAws_json1_1CloudWatchLoggingOptions(output.CloudWatchLoggingOptions, context)
2706
- : undefined,
2707
- ClusterEndpoint: __expectString(output.ClusterEndpoint),
2708
- DomainARN: __expectString(output.DomainARN),
2709
- IndexName: __expectString(output.IndexName),
2710
- IndexRotationPeriod: __expectString(output.IndexRotationPeriod),
2711
- ProcessingConfiguration:
2712
- output.ProcessingConfiguration !== undefined && output.ProcessingConfiguration !== null
2713
- ? deserializeAws_json1_1ProcessingConfiguration(output.ProcessingConfiguration, context)
2714
- : undefined,
2715
- RetryOptions:
2716
- output.RetryOptions !== undefined && output.RetryOptions !== null
2717
- ? deserializeAws_json1_1ElasticsearchRetryOptions(output.RetryOptions, context)
2718
- : undefined,
2719
- RoleARN: __expectString(output.RoleARN),
2720
- S3BackupMode: __expectString(output.S3BackupMode),
2721
- S3DestinationDescription:
2722
- output.S3DestinationDescription !== undefined && output.S3DestinationDescription !== null
2723
- ? deserializeAws_json1_1S3DestinationDescription(output.S3DestinationDescription, context)
2724
- : undefined,
2725
- TypeName: __expectString(output.TypeName),
2726
- VpcConfigurationDescription:
2727
- output.VpcConfigurationDescription !== undefined && output.VpcConfigurationDescription !== null
2728
- ? deserializeAws_json1_1VpcConfigurationDescription(output.VpcConfigurationDescription, context)
2729
- : undefined,
2730
- } as any;
2731
- };
2732
-
2733
- const deserializeAws_json1_1ElasticsearchRetryOptions = (
2734
- output: any,
2735
- context: __SerdeContext
2736
- ): ElasticsearchRetryOptions => {
2737
- return {
2738
- DurationInSeconds: __expectInt32(output.DurationInSeconds),
2739
- } as any;
2740
- };
2741
-
2742
- const deserializeAws_json1_1EncryptionConfiguration = (
2743
- output: any,
2744
- context: __SerdeContext
2745
- ): EncryptionConfiguration => {
2746
- return {
2747
- KMSEncryptionConfig:
2748
- output.KMSEncryptionConfig !== undefined && output.KMSEncryptionConfig !== null
2749
- ? deserializeAws_json1_1KMSEncryptionConfig(output.KMSEncryptionConfig, context)
2750
- : undefined,
2751
- NoEncryptionConfig: __expectString(output.NoEncryptionConfig),
2752
- } as any;
2753
- };
2754
-
2755
- const deserializeAws_json1_1ExtendedS3DestinationDescription = (
2756
- output: any,
2757
- context: __SerdeContext
2758
- ): ExtendedS3DestinationDescription => {
2759
- return {
2760
- BucketARN: __expectString(output.BucketARN),
2761
- BufferingHints:
2762
- output.BufferingHints !== undefined && output.BufferingHints !== null
2763
- ? deserializeAws_json1_1BufferingHints(output.BufferingHints, context)
2764
- : undefined,
2765
- CloudWatchLoggingOptions:
2766
- output.CloudWatchLoggingOptions !== undefined && output.CloudWatchLoggingOptions !== null
2767
- ? deserializeAws_json1_1CloudWatchLoggingOptions(output.CloudWatchLoggingOptions, context)
2768
- : undefined,
2769
- CompressionFormat: __expectString(output.CompressionFormat),
2770
- DataFormatConversionConfiguration:
2771
- output.DataFormatConversionConfiguration !== undefined && output.DataFormatConversionConfiguration !== null
2772
- ? deserializeAws_json1_1DataFormatConversionConfiguration(output.DataFormatConversionConfiguration, context)
2773
- : undefined,
2774
- DynamicPartitioningConfiguration:
2775
- output.DynamicPartitioningConfiguration !== undefined && output.DynamicPartitioningConfiguration !== null
2776
- ? deserializeAws_json1_1DynamicPartitioningConfiguration(output.DynamicPartitioningConfiguration, context)
2777
- : undefined,
2778
- EncryptionConfiguration:
2779
- output.EncryptionConfiguration !== undefined && output.EncryptionConfiguration !== null
2780
- ? deserializeAws_json1_1EncryptionConfiguration(output.EncryptionConfiguration, context)
2781
- : undefined,
2782
- ErrorOutputPrefix: __expectString(output.ErrorOutputPrefix),
2783
- Prefix: __expectString(output.Prefix),
2784
- ProcessingConfiguration:
2785
- output.ProcessingConfiguration !== undefined && output.ProcessingConfiguration !== null
2786
- ? deserializeAws_json1_1ProcessingConfiguration(output.ProcessingConfiguration, context)
2787
- : undefined,
2788
- RoleARN: __expectString(output.RoleARN),
2789
- S3BackupDescription:
2790
- output.S3BackupDescription !== undefined && output.S3BackupDescription !== null
2791
- ? deserializeAws_json1_1S3DestinationDescription(output.S3BackupDescription, context)
2792
- : undefined,
2793
- S3BackupMode: __expectString(output.S3BackupMode),
2794
- } as any;
2795
- };
2796
-
2797
- const deserializeAws_json1_1FailureDescription = (output: any, context: __SerdeContext): FailureDescription => {
2798
- return {
2799
- Details: __expectString(output.Details),
2800
- Type: __expectString(output.Type),
2801
- } as any;
2802
- };
2803
-
2804
- const deserializeAws_json1_1HiveJsonSerDe = (output: any, context: __SerdeContext): HiveJsonSerDe => {
2805
- return {
2806
- TimestampFormats:
2807
- output.TimestampFormats !== undefined && output.TimestampFormats !== null
2808
- ? deserializeAws_json1_1ListOfNonEmptyStrings(output.TimestampFormats, context)
2809
- : undefined,
2810
- } as any;
2811
- };
2812
-
2813
- const deserializeAws_json1_1HttpEndpointBufferingHints = (
2814
- output: any,
2815
- context: __SerdeContext
2816
- ): HttpEndpointBufferingHints => {
2817
- return {
2818
- IntervalInSeconds: __expectInt32(output.IntervalInSeconds),
2819
- SizeInMBs: __expectInt32(output.SizeInMBs),
2820
- } as any;
2821
- };
2822
-
2823
- const deserializeAws_json1_1HttpEndpointCommonAttribute = (
2824
- output: any,
2825
- context: __SerdeContext
2826
- ): HttpEndpointCommonAttribute => {
2827
- return {
2828
- AttributeName: __expectString(output.AttributeName),
2829
- AttributeValue: __expectString(output.AttributeValue),
2830
- } as any;
2831
- };
2832
-
2833
- const deserializeAws_json1_1HttpEndpointCommonAttributesList = (
2834
- output: any,
2835
- context: __SerdeContext
2836
- ): HttpEndpointCommonAttribute[] => {
2837
- return (output || [])
2838
- .filter((e: any) => e != null)
2839
- .map((entry: any) => {
2840
- if (entry === null) {
2841
- return null as any;
2842
- }
2843
- return deserializeAws_json1_1HttpEndpointCommonAttribute(entry, context);
2844
- });
2845
- };
2846
-
2847
- const deserializeAws_json1_1HttpEndpointDescription = (
2848
- output: any,
2849
- context: __SerdeContext
2850
- ): HttpEndpointDescription => {
2851
- return {
2852
- Name: __expectString(output.Name),
2853
- Url: __expectString(output.Url),
2854
- } as any;
2855
- };
2856
-
2857
- const deserializeAws_json1_1HttpEndpointDestinationDescription = (
2858
- output: any,
2859
- context: __SerdeContext
2860
- ): HttpEndpointDestinationDescription => {
2861
- return {
2862
- BufferingHints:
2863
- output.BufferingHints !== undefined && output.BufferingHints !== null
2864
- ? deserializeAws_json1_1HttpEndpointBufferingHints(output.BufferingHints, context)
2865
- : undefined,
2866
- CloudWatchLoggingOptions:
2867
- output.CloudWatchLoggingOptions !== undefined && output.CloudWatchLoggingOptions !== null
2868
- ? deserializeAws_json1_1CloudWatchLoggingOptions(output.CloudWatchLoggingOptions, context)
2869
- : undefined,
2870
- EndpointConfiguration:
2871
- output.EndpointConfiguration !== undefined && output.EndpointConfiguration !== null
2872
- ? deserializeAws_json1_1HttpEndpointDescription(output.EndpointConfiguration, context)
2873
- : undefined,
2874
- ProcessingConfiguration:
2875
- output.ProcessingConfiguration !== undefined && output.ProcessingConfiguration !== null
2876
- ? deserializeAws_json1_1ProcessingConfiguration(output.ProcessingConfiguration, context)
2877
- : undefined,
2878
- RequestConfiguration:
2879
- output.RequestConfiguration !== undefined && output.RequestConfiguration !== null
2880
- ? deserializeAws_json1_1HttpEndpointRequestConfiguration(output.RequestConfiguration, context)
2881
- : undefined,
2882
- RetryOptions:
2883
- output.RetryOptions !== undefined && output.RetryOptions !== null
2884
- ? deserializeAws_json1_1HttpEndpointRetryOptions(output.RetryOptions, context)
2885
- : undefined,
2886
- RoleARN: __expectString(output.RoleARN),
2887
- S3BackupMode: __expectString(output.S3BackupMode),
2888
- S3DestinationDescription:
2889
- output.S3DestinationDescription !== undefined && output.S3DestinationDescription !== null
2890
- ? deserializeAws_json1_1S3DestinationDescription(output.S3DestinationDescription, context)
2891
- : undefined,
2892
- } as any;
2893
- };
2894
-
2895
- const deserializeAws_json1_1HttpEndpointRequestConfiguration = (
2896
- output: any,
2897
- context: __SerdeContext
2898
- ): HttpEndpointRequestConfiguration => {
2899
- return {
2900
- CommonAttributes:
2901
- output.CommonAttributes !== undefined && output.CommonAttributes !== null
2902
- ? deserializeAws_json1_1HttpEndpointCommonAttributesList(output.CommonAttributes, context)
2903
- : undefined,
2904
- ContentEncoding: __expectString(output.ContentEncoding),
2905
- } as any;
2906
- };
2907
-
2908
- const deserializeAws_json1_1HttpEndpointRetryOptions = (
2909
- output: any,
2910
- context: __SerdeContext
2911
- ): HttpEndpointRetryOptions => {
2912
- return {
2913
- DurationInSeconds: __expectInt32(output.DurationInSeconds),
2914
- } as any;
2915
- };
2916
-
2917
- const deserializeAws_json1_1InputFormatConfiguration = (
2918
- output: any,
2919
- context: __SerdeContext
2920
- ): InputFormatConfiguration => {
2921
- return {
2922
- Deserializer:
2923
- output.Deserializer !== undefined && output.Deserializer !== null
2924
- ? deserializeAws_json1_1Deserializer(output.Deserializer, context)
2925
- : undefined,
2926
- } as any;
2927
- };
2928
-
2929
- const deserializeAws_json1_1InvalidArgumentException = (
2930
- output: any,
2931
- context: __SerdeContext
2932
- ): InvalidArgumentException => {
2933
- return {
2934
- message: __expectString(output.message),
2935
- } as any;
2936
- };
2937
-
2938
- const deserializeAws_json1_1InvalidKMSResourceException = (
2939
- output: any,
2940
- context: __SerdeContext
2941
- ): InvalidKMSResourceException => {
2942
- return {
2943
- code: __expectString(output.code),
2944
- message: __expectString(output.message),
2945
- } as any;
2946
- };
2947
-
2948
- const deserializeAws_json1_1KinesisStreamSourceDescription = (
2949
- output: any,
2950
- context: __SerdeContext
2951
- ): KinesisStreamSourceDescription => {
2952
- return {
2953
- DeliveryStartTimestamp:
2954
- output.DeliveryStartTimestamp !== undefined && output.DeliveryStartTimestamp !== null
2955
- ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.DeliveryStartTimestamp)))
2956
- : undefined,
2957
- KinesisStreamARN: __expectString(output.KinesisStreamARN),
2958
- RoleARN: __expectString(output.RoleARN),
2959
- } as any;
2960
- };
2961
-
2962
- const deserializeAws_json1_1KMSEncryptionConfig = (output: any, context: __SerdeContext): KMSEncryptionConfig => {
2963
- return {
2964
- AWSKMSKeyARN: __expectString(output.AWSKMSKeyARN),
2965
- } as any;
2966
- };
2967
-
2968
- const deserializeAws_json1_1LimitExceededException = (output: any, context: __SerdeContext): LimitExceededException => {
2969
- return {
2970
- message: __expectString(output.message),
2971
- } as any;
2972
- };
2973
-
2974
- const deserializeAws_json1_1ListDeliveryStreamsOutput = (
2975
- output: any,
2976
- context: __SerdeContext
2977
- ): ListDeliveryStreamsOutput => {
2978
- return {
2979
- DeliveryStreamNames:
2980
- output.DeliveryStreamNames !== undefined && output.DeliveryStreamNames !== null
2981
- ? deserializeAws_json1_1DeliveryStreamNameList(output.DeliveryStreamNames, context)
2982
- : undefined,
2983
- HasMoreDeliveryStreams: __expectBoolean(output.HasMoreDeliveryStreams),
2984
- } as any;
2985
- };
2986
-
2987
- const deserializeAws_json1_1ListOfNonEmptyStrings = (output: any, context: __SerdeContext): string[] => {
2988
- return (output || [])
2989
- .filter((e: any) => e != null)
2990
- .map((entry: any) => {
2991
- if (entry === null) {
2992
- return null as any;
2993
- }
2994
- return __expectString(entry) as any;
2995
- });
2996
- };
2997
-
2998
- const deserializeAws_json1_1ListOfNonEmptyStringsWithoutWhitespace = (
2999
- output: any,
3000
- context: __SerdeContext
3001
- ): string[] => {
3002
- return (output || [])
3003
- .filter((e: any) => e != null)
3004
- .map((entry: any) => {
3005
- if (entry === null) {
3006
- return null as any;
3007
- }
3008
- return __expectString(entry) as any;
3009
- });
3010
- };
3011
-
3012
- const deserializeAws_json1_1ListTagsForDeliveryStreamOutput = (
3013
- output: any,
3014
- context: __SerdeContext
3015
- ): ListTagsForDeliveryStreamOutput => {
3016
- return {
3017
- HasMoreTags: __expectBoolean(output.HasMoreTags),
3018
- Tags:
3019
- output.Tags !== undefined && output.Tags !== null
3020
- ? deserializeAws_json1_1ListTagsForDeliveryStreamOutputTagList(output.Tags, context)
3021
- : undefined,
3022
- } as any;
3023
- };
3024
-
3025
- const deserializeAws_json1_1ListTagsForDeliveryStreamOutputTagList = (output: any, context: __SerdeContext): Tag[] => {
3026
- return (output || [])
3027
- .filter((e: any) => e != null)
3028
- .map((entry: any) => {
3029
- if (entry === null) {
3030
- return null as any;
3031
- }
3032
- return deserializeAws_json1_1Tag(entry, context);
3033
- });
3034
- };
3035
-
3036
- const deserializeAws_json1_1OpenXJsonSerDe = (output: any, context: __SerdeContext): OpenXJsonSerDe => {
3037
- return {
3038
- CaseInsensitive: __expectBoolean(output.CaseInsensitive),
3039
- ColumnToJsonKeyMappings:
3040
- output.ColumnToJsonKeyMappings !== undefined && output.ColumnToJsonKeyMappings !== null
3041
- ? deserializeAws_json1_1ColumnToJsonKeyMappings(output.ColumnToJsonKeyMappings, context)
3042
- : undefined,
3043
- ConvertDotsInJsonKeysToUnderscores: __expectBoolean(output.ConvertDotsInJsonKeysToUnderscores),
3044
- } as any;
3045
- };
3046
-
3047
- const deserializeAws_json1_1OrcSerDe = (output: any, context: __SerdeContext): OrcSerDe => {
3048
- return {
3049
- BlockSizeBytes: __expectInt32(output.BlockSizeBytes),
3050
- BloomFilterColumns:
3051
- output.BloomFilterColumns !== undefined && output.BloomFilterColumns !== null
3052
- ? deserializeAws_json1_1ListOfNonEmptyStringsWithoutWhitespace(output.BloomFilterColumns, context)
3053
- : undefined,
3054
- BloomFilterFalsePositiveProbability: __limitedParseDouble(output.BloomFilterFalsePositiveProbability),
3055
- Compression: __expectString(output.Compression),
3056
- DictionaryKeyThreshold: __limitedParseDouble(output.DictionaryKeyThreshold),
3057
- EnablePadding: __expectBoolean(output.EnablePadding),
3058
- FormatVersion: __expectString(output.FormatVersion),
3059
- PaddingTolerance: __limitedParseDouble(output.PaddingTolerance),
3060
- RowIndexStride: __expectInt32(output.RowIndexStride),
3061
- StripeSizeBytes: __expectInt32(output.StripeSizeBytes),
3062
- } as any;
3063
- };
3064
-
3065
- const deserializeAws_json1_1OutputFormatConfiguration = (
3066
- output: any,
3067
- context: __SerdeContext
3068
- ): OutputFormatConfiguration => {
3069
- return {
3070
- Serializer:
3071
- output.Serializer !== undefined && output.Serializer !== null
3072
- ? deserializeAws_json1_1Serializer(output.Serializer, context)
3073
- : undefined,
3074
- } as any;
3075
- };
3076
-
3077
- const deserializeAws_json1_1ParquetSerDe = (output: any, context: __SerdeContext): ParquetSerDe => {
3078
- return {
3079
- BlockSizeBytes: __expectInt32(output.BlockSizeBytes),
3080
- Compression: __expectString(output.Compression),
3081
- EnableDictionaryCompression: __expectBoolean(output.EnableDictionaryCompression),
3082
- MaxPaddingBytes: __expectInt32(output.MaxPaddingBytes),
3083
- PageSizeBytes: __expectInt32(output.PageSizeBytes),
3084
- WriterVersion: __expectString(output.WriterVersion),
3085
- } as any;
3086
- };
3087
-
3088
- const deserializeAws_json1_1ProcessingConfiguration = (
3089
- output: any,
3090
- context: __SerdeContext
3091
- ): ProcessingConfiguration => {
3092
- return {
3093
- Enabled: __expectBoolean(output.Enabled),
3094
- Processors:
3095
- output.Processors !== undefined && output.Processors !== null
3096
- ? deserializeAws_json1_1ProcessorList(output.Processors, context)
3097
- : undefined,
3098
- } as any;
3099
- };
3100
-
3101
- const deserializeAws_json1_1Processor = (output: any, context: __SerdeContext): Processor => {
3102
- return {
3103
- Parameters:
3104
- output.Parameters !== undefined && output.Parameters !== null
3105
- ? deserializeAws_json1_1ProcessorParameterList(output.Parameters, context)
3106
- : undefined,
3107
- Type: __expectString(output.Type),
3108
- } as any;
3109
- };
3110
-
3111
- const deserializeAws_json1_1ProcessorList = (output: any, context: __SerdeContext): Processor[] => {
3112
- return (output || [])
3113
- .filter((e: any) => e != null)
3114
- .map((entry: any) => {
3115
- if (entry === null) {
3116
- return null as any;
3117
- }
3118
- return deserializeAws_json1_1Processor(entry, context);
3119
- });
3120
- };
3121
-
3122
- const deserializeAws_json1_1ProcessorParameter = (output: any, context: __SerdeContext): ProcessorParameter => {
3123
- return {
3124
- ParameterName: __expectString(output.ParameterName),
3125
- ParameterValue: __expectString(output.ParameterValue),
3126
- } as any;
3127
- };
3128
-
3129
- const deserializeAws_json1_1ProcessorParameterList = (output: any, context: __SerdeContext): ProcessorParameter[] => {
3130
- return (output || [])
3131
- .filter((e: any) => e != null)
3132
- .map((entry: any) => {
3133
- if (entry === null) {
3134
- return null as any;
3135
- }
3136
- return deserializeAws_json1_1ProcessorParameter(entry, context);
3137
- });
3138
- };
3139
-
3140
- const deserializeAws_json1_1PutRecordBatchOutput = (output: any, context: __SerdeContext): PutRecordBatchOutput => {
3141
- return {
3142
- Encrypted: __expectBoolean(output.Encrypted),
3143
- FailedPutCount: __expectInt32(output.FailedPutCount),
3144
- RequestResponses:
3145
- output.RequestResponses !== undefined && output.RequestResponses !== null
3146
- ? deserializeAws_json1_1PutRecordBatchResponseEntryList(output.RequestResponses, context)
3147
- : undefined,
3148
- } as any;
3149
- };
3150
-
3151
- const deserializeAws_json1_1PutRecordBatchResponseEntry = (
3152
- output: any,
3153
- context: __SerdeContext
3154
- ): PutRecordBatchResponseEntry => {
3155
- return {
3156
- ErrorCode: __expectString(output.ErrorCode),
3157
- ErrorMessage: __expectString(output.ErrorMessage),
3158
- RecordId: __expectString(output.RecordId),
3159
- } as any;
3160
- };
3161
-
3162
- const deserializeAws_json1_1PutRecordBatchResponseEntryList = (
3163
- output: any,
3164
- context: __SerdeContext
3165
- ): PutRecordBatchResponseEntry[] => {
3166
- return (output || [])
3167
- .filter((e: any) => e != null)
3168
- .map((entry: any) => {
3169
- if (entry === null) {
3170
- return null as any;
3171
- }
3172
- return deserializeAws_json1_1PutRecordBatchResponseEntry(entry, context);
3173
- });
3174
- };
3175
-
3176
- const deserializeAws_json1_1PutRecordOutput = (output: any, context: __SerdeContext): PutRecordOutput => {
3177
- return {
3178
- Encrypted: __expectBoolean(output.Encrypted),
3179
- RecordId: __expectString(output.RecordId),
3180
- } as any;
3181
- };
3182
-
3183
- const deserializeAws_json1_1RedshiftDestinationDescription = (
3184
- output: any,
3185
- context: __SerdeContext
3186
- ): RedshiftDestinationDescription => {
3187
- return {
3188
- CloudWatchLoggingOptions:
3189
- output.CloudWatchLoggingOptions !== undefined && output.CloudWatchLoggingOptions !== null
3190
- ? deserializeAws_json1_1CloudWatchLoggingOptions(output.CloudWatchLoggingOptions, context)
3191
- : undefined,
3192
- ClusterJDBCURL: __expectString(output.ClusterJDBCURL),
3193
- CopyCommand:
3194
- output.CopyCommand !== undefined && output.CopyCommand !== null
3195
- ? deserializeAws_json1_1CopyCommand(output.CopyCommand, context)
3196
- : undefined,
3197
- ProcessingConfiguration:
3198
- output.ProcessingConfiguration !== undefined && output.ProcessingConfiguration !== null
3199
- ? deserializeAws_json1_1ProcessingConfiguration(output.ProcessingConfiguration, context)
3200
- : undefined,
3201
- RetryOptions:
3202
- output.RetryOptions !== undefined && output.RetryOptions !== null
3203
- ? deserializeAws_json1_1RedshiftRetryOptions(output.RetryOptions, context)
3204
- : undefined,
3205
- RoleARN: __expectString(output.RoleARN),
3206
- S3BackupDescription:
3207
- output.S3BackupDescription !== undefined && output.S3BackupDescription !== null
3208
- ? deserializeAws_json1_1S3DestinationDescription(output.S3BackupDescription, context)
3209
- : undefined,
3210
- S3BackupMode: __expectString(output.S3BackupMode),
3211
- S3DestinationDescription:
3212
- output.S3DestinationDescription !== undefined && output.S3DestinationDescription !== null
3213
- ? deserializeAws_json1_1S3DestinationDescription(output.S3DestinationDescription, context)
3214
- : undefined,
3215
- Username: __expectString(output.Username),
3216
- } as any;
3217
- };
3218
-
3219
- const deserializeAws_json1_1RedshiftRetryOptions = (output: any, context: __SerdeContext): RedshiftRetryOptions => {
3220
- return {
3221
- DurationInSeconds: __expectInt32(output.DurationInSeconds),
3222
- } as any;
3223
- };
3224
-
3225
- const deserializeAws_json1_1ResourceInUseException = (output: any, context: __SerdeContext): ResourceInUseException => {
3226
- return {
3227
- message: __expectString(output.message),
3228
- } as any;
3229
- };
3230
-
3231
- const deserializeAws_json1_1ResourceNotFoundException = (
3232
- output: any,
3233
- context: __SerdeContext
3234
- ): ResourceNotFoundException => {
3235
- return {
3236
- message: __expectString(output.message),
3237
- } as any;
3238
- };
3239
-
3240
- const deserializeAws_json1_1RetryOptions = (output: any, context: __SerdeContext): RetryOptions => {
3241
- return {
3242
- DurationInSeconds: __expectInt32(output.DurationInSeconds),
3243
- } as any;
3244
- };
3245
-
3246
- const deserializeAws_json1_1S3DestinationDescription = (
3247
- output: any,
3248
- context: __SerdeContext
3249
- ): S3DestinationDescription => {
3250
- return {
3251
- BucketARN: __expectString(output.BucketARN),
3252
- BufferingHints:
3253
- output.BufferingHints !== undefined && output.BufferingHints !== null
3254
- ? deserializeAws_json1_1BufferingHints(output.BufferingHints, context)
3255
- : undefined,
3256
- CloudWatchLoggingOptions:
3257
- output.CloudWatchLoggingOptions !== undefined && output.CloudWatchLoggingOptions !== null
3258
- ? deserializeAws_json1_1CloudWatchLoggingOptions(output.CloudWatchLoggingOptions, context)
3259
- : undefined,
3260
- CompressionFormat: __expectString(output.CompressionFormat),
3261
- EncryptionConfiguration:
3262
- output.EncryptionConfiguration !== undefined && output.EncryptionConfiguration !== null
3263
- ? deserializeAws_json1_1EncryptionConfiguration(output.EncryptionConfiguration, context)
3264
- : undefined,
3265
- ErrorOutputPrefix: __expectString(output.ErrorOutputPrefix),
3266
- Prefix: __expectString(output.Prefix),
3267
- RoleARN: __expectString(output.RoleARN),
3268
- } as any;
3269
- };
3270
-
3271
- const deserializeAws_json1_1SchemaConfiguration = (output: any, context: __SerdeContext): SchemaConfiguration => {
3272
- return {
3273
- CatalogId: __expectString(output.CatalogId),
3274
- DatabaseName: __expectString(output.DatabaseName),
3275
- Region: __expectString(output.Region),
3276
- RoleARN: __expectString(output.RoleARN),
3277
- TableName: __expectString(output.TableName),
3278
- VersionId: __expectString(output.VersionId),
3279
- } as any;
3280
- };
3281
-
3282
- const deserializeAws_json1_1SecurityGroupIdList = (output: any, context: __SerdeContext): string[] => {
3283
- return (output || [])
3284
- .filter((e: any) => e != null)
3285
- .map((entry: any) => {
3286
- if (entry === null) {
3287
- return null as any;
3288
- }
3289
- return __expectString(entry) as any;
3290
- });
3291
- };
3292
-
3293
- const deserializeAws_json1_1Serializer = (output: any, context: __SerdeContext): Serializer => {
3294
- return {
3295
- OrcSerDe:
3296
- output.OrcSerDe !== undefined && output.OrcSerDe !== null
3297
- ? deserializeAws_json1_1OrcSerDe(output.OrcSerDe, context)
3298
- : undefined,
3299
- ParquetSerDe:
3300
- output.ParquetSerDe !== undefined && output.ParquetSerDe !== null
3301
- ? deserializeAws_json1_1ParquetSerDe(output.ParquetSerDe, context)
3302
- : undefined,
3303
- } as any;
3304
- };
3305
-
3306
- const deserializeAws_json1_1ServiceUnavailableException = (
3307
- output: any,
3308
- context: __SerdeContext
3309
- ): ServiceUnavailableException => {
3310
- return {
3311
- message: __expectString(output.message),
3312
- } as any;
3313
- };
3314
-
3315
- const deserializeAws_json1_1SourceDescription = (output: any, context: __SerdeContext): SourceDescription => {
3316
- return {
3317
- KinesisStreamSourceDescription:
3318
- output.KinesisStreamSourceDescription !== undefined && output.KinesisStreamSourceDescription !== null
3319
- ? deserializeAws_json1_1KinesisStreamSourceDescription(output.KinesisStreamSourceDescription, context)
3320
- : undefined,
3321
- } as any;
3322
- };
3323
-
3324
- const deserializeAws_json1_1SplunkDestinationDescription = (
3325
- output: any,
3326
- context: __SerdeContext
3327
- ): SplunkDestinationDescription => {
3328
- return {
3329
- CloudWatchLoggingOptions:
3330
- output.CloudWatchLoggingOptions !== undefined && output.CloudWatchLoggingOptions !== null
3331
- ? deserializeAws_json1_1CloudWatchLoggingOptions(output.CloudWatchLoggingOptions, context)
3332
- : undefined,
3333
- HECAcknowledgmentTimeoutInSeconds: __expectInt32(output.HECAcknowledgmentTimeoutInSeconds),
3334
- HECEndpoint: __expectString(output.HECEndpoint),
3335
- HECEndpointType: __expectString(output.HECEndpointType),
3336
- HECToken: __expectString(output.HECToken),
3337
- ProcessingConfiguration:
3338
- output.ProcessingConfiguration !== undefined && output.ProcessingConfiguration !== null
3339
- ? deserializeAws_json1_1ProcessingConfiguration(output.ProcessingConfiguration, context)
3340
- : undefined,
3341
- RetryOptions:
3342
- output.RetryOptions !== undefined && output.RetryOptions !== null
3343
- ? deserializeAws_json1_1SplunkRetryOptions(output.RetryOptions, context)
3344
- : undefined,
3345
- S3BackupMode: __expectString(output.S3BackupMode),
3346
- S3DestinationDescription:
3347
- output.S3DestinationDescription !== undefined && output.S3DestinationDescription !== null
3348
- ? deserializeAws_json1_1S3DestinationDescription(output.S3DestinationDescription, context)
3349
- : undefined,
3350
- } as any;
3351
- };
3352
-
3353
- const deserializeAws_json1_1SplunkRetryOptions = (output: any, context: __SerdeContext): SplunkRetryOptions => {
3354
- return {
3355
- DurationInSeconds: __expectInt32(output.DurationInSeconds),
3356
- } as any;
3357
- };
3358
-
3359
- const deserializeAws_json1_1StartDeliveryStreamEncryptionOutput = (
3360
- output: any,
3361
- context: __SerdeContext
3362
- ): StartDeliveryStreamEncryptionOutput => {
3363
- return {} as any;
3364
- };
3365
-
3366
- const deserializeAws_json1_1StopDeliveryStreamEncryptionOutput = (
3367
- output: any,
3368
- context: __SerdeContext
3369
- ): StopDeliveryStreamEncryptionOutput => {
3370
- return {} as any;
3371
- };
3372
-
3373
- const deserializeAws_json1_1SubnetIdList = (output: any, context: __SerdeContext): string[] => {
3374
- return (output || [])
3375
- .filter((e: any) => e != null)
3376
- .map((entry: any) => {
3377
- if (entry === null) {
3378
- return null as any;
3379
- }
3380
- return __expectString(entry) as any;
3381
- });
3382
- };
3383
-
3384
- const deserializeAws_json1_1Tag = (output: any, context: __SerdeContext): Tag => {
3385
- return {
3386
- Key: __expectString(output.Key),
3387
- Value: __expectString(output.Value),
3388
- } as any;
3389
- };
3390
-
3391
- const deserializeAws_json1_1TagDeliveryStreamOutput = (
3392
- output: any,
3393
- context: __SerdeContext
3394
- ): TagDeliveryStreamOutput => {
3395
- return {} as any;
3396
- };
3397
-
3398
- const deserializeAws_json1_1UntagDeliveryStreamOutput = (
3399
- output: any,
3400
- context: __SerdeContext
3401
- ): UntagDeliveryStreamOutput => {
3402
- return {} as any;
3403
- };
3404
-
3405
- const deserializeAws_json1_1UpdateDestinationOutput = (
3406
- output: any,
3407
- context: __SerdeContext
3408
- ): UpdateDestinationOutput => {
3409
- return {} as any;
3410
- };
3411
-
3412
- const deserializeAws_json1_1VpcConfigurationDescription = (
3413
- output: any,
3414
- context: __SerdeContext
3415
- ): VpcConfigurationDescription => {
3416
- return {
3417
- RoleARN: __expectString(output.RoleARN),
3418
- SecurityGroupIds:
3419
- output.SecurityGroupIds !== undefined && output.SecurityGroupIds !== null
3420
- ? deserializeAws_json1_1SecurityGroupIdList(output.SecurityGroupIds, context)
3421
- : undefined,
3422
- SubnetIds:
3423
- output.SubnetIds !== undefined && output.SubnetIds !== null
3424
- ? deserializeAws_json1_1SubnetIdList(output.SubnetIds, context)
3425
- : undefined,
3426
- VpcId: __expectString(output.VpcId),
3427
- } as any;
3428
- };
3429
-
3430
- const deserializeMetadata = (output: __HttpResponse): __ResponseMetadata => ({
3431
- httpStatusCode: output.statusCode,
3432
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"],
3433
- extendedRequestId: output.headers["x-amz-id-2"],
3434
- cfId: output.headers["x-amz-cf-id"],
3435
- });
3436
-
3437
- // Collect low-level response body stream to Uint8Array.
3438
- const collectBody = (streamBody: any = new Uint8Array(), context: __SerdeContext): Promise<Uint8Array> => {
3439
- if (streamBody instanceof Uint8Array) {
3440
- return Promise.resolve(streamBody);
3441
- }
3442
- return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
3443
- };
3444
-
3445
- // Encode Uint8Array data into string with utf-8.
3446
- const collectBodyString = (streamBody: any, context: __SerdeContext): Promise<string> =>
3447
- collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
3448
-
3449
- const buildHttpRpcRequest = async (
3450
- context: __SerdeContext,
3451
- headers: __HeaderBag,
3452
- path: string,
3453
- resolvedHostname: string | undefined,
3454
- body: any
3455
- ): Promise<__HttpRequest> => {
3456
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
3457
- const contents: any = {
3458
- protocol,
3459
- hostname,
3460
- port,
3461
- method: "POST",
3462
- path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
3463
- headers,
3464
- };
3465
- if (resolvedHostname !== undefined) {
3466
- contents.hostname = resolvedHostname;
3467
- }
3468
- if (body !== undefined) {
3469
- contents.body = body;
3470
- }
3471
- return new __HttpRequest(contents);
3472
- };
3473
-
3474
- const parseBody = (streamBody: any, context: __SerdeContext): any =>
3475
- collectBodyString(streamBody, context).then((encoded) => {
3476
- if (encoded.length) {
3477
- return JSON.parse(encoded);
3478
- }
3479
- return {};
3480
- });
3481
-
3482
- /**
3483
- * Load an error code for the aws.rest-json-1.1 protocol.
3484
- */
3485
- const loadRestJsonErrorCode = (output: __HttpResponse, data: any): string => {
3486
- const findKey = (object: any, key: string) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
3487
-
3488
- const sanitizeErrorCode = (rawValue: string): string => {
3489
- let cleanValue = rawValue;
3490
- if (cleanValue.indexOf(":") >= 0) {
3491
- cleanValue = cleanValue.split(":")[0];
3492
- }
3493
- if (cleanValue.indexOf("#") >= 0) {
3494
- cleanValue = cleanValue.split("#")[1];
3495
- }
3496
- return cleanValue;
3497
- };
3498
-
3499
- const headerKey = findKey(output.headers, "x-amzn-errortype");
3500
- if (headerKey !== undefined) {
3501
- return sanitizeErrorCode(output.headers[headerKey]);
3502
- }
3503
-
3504
- if (data.code !== undefined) {
3505
- return sanitizeErrorCode(data.code);
3506
- }
3507
-
3508
- if (data["__type"] !== undefined) {
3509
- return sanitizeErrorCode(data["__type"]);
3510
- }
3511
-
3512
- return "";
3513
- };