@aws-sdk/client-pipes 3.490.0 → 3.496.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.
- package/dist-cjs/Pipes.js +1 -31
- package/dist-cjs/PipesClient.js +1 -43
- package/dist-cjs/commands/CreatePipeCommand.js +1 -29
- package/dist-cjs/commands/DeletePipeCommand.js +1 -28
- package/dist-cjs/commands/DescribePipeCommand.js +1 -29
- package/dist-cjs/commands/ListPipesCommand.js +1 -29
- package/dist-cjs/commands/ListTagsForResourceCommand.js +1 -29
- package/dist-cjs/commands/StartPipeCommand.js +1 -28
- package/dist-cjs/commands/StopPipeCommand.js +1 -28
- package/dist-cjs/commands/TagResourceCommand.js +1 -29
- package/dist-cjs/commands/UntagResourceCommand.js +1 -28
- package/dist-cjs/commands/UpdatePipeCommand.js +1 -29
- package/dist-cjs/commands/index.js +1 -13
- package/dist-cjs/endpoint/EndpointParameters.js +1 -18
- package/dist-cjs/extensionConfiguration.js +1 -2
- package/dist-cjs/index.js +1805 -11
- package/dist-cjs/models/PipesServiceException.js +1 -12
- package/dist-cjs/models/index.js +1 -4
- package/dist-cjs/models/models_0.js +1 -493
- package/dist-cjs/pagination/Interfaces.js +1 -2
- package/dist-cjs/pagination/ListPipesPaginator.js +1 -7
- package/dist-cjs/pagination/index.js +1 -5
- package/dist-cjs/protocols/Aws_restJson1.js +1 -850
- package/dist-cjs/runtimeExtensions.js +1 -22
- package/package.json +40 -40
|
@@ -1,850 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_UpdatePipeCommand = exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_StopPipeCommand = exports.de_StartPipeCommand = exports.de_ListTagsForResourceCommand = exports.de_ListPipesCommand = exports.de_DescribePipeCommand = exports.de_DeletePipeCommand = exports.de_CreatePipeCommand = exports.se_UpdatePipeCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_StopPipeCommand = exports.se_StartPipeCommand = exports.se_ListTagsForResourceCommand = exports.se_ListPipesCommand = exports.se_DescribePipeCommand = exports.se_DeletePipeCommand = exports.se_CreatePipeCommand = void 0;
|
|
4
|
-
const core_1 = require("@smithy/core");
|
|
5
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
6
|
-
const models_0_1 = require("../models/models_0");
|
|
7
|
-
const PipesServiceException_1 = require("../models/PipesServiceException");
|
|
8
|
-
const se_CreatePipeCommand = async (input, context) => {
|
|
9
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
10
|
-
const headers = {
|
|
11
|
-
"content-type": "application/json",
|
|
12
|
-
};
|
|
13
|
-
b.bp("/v1/pipes/{Name}");
|
|
14
|
-
b.p("Name", () => input.Name, "{Name}", false);
|
|
15
|
-
let body;
|
|
16
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
17
|
-
Description: [],
|
|
18
|
-
DesiredState: [],
|
|
19
|
-
Enrichment: [],
|
|
20
|
-
EnrichmentParameters: (_) => (0, smithy_client_1._json)(_),
|
|
21
|
-
LogConfiguration: (_) => (0, smithy_client_1._json)(_),
|
|
22
|
-
RoleArn: [],
|
|
23
|
-
Source: [],
|
|
24
|
-
SourceParameters: (_) => se_PipeSourceParameters(_, context),
|
|
25
|
-
Tags: (_) => (0, smithy_client_1._json)(_),
|
|
26
|
-
Target: [],
|
|
27
|
-
TargetParameters: (_) => (0, smithy_client_1._json)(_),
|
|
28
|
-
}));
|
|
29
|
-
b.m("POST").h(headers).b(body);
|
|
30
|
-
return b.build();
|
|
31
|
-
};
|
|
32
|
-
exports.se_CreatePipeCommand = se_CreatePipeCommand;
|
|
33
|
-
const se_DeletePipeCommand = async (input, context) => {
|
|
34
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
35
|
-
const headers = {};
|
|
36
|
-
b.bp("/v1/pipes/{Name}");
|
|
37
|
-
b.p("Name", () => input.Name, "{Name}", false);
|
|
38
|
-
let body;
|
|
39
|
-
b.m("DELETE").h(headers).b(body);
|
|
40
|
-
return b.build();
|
|
41
|
-
};
|
|
42
|
-
exports.se_DeletePipeCommand = se_DeletePipeCommand;
|
|
43
|
-
const se_DescribePipeCommand = async (input, context) => {
|
|
44
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
45
|
-
const headers = {};
|
|
46
|
-
b.bp("/v1/pipes/{Name}");
|
|
47
|
-
b.p("Name", () => input.Name, "{Name}", false);
|
|
48
|
-
let body;
|
|
49
|
-
b.m("GET").h(headers).b(body);
|
|
50
|
-
return b.build();
|
|
51
|
-
};
|
|
52
|
-
exports.se_DescribePipeCommand = se_DescribePipeCommand;
|
|
53
|
-
const se_ListPipesCommand = async (input, context) => {
|
|
54
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
55
|
-
const headers = {};
|
|
56
|
-
b.bp("/v1/pipes");
|
|
57
|
-
const query = (0, smithy_client_1.map)({
|
|
58
|
-
[_NP]: [, input[_NP]],
|
|
59
|
-
[_DS]: [, input[_DS]],
|
|
60
|
-
[_CS]: [, input[_CS]],
|
|
61
|
-
[_SP]: [, input[_SP]],
|
|
62
|
-
[_TP]: [, input[_TP]],
|
|
63
|
-
[_NT]: [, input[_NT]],
|
|
64
|
-
[_L]: [() => input.Limit !== void 0, () => input[_L].toString()],
|
|
65
|
-
});
|
|
66
|
-
let body;
|
|
67
|
-
b.m("GET").h(headers).q(query).b(body);
|
|
68
|
-
return b.build();
|
|
69
|
-
};
|
|
70
|
-
exports.se_ListPipesCommand = se_ListPipesCommand;
|
|
71
|
-
const se_ListTagsForResourceCommand = async (input, context) => {
|
|
72
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
73
|
-
const headers = {};
|
|
74
|
-
b.bp("/tags/{resourceArn}");
|
|
75
|
-
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
76
|
-
let body;
|
|
77
|
-
b.m("GET").h(headers).b(body);
|
|
78
|
-
return b.build();
|
|
79
|
-
};
|
|
80
|
-
exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
|
|
81
|
-
const se_StartPipeCommand = async (input, context) => {
|
|
82
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
83
|
-
const headers = {};
|
|
84
|
-
b.bp("/v1/pipes/{Name}/start");
|
|
85
|
-
b.p("Name", () => input.Name, "{Name}", false);
|
|
86
|
-
let body;
|
|
87
|
-
b.m("POST").h(headers).b(body);
|
|
88
|
-
return b.build();
|
|
89
|
-
};
|
|
90
|
-
exports.se_StartPipeCommand = se_StartPipeCommand;
|
|
91
|
-
const se_StopPipeCommand = async (input, context) => {
|
|
92
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
93
|
-
const headers = {};
|
|
94
|
-
b.bp("/v1/pipes/{Name}/stop");
|
|
95
|
-
b.p("Name", () => input.Name, "{Name}", false);
|
|
96
|
-
let body;
|
|
97
|
-
b.m("POST").h(headers).b(body);
|
|
98
|
-
return b.build();
|
|
99
|
-
};
|
|
100
|
-
exports.se_StopPipeCommand = se_StopPipeCommand;
|
|
101
|
-
const se_TagResourceCommand = async (input, context) => {
|
|
102
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
103
|
-
const headers = {
|
|
104
|
-
"content-type": "application/json",
|
|
105
|
-
};
|
|
106
|
-
b.bp("/tags/{resourceArn}");
|
|
107
|
-
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
108
|
-
let body;
|
|
109
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
110
|
-
tags: (_) => (0, smithy_client_1._json)(_),
|
|
111
|
-
}));
|
|
112
|
-
b.m("POST").h(headers).b(body);
|
|
113
|
-
return b.build();
|
|
114
|
-
};
|
|
115
|
-
exports.se_TagResourceCommand = se_TagResourceCommand;
|
|
116
|
-
const se_UntagResourceCommand = async (input, context) => {
|
|
117
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
118
|
-
const headers = {};
|
|
119
|
-
b.bp("/tags/{resourceArn}");
|
|
120
|
-
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
121
|
-
const query = (0, smithy_client_1.map)({
|
|
122
|
-
[_tK]: [
|
|
123
|
-
(0, smithy_client_1.expectNonNull)(input.tagKeys, `tagKeys`) != null,
|
|
124
|
-
() => (input[_tK] || []).map((_entry) => _entry),
|
|
125
|
-
],
|
|
126
|
-
});
|
|
127
|
-
let body;
|
|
128
|
-
b.m("DELETE").h(headers).q(query).b(body);
|
|
129
|
-
return b.build();
|
|
130
|
-
};
|
|
131
|
-
exports.se_UntagResourceCommand = se_UntagResourceCommand;
|
|
132
|
-
const se_UpdatePipeCommand = async (input, context) => {
|
|
133
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
134
|
-
const headers = {
|
|
135
|
-
"content-type": "application/json",
|
|
136
|
-
};
|
|
137
|
-
b.bp("/v1/pipes/{Name}");
|
|
138
|
-
b.p("Name", () => input.Name, "{Name}", false);
|
|
139
|
-
let body;
|
|
140
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
141
|
-
Description: [],
|
|
142
|
-
DesiredState: [],
|
|
143
|
-
Enrichment: [],
|
|
144
|
-
EnrichmentParameters: (_) => (0, smithy_client_1._json)(_),
|
|
145
|
-
LogConfiguration: (_) => (0, smithy_client_1._json)(_),
|
|
146
|
-
RoleArn: [],
|
|
147
|
-
SourceParameters: (_) => (0, smithy_client_1._json)(_),
|
|
148
|
-
Target: [],
|
|
149
|
-
TargetParameters: (_) => (0, smithy_client_1._json)(_),
|
|
150
|
-
}));
|
|
151
|
-
b.m("PUT").h(headers).b(body);
|
|
152
|
-
return b.build();
|
|
153
|
-
};
|
|
154
|
-
exports.se_UpdatePipeCommand = se_UpdatePipeCommand;
|
|
155
|
-
const de_CreatePipeCommand = async (output, context) => {
|
|
156
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
157
|
-
return de_CreatePipeCommandError(output, context);
|
|
158
|
-
}
|
|
159
|
-
const contents = (0, smithy_client_1.map)({
|
|
160
|
-
$metadata: deserializeMetadata(output),
|
|
161
|
-
});
|
|
162
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
163
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
164
|
-
Arn: smithy_client_1.expectString,
|
|
165
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
166
|
-
CurrentState: smithy_client_1.expectString,
|
|
167
|
-
DesiredState: smithy_client_1.expectString,
|
|
168
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
169
|
-
Name: smithy_client_1.expectString,
|
|
170
|
-
});
|
|
171
|
-
Object.assign(contents, doc);
|
|
172
|
-
return contents;
|
|
173
|
-
};
|
|
174
|
-
exports.de_CreatePipeCommand = de_CreatePipeCommand;
|
|
175
|
-
const de_CreatePipeCommandError = async (output, context) => {
|
|
176
|
-
const parsedOutput = {
|
|
177
|
-
...output,
|
|
178
|
-
body: await parseErrorBody(output.body, context),
|
|
179
|
-
};
|
|
180
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
181
|
-
switch (errorCode) {
|
|
182
|
-
case "ConflictException":
|
|
183
|
-
case "com.amazonaws.pipes#ConflictException":
|
|
184
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
185
|
-
case "InternalException":
|
|
186
|
-
case "com.amazonaws.pipes#InternalException":
|
|
187
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
188
|
-
case "NotFoundException":
|
|
189
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
190
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
191
|
-
case "ServiceQuotaExceededException":
|
|
192
|
-
case "com.amazonaws.pipes#ServiceQuotaExceededException":
|
|
193
|
-
throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
|
|
194
|
-
case "ThrottlingException":
|
|
195
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
196
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
197
|
-
case "ValidationException":
|
|
198
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
199
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
200
|
-
default:
|
|
201
|
-
const parsedBody = parsedOutput.body;
|
|
202
|
-
return throwDefaultError({
|
|
203
|
-
output,
|
|
204
|
-
parsedBody,
|
|
205
|
-
errorCode,
|
|
206
|
-
});
|
|
207
|
-
}
|
|
208
|
-
};
|
|
209
|
-
const de_DeletePipeCommand = async (output, context) => {
|
|
210
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
211
|
-
return de_DeletePipeCommandError(output, context);
|
|
212
|
-
}
|
|
213
|
-
const contents = (0, smithy_client_1.map)({
|
|
214
|
-
$metadata: deserializeMetadata(output),
|
|
215
|
-
});
|
|
216
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
217
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
218
|
-
Arn: smithy_client_1.expectString,
|
|
219
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
220
|
-
CurrentState: smithy_client_1.expectString,
|
|
221
|
-
DesiredState: smithy_client_1.expectString,
|
|
222
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
223
|
-
Name: smithy_client_1.expectString,
|
|
224
|
-
});
|
|
225
|
-
Object.assign(contents, doc);
|
|
226
|
-
return contents;
|
|
227
|
-
};
|
|
228
|
-
exports.de_DeletePipeCommand = de_DeletePipeCommand;
|
|
229
|
-
const de_DeletePipeCommandError = async (output, context) => {
|
|
230
|
-
const parsedOutput = {
|
|
231
|
-
...output,
|
|
232
|
-
body: await parseErrorBody(output.body, context),
|
|
233
|
-
};
|
|
234
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
235
|
-
switch (errorCode) {
|
|
236
|
-
case "ConflictException":
|
|
237
|
-
case "com.amazonaws.pipes#ConflictException":
|
|
238
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
239
|
-
case "InternalException":
|
|
240
|
-
case "com.amazonaws.pipes#InternalException":
|
|
241
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
242
|
-
case "NotFoundException":
|
|
243
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
244
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
245
|
-
case "ThrottlingException":
|
|
246
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
247
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
248
|
-
case "ValidationException":
|
|
249
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
250
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
251
|
-
default:
|
|
252
|
-
const parsedBody = parsedOutput.body;
|
|
253
|
-
return throwDefaultError({
|
|
254
|
-
output,
|
|
255
|
-
parsedBody,
|
|
256
|
-
errorCode,
|
|
257
|
-
});
|
|
258
|
-
}
|
|
259
|
-
};
|
|
260
|
-
const de_DescribePipeCommand = async (output, context) => {
|
|
261
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
262
|
-
return de_DescribePipeCommandError(output, context);
|
|
263
|
-
}
|
|
264
|
-
const contents = (0, smithy_client_1.map)({
|
|
265
|
-
$metadata: deserializeMetadata(output),
|
|
266
|
-
});
|
|
267
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
268
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
269
|
-
Arn: smithy_client_1.expectString,
|
|
270
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
271
|
-
CurrentState: smithy_client_1.expectString,
|
|
272
|
-
Description: smithy_client_1.expectString,
|
|
273
|
-
DesiredState: smithy_client_1.expectString,
|
|
274
|
-
Enrichment: smithy_client_1.expectString,
|
|
275
|
-
EnrichmentParameters: smithy_client_1._json,
|
|
276
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
277
|
-
LogConfiguration: smithy_client_1._json,
|
|
278
|
-
Name: smithy_client_1.expectString,
|
|
279
|
-
RoleArn: smithy_client_1.expectString,
|
|
280
|
-
Source: smithy_client_1.expectString,
|
|
281
|
-
SourceParameters: (_) => de_PipeSourceParameters(_, context),
|
|
282
|
-
StateReason: smithy_client_1.expectString,
|
|
283
|
-
Tags: smithy_client_1._json,
|
|
284
|
-
Target: smithy_client_1.expectString,
|
|
285
|
-
TargetParameters: smithy_client_1._json,
|
|
286
|
-
});
|
|
287
|
-
Object.assign(contents, doc);
|
|
288
|
-
return contents;
|
|
289
|
-
};
|
|
290
|
-
exports.de_DescribePipeCommand = de_DescribePipeCommand;
|
|
291
|
-
const de_DescribePipeCommandError = async (output, context) => {
|
|
292
|
-
const parsedOutput = {
|
|
293
|
-
...output,
|
|
294
|
-
body: await parseErrorBody(output.body, context),
|
|
295
|
-
};
|
|
296
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
297
|
-
switch (errorCode) {
|
|
298
|
-
case "InternalException":
|
|
299
|
-
case "com.amazonaws.pipes#InternalException":
|
|
300
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
301
|
-
case "NotFoundException":
|
|
302
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
303
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
304
|
-
case "ThrottlingException":
|
|
305
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
306
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
307
|
-
case "ValidationException":
|
|
308
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
309
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
310
|
-
default:
|
|
311
|
-
const parsedBody = parsedOutput.body;
|
|
312
|
-
return throwDefaultError({
|
|
313
|
-
output,
|
|
314
|
-
parsedBody,
|
|
315
|
-
errorCode,
|
|
316
|
-
});
|
|
317
|
-
}
|
|
318
|
-
};
|
|
319
|
-
const de_ListPipesCommand = async (output, context) => {
|
|
320
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
321
|
-
return de_ListPipesCommandError(output, context);
|
|
322
|
-
}
|
|
323
|
-
const contents = (0, smithy_client_1.map)({
|
|
324
|
-
$metadata: deserializeMetadata(output),
|
|
325
|
-
});
|
|
326
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
327
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
328
|
-
NextToken: smithy_client_1.expectString,
|
|
329
|
-
Pipes: (_) => de_PipeList(_, context),
|
|
330
|
-
});
|
|
331
|
-
Object.assign(contents, doc);
|
|
332
|
-
return contents;
|
|
333
|
-
};
|
|
334
|
-
exports.de_ListPipesCommand = de_ListPipesCommand;
|
|
335
|
-
const de_ListPipesCommandError = async (output, context) => {
|
|
336
|
-
const parsedOutput = {
|
|
337
|
-
...output,
|
|
338
|
-
body: await parseErrorBody(output.body, context),
|
|
339
|
-
};
|
|
340
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
341
|
-
switch (errorCode) {
|
|
342
|
-
case "InternalException":
|
|
343
|
-
case "com.amazonaws.pipes#InternalException":
|
|
344
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
345
|
-
case "ThrottlingException":
|
|
346
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
347
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
348
|
-
case "ValidationException":
|
|
349
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
350
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
351
|
-
default:
|
|
352
|
-
const parsedBody = parsedOutput.body;
|
|
353
|
-
return throwDefaultError({
|
|
354
|
-
output,
|
|
355
|
-
parsedBody,
|
|
356
|
-
errorCode,
|
|
357
|
-
});
|
|
358
|
-
}
|
|
359
|
-
};
|
|
360
|
-
const de_ListTagsForResourceCommand = async (output, context) => {
|
|
361
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
362
|
-
return de_ListTagsForResourceCommandError(output, context);
|
|
363
|
-
}
|
|
364
|
-
const contents = (0, smithy_client_1.map)({
|
|
365
|
-
$metadata: deserializeMetadata(output),
|
|
366
|
-
});
|
|
367
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
368
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
369
|
-
tags: smithy_client_1._json,
|
|
370
|
-
});
|
|
371
|
-
Object.assign(contents, doc);
|
|
372
|
-
return contents;
|
|
373
|
-
};
|
|
374
|
-
exports.de_ListTagsForResourceCommand = de_ListTagsForResourceCommand;
|
|
375
|
-
const de_ListTagsForResourceCommandError = async (output, context) => {
|
|
376
|
-
const parsedOutput = {
|
|
377
|
-
...output,
|
|
378
|
-
body: await parseErrorBody(output.body, context),
|
|
379
|
-
};
|
|
380
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
381
|
-
switch (errorCode) {
|
|
382
|
-
case "InternalException":
|
|
383
|
-
case "com.amazonaws.pipes#InternalException":
|
|
384
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
385
|
-
case "NotFoundException":
|
|
386
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
387
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
388
|
-
case "ValidationException":
|
|
389
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
390
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
391
|
-
default:
|
|
392
|
-
const parsedBody = parsedOutput.body;
|
|
393
|
-
return throwDefaultError({
|
|
394
|
-
output,
|
|
395
|
-
parsedBody,
|
|
396
|
-
errorCode,
|
|
397
|
-
});
|
|
398
|
-
}
|
|
399
|
-
};
|
|
400
|
-
const de_StartPipeCommand = async (output, context) => {
|
|
401
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
402
|
-
return de_StartPipeCommandError(output, context);
|
|
403
|
-
}
|
|
404
|
-
const contents = (0, smithy_client_1.map)({
|
|
405
|
-
$metadata: deserializeMetadata(output),
|
|
406
|
-
});
|
|
407
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
408
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
409
|
-
Arn: smithy_client_1.expectString,
|
|
410
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
411
|
-
CurrentState: smithy_client_1.expectString,
|
|
412
|
-
DesiredState: smithy_client_1.expectString,
|
|
413
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
414
|
-
Name: smithy_client_1.expectString,
|
|
415
|
-
});
|
|
416
|
-
Object.assign(contents, doc);
|
|
417
|
-
return contents;
|
|
418
|
-
};
|
|
419
|
-
exports.de_StartPipeCommand = de_StartPipeCommand;
|
|
420
|
-
const de_StartPipeCommandError = async (output, context) => {
|
|
421
|
-
const parsedOutput = {
|
|
422
|
-
...output,
|
|
423
|
-
body: await parseErrorBody(output.body, context),
|
|
424
|
-
};
|
|
425
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
426
|
-
switch (errorCode) {
|
|
427
|
-
case "ConflictException":
|
|
428
|
-
case "com.amazonaws.pipes#ConflictException":
|
|
429
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
430
|
-
case "InternalException":
|
|
431
|
-
case "com.amazonaws.pipes#InternalException":
|
|
432
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
433
|
-
case "NotFoundException":
|
|
434
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
435
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
436
|
-
case "ThrottlingException":
|
|
437
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
438
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
439
|
-
case "ValidationException":
|
|
440
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
441
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
442
|
-
default:
|
|
443
|
-
const parsedBody = parsedOutput.body;
|
|
444
|
-
return throwDefaultError({
|
|
445
|
-
output,
|
|
446
|
-
parsedBody,
|
|
447
|
-
errorCode,
|
|
448
|
-
});
|
|
449
|
-
}
|
|
450
|
-
};
|
|
451
|
-
const de_StopPipeCommand = async (output, context) => {
|
|
452
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
453
|
-
return de_StopPipeCommandError(output, context);
|
|
454
|
-
}
|
|
455
|
-
const contents = (0, smithy_client_1.map)({
|
|
456
|
-
$metadata: deserializeMetadata(output),
|
|
457
|
-
});
|
|
458
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
459
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
460
|
-
Arn: smithy_client_1.expectString,
|
|
461
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
462
|
-
CurrentState: smithy_client_1.expectString,
|
|
463
|
-
DesiredState: smithy_client_1.expectString,
|
|
464
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
465
|
-
Name: smithy_client_1.expectString,
|
|
466
|
-
});
|
|
467
|
-
Object.assign(contents, doc);
|
|
468
|
-
return contents;
|
|
469
|
-
};
|
|
470
|
-
exports.de_StopPipeCommand = de_StopPipeCommand;
|
|
471
|
-
const de_StopPipeCommandError = async (output, context) => {
|
|
472
|
-
const parsedOutput = {
|
|
473
|
-
...output,
|
|
474
|
-
body: await parseErrorBody(output.body, context),
|
|
475
|
-
};
|
|
476
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
477
|
-
switch (errorCode) {
|
|
478
|
-
case "ConflictException":
|
|
479
|
-
case "com.amazonaws.pipes#ConflictException":
|
|
480
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
481
|
-
case "InternalException":
|
|
482
|
-
case "com.amazonaws.pipes#InternalException":
|
|
483
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
484
|
-
case "NotFoundException":
|
|
485
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
486
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
487
|
-
case "ThrottlingException":
|
|
488
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
489
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
490
|
-
case "ValidationException":
|
|
491
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
492
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
493
|
-
default:
|
|
494
|
-
const parsedBody = parsedOutput.body;
|
|
495
|
-
return throwDefaultError({
|
|
496
|
-
output,
|
|
497
|
-
parsedBody,
|
|
498
|
-
errorCode,
|
|
499
|
-
});
|
|
500
|
-
}
|
|
501
|
-
};
|
|
502
|
-
const de_TagResourceCommand = async (output, context) => {
|
|
503
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
504
|
-
return de_TagResourceCommandError(output, context);
|
|
505
|
-
}
|
|
506
|
-
const contents = (0, smithy_client_1.map)({
|
|
507
|
-
$metadata: deserializeMetadata(output),
|
|
508
|
-
});
|
|
509
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
510
|
-
return contents;
|
|
511
|
-
};
|
|
512
|
-
exports.de_TagResourceCommand = de_TagResourceCommand;
|
|
513
|
-
const de_TagResourceCommandError = async (output, context) => {
|
|
514
|
-
const parsedOutput = {
|
|
515
|
-
...output,
|
|
516
|
-
body: await parseErrorBody(output.body, context),
|
|
517
|
-
};
|
|
518
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
519
|
-
switch (errorCode) {
|
|
520
|
-
case "InternalException":
|
|
521
|
-
case "com.amazonaws.pipes#InternalException":
|
|
522
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
523
|
-
case "NotFoundException":
|
|
524
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
525
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
526
|
-
case "ValidationException":
|
|
527
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
528
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
529
|
-
default:
|
|
530
|
-
const parsedBody = parsedOutput.body;
|
|
531
|
-
return throwDefaultError({
|
|
532
|
-
output,
|
|
533
|
-
parsedBody,
|
|
534
|
-
errorCode,
|
|
535
|
-
});
|
|
536
|
-
}
|
|
537
|
-
};
|
|
538
|
-
const de_UntagResourceCommand = async (output, context) => {
|
|
539
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
540
|
-
return de_UntagResourceCommandError(output, context);
|
|
541
|
-
}
|
|
542
|
-
const contents = (0, smithy_client_1.map)({
|
|
543
|
-
$metadata: deserializeMetadata(output),
|
|
544
|
-
});
|
|
545
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
546
|
-
return contents;
|
|
547
|
-
};
|
|
548
|
-
exports.de_UntagResourceCommand = de_UntagResourceCommand;
|
|
549
|
-
const de_UntagResourceCommandError = async (output, context) => {
|
|
550
|
-
const parsedOutput = {
|
|
551
|
-
...output,
|
|
552
|
-
body: await parseErrorBody(output.body, context),
|
|
553
|
-
};
|
|
554
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
555
|
-
switch (errorCode) {
|
|
556
|
-
case "InternalException":
|
|
557
|
-
case "com.amazonaws.pipes#InternalException":
|
|
558
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
559
|
-
case "NotFoundException":
|
|
560
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
561
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
562
|
-
case "ValidationException":
|
|
563
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
564
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
565
|
-
default:
|
|
566
|
-
const parsedBody = parsedOutput.body;
|
|
567
|
-
return throwDefaultError({
|
|
568
|
-
output,
|
|
569
|
-
parsedBody,
|
|
570
|
-
errorCode,
|
|
571
|
-
});
|
|
572
|
-
}
|
|
573
|
-
};
|
|
574
|
-
const de_UpdatePipeCommand = async (output, context) => {
|
|
575
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
576
|
-
return de_UpdatePipeCommandError(output, context);
|
|
577
|
-
}
|
|
578
|
-
const contents = (0, smithy_client_1.map)({
|
|
579
|
-
$metadata: deserializeMetadata(output),
|
|
580
|
-
});
|
|
581
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
582
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
583
|
-
Arn: smithy_client_1.expectString,
|
|
584
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
585
|
-
CurrentState: smithy_client_1.expectString,
|
|
586
|
-
DesiredState: smithy_client_1.expectString,
|
|
587
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
588
|
-
Name: smithy_client_1.expectString,
|
|
589
|
-
});
|
|
590
|
-
Object.assign(contents, doc);
|
|
591
|
-
return contents;
|
|
592
|
-
};
|
|
593
|
-
exports.de_UpdatePipeCommand = de_UpdatePipeCommand;
|
|
594
|
-
const de_UpdatePipeCommandError = async (output, context) => {
|
|
595
|
-
const parsedOutput = {
|
|
596
|
-
...output,
|
|
597
|
-
body: await parseErrorBody(output.body, context),
|
|
598
|
-
};
|
|
599
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
600
|
-
switch (errorCode) {
|
|
601
|
-
case "ConflictException":
|
|
602
|
-
case "com.amazonaws.pipes#ConflictException":
|
|
603
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
604
|
-
case "InternalException":
|
|
605
|
-
case "com.amazonaws.pipes#InternalException":
|
|
606
|
-
throw await de_InternalExceptionRes(parsedOutput, context);
|
|
607
|
-
case "NotFoundException":
|
|
608
|
-
case "com.amazonaws.pipes#NotFoundException":
|
|
609
|
-
throw await de_NotFoundExceptionRes(parsedOutput, context);
|
|
610
|
-
case "ThrottlingException":
|
|
611
|
-
case "com.amazonaws.pipes#ThrottlingException":
|
|
612
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
613
|
-
case "ValidationException":
|
|
614
|
-
case "com.amazonaws.pipes#ValidationException":
|
|
615
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
616
|
-
default:
|
|
617
|
-
const parsedBody = parsedOutput.body;
|
|
618
|
-
return throwDefaultError({
|
|
619
|
-
output,
|
|
620
|
-
parsedBody,
|
|
621
|
-
errorCode,
|
|
622
|
-
});
|
|
623
|
-
}
|
|
624
|
-
};
|
|
625
|
-
const throwDefaultError = (0, smithy_client_1.withBaseException)(PipesServiceException_1.PipesServiceException);
|
|
626
|
-
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
627
|
-
const contents = (0, smithy_client_1.map)({});
|
|
628
|
-
const data = parsedOutput.body;
|
|
629
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
630
|
-
message: smithy_client_1.expectString,
|
|
631
|
-
resourceId: smithy_client_1.expectString,
|
|
632
|
-
resourceType: smithy_client_1.expectString,
|
|
633
|
-
});
|
|
634
|
-
Object.assign(contents, doc);
|
|
635
|
-
const exception = new models_0_1.ConflictException({
|
|
636
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
637
|
-
...contents,
|
|
638
|
-
});
|
|
639
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
640
|
-
};
|
|
641
|
-
const de_InternalExceptionRes = async (parsedOutput, context) => {
|
|
642
|
-
const contents = (0, smithy_client_1.map)({
|
|
643
|
-
[_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => (0, smithy_client_1.strictParseInt32)(parsedOutput.headers[_ra])],
|
|
644
|
-
});
|
|
645
|
-
const data = parsedOutput.body;
|
|
646
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
647
|
-
message: smithy_client_1.expectString,
|
|
648
|
-
});
|
|
649
|
-
Object.assign(contents, doc);
|
|
650
|
-
const exception = new models_0_1.InternalException({
|
|
651
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
652
|
-
...contents,
|
|
653
|
-
});
|
|
654
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
655
|
-
};
|
|
656
|
-
const de_NotFoundExceptionRes = async (parsedOutput, context) => {
|
|
657
|
-
const contents = (0, smithy_client_1.map)({});
|
|
658
|
-
const data = parsedOutput.body;
|
|
659
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
660
|
-
message: smithy_client_1.expectString,
|
|
661
|
-
});
|
|
662
|
-
Object.assign(contents, doc);
|
|
663
|
-
const exception = new models_0_1.NotFoundException({
|
|
664
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
665
|
-
...contents,
|
|
666
|
-
});
|
|
667
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
668
|
-
};
|
|
669
|
-
const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
|
|
670
|
-
const contents = (0, smithy_client_1.map)({});
|
|
671
|
-
const data = parsedOutput.body;
|
|
672
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
673
|
-
message: smithy_client_1.expectString,
|
|
674
|
-
quotaCode: smithy_client_1.expectString,
|
|
675
|
-
resourceId: smithy_client_1.expectString,
|
|
676
|
-
resourceType: smithy_client_1.expectString,
|
|
677
|
-
serviceCode: smithy_client_1.expectString,
|
|
678
|
-
});
|
|
679
|
-
Object.assign(contents, doc);
|
|
680
|
-
const exception = new models_0_1.ServiceQuotaExceededException({
|
|
681
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
682
|
-
...contents,
|
|
683
|
-
});
|
|
684
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
685
|
-
};
|
|
686
|
-
const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
|
|
687
|
-
const contents = (0, smithy_client_1.map)({
|
|
688
|
-
[_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => (0, smithy_client_1.strictParseInt32)(parsedOutput.headers[_ra])],
|
|
689
|
-
});
|
|
690
|
-
const data = parsedOutput.body;
|
|
691
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
692
|
-
message: smithy_client_1.expectString,
|
|
693
|
-
quotaCode: smithy_client_1.expectString,
|
|
694
|
-
serviceCode: smithy_client_1.expectString,
|
|
695
|
-
});
|
|
696
|
-
Object.assign(contents, doc);
|
|
697
|
-
const exception = new models_0_1.ThrottlingException({
|
|
698
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
699
|
-
...contents,
|
|
700
|
-
});
|
|
701
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
702
|
-
};
|
|
703
|
-
const de_ValidationExceptionRes = async (parsedOutput, context) => {
|
|
704
|
-
const contents = (0, smithy_client_1.map)({});
|
|
705
|
-
const data = parsedOutput.body;
|
|
706
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
707
|
-
fieldList: smithy_client_1._json,
|
|
708
|
-
message: smithy_client_1.expectString,
|
|
709
|
-
});
|
|
710
|
-
Object.assign(contents, doc);
|
|
711
|
-
const exception = new models_0_1.ValidationException({
|
|
712
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
713
|
-
...contents,
|
|
714
|
-
});
|
|
715
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
716
|
-
};
|
|
717
|
-
const se_PipeSourceKinesisStreamParameters = (input, context) => {
|
|
718
|
-
return (0, smithy_client_1.take)(input, {
|
|
719
|
-
BatchSize: [],
|
|
720
|
-
DeadLetterConfig: smithy_client_1._json,
|
|
721
|
-
MaximumBatchingWindowInSeconds: [],
|
|
722
|
-
MaximumRecordAgeInSeconds: [],
|
|
723
|
-
MaximumRetryAttempts: [],
|
|
724
|
-
OnPartialBatchItemFailure: [],
|
|
725
|
-
ParallelizationFactor: [],
|
|
726
|
-
StartingPosition: [],
|
|
727
|
-
StartingPositionTimestamp: (_) => Math.round(_.getTime() / 1000),
|
|
728
|
-
});
|
|
729
|
-
};
|
|
730
|
-
const se_PipeSourceParameters = (input, context) => {
|
|
731
|
-
return (0, smithy_client_1.take)(input, {
|
|
732
|
-
ActiveMQBrokerParameters: smithy_client_1._json,
|
|
733
|
-
DynamoDBStreamParameters: smithy_client_1._json,
|
|
734
|
-
FilterCriteria: smithy_client_1._json,
|
|
735
|
-
KinesisStreamParameters: (_) => se_PipeSourceKinesisStreamParameters(_, context),
|
|
736
|
-
ManagedStreamingKafkaParameters: smithy_client_1._json,
|
|
737
|
-
RabbitMQBrokerParameters: smithy_client_1._json,
|
|
738
|
-
SelfManagedKafkaParameters: smithy_client_1._json,
|
|
739
|
-
SqsQueueParameters: smithy_client_1._json,
|
|
740
|
-
});
|
|
741
|
-
};
|
|
742
|
-
const de_Pipe = (output, context) => {
|
|
743
|
-
return (0, smithy_client_1.take)(output, {
|
|
744
|
-
Arn: smithy_client_1.expectString,
|
|
745
|
-
CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
746
|
-
CurrentState: smithy_client_1.expectString,
|
|
747
|
-
DesiredState: smithy_client_1.expectString,
|
|
748
|
-
Enrichment: smithy_client_1.expectString,
|
|
749
|
-
LastModifiedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
750
|
-
Name: smithy_client_1.expectString,
|
|
751
|
-
Source: smithy_client_1.expectString,
|
|
752
|
-
StateReason: smithy_client_1.expectString,
|
|
753
|
-
Target: smithy_client_1.expectString,
|
|
754
|
-
});
|
|
755
|
-
};
|
|
756
|
-
const de_PipeList = (output, context) => {
|
|
757
|
-
const retVal = (output || [])
|
|
758
|
-
.filter((e) => e != null)
|
|
759
|
-
.map((entry) => {
|
|
760
|
-
return de_Pipe(entry, context);
|
|
761
|
-
});
|
|
762
|
-
return retVal;
|
|
763
|
-
};
|
|
764
|
-
const de_PipeSourceKinesisStreamParameters = (output, context) => {
|
|
765
|
-
return (0, smithy_client_1.take)(output, {
|
|
766
|
-
BatchSize: smithy_client_1.expectInt32,
|
|
767
|
-
DeadLetterConfig: smithy_client_1._json,
|
|
768
|
-
MaximumBatchingWindowInSeconds: smithy_client_1.expectInt32,
|
|
769
|
-
MaximumRecordAgeInSeconds: smithy_client_1.expectInt32,
|
|
770
|
-
MaximumRetryAttempts: smithy_client_1.expectInt32,
|
|
771
|
-
OnPartialBatchItemFailure: smithy_client_1.expectString,
|
|
772
|
-
ParallelizationFactor: smithy_client_1.expectInt32,
|
|
773
|
-
StartingPosition: smithy_client_1.expectString,
|
|
774
|
-
StartingPositionTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
775
|
-
});
|
|
776
|
-
};
|
|
777
|
-
const de_PipeSourceParameters = (output, context) => {
|
|
778
|
-
return (0, smithy_client_1.take)(output, {
|
|
779
|
-
ActiveMQBrokerParameters: smithy_client_1._json,
|
|
780
|
-
DynamoDBStreamParameters: smithy_client_1._json,
|
|
781
|
-
FilterCriteria: smithy_client_1._json,
|
|
782
|
-
KinesisStreamParameters: (_) => de_PipeSourceKinesisStreamParameters(_, context),
|
|
783
|
-
ManagedStreamingKafkaParameters: smithy_client_1._json,
|
|
784
|
-
RabbitMQBrokerParameters: smithy_client_1._json,
|
|
785
|
-
SelfManagedKafkaParameters: smithy_client_1._json,
|
|
786
|
-
SqsQueueParameters: smithy_client_1._json,
|
|
787
|
-
});
|
|
788
|
-
};
|
|
789
|
-
const deserializeMetadata = (output) => ({
|
|
790
|
-
httpStatusCode: output.statusCode,
|
|
791
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
792
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
793
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
794
|
-
});
|
|
795
|
-
const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
796
|
-
const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
797
|
-
value !== null &&
|
|
798
|
-
value !== "" &&
|
|
799
|
-
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
800
|
-
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
801
|
-
const _CS = "CurrentState";
|
|
802
|
-
const _DS = "DesiredState";
|
|
803
|
-
const _L = "Limit";
|
|
804
|
-
const _NP = "NamePrefix";
|
|
805
|
-
const _NT = "NextToken";
|
|
806
|
-
const _SP = "SourcePrefix";
|
|
807
|
-
const _TP = "TargetPrefix";
|
|
808
|
-
const _rAS = "retryAfterSeconds";
|
|
809
|
-
const _ra = "retry-after";
|
|
810
|
-
const _tK = "tagKeys";
|
|
811
|
-
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
812
|
-
if (encoded.length) {
|
|
813
|
-
return JSON.parse(encoded);
|
|
814
|
-
}
|
|
815
|
-
return {};
|
|
816
|
-
});
|
|
817
|
-
const parseErrorBody = async (errorBody, context) => {
|
|
818
|
-
const value = await parseBody(errorBody, context);
|
|
819
|
-
value.message = value.message ?? value.Message;
|
|
820
|
-
return value;
|
|
821
|
-
};
|
|
822
|
-
const loadRestJsonErrorCode = (output, data) => {
|
|
823
|
-
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
824
|
-
const sanitizeErrorCode = (rawValue) => {
|
|
825
|
-
let cleanValue = rawValue;
|
|
826
|
-
if (typeof cleanValue === "number") {
|
|
827
|
-
cleanValue = cleanValue.toString();
|
|
828
|
-
}
|
|
829
|
-
if (cleanValue.indexOf(",") >= 0) {
|
|
830
|
-
cleanValue = cleanValue.split(",")[0];
|
|
831
|
-
}
|
|
832
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
833
|
-
cleanValue = cleanValue.split(":")[0];
|
|
834
|
-
}
|
|
835
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
836
|
-
cleanValue = cleanValue.split("#")[1];
|
|
837
|
-
}
|
|
838
|
-
return cleanValue;
|
|
839
|
-
};
|
|
840
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
841
|
-
if (headerKey !== undefined) {
|
|
842
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
843
|
-
}
|
|
844
|
-
if (data.code !== undefined) {
|
|
845
|
-
return sanitizeErrorCode(data.code);
|
|
846
|
-
}
|
|
847
|
-
if (data["__type"] !== undefined) {
|
|
848
|
-
return sanitizeErrorCode(data["__type"]);
|
|
849
|
-
}
|
|
850
|
-
};
|
|
1
|
+
module.exports = require("../index.js");
|