@aws-sdk/client-dataexchange 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/DataExchange.js +1 -71
- package/dist-cjs/DataExchangeClient.js +1 -43
- package/dist-cjs/commands/CancelJobCommand.js +1 -28
- package/dist-cjs/commands/CreateDataSetCommand.js +1 -28
- package/dist-cjs/commands/CreateEventActionCommand.js +1 -28
- package/dist-cjs/commands/CreateJobCommand.js +1 -28
- package/dist-cjs/commands/CreateRevisionCommand.js +1 -28
- package/dist-cjs/commands/DeleteAssetCommand.js +1 -28
- package/dist-cjs/commands/DeleteDataSetCommand.js +1 -28
- package/dist-cjs/commands/DeleteEventActionCommand.js +1 -28
- package/dist-cjs/commands/DeleteRevisionCommand.js +1 -28
- package/dist-cjs/commands/GetAssetCommand.js +1 -28
- package/dist-cjs/commands/GetDataSetCommand.js +1 -28
- package/dist-cjs/commands/GetEventActionCommand.js +1 -28
- package/dist-cjs/commands/GetJobCommand.js +1 -28
- package/dist-cjs/commands/GetRevisionCommand.js +1 -28
- package/dist-cjs/commands/ListDataSetRevisionsCommand.js +1 -28
- package/dist-cjs/commands/ListDataSetsCommand.js +1 -28
- package/dist-cjs/commands/ListEventActionsCommand.js +1 -28
- package/dist-cjs/commands/ListJobsCommand.js +1 -28
- package/dist-cjs/commands/ListRevisionAssetsCommand.js +1 -28
- package/dist-cjs/commands/ListTagsForResourceCommand.js +1 -28
- package/dist-cjs/commands/RevokeRevisionCommand.js +1 -28
- package/dist-cjs/commands/SendApiAssetCommand.js +1 -28
- package/dist-cjs/commands/SendDataSetNotificationCommand.js +1 -28
- package/dist-cjs/commands/StartJobCommand.js +1 -28
- package/dist-cjs/commands/TagResourceCommand.js +1 -28
- package/dist-cjs/commands/UntagResourceCommand.js +1 -28
- package/dist-cjs/commands/UpdateAssetCommand.js +1 -28
- package/dist-cjs/commands/UpdateDataSetCommand.js +1 -28
- package/dist-cjs/commands/UpdateEventActionCommand.js +1 -28
- package/dist-cjs/commands/UpdateRevisionCommand.js +1 -28
- package/dist-cjs/commands/index.js +1 -33
- package/dist-cjs/endpoint/EndpointParameters.js +1 -18
- package/dist-cjs/extensionConfiguration.js +1 -2
- package/dist-cjs/index.js +3283 -11
- package/dist-cjs/models/DataExchangeServiceException.js +1 -12
- package/dist-cjs/models/index.js +1 -4
- package/dist-cjs/models/models_0.js +1 -237
- package/dist-cjs/pagination/Interfaces.js +1 -2
- package/dist-cjs/pagination/ListDataSetRevisionsPaginator.js +1 -7
- package/dist-cjs/pagination/ListDataSetsPaginator.js +1 -7
- package/dist-cjs/pagination/ListEventActionsPaginator.js +1 -7
- package/dist-cjs/pagination/ListJobsPaginator.js +1 -7
- package/dist-cjs/pagination/ListRevisionAssetsPaginator.js +1 -7
- package/dist-cjs/pagination/index.js +1 -9
- package/dist-cjs/protocols/Aws_restJson1.js +1 -2244
- package/dist-cjs/runtimeExtensions.js +1 -22
- package/package.json +40 -40
|
@@ -1,2244 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_ListTagsForResourceCommand = exports.de_ListRevisionAssetsCommand = exports.de_ListJobsCommand = exports.de_ListEventActionsCommand = exports.de_ListDataSetsCommand = exports.de_ListDataSetRevisionsCommand = exports.de_GetRevisionCommand = exports.de_GetJobCommand = exports.de_GetEventActionCommand = exports.de_GetDataSetCommand = exports.de_GetAssetCommand = exports.de_DeleteRevisionCommand = exports.de_DeleteEventActionCommand = exports.de_DeleteDataSetCommand = exports.de_DeleteAssetCommand = exports.de_CreateRevisionCommand = exports.de_CreateJobCommand = exports.de_CreateEventActionCommand = exports.de_CreateDataSetCommand = exports.de_CancelJobCommand = exports.se_UpdateRevisionCommand = exports.se_UpdateEventActionCommand = exports.se_UpdateDataSetCommand = exports.se_UpdateAssetCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_StartJobCommand = exports.se_SendDataSetNotificationCommand = exports.se_SendApiAssetCommand = exports.se_RevokeRevisionCommand = exports.se_ListTagsForResourceCommand = exports.se_ListRevisionAssetsCommand = exports.se_ListJobsCommand = exports.se_ListEventActionsCommand = exports.se_ListDataSetsCommand = exports.se_ListDataSetRevisionsCommand = exports.se_GetRevisionCommand = exports.se_GetJobCommand = exports.se_GetEventActionCommand = exports.se_GetDataSetCommand = exports.se_GetAssetCommand = exports.se_DeleteRevisionCommand = exports.se_DeleteEventActionCommand = exports.se_DeleteDataSetCommand = exports.se_DeleteAssetCommand = exports.se_CreateRevisionCommand = exports.se_CreateJobCommand = exports.se_CreateEventActionCommand = exports.se_CreateDataSetCommand = exports.se_CancelJobCommand = void 0;
|
|
4
|
-
exports.de_UpdateRevisionCommand = exports.de_UpdateEventActionCommand = exports.de_UpdateDataSetCommand = exports.de_UpdateAssetCommand = exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_StartJobCommand = exports.de_SendDataSetNotificationCommand = exports.de_SendApiAssetCommand = exports.de_RevokeRevisionCommand = void 0;
|
|
5
|
-
const core_1 = require("@smithy/core");
|
|
6
|
-
const protocol_http_1 = require("@smithy/protocol-http");
|
|
7
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
8
|
-
const uuid_1 = require("uuid");
|
|
9
|
-
const DataExchangeServiceException_1 = require("../models/DataExchangeServiceException");
|
|
10
|
-
const models_0_1 = require("../models/models_0");
|
|
11
|
-
const se_CancelJobCommand = async (input, context) => {
|
|
12
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
13
|
-
const headers = {};
|
|
14
|
-
b.bp("/v1/jobs/{JobId}");
|
|
15
|
-
b.p("JobId", () => input.JobId, "{JobId}", false);
|
|
16
|
-
let body;
|
|
17
|
-
b.m("DELETE").h(headers).b(body);
|
|
18
|
-
return b.build();
|
|
19
|
-
};
|
|
20
|
-
exports.se_CancelJobCommand = se_CancelJobCommand;
|
|
21
|
-
const se_CreateDataSetCommand = async (input, context) => {
|
|
22
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
23
|
-
const headers = {
|
|
24
|
-
"content-type": "application/json",
|
|
25
|
-
};
|
|
26
|
-
b.bp("/v1/data-sets");
|
|
27
|
-
let body;
|
|
28
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
29
|
-
AssetType: [],
|
|
30
|
-
Description: [],
|
|
31
|
-
Name: [],
|
|
32
|
-
Tags: (_) => (0, smithy_client_1._json)(_),
|
|
33
|
-
}));
|
|
34
|
-
b.m("POST").h(headers).b(body);
|
|
35
|
-
return b.build();
|
|
36
|
-
};
|
|
37
|
-
exports.se_CreateDataSetCommand = se_CreateDataSetCommand;
|
|
38
|
-
const se_CreateEventActionCommand = async (input, context) => {
|
|
39
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
40
|
-
const headers = {
|
|
41
|
-
"content-type": "application/json",
|
|
42
|
-
};
|
|
43
|
-
b.bp("/v1/event-actions");
|
|
44
|
-
let body;
|
|
45
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
46
|
-
Action: (_) => (0, smithy_client_1._json)(_),
|
|
47
|
-
Event: (_) => (0, smithy_client_1._json)(_),
|
|
48
|
-
}));
|
|
49
|
-
b.m("POST").h(headers).b(body);
|
|
50
|
-
return b.build();
|
|
51
|
-
};
|
|
52
|
-
exports.se_CreateEventActionCommand = se_CreateEventActionCommand;
|
|
53
|
-
const se_CreateJobCommand = async (input, context) => {
|
|
54
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
55
|
-
const headers = {
|
|
56
|
-
"content-type": "application/json",
|
|
57
|
-
};
|
|
58
|
-
b.bp("/v1/jobs");
|
|
59
|
-
let body;
|
|
60
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
61
|
-
Details: (_) => (0, smithy_client_1._json)(_),
|
|
62
|
-
Type: [],
|
|
63
|
-
}));
|
|
64
|
-
b.m("POST").h(headers).b(body);
|
|
65
|
-
return b.build();
|
|
66
|
-
};
|
|
67
|
-
exports.se_CreateJobCommand = se_CreateJobCommand;
|
|
68
|
-
const se_CreateRevisionCommand = async (input, context) => {
|
|
69
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
70
|
-
const headers = {
|
|
71
|
-
"content-type": "application/json",
|
|
72
|
-
};
|
|
73
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions");
|
|
74
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
75
|
-
let body;
|
|
76
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
77
|
-
Comment: [],
|
|
78
|
-
Tags: (_) => (0, smithy_client_1._json)(_),
|
|
79
|
-
}));
|
|
80
|
-
b.m("POST").h(headers).b(body);
|
|
81
|
-
return b.build();
|
|
82
|
-
};
|
|
83
|
-
exports.se_CreateRevisionCommand = se_CreateRevisionCommand;
|
|
84
|
-
const se_DeleteAssetCommand = async (input, context) => {
|
|
85
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
86
|
-
const headers = {};
|
|
87
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}");
|
|
88
|
-
b.p("AssetId", () => input.AssetId, "{AssetId}", false);
|
|
89
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
90
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
91
|
-
let body;
|
|
92
|
-
b.m("DELETE").h(headers).b(body);
|
|
93
|
-
return b.build();
|
|
94
|
-
};
|
|
95
|
-
exports.se_DeleteAssetCommand = se_DeleteAssetCommand;
|
|
96
|
-
const se_DeleteDataSetCommand = async (input, context) => {
|
|
97
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
98
|
-
const headers = {};
|
|
99
|
-
b.bp("/v1/data-sets/{DataSetId}");
|
|
100
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
101
|
-
let body;
|
|
102
|
-
b.m("DELETE").h(headers).b(body);
|
|
103
|
-
return b.build();
|
|
104
|
-
};
|
|
105
|
-
exports.se_DeleteDataSetCommand = se_DeleteDataSetCommand;
|
|
106
|
-
const se_DeleteEventActionCommand = async (input, context) => {
|
|
107
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
108
|
-
const headers = {};
|
|
109
|
-
b.bp("/v1/event-actions/{EventActionId}");
|
|
110
|
-
b.p("EventActionId", () => input.EventActionId, "{EventActionId}", false);
|
|
111
|
-
let body;
|
|
112
|
-
b.m("DELETE").h(headers).b(body);
|
|
113
|
-
return b.build();
|
|
114
|
-
};
|
|
115
|
-
exports.se_DeleteEventActionCommand = se_DeleteEventActionCommand;
|
|
116
|
-
const se_DeleteRevisionCommand = async (input, context) => {
|
|
117
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
118
|
-
const headers = {};
|
|
119
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}");
|
|
120
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
121
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
122
|
-
let body;
|
|
123
|
-
b.m("DELETE").h(headers).b(body);
|
|
124
|
-
return b.build();
|
|
125
|
-
};
|
|
126
|
-
exports.se_DeleteRevisionCommand = se_DeleteRevisionCommand;
|
|
127
|
-
const se_GetAssetCommand = async (input, context) => {
|
|
128
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
129
|
-
const headers = {};
|
|
130
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}");
|
|
131
|
-
b.p("AssetId", () => input.AssetId, "{AssetId}", false);
|
|
132
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
133
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
134
|
-
let body;
|
|
135
|
-
b.m("GET").h(headers).b(body);
|
|
136
|
-
return b.build();
|
|
137
|
-
};
|
|
138
|
-
exports.se_GetAssetCommand = se_GetAssetCommand;
|
|
139
|
-
const se_GetDataSetCommand = async (input, context) => {
|
|
140
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
141
|
-
const headers = {};
|
|
142
|
-
b.bp("/v1/data-sets/{DataSetId}");
|
|
143
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
144
|
-
let body;
|
|
145
|
-
b.m("GET").h(headers).b(body);
|
|
146
|
-
return b.build();
|
|
147
|
-
};
|
|
148
|
-
exports.se_GetDataSetCommand = se_GetDataSetCommand;
|
|
149
|
-
const se_GetEventActionCommand = async (input, context) => {
|
|
150
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
151
|
-
const headers = {};
|
|
152
|
-
b.bp("/v1/event-actions/{EventActionId}");
|
|
153
|
-
b.p("EventActionId", () => input.EventActionId, "{EventActionId}", false);
|
|
154
|
-
let body;
|
|
155
|
-
b.m("GET").h(headers).b(body);
|
|
156
|
-
return b.build();
|
|
157
|
-
};
|
|
158
|
-
exports.se_GetEventActionCommand = se_GetEventActionCommand;
|
|
159
|
-
const se_GetJobCommand = async (input, context) => {
|
|
160
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
161
|
-
const headers = {};
|
|
162
|
-
b.bp("/v1/jobs/{JobId}");
|
|
163
|
-
b.p("JobId", () => input.JobId, "{JobId}", false);
|
|
164
|
-
let body;
|
|
165
|
-
b.m("GET").h(headers).b(body);
|
|
166
|
-
return b.build();
|
|
167
|
-
};
|
|
168
|
-
exports.se_GetJobCommand = se_GetJobCommand;
|
|
169
|
-
const se_GetRevisionCommand = async (input, context) => {
|
|
170
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
171
|
-
const headers = {};
|
|
172
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}");
|
|
173
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
174
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
175
|
-
let body;
|
|
176
|
-
b.m("GET").h(headers).b(body);
|
|
177
|
-
return b.build();
|
|
178
|
-
};
|
|
179
|
-
exports.se_GetRevisionCommand = se_GetRevisionCommand;
|
|
180
|
-
const se_ListDataSetRevisionsCommand = async (input, context) => {
|
|
181
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
182
|
-
const headers = {};
|
|
183
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions");
|
|
184
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
185
|
-
const query = (0, smithy_client_1.map)({
|
|
186
|
-
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
187
|
-
[_nT]: [, input[_NT]],
|
|
188
|
-
});
|
|
189
|
-
let body;
|
|
190
|
-
b.m("GET").h(headers).q(query).b(body);
|
|
191
|
-
return b.build();
|
|
192
|
-
};
|
|
193
|
-
exports.se_ListDataSetRevisionsCommand = se_ListDataSetRevisionsCommand;
|
|
194
|
-
const se_ListDataSetsCommand = async (input, context) => {
|
|
195
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
196
|
-
const headers = {};
|
|
197
|
-
b.bp("/v1/data-sets");
|
|
198
|
-
const query = (0, smithy_client_1.map)({
|
|
199
|
-
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
200
|
-
[_nT]: [, input[_NT]],
|
|
201
|
-
[_o]: [, input[_O]],
|
|
202
|
-
});
|
|
203
|
-
let body;
|
|
204
|
-
b.m("GET").h(headers).q(query).b(body);
|
|
205
|
-
return b.build();
|
|
206
|
-
};
|
|
207
|
-
exports.se_ListDataSetsCommand = se_ListDataSetsCommand;
|
|
208
|
-
const se_ListEventActionsCommand = async (input, context) => {
|
|
209
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
210
|
-
const headers = {};
|
|
211
|
-
b.bp("/v1/event-actions");
|
|
212
|
-
const query = (0, smithy_client_1.map)({
|
|
213
|
-
[_eSI]: [, input[_ESI]],
|
|
214
|
-
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
215
|
-
[_nT]: [, input[_NT]],
|
|
216
|
-
});
|
|
217
|
-
let body;
|
|
218
|
-
b.m("GET").h(headers).q(query).b(body);
|
|
219
|
-
return b.build();
|
|
220
|
-
};
|
|
221
|
-
exports.se_ListEventActionsCommand = se_ListEventActionsCommand;
|
|
222
|
-
const se_ListJobsCommand = async (input, context) => {
|
|
223
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
224
|
-
const headers = {};
|
|
225
|
-
b.bp("/v1/jobs");
|
|
226
|
-
const query = (0, smithy_client_1.map)({
|
|
227
|
-
[_dSI]: [, input[_DSI]],
|
|
228
|
-
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
229
|
-
[_nT]: [, input[_NT]],
|
|
230
|
-
[_rI]: [, input[_RI]],
|
|
231
|
-
});
|
|
232
|
-
let body;
|
|
233
|
-
b.m("GET").h(headers).q(query).b(body);
|
|
234
|
-
return b.build();
|
|
235
|
-
};
|
|
236
|
-
exports.se_ListJobsCommand = se_ListJobsCommand;
|
|
237
|
-
const se_ListRevisionAssetsCommand = async (input, context) => {
|
|
238
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
239
|
-
const headers = {};
|
|
240
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets");
|
|
241
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
242
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
243
|
-
const query = (0, smithy_client_1.map)({
|
|
244
|
-
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
245
|
-
[_nT]: [, input[_NT]],
|
|
246
|
-
});
|
|
247
|
-
let body;
|
|
248
|
-
b.m("GET").h(headers).q(query).b(body);
|
|
249
|
-
return b.build();
|
|
250
|
-
};
|
|
251
|
-
exports.se_ListRevisionAssetsCommand = se_ListRevisionAssetsCommand;
|
|
252
|
-
const se_ListTagsForResourceCommand = async (input, context) => {
|
|
253
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
254
|
-
const headers = {};
|
|
255
|
-
b.bp("/tags/{ResourceArn}");
|
|
256
|
-
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
257
|
-
let body;
|
|
258
|
-
b.m("GET").h(headers).b(body);
|
|
259
|
-
return b.build();
|
|
260
|
-
};
|
|
261
|
-
exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
|
|
262
|
-
const se_RevokeRevisionCommand = async (input, context) => {
|
|
263
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
264
|
-
const headers = {
|
|
265
|
-
"content-type": "application/json",
|
|
266
|
-
};
|
|
267
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/revoke");
|
|
268
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
269
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
270
|
-
let body;
|
|
271
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
272
|
-
RevocationComment: [],
|
|
273
|
-
}));
|
|
274
|
-
b.m("POST").h(headers).b(body);
|
|
275
|
-
return b.build();
|
|
276
|
-
};
|
|
277
|
-
exports.se_RevokeRevisionCommand = se_RevokeRevisionCommand;
|
|
278
|
-
const se_SendApiAssetCommand = async (input, context) => {
|
|
279
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
280
|
-
const headers = (0, smithy_client_1.map)({}, isSerializableHeaderValue, {
|
|
281
|
-
"content-type": "text/plain",
|
|
282
|
-
[_xadai]: input[_AI],
|
|
283
|
-
[_xaddsi]: input[_DSI],
|
|
284
|
-
[_xadhm]: input[_M],
|
|
285
|
-
[_xadp]: input[_P],
|
|
286
|
-
[_xadri]: input[_RI],
|
|
287
|
-
...(input.RequestHeaders !== undefined &&
|
|
288
|
-
Object.keys(input.RequestHeaders).reduce((acc, suffix) => {
|
|
289
|
-
acc[`x-amzn-dataexchange-header-${suffix.toLowerCase()}`] = input.RequestHeaders[suffix];
|
|
290
|
-
return acc;
|
|
291
|
-
}, {})),
|
|
292
|
-
});
|
|
293
|
-
b.bp("/v1");
|
|
294
|
-
const query = (0, smithy_client_1.map)({
|
|
295
|
-
...(0, smithy_client_1.convertMap)(input.QueryStringParameters),
|
|
296
|
-
});
|
|
297
|
-
let body;
|
|
298
|
-
if (input.Body !== undefined) {
|
|
299
|
-
body = input.Body;
|
|
300
|
-
}
|
|
301
|
-
let { hostname: resolvedHostname } = await context.endpoint();
|
|
302
|
-
if (context.disableHostPrefix !== true) {
|
|
303
|
-
resolvedHostname = "api-fulfill." + resolvedHostname;
|
|
304
|
-
if (!(0, protocol_http_1.isValidHostname)(resolvedHostname)) {
|
|
305
|
-
throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
|
|
306
|
-
}
|
|
307
|
-
}
|
|
308
|
-
b.hn(resolvedHostname);
|
|
309
|
-
b.m("POST").h(headers).q(query).b(body);
|
|
310
|
-
return b.build();
|
|
311
|
-
};
|
|
312
|
-
exports.se_SendApiAssetCommand = se_SendApiAssetCommand;
|
|
313
|
-
const se_SendDataSetNotificationCommand = async (input, context) => {
|
|
314
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
315
|
-
const headers = {
|
|
316
|
-
"content-type": "application/json",
|
|
317
|
-
};
|
|
318
|
-
b.bp("/v1/data-sets/{DataSetId}/notification");
|
|
319
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
320
|
-
let body;
|
|
321
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
322
|
-
ClientToken: [true, (_) => _ ?? (0, uuid_1.v4)()],
|
|
323
|
-
Comment: [],
|
|
324
|
-
Details: (_) => se_NotificationDetails(_, context),
|
|
325
|
-
Scope: (_) => (0, smithy_client_1._json)(_),
|
|
326
|
-
Type: [],
|
|
327
|
-
}));
|
|
328
|
-
b.m("POST").h(headers).b(body);
|
|
329
|
-
return b.build();
|
|
330
|
-
};
|
|
331
|
-
exports.se_SendDataSetNotificationCommand = se_SendDataSetNotificationCommand;
|
|
332
|
-
const se_StartJobCommand = async (input, context) => {
|
|
333
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
334
|
-
const headers = {};
|
|
335
|
-
b.bp("/v1/jobs/{JobId}");
|
|
336
|
-
b.p("JobId", () => input.JobId, "{JobId}", false);
|
|
337
|
-
let body;
|
|
338
|
-
b.m("PATCH").h(headers).b(body);
|
|
339
|
-
return b.build();
|
|
340
|
-
};
|
|
341
|
-
exports.se_StartJobCommand = se_StartJobCommand;
|
|
342
|
-
const se_TagResourceCommand = async (input, context) => {
|
|
343
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
344
|
-
const headers = {
|
|
345
|
-
"content-type": "application/json",
|
|
346
|
-
};
|
|
347
|
-
b.bp("/tags/{ResourceArn}");
|
|
348
|
-
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
349
|
-
let body;
|
|
350
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
351
|
-
tags: [, (_) => (0, smithy_client_1._json)(_), `Tags`],
|
|
352
|
-
}));
|
|
353
|
-
b.m("POST").h(headers).b(body);
|
|
354
|
-
return b.build();
|
|
355
|
-
};
|
|
356
|
-
exports.se_TagResourceCommand = se_TagResourceCommand;
|
|
357
|
-
const se_UntagResourceCommand = async (input, context) => {
|
|
358
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
359
|
-
const headers = {};
|
|
360
|
-
b.bp("/tags/{ResourceArn}");
|
|
361
|
-
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
362
|
-
const query = (0, smithy_client_1.map)({
|
|
363
|
-
[_tK]: [
|
|
364
|
-
(0, smithy_client_1.expectNonNull)(input.TagKeys, `TagKeys`) != null,
|
|
365
|
-
() => (input[_TK] || []).map((_entry) => _entry),
|
|
366
|
-
],
|
|
367
|
-
});
|
|
368
|
-
let body;
|
|
369
|
-
b.m("DELETE").h(headers).q(query).b(body);
|
|
370
|
-
return b.build();
|
|
371
|
-
};
|
|
372
|
-
exports.se_UntagResourceCommand = se_UntagResourceCommand;
|
|
373
|
-
const se_UpdateAssetCommand = async (input, context) => {
|
|
374
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
375
|
-
const headers = {
|
|
376
|
-
"content-type": "application/json",
|
|
377
|
-
};
|
|
378
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}");
|
|
379
|
-
b.p("AssetId", () => input.AssetId, "{AssetId}", false);
|
|
380
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
381
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
382
|
-
let body;
|
|
383
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
384
|
-
Name: [],
|
|
385
|
-
}));
|
|
386
|
-
b.m("PATCH").h(headers).b(body);
|
|
387
|
-
return b.build();
|
|
388
|
-
};
|
|
389
|
-
exports.se_UpdateAssetCommand = se_UpdateAssetCommand;
|
|
390
|
-
const se_UpdateDataSetCommand = async (input, context) => {
|
|
391
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
392
|
-
const headers = {
|
|
393
|
-
"content-type": "application/json",
|
|
394
|
-
};
|
|
395
|
-
b.bp("/v1/data-sets/{DataSetId}");
|
|
396
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
397
|
-
let body;
|
|
398
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
399
|
-
Description: [],
|
|
400
|
-
Name: [],
|
|
401
|
-
}));
|
|
402
|
-
b.m("PATCH").h(headers).b(body);
|
|
403
|
-
return b.build();
|
|
404
|
-
};
|
|
405
|
-
exports.se_UpdateDataSetCommand = se_UpdateDataSetCommand;
|
|
406
|
-
const se_UpdateEventActionCommand = async (input, context) => {
|
|
407
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
408
|
-
const headers = {
|
|
409
|
-
"content-type": "application/json",
|
|
410
|
-
};
|
|
411
|
-
b.bp("/v1/event-actions/{EventActionId}");
|
|
412
|
-
b.p("EventActionId", () => input.EventActionId, "{EventActionId}", false);
|
|
413
|
-
let body;
|
|
414
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
415
|
-
Action: (_) => (0, smithy_client_1._json)(_),
|
|
416
|
-
}));
|
|
417
|
-
b.m("PATCH").h(headers).b(body);
|
|
418
|
-
return b.build();
|
|
419
|
-
};
|
|
420
|
-
exports.se_UpdateEventActionCommand = se_UpdateEventActionCommand;
|
|
421
|
-
const se_UpdateRevisionCommand = async (input, context) => {
|
|
422
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
423
|
-
const headers = {
|
|
424
|
-
"content-type": "application/json",
|
|
425
|
-
};
|
|
426
|
-
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}");
|
|
427
|
-
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
428
|
-
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
429
|
-
let body;
|
|
430
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
431
|
-
Comment: [],
|
|
432
|
-
Finalized: [],
|
|
433
|
-
}));
|
|
434
|
-
b.m("PATCH").h(headers).b(body);
|
|
435
|
-
return b.build();
|
|
436
|
-
};
|
|
437
|
-
exports.se_UpdateRevisionCommand = se_UpdateRevisionCommand;
|
|
438
|
-
const de_CancelJobCommand = async (output, context) => {
|
|
439
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
440
|
-
return de_CancelJobCommandError(output, context);
|
|
441
|
-
}
|
|
442
|
-
const contents = (0, smithy_client_1.map)({
|
|
443
|
-
$metadata: deserializeMetadata(output),
|
|
444
|
-
});
|
|
445
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
446
|
-
return contents;
|
|
447
|
-
};
|
|
448
|
-
exports.de_CancelJobCommand = de_CancelJobCommand;
|
|
449
|
-
const de_CancelJobCommandError = async (output, context) => {
|
|
450
|
-
const parsedOutput = {
|
|
451
|
-
...output,
|
|
452
|
-
body: await parseErrorBody(output.body, context),
|
|
453
|
-
};
|
|
454
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
455
|
-
switch (errorCode) {
|
|
456
|
-
case "ConflictException":
|
|
457
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
458
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
459
|
-
case "InternalServerException":
|
|
460
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
461
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
462
|
-
case "ResourceNotFoundException":
|
|
463
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
464
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
465
|
-
case "ThrottlingException":
|
|
466
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
467
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
468
|
-
case "ValidationException":
|
|
469
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
470
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
471
|
-
default:
|
|
472
|
-
const parsedBody = parsedOutput.body;
|
|
473
|
-
return throwDefaultError({
|
|
474
|
-
output,
|
|
475
|
-
parsedBody,
|
|
476
|
-
errorCode,
|
|
477
|
-
});
|
|
478
|
-
}
|
|
479
|
-
};
|
|
480
|
-
const de_CreateDataSetCommand = async (output, context) => {
|
|
481
|
-
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
482
|
-
return de_CreateDataSetCommandError(output, context);
|
|
483
|
-
}
|
|
484
|
-
const contents = (0, smithy_client_1.map)({
|
|
485
|
-
$metadata: deserializeMetadata(output),
|
|
486
|
-
});
|
|
487
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
488
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
489
|
-
Arn: smithy_client_1.expectString,
|
|
490
|
-
AssetType: smithy_client_1.expectString,
|
|
491
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
492
|
-
Description: smithy_client_1.expectString,
|
|
493
|
-
Id: smithy_client_1.expectString,
|
|
494
|
-
Name: smithy_client_1.expectString,
|
|
495
|
-
Origin: smithy_client_1.expectString,
|
|
496
|
-
OriginDetails: smithy_client_1._json,
|
|
497
|
-
SourceId: smithy_client_1.expectString,
|
|
498
|
-
Tags: smithy_client_1._json,
|
|
499
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
500
|
-
});
|
|
501
|
-
Object.assign(contents, doc);
|
|
502
|
-
return contents;
|
|
503
|
-
};
|
|
504
|
-
exports.de_CreateDataSetCommand = de_CreateDataSetCommand;
|
|
505
|
-
const de_CreateDataSetCommandError = async (output, context) => {
|
|
506
|
-
const parsedOutput = {
|
|
507
|
-
...output,
|
|
508
|
-
body: await parseErrorBody(output.body, context),
|
|
509
|
-
};
|
|
510
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
511
|
-
switch (errorCode) {
|
|
512
|
-
case "AccessDeniedException":
|
|
513
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
514
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
515
|
-
case "InternalServerException":
|
|
516
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
517
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
518
|
-
case "ServiceLimitExceededException":
|
|
519
|
-
case "com.amazonaws.dataexchange#ServiceLimitExceededException":
|
|
520
|
-
throw await de_ServiceLimitExceededExceptionRes(parsedOutput, context);
|
|
521
|
-
case "ThrottlingException":
|
|
522
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
523
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
524
|
-
case "ValidationException":
|
|
525
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
526
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
527
|
-
default:
|
|
528
|
-
const parsedBody = parsedOutput.body;
|
|
529
|
-
return throwDefaultError({
|
|
530
|
-
output,
|
|
531
|
-
parsedBody,
|
|
532
|
-
errorCode,
|
|
533
|
-
});
|
|
534
|
-
}
|
|
535
|
-
};
|
|
536
|
-
const de_CreateEventActionCommand = async (output, context) => {
|
|
537
|
-
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
538
|
-
return de_CreateEventActionCommandError(output, context);
|
|
539
|
-
}
|
|
540
|
-
const contents = (0, smithy_client_1.map)({
|
|
541
|
-
$metadata: deserializeMetadata(output),
|
|
542
|
-
});
|
|
543
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
544
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
545
|
-
Action: smithy_client_1._json,
|
|
546
|
-
Arn: smithy_client_1.expectString,
|
|
547
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
548
|
-
Event: smithy_client_1._json,
|
|
549
|
-
Id: smithy_client_1.expectString,
|
|
550
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
551
|
-
});
|
|
552
|
-
Object.assign(contents, doc);
|
|
553
|
-
return contents;
|
|
554
|
-
};
|
|
555
|
-
exports.de_CreateEventActionCommand = de_CreateEventActionCommand;
|
|
556
|
-
const de_CreateEventActionCommandError = async (output, context) => {
|
|
557
|
-
const parsedOutput = {
|
|
558
|
-
...output,
|
|
559
|
-
body: await parseErrorBody(output.body, context),
|
|
560
|
-
};
|
|
561
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
562
|
-
switch (errorCode) {
|
|
563
|
-
case "AccessDeniedException":
|
|
564
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
565
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
566
|
-
case "InternalServerException":
|
|
567
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
568
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
569
|
-
case "ServiceLimitExceededException":
|
|
570
|
-
case "com.amazonaws.dataexchange#ServiceLimitExceededException":
|
|
571
|
-
throw await de_ServiceLimitExceededExceptionRes(parsedOutput, context);
|
|
572
|
-
case "ThrottlingException":
|
|
573
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
574
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
575
|
-
case "ValidationException":
|
|
576
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
577
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
578
|
-
default:
|
|
579
|
-
const parsedBody = parsedOutput.body;
|
|
580
|
-
return throwDefaultError({
|
|
581
|
-
output,
|
|
582
|
-
parsedBody,
|
|
583
|
-
errorCode,
|
|
584
|
-
});
|
|
585
|
-
}
|
|
586
|
-
};
|
|
587
|
-
const de_CreateJobCommand = async (output, context) => {
|
|
588
|
-
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
589
|
-
return de_CreateJobCommandError(output, context);
|
|
590
|
-
}
|
|
591
|
-
const contents = (0, smithy_client_1.map)({
|
|
592
|
-
$metadata: deserializeMetadata(output),
|
|
593
|
-
});
|
|
594
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
595
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
596
|
-
Arn: smithy_client_1.expectString,
|
|
597
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
598
|
-
Details: (_) => de_ResponseDetails(_, context),
|
|
599
|
-
Errors: (_) => de_ListOfJobError(_, context),
|
|
600
|
-
Id: smithy_client_1.expectString,
|
|
601
|
-
State: smithy_client_1.expectString,
|
|
602
|
-
Type: smithy_client_1.expectString,
|
|
603
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
604
|
-
});
|
|
605
|
-
Object.assign(contents, doc);
|
|
606
|
-
return contents;
|
|
607
|
-
};
|
|
608
|
-
exports.de_CreateJobCommand = de_CreateJobCommand;
|
|
609
|
-
const de_CreateJobCommandError = async (output, context) => {
|
|
610
|
-
const parsedOutput = {
|
|
611
|
-
...output,
|
|
612
|
-
body: await parseErrorBody(output.body, context),
|
|
613
|
-
};
|
|
614
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
615
|
-
switch (errorCode) {
|
|
616
|
-
case "AccessDeniedException":
|
|
617
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
618
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
619
|
-
case "ConflictException":
|
|
620
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
621
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
622
|
-
case "InternalServerException":
|
|
623
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
624
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
625
|
-
case "ResourceNotFoundException":
|
|
626
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
627
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
628
|
-
case "ThrottlingException":
|
|
629
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
630
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
631
|
-
case "ValidationException":
|
|
632
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
633
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
634
|
-
default:
|
|
635
|
-
const parsedBody = parsedOutput.body;
|
|
636
|
-
return throwDefaultError({
|
|
637
|
-
output,
|
|
638
|
-
parsedBody,
|
|
639
|
-
errorCode,
|
|
640
|
-
});
|
|
641
|
-
}
|
|
642
|
-
};
|
|
643
|
-
const de_CreateRevisionCommand = async (output, context) => {
|
|
644
|
-
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
645
|
-
return de_CreateRevisionCommandError(output, context);
|
|
646
|
-
}
|
|
647
|
-
const contents = (0, smithy_client_1.map)({
|
|
648
|
-
$metadata: deserializeMetadata(output),
|
|
649
|
-
});
|
|
650
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
651
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
652
|
-
Arn: smithy_client_1.expectString,
|
|
653
|
-
Comment: smithy_client_1.expectString,
|
|
654
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
655
|
-
DataSetId: smithy_client_1.expectString,
|
|
656
|
-
Finalized: smithy_client_1.expectBoolean,
|
|
657
|
-
Id: smithy_client_1.expectString,
|
|
658
|
-
RevocationComment: smithy_client_1.expectString,
|
|
659
|
-
Revoked: smithy_client_1.expectBoolean,
|
|
660
|
-
RevokedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
661
|
-
SourceId: smithy_client_1.expectString,
|
|
662
|
-
Tags: smithy_client_1._json,
|
|
663
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
664
|
-
});
|
|
665
|
-
Object.assign(contents, doc);
|
|
666
|
-
return contents;
|
|
667
|
-
};
|
|
668
|
-
exports.de_CreateRevisionCommand = de_CreateRevisionCommand;
|
|
669
|
-
const de_CreateRevisionCommandError = async (output, context) => {
|
|
670
|
-
const parsedOutput = {
|
|
671
|
-
...output,
|
|
672
|
-
body: await parseErrorBody(output.body, context),
|
|
673
|
-
};
|
|
674
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
675
|
-
switch (errorCode) {
|
|
676
|
-
case "AccessDeniedException":
|
|
677
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
678
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
679
|
-
case "InternalServerException":
|
|
680
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
681
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
682
|
-
case "ResourceNotFoundException":
|
|
683
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
684
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
685
|
-
case "ThrottlingException":
|
|
686
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
687
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
688
|
-
case "ValidationException":
|
|
689
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
690
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
691
|
-
default:
|
|
692
|
-
const parsedBody = parsedOutput.body;
|
|
693
|
-
return throwDefaultError({
|
|
694
|
-
output,
|
|
695
|
-
parsedBody,
|
|
696
|
-
errorCode,
|
|
697
|
-
});
|
|
698
|
-
}
|
|
699
|
-
};
|
|
700
|
-
const de_DeleteAssetCommand = async (output, context) => {
|
|
701
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
702
|
-
return de_DeleteAssetCommandError(output, context);
|
|
703
|
-
}
|
|
704
|
-
const contents = (0, smithy_client_1.map)({
|
|
705
|
-
$metadata: deserializeMetadata(output),
|
|
706
|
-
});
|
|
707
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
708
|
-
return contents;
|
|
709
|
-
};
|
|
710
|
-
exports.de_DeleteAssetCommand = de_DeleteAssetCommand;
|
|
711
|
-
const de_DeleteAssetCommandError = async (output, context) => {
|
|
712
|
-
const parsedOutput = {
|
|
713
|
-
...output,
|
|
714
|
-
body: await parseErrorBody(output.body, context),
|
|
715
|
-
};
|
|
716
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
717
|
-
switch (errorCode) {
|
|
718
|
-
case "AccessDeniedException":
|
|
719
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
720
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
721
|
-
case "ConflictException":
|
|
722
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
723
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
724
|
-
case "InternalServerException":
|
|
725
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
726
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
727
|
-
case "ResourceNotFoundException":
|
|
728
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
729
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
730
|
-
case "ThrottlingException":
|
|
731
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
732
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
733
|
-
case "ValidationException":
|
|
734
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
735
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
736
|
-
default:
|
|
737
|
-
const parsedBody = parsedOutput.body;
|
|
738
|
-
return throwDefaultError({
|
|
739
|
-
output,
|
|
740
|
-
parsedBody,
|
|
741
|
-
errorCode,
|
|
742
|
-
});
|
|
743
|
-
}
|
|
744
|
-
};
|
|
745
|
-
const de_DeleteDataSetCommand = async (output, context) => {
|
|
746
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
747
|
-
return de_DeleteDataSetCommandError(output, context);
|
|
748
|
-
}
|
|
749
|
-
const contents = (0, smithy_client_1.map)({
|
|
750
|
-
$metadata: deserializeMetadata(output),
|
|
751
|
-
});
|
|
752
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
753
|
-
return contents;
|
|
754
|
-
};
|
|
755
|
-
exports.de_DeleteDataSetCommand = de_DeleteDataSetCommand;
|
|
756
|
-
const de_DeleteDataSetCommandError = async (output, context) => {
|
|
757
|
-
const parsedOutput = {
|
|
758
|
-
...output,
|
|
759
|
-
body: await parseErrorBody(output.body, context),
|
|
760
|
-
};
|
|
761
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
762
|
-
switch (errorCode) {
|
|
763
|
-
case "AccessDeniedException":
|
|
764
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
765
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
766
|
-
case "ConflictException":
|
|
767
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
768
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
769
|
-
case "InternalServerException":
|
|
770
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
771
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
772
|
-
case "ResourceNotFoundException":
|
|
773
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
774
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
775
|
-
case "ThrottlingException":
|
|
776
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
777
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
778
|
-
case "ValidationException":
|
|
779
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
780
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
781
|
-
default:
|
|
782
|
-
const parsedBody = parsedOutput.body;
|
|
783
|
-
return throwDefaultError({
|
|
784
|
-
output,
|
|
785
|
-
parsedBody,
|
|
786
|
-
errorCode,
|
|
787
|
-
});
|
|
788
|
-
}
|
|
789
|
-
};
|
|
790
|
-
const de_DeleteEventActionCommand = async (output, context) => {
|
|
791
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
792
|
-
return de_DeleteEventActionCommandError(output, context);
|
|
793
|
-
}
|
|
794
|
-
const contents = (0, smithy_client_1.map)({
|
|
795
|
-
$metadata: deserializeMetadata(output),
|
|
796
|
-
});
|
|
797
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
798
|
-
return contents;
|
|
799
|
-
};
|
|
800
|
-
exports.de_DeleteEventActionCommand = de_DeleteEventActionCommand;
|
|
801
|
-
const de_DeleteEventActionCommandError = async (output, context) => {
|
|
802
|
-
const parsedOutput = {
|
|
803
|
-
...output,
|
|
804
|
-
body: await parseErrorBody(output.body, context),
|
|
805
|
-
};
|
|
806
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
807
|
-
switch (errorCode) {
|
|
808
|
-
case "InternalServerException":
|
|
809
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
810
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
811
|
-
case "ResourceNotFoundException":
|
|
812
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
813
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
814
|
-
case "ThrottlingException":
|
|
815
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
816
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
817
|
-
case "ValidationException":
|
|
818
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
819
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
820
|
-
default:
|
|
821
|
-
const parsedBody = parsedOutput.body;
|
|
822
|
-
return throwDefaultError({
|
|
823
|
-
output,
|
|
824
|
-
parsedBody,
|
|
825
|
-
errorCode,
|
|
826
|
-
});
|
|
827
|
-
}
|
|
828
|
-
};
|
|
829
|
-
const de_DeleteRevisionCommand = async (output, context) => {
|
|
830
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
831
|
-
return de_DeleteRevisionCommandError(output, context);
|
|
832
|
-
}
|
|
833
|
-
const contents = (0, smithy_client_1.map)({
|
|
834
|
-
$metadata: deserializeMetadata(output),
|
|
835
|
-
});
|
|
836
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
837
|
-
return contents;
|
|
838
|
-
};
|
|
839
|
-
exports.de_DeleteRevisionCommand = de_DeleteRevisionCommand;
|
|
840
|
-
const de_DeleteRevisionCommandError = async (output, context) => {
|
|
841
|
-
const parsedOutput = {
|
|
842
|
-
...output,
|
|
843
|
-
body: await parseErrorBody(output.body, context),
|
|
844
|
-
};
|
|
845
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
846
|
-
switch (errorCode) {
|
|
847
|
-
case "AccessDeniedException":
|
|
848
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
849
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
850
|
-
case "ConflictException":
|
|
851
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
852
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
853
|
-
case "InternalServerException":
|
|
854
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
855
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
856
|
-
case "ResourceNotFoundException":
|
|
857
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
858
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
859
|
-
case "ThrottlingException":
|
|
860
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
861
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
862
|
-
case "ValidationException":
|
|
863
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
864
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
865
|
-
default:
|
|
866
|
-
const parsedBody = parsedOutput.body;
|
|
867
|
-
return throwDefaultError({
|
|
868
|
-
output,
|
|
869
|
-
parsedBody,
|
|
870
|
-
errorCode,
|
|
871
|
-
});
|
|
872
|
-
}
|
|
873
|
-
};
|
|
874
|
-
const de_GetAssetCommand = async (output, context) => {
|
|
875
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
876
|
-
return de_GetAssetCommandError(output, context);
|
|
877
|
-
}
|
|
878
|
-
const contents = (0, smithy_client_1.map)({
|
|
879
|
-
$metadata: deserializeMetadata(output),
|
|
880
|
-
});
|
|
881
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
882
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
883
|
-
Arn: smithy_client_1.expectString,
|
|
884
|
-
AssetDetails: (_) => de_AssetDetails(_, context),
|
|
885
|
-
AssetType: smithy_client_1.expectString,
|
|
886
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
887
|
-
DataSetId: smithy_client_1.expectString,
|
|
888
|
-
Id: smithy_client_1.expectString,
|
|
889
|
-
Name: smithy_client_1.expectString,
|
|
890
|
-
RevisionId: smithy_client_1.expectString,
|
|
891
|
-
SourceId: smithy_client_1.expectString,
|
|
892
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
893
|
-
});
|
|
894
|
-
Object.assign(contents, doc);
|
|
895
|
-
return contents;
|
|
896
|
-
};
|
|
897
|
-
exports.de_GetAssetCommand = de_GetAssetCommand;
|
|
898
|
-
const de_GetAssetCommandError = async (output, context) => {
|
|
899
|
-
const parsedOutput = {
|
|
900
|
-
...output,
|
|
901
|
-
body: await parseErrorBody(output.body, context),
|
|
902
|
-
};
|
|
903
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
904
|
-
switch (errorCode) {
|
|
905
|
-
case "InternalServerException":
|
|
906
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
907
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
908
|
-
case "ResourceNotFoundException":
|
|
909
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
910
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
911
|
-
case "ThrottlingException":
|
|
912
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
913
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
914
|
-
case "ValidationException":
|
|
915
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
916
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
917
|
-
default:
|
|
918
|
-
const parsedBody = parsedOutput.body;
|
|
919
|
-
return throwDefaultError({
|
|
920
|
-
output,
|
|
921
|
-
parsedBody,
|
|
922
|
-
errorCode,
|
|
923
|
-
});
|
|
924
|
-
}
|
|
925
|
-
};
|
|
926
|
-
const de_GetDataSetCommand = async (output, context) => {
|
|
927
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
928
|
-
return de_GetDataSetCommandError(output, context);
|
|
929
|
-
}
|
|
930
|
-
const contents = (0, smithy_client_1.map)({
|
|
931
|
-
$metadata: deserializeMetadata(output),
|
|
932
|
-
});
|
|
933
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
934
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
935
|
-
Arn: smithy_client_1.expectString,
|
|
936
|
-
AssetType: smithy_client_1.expectString,
|
|
937
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
938
|
-
Description: smithy_client_1.expectString,
|
|
939
|
-
Id: smithy_client_1.expectString,
|
|
940
|
-
Name: smithy_client_1.expectString,
|
|
941
|
-
Origin: smithy_client_1.expectString,
|
|
942
|
-
OriginDetails: smithy_client_1._json,
|
|
943
|
-
SourceId: smithy_client_1.expectString,
|
|
944
|
-
Tags: smithy_client_1._json,
|
|
945
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
946
|
-
});
|
|
947
|
-
Object.assign(contents, doc);
|
|
948
|
-
return contents;
|
|
949
|
-
};
|
|
950
|
-
exports.de_GetDataSetCommand = de_GetDataSetCommand;
|
|
951
|
-
const de_GetDataSetCommandError = async (output, context) => {
|
|
952
|
-
const parsedOutput = {
|
|
953
|
-
...output,
|
|
954
|
-
body: await parseErrorBody(output.body, context),
|
|
955
|
-
};
|
|
956
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
957
|
-
switch (errorCode) {
|
|
958
|
-
case "InternalServerException":
|
|
959
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
960
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
961
|
-
case "ResourceNotFoundException":
|
|
962
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
963
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
964
|
-
case "ThrottlingException":
|
|
965
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
966
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
967
|
-
case "ValidationException":
|
|
968
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
969
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
970
|
-
default:
|
|
971
|
-
const parsedBody = parsedOutput.body;
|
|
972
|
-
return throwDefaultError({
|
|
973
|
-
output,
|
|
974
|
-
parsedBody,
|
|
975
|
-
errorCode,
|
|
976
|
-
});
|
|
977
|
-
}
|
|
978
|
-
};
|
|
979
|
-
const de_GetEventActionCommand = async (output, context) => {
|
|
980
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
981
|
-
return de_GetEventActionCommandError(output, context);
|
|
982
|
-
}
|
|
983
|
-
const contents = (0, smithy_client_1.map)({
|
|
984
|
-
$metadata: deserializeMetadata(output),
|
|
985
|
-
});
|
|
986
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
987
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
988
|
-
Action: smithy_client_1._json,
|
|
989
|
-
Arn: smithy_client_1.expectString,
|
|
990
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
991
|
-
Event: smithy_client_1._json,
|
|
992
|
-
Id: smithy_client_1.expectString,
|
|
993
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
994
|
-
});
|
|
995
|
-
Object.assign(contents, doc);
|
|
996
|
-
return contents;
|
|
997
|
-
};
|
|
998
|
-
exports.de_GetEventActionCommand = de_GetEventActionCommand;
|
|
999
|
-
const de_GetEventActionCommandError = async (output, context) => {
|
|
1000
|
-
const parsedOutput = {
|
|
1001
|
-
...output,
|
|
1002
|
-
body: await parseErrorBody(output.body, context),
|
|
1003
|
-
};
|
|
1004
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1005
|
-
switch (errorCode) {
|
|
1006
|
-
case "InternalServerException":
|
|
1007
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1008
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1009
|
-
case "ResourceNotFoundException":
|
|
1010
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1011
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1012
|
-
case "ThrottlingException":
|
|
1013
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1014
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1015
|
-
case "ValidationException":
|
|
1016
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1017
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1018
|
-
default:
|
|
1019
|
-
const parsedBody = parsedOutput.body;
|
|
1020
|
-
return throwDefaultError({
|
|
1021
|
-
output,
|
|
1022
|
-
parsedBody,
|
|
1023
|
-
errorCode,
|
|
1024
|
-
});
|
|
1025
|
-
}
|
|
1026
|
-
};
|
|
1027
|
-
const de_GetJobCommand = async (output, context) => {
|
|
1028
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1029
|
-
return de_GetJobCommandError(output, context);
|
|
1030
|
-
}
|
|
1031
|
-
const contents = (0, smithy_client_1.map)({
|
|
1032
|
-
$metadata: deserializeMetadata(output),
|
|
1033
|
-
});
|
|
1034
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1035
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1036
|
-
Arn: smithy_client_1.expectString,
|
|
1037
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1038
|
-
Details: (_) => de_ResponseDetails(_, context),
|
|
1039
|
-
Errors: (_) => de_ListOfJobError(_, context),
|
|
1040
|
-
Id: smithy_client_1.expectString,
|
|
1041
|
-
State: smithy_client_1.expectString,
|
|
1042
|
-
Type: smithy_client_1.expectString,
|
|
1043
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1044
|
-
});
|
|
1045
|
-
Object.assign(contents, doc);
|
|
1046
|
-
return contents;
|
|
1047
|
-
};
|
|
1048
|
-
exports.de_GetJobCommand = de_GetJobCommand;
|
|
1049
|
-
const de_GetJobCommandError = async (output, context) => {
|
|
1050
|
-
const parsedOutput = {
|
|
1051
|
-
...output,
|
|
1052
|
-
body: await parseErrorBody(output.body, context),
|
|
1053
|
-
};
|
|
1054
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1055
|
-
switch (errorCode) {
|
|
1056
|
-
case "InternalServerException":
|
|
1057
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1058
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1059
|
-
case "ResourceNotFoundException":
|
|
1060
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1061
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1062
|
-
case "ThrottlingException":
|
|
1063
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1064
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1065
|
-
case "ValidationException":
|
|
1066
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1067
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1068
|
-
default:
|
|
1069
|
-
const parsedBody = parsedOutput.body;
|
|
1070
|
-
return throwDefaultError({
|
|
1071
|
-
output,
|
|
1072
|
-
parsedBody,
|
|
1073
|
-
errorCode,
|
|
1074
|
-
});
|
|
1075
|
-
}
|
|
1076
|
-
};
|
|
1077
|
-
const de_GetRevisionCommand = async (output, context) => {
|
|
1078
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1079
|
-
return de_GetRevisionCommandError(output, context);
|
|
1080
|
-
}
|
|
1081
|
-
const contents = (0, smithy_client_1.map)({
|
|
1082
|
-
$metadata: deserializeMetadata(output),
|
|
1083
|
-
});
|
|
1084
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1085
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1086
|
-
Arn: smithy_client_1.expectString,
|
|
1087
|
-
Comment: smithy_client_1.expectString,
|
|
1088
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1089
|
-
DataSetId: smithy_client_1.expectString,
|
|
1090
|
-
Finalized: smithy_client_1.expectBoolean,
|
|
1091
|
-
Id: smithy_client_1.expectString,
|
|
1092
|
-
RevocationComment: smithy_client_1.expectString,
|
|
1093
|
-
Revoked: smithy_client_1.expectBoolean,
|
|
1094
|
-
RevokedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1095
|
-
SourceId: smithy_client_1.expectString,
|
|
1096
|
-
Tags: smithy_client_1._json,
|
|
1097
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1098
|
-
});
|
|
1099
|
-
Object.assign(contents, doc);
|
|
1100
|
-
return contents;
|
|
1101
|
-
};
|
|
1102
|
-
exports.de_GetRevisionCommand = de_GetRevisionCommand;
|
|
1103
|
-
const de_GetRevisionCommandError = async (output, context) => {
|
|
1104
|
-
const parsedOutput = {
|
|
1105
|
-
...output,
|
|
1106
|
-
body: await parseErrorBody(output.body, context),
|
|
1107
|
-
};
|
|
1108
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1109
|
-
switch (errorCode) {
|
|
1110
|
-
case "InternalServerException":
|
|
1111
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1112
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1113
|
-
case "ResourceNotFoundException":
|
|
1114
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1115
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1116
|
-
case "ThrottlingException":
|
|
1117
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1118
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1119
|
-
case "ValidationException":
|
|
1120
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1121
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1122
|
-
default:
|
|
1123
|
-
const parsedBody = parsedOutput.body;
|
|
1124
|
-
return throwDefaultError({
|
|
1125
|
-
output,
|
|
1126
|
-
parsedBody,
|
|
1127
|
-
errorCode,
|
|
1128
|
-
});
|
|
1129
|
-
}
|
|
1130
|
-
};
|
|
1131
|
-
const de_ListDataSetRevisionsCommand = async (output, context) => {
|
|
1132
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1133
|
-
return de_ListDataSetRevisionsCommandError(output, context);
|
|
1134
|
-
}
|
|
1135
|
-
const contents = (0, smithy_client_1.map)({
|
|
1136
|
-
$metadata: deserializeMetadata(output),
|
|
1137
|
-
});
|
|
1138
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1139
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1140
|
-
NextToken: smithy_client_1.expectString,
|
|
1141
|
-
Revisions: (_) => de_ListOfRevisionEntry(_, context),
|
|
1142
|
-
});
|
|
1143
|
-
Object.assign(contents, doc);
|
|
1144
|
-
return contents;
|
|
1145
|
-
};
|
|
1146
|
-
exports.de_ListDataSetRevisionsCommand = de_ListDataSetRevisionsCommand;
|
|
1147
|
-
const de_ListDataSetRevisionsCommandError = async (output, context) => {
|
|
1148
|
-
const parsedOutput = {
|
|
1149
|
-
...output,
|
|
1150
|
-
body: await parseErrorBody(output.body, context),
|
|
1151
|
-
};
|
|
1152
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1153
|
-
switch (errorCode) {
|
|
1154
|
-
case "InternalServerException":
|
|
1155
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1156
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1157
|
-
case "ResourceNotFoundException":
|
|
1158
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1159
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1160
|
-
case "ThrottlingException":
|
|
1161
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1162
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1163
|
-
case "ValidationException":
|
|
1164
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1165
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1166
|
-
default:
|
|
1167
|
-
const parsedBody = parsedOutput.body;
|
|
1168
|
-
return throwDefaultError({
|
|
1169
|
-
output,
|
|
1170
|
-
parsedBody,
|
|
1171
|
-
errorCode,
|
|
1172
|
-
});
|
|
1173
|
-
}
|
|
1174
|
-
};
|
|
1175
|
-
const de_ListDataSetsCommand = async (output, context) => {
|
|
1176
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1177
|
-
return de_ListDataSetsCommandError(output, context);
|
|
1178
|
-
}
|
|
1179
|
-
const contents = (0, smithy_client_1.map)({
|
|
1180
|
-
$metadata: deserializeMetadata(output),
|
|
1181
|
-
});
|
|
1182
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1183
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1184
|
-
DataSets: (_) => de_ListOfDataSetEntry(_, context),
|
|
1185
|
-
NextToken: smithy_client_1.expectString,
|
|
1186
|
-
});
|
|
1187
|
-
Object.assign(contents, doc);
|
|
1188
|
-
return contents;
|
|
1189
|
-
};
|
|
1190
|
-
exports.de_ListDataSetsCommand = de_ListDataSetsCommand;
|
|
1191
|
-
const de_ListDataSetsCommandError = async (output, context) => {
|
|
1192
|
-
const parsedOutput = {
|
|
1193
|
-
...output,
|
|
1194
|
-
body: await parseErrorBody(output.body, context),
|
|
1195
|
-
};
|
|
1196
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1197
|
-
switch (errorCode) {
|
|
1198
|
-
case "InternalServerException":
|
|
1199
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1200
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1201
|
-
case "ResourceNotFoundException":
|
|
1202
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1203
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1204
|
-
case "ThrottlingException":
|
|
1205
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1206
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1207
|
-
case "ValidationException":
|
|
1208
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1209
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1210
|
-
default:
|
|
1211
|
-
const parsedBody = parsedOutput.body;
|
|
1212
|
-
return throwDefaultError({
|
|
1213
|
-
output,
|
|
1214
|
-
parsedBody,
|
|
1215
|
-
errorCode,
|
|
1216
|
-
});
|
|
1217
|
-
}
|
|
1218
|
-
};
|
|
1219
|
-
const de_ListEventActionsCommand = async (output, context) => {
|
|
1220
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1221
|
-
return de_ListEventActionsCommandError(output, context);
|
|
1222
|
-
}
|
|
1223
|
-
const contents = (0, smithy_client_1.map)({
|
|
1224
|
-
$metadata: deserializeMetadata(output),
|
|
1225
|
-
});
|
|
1226
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1227
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1228
|
-
EventActions: (_) => de_ListOfEventActionEntry(_, context),
|
|
1229
|
-
NextToken: smithy_client_1.expectString,
|
|
1230
|
-
});
|
|
1231
|
-
Object.assign(contents, doc);
|
|
1232
|
-
return contents;
|
|
1233
|
-
};
|
|
1234
|
-
exports.de_ListEventActionsCommand = de_ListEventActionsCommand;
|
|
1235
|
-
const de_ListEventActionsCommandError = async (output, context) => {
|
|
1236
|
-
const parsedOutput = {
|
|
1237
|
-
...output,
|
|
1238
|
-
body: await parseErrorBody(output.body, context),
|
|
1239
|
-
};
|
|
1240
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1241
|
-
switch (errorCode) {
|
|
1242
|
-
case "InternalServerException":
|
|
1243
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1244
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1245
|
-
case "ResourceNotFoundException":
|
|
1246
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1247
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1248
|
-
case "ThrottlingException":
|
|
1249
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1250
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1251
|
-
case "ValidationException":
|
|
1252
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1253
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1254
|
-
default:
|
|
1255
|
-
const parsedBody = parsedOutput.body;
|
|
1256
|
-
return throwDefaultError({
|
|
1257
|
-
output,
|
|
1258
|
-
parsedBody,
|
|
1259
|
-
errorCode,
|
|
1260
|
-
});
|
|
1261
|
-
}
|
|
1262
|
-
};
|
|
1263
|
-
const de_ListJobsCommand = async (output, context) => {
|
|
1264
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1265
|
-
return de_ListJobsCommandError(output, context);
|
|
1266
|
-
}
|
|
1267
|
-
const contents = (0, smithy_client_1.map)({
|
|
1268
|
-
$metadata: deserializeMetadata(output),
|
|
1269
|
-
});
|
|
1270
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1271
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1272
|
-
Jobs: (_) => de_ListOfJobEntry(_, context),
|
|
1273
|
-
NextToken: smithy_client_1.expectString,
|
|
1274
|
-
});
|
|
1275
|
-
Object.assign(contents, doc);
|
|
1276
|
-
return contents;
|
|
1277
|
-
};
|
|
1278
|
-
exports.de_ListJobsCommand = de_ListJobsCommand;
|
|
1279
|
-
const de_ListJobsCommandError = async (output, context) => {
|
|
1280
|
-
const parsedOutput = {
|
|
1281
|
-
...output,
|
|
1282
|
-
body: await parseErrorBody(output.body, context),
|
|
1283
|
-
};
|
|
1284
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1285
|
-
switch (errorCode) {
|
|
1286
|
-
case "InternalServerException":
|
|
1287
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1288
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1289
|
-
case "ResourceNotFoundException":
|
|
1290
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1291
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1292
|
-
case "ThrottlingException":
|
|
1293
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1294
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1295
|
-
case "ValidationException":
|
|
1296
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1297
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1298
|
-
default:
|
|
1299
|
-
const parsedBody = parsedOutput.body;
|
|
1300
|
-
return throwDefaultError({
|
|
1301
|
-
output,
|
|
1302
|
-
parsedBody,
|
|
1303
|
-
errorCode,
|
|
1304
|
-
});
|
|
1305
|
-
}
|
|
1306
|
-
};
|
|
1307
|
-
const de_ListRevisionAssetsCommand = async (output, context) => {
|
|
1308
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1309
|
-
return de_ListRevisionAssetsCommandError(output, context);
|
|
1310
|
-
}
|
|
1311
|
-
const contents = (0, smithy_client_1.map)({
|
|
1312
|
-
$metadata: deserializeMetadata(output),
|
|
1313
|
-
});
|
|
1314
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1315
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1316
|
-
Assets: (_) => de_ListOfAssetEntry(_, context),
|
|
1317
|
-
NextToken: smithy_client_1.expectString,
|
|
1318
|
-
});
|
|
1319
|
-
Object.assign(contents, doc);
|
|
1320
|
-
return contents;
|
|
1321
|
-
};
|
|
1322
|
-
exports.de_ListRevisionAssetsCommand = de_ListRevisionAssetsCommand;
|
|
1323
|
-
const de_ListRevisionAssetsCommandError = async (output, context) => {
|
|
1324
|
-
const parsedOutput = {
|
|
1325
|
-
...output,
|
|
1326
|
-
body: await parseErrorBody(output.body, context),
|
|
1327
|
-
};
|
|
1328
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1329
|
-
switch (errorCode) {
|
|
1330
|
-
case "InternalServerException":
|
|
1331
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1332
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1333
|
-
case "ResourceNotFoundException":
|
|
1334
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1335
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1336
|
-
case "ThrottlingException":
|
|
1337
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1338
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1339
|
-
case "ValidationException":
|
|
1340
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1341
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1342
|
-
default:
|
|
1343
|
-
const parsedBody = parsedOutput.body;
|
|
1344
|
-
return throwDefaultError({
|
|
1345
|
-
output,
|
|
1346
|
-
parsedBody,
|
|
1347
|
-
errorCode,
|
|
1348
|
-
});
|
|
1349
|
-
}
|
|
1350
|
-
};
|
|
1351
|
-
const de_ListTagsForResourceCommand = async (output, context) => {
|
|
1352
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1353
|
-
return de_ListTagsForResourceCommandError(output, context);
|
|
1354
|
-
}
|
|
1355
|
-
const contents = (0, smithy_client_1.map)({
|
|
1356
|
-
$metadata: deserializeMetadata(output),
|
|
1357
|
-
});
|
|
1358
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1359
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1360
|
-
Tags: [, smithy_client_1._json, `tags`],
|
|
1361
|
-
});
|
|
1362
|
-
Object.assign(contents, doc);
|
|
1363
|
-
return contents;
|
|
1364
|
-
};
|
|
1365
|
-
exports.de_ListTagsForResourceCommand = de_ListTagsForResourceCommand;
|
|
1366
|
-
const de_ListTagsForResourceCommandError = async (output, context) => {
|
|
1367
|
-
const parsedOutput = {
|
|
1368
|
-
...output,
|
|
1369
|
-
body: await parseErrorBody(output.body, context),
|
|
1370
|
-
};
|
|
1371
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1372
|
-
const parsedBody = parsedOutput.body;
|
|
1373
|
-
return throwDefaultError({
|
|
1374
|
-
output,
|
|
1375
|
-
parsedBody,
|
|
1376
|
-
errorCode,
|
|
1377
|
-
});
|
|
1378
|
-
};
|
|
1379
|
-
const de_RevokeRevisionCommand = async (output, context) => {
|
|
1380
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1381
|
-
return de_RevokeRevisionCommandError(output, context);
|
|
1382
|
-
}
|
|
1383
|
-
const contents = (0, smithy_client_1.map)({
|
|
1384
|
-
$metadata: deserializeMetadata(output),
|
|
1385
|
-
});
|
|
1386
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1387
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1388
|
-
Arn: smithy_client_1.expectString,
|
|
1389
|
-
Comment: smithy_client_1.expectString,
|
|
1390
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1391
|
-
DataSetId: smithy_client_1.expectString,
|
|
1392
|
-
Finalized: smithy_client_1.expectBoolean,
|
|
1393
|
-
Id: smithy_client_1.expectString,
|
|
1394
|
-
RevocationComment: smithy_client_1.expectString,
|
|
1395
|
-
Revoked: smithy_client_1.expectBoolean,
|
|
1396
|
-
RevokedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1397
|
-
SourceId: smithy_client_1.expectString,
|
|
1398
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1399
|
-
});
|
|
1400
|
-
Object.assign(contents, doc);
|
|
1401
|
-
return contents;
|
|
1402
|
-
};
|
|
1403
|
-
exports.de_RevokeRevisionCommand = de_RevokeRevisionCommand;
|
|
1404
|
-
const de_RevokeRevisionCommandError = async (output, context) => {
|
|
1405
|
-
const parsedOutput = {
|
|
1406
|
-
...output,
|
|
1407
|
-
body: await parseErrorBody(output.body, context),
|
|
1408
|
-
};
|
|
1409
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1410
|
-
switch (errorCode) {
|
|
1411
|
-
case "AccessDeniedException":
|
|
1412
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1413
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1414
|
-
case "ConflictException":
|
|
1415
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
1416
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1417
|
-
case "InternalServerException":
|
|
1418
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1419
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1420
|
-
case "ResourceNotFoundException":
|
|
1421
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1422
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1423
|
-
case "ThrottlingException":
|
|
1424
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1425
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1426
|
-
case "ValidationException":
|
|
1427
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1428
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1429
|
-
default:
|
|
1430
|
-
const parsedBody = parsedOutput.body;
|
|
1431
|
-
return throwDefaultError({
|
|
1432
|
-
output,
|
|
1433
|
-
parsedBody,
|
|
1434
|
-
errorCode,
|
|
1435
|
-
});
|
|
1436
|
-
}
|
|
1437
|
-
};
|
|
1438
|
-
const de_SendApiAssetCommand = async (output, context) => {
|
|
1439
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1440
|
-
return de_SendApiAssetCommandError(output, context);
|
|
1441
|
-
}
|
|
1442
|
-
const contents = (0, smithy_client_1.map)({
|
|
1443
|
-
$metadata: deserializeMetadata(output),
|
|
1444
|
-
ResponseHeaders: [
|
|
1445
|
-
,
|
|
1446
|
-
Object.keys(output.headers)
|
|
1447
|
-
.filter((header) => header.startsWith(""))
|
|
1448
|
-
.reduce((acc, header) => {
|
|
1449
|
-
acc[header.substring(0)] = output.headers[header];
|
|
1450
|
-
return acc;
|
|
1451
|
-
}, {}),
|
|
1452
|
-
],
|
|
1453
|
-
});
|
|
1454
|
-
const data = await collectBodyString(output.body, context);
|
|
1455
|
-
contents.Body = (0, smithy_client_1.expectString)(data);
|
|
1456
|
-
return contents;
|
|
1457
|
-
};
|
|
1458
|
-
exports.de_SendApiAssetCommand = de_SendApiAssetCommand;
|
|
1459
|
-
const de_SendApiAssetCommandError = async (output, context) => {
|
|
1460
|
-
const parsedOutput = {
|
|
1461
|
-
...output,
|
|
1462
|
-
body: await parseErrorBody(output.body, context),
|
|
1463
|
-
};
|
|
1464
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1465
|
-
switch (errorCode) {
|
|
1466
|
-
case "AccessDeniedException":
|
|
1467
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1468
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1469
|
-
case "InternalServerException":
|
|
1470
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1471
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1472
|
-
case "ResourceNotFoundException":
|
|
1473
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1474
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1475
|
-
case "ThrottlingException":
|
|
1476
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1477
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1478
|
-
case "ValidationException":
|
|
1479
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1480
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1481
|
-
default:
|
|
1482
|
-
const parsedBody = parsedOutput.body;
|
|
1483
|
-
return throwDefaultError({
|
|
1484
|
-
output,
|
|
1485
|
-
parsedBody,
|
|
1486
|
-
errorCode,
|
|
1487
|
-
});
|
|
1488
|
-
}
|
|
1489
|
-
};
|
|
1490
|
-
const de_SendDataSetNotificationCommand = async (output, context) => {
|
|
1491
|
-
if (output.statusCode !== 202 && output.statusCode >= 300) {
|
|
1492
|
-
return de_SendDataSetNotificationCommandError(output, context);
|
|
1493
|
-
}
|
|
1494
|
-
const contents = (0, smithy_client_1.map)({
|
|
1495
|
-
$metadata: deserializeMetadata(output),
|
|
1496
|
-
});
|
|
1497
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1498
|
-
return contents;
|
|
1499
|
-
};
|
|
1500
|
-
exports.de_SendDataSetNotificationCommand = de_SendDataSetNotificationCommand;
|
|
1501
|
-
const de_SendDataSetNotificationCommandError = async (output, context) => {
|
|
1502
|
-
const parsedOutput = {
|
|
1503
|
-
...output,
|
|
1504
|
-
body: await parseErrorBody(output.body, context),
|
|
1505
|
-
};
|
|
1506
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1507
|
-
switch (errorCode) {
|
|
1508
|
-
case "AccessDeniedException":
|
|
1509
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1510
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1511
|
-
case "ConflictException":
|
|
1512
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
1513
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1514
|
-
case "InternalServerException":
|
|
1515
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1516
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1517
|
-
case "ResourceNotFoundException":
|
|
1518
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1519
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1520
|
-
case "ThrottlingException":
|
|
1521
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1522
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1523
|
-
case "ValidationException":
|
|
1524
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1525
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1526
|
-
default:
|
|
1527
|
-
const parsedBody = parsedOutput.body;
|
|
1528
|
-
return throwDefaultError({
|
|
1529
|
-
output,
|
|
1530
|
-
parsedBody,
|
|
1531
|
-
errorCode,
|
|
1532
|
-
});
|
|
1533
|
-
}
|
|
1534
|
-
};
|
|
1535
|
-
const de_StartJobCommand = async (output, context) => {
|
|
1536
|
-
if (output.statusCode !== 202 && output.statusCode >= 300) {
|
|
1537
|
-
return de_StartJobCommandError(output, context);
|
|
1538
|
-
}
|
|
1539
|
-
const contents = (0, smithy_client_1.map)({
|
|
1540
|
-
$metadata: deserializeMetadata(output),
|
|
1541
|
-
});
|
|
1542
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1543
|
-
return contents;
|
|
1544
|
-
};
|
|
1545
|
-
exports.de_StartJobCommand = de_StartJobCommand;
|
|
1546
|
-
const de_StartJobCommandError = async (output, context) => {
|
|
1547
|
-
const parsedOutput = {
|
|
1548
|
-
...output,
|
|
1549
|
-
body: await parseErrorBody(output.body, context),
|
|
1550
|
-
};
|
|
1551
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1552
|
-
switch (errorCode) {
|
|
1553
|
-
case "AccessDeniedException":
|
|
1554
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1555
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1556
|
-
case "ConflictException":
|
|
1557
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
1558
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1559
|
-
case "InternalServerException":
|
|
1560
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1561
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1562
|
-
case "ResourceNotFoundException":
|
|
1563
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1564
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1565
|
-
case "ThrottlingException":
|
|
1566
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1567
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1568
|
-
case "ValidationException":
|
|
1569
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1570
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1571
|
-
default:
|
|
1572
|
-
const parsedBody = parsedOutput.body;
|
|
1573
|
-
return throwDefaultError({
|
|
1574
|
-
output,
|
|
1575
|
-
parsedBody,
|
|
1576
|
-
errorCode,
|
|
1577
|
-
});
|
|
1578
|
-
}
|
|
1579
|
-
};
|
|
1580
|
-
const de_TagResourceCommand = async (output, context) => {
|
|
1581
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1582
|
-
return de_TagResourceCommandError(output, context);
|
|
1583
|
-
}
|
|
1584
|
-
const contents = (0, smithy_client_1.map)({
|
|
1585
|
-
$metadata: deserializeMetadata(output),
|
|
1586
|
-
});
|
|
1587
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1588
|
-
return contents;
|
|
1589
|
-
};
|
|
1590
|
-
exports.de_TagResourceCommand = de_TagResourceCommand;
|
|
1591
|
-
const de_TagResourceCommandError = async (output, context) => {
|
|
1592
|
-
const parsedOutput = {
|
|
1593
|
-
...output,
|
|
1594
|
-
body: await parseErrorBody(output.body, context),
|
|
1595
|
-
};
|
|
1596
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1597
|
-
const parsedBody = parsedOutput.body;
|
|
1598
|
-
return throwDefaultError({
|
|
1599
|
-
output,
|
|
1600
|
-
parsedBody,
|
|
1601
|
-
errorCode,
|
|
1602
|
-
});
|
|
1603
|
-
};
|
|
1604
|
-
const de_UntagResourceCommand = async (output, context) => {
|
|
1605
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1606
|
-
return de_UntagResourceCommandError(output, context);
|
|
1607
|
-
}
|
|
1608
|
-
const contents = (0, smithy_client_1.map)({
|
|
1609
|
-
$metadata: deserializeMetadata(output),
|
|
1610
|
-
});
|
|
1611
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1612
|
-
return contents;
|
|
1613
|
-
};
|
|
1614
|
-
exports.de_UntagResourceCommand = de_UntagResourceCommand;
|
|
1615
|
-
const de_UntagResourceCommandError = async (output, context) => {
|
|
1616
|
-
const parsedOutput = {
|
|
1617
|
-
...output,
|
|
1618
|
-
body: await parseErrorBody(output.body, context),
|
|
1619
|
-
};
|
|
1620
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1621
|
-
const parsedBody = parsedOutput.body;
|
|
1622
|
-
return throwDefaultError({
|
|
1623
|
-
output,
|
|
1624
|
-
parsedBody,
|
|
1625
|
-
errorCode,
|
|
1626
|
-
});
|
|
1627
|
-
};
|
|
1628
|
-
const de_UpdateAssetCommand = async (output, context) => {
|
|
1629
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1630
|
-
return de_UpdateAssetCommandError(output, context);
|
|
1631
|
-
}
|
|
1632
|
-
const contents = (0, smithy_client_1.map)({
|
|
1633
|
-
$metadata: deserializeMetadata(output),
|
|
1634
|
-
});
|
|
1635
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1636
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1637
|
-
Arn: smithy_client_1.expectString,
|
|
1638
|
-
AssetDetails: (_) => de_AssetDetails(_, context),
|
|
1639
|
-
AssetType: smithy_client_1.expectString,
|
|
1640
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1641
|
-
DataSetId: smithy_client_1.expectString,
|
|
1642
|
-
Id: smithy_client_1.expectString,
|
|
1643
|
-
Name: smithy_client_1.expectString,
|
|
1644
|
-
RevisionId: smithy_client_1.expectString,
|
|
1645
|
-
SourceId: smithy_client_1.expectString,
|
|
1646
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1647
|
-
});
|
|
1648
|
-
Object.assign(contents, doc);
|
|
1649
|
-
return contents;
|
|
1650
|
-
};
|
|
1651
|
-
exports.de_UpdateAssetCommand = de_UpdateAssetCommand;
|
|
1652
|
-
const de_UpdateAssetCommandError = async (output, context) => {
|
|
1653
|
-
const parsedOutput = {
|
|
1654
|
-
...output,
|
|
1655
|
-
body: await parseErrorBody(output.body, context),
|
|
1656
|
-
};
|
|
1657
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1658
|
-
switch (errorCode) {
|
|
1659
|
-
case "AccessDeniedException":
|
|
1660
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1661
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1662
|
-
case "ConflictException":
|
|
1663
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
1664
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1665
|
-
case "InternalServerException":
|
|
1666
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1667
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1668
|
-
case "ResourceNotFoundException":
|
|
1669
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1670
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1671
|
-
case "ThrottlingException":
|
|
1672
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1673
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1674
|
-
case "ValidationException":
|
|
1675
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1676
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1677
|
-
default:
|
|
1678
|
-
const parsedBody = parsedOutput.body;
|
|
1679
|
-
return throwDefaultError({
|
|
1680
|
-
output,
|
|
1681
|
-
parsedBody,
|
|
1682
|
-
errorCode,
|
|
1683
|
-
});
|
|
1684
|
-
}
|
|
1685
|
-
};
|
|
1686
|
-
const de_UpdateDataSetCommand = async (output, context) => {
|
|
1687
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1688
|
-
return de_UpdateDataSetCommandError(output, context);
|
|
1689
|
-
}
|
|
1690
|
-
const contents = (0, smithy_client_1.map)({
|
|
1691
|
-
$metadata: deserializeMetadata(output),
|
|
1692
|
-
});
|
|
1693
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1694
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1695
|
-
Arn: smithy_client_1.expectString,
|
|
1696
|
-
AssetType: smithy_client_1.expectString,
|
|
1697
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1698
|
-
Description: smithy_client_1.expectString,
|
|
1699
|
-
Id: smithy_client_1.expectString,
|
|
1700
|
-
Name: smithy_client_1.expectString,
|
|
1701
|
-
Origin: smithy_client_1.expectString,
|
|
1702
|
-
OriginDetails: smithy_client_1._json,
|
|
1703
|
-
SourceId: smithy_client_1.expectString,
|
|
1704
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1705
|
-
});
|
|
1706
|
-
Object.assign(contents, doc);
|
|
1707
|
-
return contents;
|
|
1708
|
-
};
|
|
1709
|
-
exports.de_UpdateDataSetCommand = de_UpdateDataSetCommand;
|
|
1710
|
-
const de_UpdateDataSetCommandError = async (output, context) => {
|
|
1711
|
-
const parsedOutput = {
|
|
1712
|
-
...output,
|
|
1713
|
-
body: await parseErrorBody(output.body, context),
|
|
1714
|
-
};
|
|
1715
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1716
|
-
switch (errorCode) {
|
|
1717
|
-
case "AccessDeniedException":
|
|
1718
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1719
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1720
|
-
case "InternalServerException":
|
|
1721
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1722
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1723
|
-
case "ResourceNotFoundException":
|
|
1724
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1725
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1726
|
-
case "ThrottlingException":
|
|
1727
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1728
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1729
|
-
case "ValidationException":
|
|
1730
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1731
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1732
|
-
default:
|
|
1733
|
-
const parsedBody = parsedOutput.body;
|
|
1734
|
-
return throwDefaultError({
|
|
1735
|
-
output,
|
|
1736
|
-
parsedBody,
|
|
1737
|
-
errorCode,
|
|
1738
|
-
});
|
|
1739
|
-
}
|
|
1740
|
-
};
|
|
1741
|
-
const de_UpdateEventActionCommand = async (output, context) => {
|
|
1742
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1743
|
-
return de_UpdateEventActionCommandError(output, context);
|
|
1744
|
-
}
|
|
1745
|
-
const contents = (0, smithy_client_1.map)({
|
|
1746
|
-
$metadata: deserializeMetadata(output),
|
|
1747
|
-
});
|
|
1748
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1749
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1750
|
-
Action: smithy_client_1._json,
|
|
1751
|
-
Arn: smithy_client_1.expectString,
|
|
1752
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1753
|
-
Event: smithy_client_1._json,
|
|
1754
|
-
Id: smithy_client_1.expectString,
|
|
1755
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1756
|
-
});
|
|
1757
|
-
Object.assign(contents, doc);
|
|
1758
|
-
return contents;
|
|
1759
|
-
};
|
|
1760
|
-
exports.de_UpdateEventActionCommand = de_UpdateEventActionCommand;
|
|
1761
|
-
const de_UpdateEventActionCommandError = async (output, context) => {
|
|
1762
|
-
const parsedOutput = {
|
|
1763
|
-
...output,
|
|
1764
|
-
body: await parseErrorBody(output.body, context),
|
|
1765
|
-
};
|
|
1766
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1767
|
-
switch (errorCode) {
|
|
1768
|
-
case "AccessDeniedException":
|
|
1769
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1770
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1771
|
-
case "InternalServerException":
|
|
1772
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1773
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1774
|
-
case "ResourceNotFoundException":
|
|
1775
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1776
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1777
|
-
case "ThrottlingException":
|
|
1778
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1779
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1780
|
-
case "ValidationException":
|
|
1781
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1782
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1783
|
-
default:
|
|
1784
|
-
const parsedBody = parsedOutput.body;
|
|
1785
|
-
return throwDefaultError({
|
|
1786
|
-
output,
|
|
1787
|
-
parsedBody,
|
|
1788
|
-
errorCode,
|
|
1789
|
-
});
|
|
1790
|
-
}
|
|
1791
|
-
};
|
|
1792
|
-
const de_UpdateRevisionCommand = async (output, context) => {
|
|
1793
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1794
|
-
return de_UpdateRevisionCommandError(output, context);
|
|
1795
|
-
}
|
|
1796
|
-
const contents = (0, smithy_client_1.map)({
|
|
1797
|
-
$metadata: deserializeMetadata(output),
|
|
1798
|
-
});
|
|
1799
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1800
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1801
|
-
Arn: smithy_client_1.expectString,
|
|
1802
|
-
Comment: smithy_client_1.expectString,
|
|
1803
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1804
|
-
DataSetId: smithy_client_1.expectString,
|
|
1805
|
-
Finalized: smithy_client_1.expectBoolean,
|
|
1806
|
-
Id: smithy_client_1.expectString,
|
|
1807
|
-
RevocationComment: smithy_client_1.expectString,
|
|
1808
|
-
Revoked: smithy_client_1.expectBoolean,
|
|
1809
|
-
RevokedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1810
|
-
SourceId: smithy_client_1.expectString,
|
|
1811
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1812
|
-
});
|
|
1813
|
-
Object.assign(contents, doc);
|
|
1814
|
-
return contents;
|
|
1815
|
-
};
|
|
1816
|
-
exports.de_UpdateRevisionCommand = de_UpdateRevisionCommand;
|
|
1817
|
-
const de_UpdateRevisionCommandError = async (output, context) => {
|
|
1818
|
-
const parsedOutput = {
|
|
1819
|
-
...output,
|
|
1820
|
-
body: await parseErrorBody(output.body, context),
|
|
1821
|
-
};
|
|
1822
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1823
|
-
switch (errorCode) {
|
|
1824
|
-
case "AccessDeniedException":
|
|
1825
|
-
case "com.amazonaws.dataexchange#AccessDeniedException":
|
|
1826
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1827
|
-
case "ConflictException":
|
|
1828
|
-
case "com.amazonaws.dataexchange#ConflictException":
|
|
1829
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1830
|
-
case "InternalServerException":
|
|
1831
|
-
case "com.amazonaws.dataexchange#InternalServerException":
|
|
1832
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1833
|
-
case "ResourceNotFoundException":
|
|
1834
|
-
case "com.amazonaws.dataexchange#ResourceNotFoundException":
|
|
1835
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1836
|
-
case "ThrottlingException":
|
|
1837
|
-
case "com.amazonaws.dataexchange#ThrottlingException":
|
|
1838
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1839
|
-
case "ValidationException":
|
|
1840
|
-
case "com.amazonaws.dataexchange#ValidationException":
|
|
1841
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1842
|
-
default:
|
|
1843
|
-
const parsedBody = parsedOutput.body;
|
|
1844
|
-
return throwDefaultError({
|
|
1845
|
-
output,
|
|
1846
|
-
parsedBody,
|
|
1847
|
-
errorCode,
|
|
1848
|
-
});
|
|
1849
|
-
}
|
|
1850
|
-
};
|
|
1851
|
-
const throwDefaultError = (0, smithy_client_1.withBaseException)(DataExchangeServiceException_1.DataExchangeServiceException);
|
|
1852
|
-
const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
1853
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1854
|
-
const data = parsedOutput.body;
|
|
1855
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1856
|
-
Message: smithy_client_1.expectString,
|
|
1857
|
-
});
|
|
1858
|
-
Object.assign(contents, doc);
|
|
1859
|
-
const exception = new models_0_1.AccessDeniedException({
|
|
1860
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1861
|
-
...contents,
|
|
1862
|
-
});
|
|
1863
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1864
|
-
};
|
|
1865
|
-
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
1866
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1867
|
-
const data = parsedOutput.body;
|
|
1868
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1869
|
-
Message: smithy_client_1.expectString,
|
|
1870
|
-
ResourceId: smithy_client_1.expectString,
|
|
1871
|
-
ResourceType: smithy_client_1.expectString,
|
|
1872
|
-
});
|
|
1873
|
-
Object.assign(contents, doc);
|
|
1874
|
-
const exception = new models_0_1.ConflictException({
|
|
1875
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1876
|
-
...contents,
|
|
1877
|
-
});
|
|
1878
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1879
|
-
};
|
|
1880
|
-
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
1881
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1882
|
-
const data = parsedOutput.body;
|
|
1883
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1884
|
-
Message: smithy_client_1.expectString,
|
|
1885
|
-
});
|
|
1886
|
-
Object.assign(contents, doc);
|
|
1887
|
-
const exception = new models_0_1.InternalServerException({
|
|
1888
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1889
|
-
...contents,
|
|
1890
|
-
});
|
|
1891
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1892
|
-
};
|
|
1893
|
-
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
1894
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1895
|
-
const data = parsedOutput.body;
|
|
1896
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1897
|
-
Message: smithy_client_1.expectString,
|
|
1898
|
-
ResourceId: smithy_client_1.expectString,
|
|
1899
|
-
ResourceType: smithy_client_1.expectString,
|
|
1900
|
-
});
|
|
1901
|
-
Object.assign(contents, doc);
|
|
1902
|
-
const exception = new models_0_1.ResourceNotFoundException({
|
|
1903
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1904
|
-
...contents,
|
|
1905
|
-
});
|
|
1906
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1907
|
-
};
|
|
1908
|
-
const de_ServiceLimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
1909
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1910
|
-
const data = parsedOutput.body;
|
|
1911
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1912
|
-
LimitName: smithy_client_1.expectString,
|
|
1913
|
-
LimitValue: smithy_client_1.limitedParseDouble,
|
|
1914
|
-
Message: smithy_client_1.expectString,
|
|
1915
|
-
});
|
|
1916
|
-
Object.assign(contents, doc);
|
|
1917
|
-
const exception = new models_0_1.ServiceLimitExceededException({
|
|
1918
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1919
|
-
...contents,
|
|
1920
|
-
});
|
|
1921
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1922
|
-
};
|
|
1923
|
-
const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
|
|
1924
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1925
|
-
const data = parsedOutput.body;
|
|
1926
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1927
|
-
Message: smithy_client_1.expectString,
|
|
1928
|
-
});
|
|
1929
|
-
Object.assign(contents, doc);
|
|
1930
|
-
const exception = new models_0_1.ThrottlingException({
|
|
1931
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1932
|
-
...contents,
|
|
1933
|
-
});
|
|
1934
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1935
|
-
};
|
|
1936
|
-
const de_ValidationExceptionRes = async (parsedOutput, context) => {
|
|
1937
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1938
|
-
const data = parsedOutput.body;
|
|
1939
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1940
|
-
ExceptionCause: smithy_client_1.expectString,
|
|
1941
|
-
Message: smithy_client_1.expectString,
|
|
1942
|
-
});
|
|
1943
|
-
Object.assign(contents, doc);
|
|
1944
|
-
const exception = new models_0_1.ValidationException({
|
|
1945
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1946
|
-
...contents,
|
|
1947
|
-
});
|
|
1948
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1949
|
-
};
|
|
1950
|
-
const se_DataUpdateRequestDetails = (input, context) => {
|
|
1951
|
-
return (0, smithy_client_1.take)(input, {
|
|
1952
|
-
DataUpdatedAt: (_) => _.toISOString().split(".")[0] + "Z",
|
|
1953
|
-
});
|
|
1954
|
-
};
|
|
1955
|
-
const se_DeprecationRequestDetails = (input, context) => {
|
|
1956
|
-
return (0, smithy_client_1.take)(input, {
|
|
1957
|
-
DeprecationAt: (_) => _.toISOString().split(".")[0] + "Z",
|
|
1958
|
-
});
|
|
1959
|
-
};
|
|
1960
|
-
const se_NotificationDetails = (input, context) => {
|
|
1961
|
-
return (0, smithy_client_1.take)(input, {
|
|
1962
|
-
DataUpdate: (_) => se_DataUpdateRequestDetails(_, context),
|
|
1963
|
-
Deprecation: (_) => se_DeprecationRequestDetails(_, context),
|
|
1964
|
-
SchemaChange: (_) => se_SchemaChangeRequestDetails(_, context),
|
|
1965
|
-
});
|
|
1966
|
-
};
|
|
1967
|
-
const se_SchemaChangeRequestDetails = (input, context) => {
|
|
1968
|
-
return (0, smithy_client_1.take)(input, {
|
|
1969
|
-
Changes: smithy_client_1._json,
|
|
1970
|
-
SchemaChangeAt: (_) => _.toISOString().split(".")[0] + "Z",
|
|
1971
|
-
});
|
|
1972
|
-
};
|
|
1973
|
-
const de_ApiGatewayApiAsset = (output, context) => {
|
|
1974
|
-
return (0, smithy_client_1.take)(output, {
|
|
1975
|
-
ApiDescription: smithy_client_1.expectString,
|
|
1976
|
-
ApiEndpoint: smithy_client_1.expectString,
|
|
1977
|
-
ApiId: smithy_client_1.expectString,
|
|
1978
|
-
ApiKey: smithy_client_1.expectString,
|
|
1979
|
-
ApiName: smithy_client_1.expectString,
|
|
1980
|
-
ApiSpecificationDownloadUrl: smithy_client_1.expectString,
|
|
1981
|
-
ApiSpecificationDownloadUrlExpiresAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1982
|
-
ProtocolType: smithy_client_1.expectString,
|
|
1983
|
-
Stage: smithy_client_1.expectString,
|
|
1984
|
-
});
|
|
1985
|
-
};
|
|
1986
|
-
const de_AssetDetails = (output, context) => {
|
|
1987
|
-
return (0, smithy_client_1.take)(output, {
|
|
1988
|
-
ApiGatewayApiAsset: (_) => de_ApiGatewayApiAsset(_, context),
|
|
1989
|
-
LakeFormationDataPermissionAsset: smithy_client_1._json,
|
|
1990
|
-
RedshiftDataShareAsset: smithy_client_1._json,
|
|
1991
|
-
S3DataAccessAsset: smithy_client_1._json,
|
|
1992
|
-
S3SnapshotAsset: (_) => de_S3SnapshotAsset(_, context),
|
|
1993
|
-
});
|
|
1994
|
-
};
|
|
1995
|
-
const de_AssetEntry = (output, context) => {
|
|
1996
|
-
return (0, smithy_client_1.take)(output, {
|
|
1997
|
-
Arn: smithy_client_1.expectString,
|
|
1998
|
-
AssetDetails: (_) => de_AssetDetails(_, context),
|
|
1999
|
-
AssetType: smithy_client_1.expectString,
|
|
2000
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2001
|
-
DataSetId: smithy_client_1.expectString,
|
|
2002
|
-
Id: smithy_client_1.expectString,
|
|
2003
|
-
Name: smithy_client_1.expectString,
|
|
2004
|
-
RevisionId: smithy_client_1.expectString,
|
|
2005
|
-
SourceId: smithy_client_1.expectString,
|
|
2006
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2007
|
-
});
|
|
2008
|
-
};
|
|
2009
|
-
const de_DataSetEntry = (output, context) => {
|
|
2010
|
-
return (0, smithy_client_1.take)(output, {
|
|
2011
|
-
Arn: smithy_client_1.expectString,
|
|
2012
|
-
AssetType: smithy_client_1.expectString,
|
|
2013
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2014
|
-
Description: smithy_client_1.expectString,
|
|
2015
|
-
Id: smithy_client_1.expectString,
|
|
2016
|
-
Name: smithy_client_1.expectString,
|
|
2017
|
-
Origin: smithy_client_1.expectString,
|
|
2018
|
-
OriginDetails: smithy_client_1._json,
|
|
2019
|
-
SourceId: smithy_client_1.expectString,
|
|
2020
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2021
|
-
});
|
|
2022
|
-
};
|
|
2023
|
-
const de_EventActionEntry = (output, context) => {
|
|
2024
|
-
return (0, smithy_client_1.take)(output, {
|
|
2025
|
-
Action: smithy_client_1._json,
|
|
2026
|
-
Arn: smithy_client_1.expectString,
|
|
2027
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2028
|
-
Event: smithy_client_1._json,
|
|
2029
|
-
Id: smithy_client_1.expectString,
|
|
2030
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2031
|
-
});
|
|
2032
|
-
};
|
|
2033
|
-
const de_ExportAssetToSignedUrlResponseDetails = (output, context) => {
|
|
2034
|
-
return (0, smithy_client_1.take)(output, {
|
|
2035
|
-
AssetId: smithy_client_1.expectString,
|
|
2036
|
-
DataSetId: smithy_client_1.expectString,
|
|
2037
|
-
RevisionId: smithy_client_1.expectString,
|
|
2038
|
-
SignedUrl: smithy_client_1.expectString,
|
|
2039
|
-
SignedUrlExpiresAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2040
|
-
});
|
|
2041
|
-
};
|
|
2042
|
-
const de_ImportAssetFromApiGatewayApiResponseDetails = (output, context) => {
|
|
2043
|
-
return (0, smithy_client_1.take)(output, {
|
|
2044
|
-
ApiDescription: smithy_client_1.expectString,
|
|
2045
|
-
ApiId: smithy_client_1.expectString,
|
|
2046
|
-
ApiKey: smithy_client_1.expectString,
|
|
2047
|
-
ApiName: smithy_client_1.expectString,
|
|
2048
|
-
ApiSpecificationMd5Hash: smithy_client_1.expectString,
|
|
2049
|
-
ApiSpecificationUploadUrl: smithy_client_1.expectString,
|
|
2050
|
-
ApiSpecificationUploadUrlExpiresAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2051
|
-
DataSetId: smithy_client_1.expectString,
|
|
2052
|
-
ProtocolType: smithy_client_1.expectString,
|
|
2053
|
-
RevisionId: smithy_client_1.expectString,
|
|
2054
|
-
Stage: smithy_client_1.expectString,
|
|
2055
|
-
});
|
|
2056
|
-
};
|
|
2057
|
-
const de_ImportAssetFromSignedUrlResponseDetails = (output, context) => {
|
|
2058
|
-
return (0, smithy_client_1.take)(output, {
|
|
2059
|
-
AssetName: smithy_client_1.expectString,
|
|
2060
|
-
DataSetId: smithy_client_1.expectString,
|
|
2061
|
-
Md5Hash: smithy_client_1.expectString,
|
|
2062
|
-
RevisionId: smithy_client_1.expectString,
|
|
2063
|
-
SignedUrl: smithy_client_1.expectString,
|
|
2064
|
-
SignedUrlExpiresAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2065
|
-
});
|
|
2066
|
-
};
|
|
2067
|
-
const de_JobEntry = (output, context) => {
|
|
2068
|
-
return (0, smithy_client_1.take)(output, {
|
|
2069
|
-
Arn: smithy_client_1.expectString,
|
|
2070
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2071
|
-
Details: (_) => de_ResponseDetails(_, context),
|
|
2072
|
-
Errors: (_) => de_ListOfJobError(_, context),
|
|
2073
|
-
Id: smithy_client_1.expectString,
|
|
2074
|
-
State: smithy_client_1.expectString,
|
|
2075
|
-
Type: smithy_client_1.expectString,
|
|
2076
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2077
|
-
});
|
|
2078
|
-
};
|
|
2079
|
-
const de_JobError = (output, context) => {
|
|
2080
|
-
return (0, smithy_client_1.take)(output, {
|
|
2081
|
-
Code: smithy_client_1.expectString,
|
|
2082
|
-
Details: smithy_client_1._json,
|
|
2083
|
-
LimitName: smithy_client_1.expectString,
|
|
2084
|
-
LimitValue: smithy_client_1.limitedParseDouble,
|
|
2085
|
-
Message: smithy_client_1.expectString,
|
|
2086
|
-
ResourceId: smithy_client_1.expectString,
|
|
2087
|
-
ResourceType: smithy_client_1.expectString,
|
|
2088
|
-
});
|
|
2089
|
-
};
|
|
2090
|
-
const de_ListOfAssetEntry = (output, context) => {
|
|
2091
|
-
const retVal = (output || [])
|
|
2092
|
-
.filter((e) => e != null)
|
|
2093
|
-
.map((entry) => {
|
|
2094
|
-
return de_AssetEntry(entry, context);
|
|
2095
|
-
});
|
|
2096
|
-
return retVal;
|
|
2097
|
-
};
|
|
2098
|
-
const de_ListOfDataSetEntry = (output, context) => {
|
|
2099
|
-
const retVal = (output || [])
|
|
2100
|
-
.filter((e) => e != null)
|
|
2101
|
-
.map((entry) => {
|
|
2102
|
-
return de_DataSetEntry(entry, context);
|
|
2103
|
-
});
|
|
2104
|
-
return retVal;
|
|
2105
|
-
};
|
|
2106
|
-
const de_ListOfEventActionEntry = (output, context) => {
|
|
2107
|
-
const retVal = (output || [])
|
|
2108
|
-
.filter((e) => e != null)
|
|
2109
|
-
.map((entry) => {
|
|
2110
|
-
return de_EventActionEntry(entry, context);
|
|
2111
|
-
});
|
|
2112
|
-
return retVal;
|
|
2113
|
-
};
|
|
2114
|
-
const de_ListOfJobEntry = (output, context) => {
|
|
2115
|
-
const retVal = (output || [])
|
|
2116
|
-
.filter((e) => e != null)
|
|
2117
|
-
.map((entry) => {
|
|
2118
|
-
return de_JobEntry(entry, context);
|
|
2119
|
-
});
|
|
2120
|
-
return retVal;
|
|
2121
|
-
};
|
|
2122
|
-
const de_ListOfJobError = (output, context) => {
|
|
2123
|
-
const retVal = (output || [])
|
|
2124
|
-
.filter((e) => e != null)
|
|
2125
|
-
.map((entry) => {
|
|
2126
|
-
return de_JobError(entry, context);
|
|
2127
|
-
});
|
|
2128
|
-
return retVal;
|
|
2129
|
-
};
|
|
2130
|
-
const de_ListOfRevisionEntry = (output, context) => {
|
|
2131
|
-
const retVal = (output || [])
|
|
2132
|
-
.filter((e) => e != null)
|
|
2133
|
-
.map((entry) => {
|
|
2134
|
-
return de_RevisionEntry(entry, context);
|
|
2135
|
-
});
|
|
2136
|
-
return retVal;
|
|
2137
|
-
};
|
|
2138
|
-
const de_ResponseDetails = (output, context) => {
|
|
2139
|
-
return (0, smithy_client_1.take)(output, {
|
|
2140
|
-
CreateS3DataAccessFromS3Bucket: smithy_client_1._json,
|
|
2141
|
-
ExportAssetToSignedUrl: (_) => de_ExportAssetToSignedUrlResponseDetails(_, context),
|
|
2142
|
-
ExportAssetsToS3: smithy_client_1._json,
|
|
2143
|
-
ExportRevisionsToS3: smithy_client_1._json,
|
|
2144
|
-
ImportAssetFromApiGatewayApi: (_) => de_ImportAssetFromApiGatewayApiResponseDetails(_, context),
|
|
2145
|
-
ImportAssetFromSignedUrl: (_) => de_ImportAssetFromSignedUrlResponseDetails(_, context),
|
|
2146
|
-
ImportAssetsFromLakeFormationTagPolicy: smithy_client_1._json,
|
|
2147
|
-
ImportAssetsFromRedshiftDataShares: smithy_client_1._json,
|
|
2148
|
-
ImportAssetsFromS3: smithy_client_1._json,
|
|
2149
|
-
});
|
|
2150
|
-
};
|
|
2151
|
-
const de_RevisionEntry = (output, context) => {
|
|
2152
|
-
return (0, smithy_client_1.take)(output, {
|
|
2153
|
-
Arn: smithy_client_1.expectString,
|
|
2154
|
-
Comment: smithy_client_1.expectString,
|
|
2155
|
-
CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2156
|
-
DataSetId: smithy_client_1.expectString,
|
|
2157
|
-
Finalized: smithy_client_1.expectBoolean,
|
|
2158
|
-
Id: smithy_client_1.expectString,
|
|
2159
|
-
RevocationComment: smithy_client_1.expectString,
|
|
2160
|
-
Revoked: smithy_client_1.expectBoolean,
|
|
2161
|
-
RevokedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2162
|
-
SourceId: smithy_client_1.expectString,
|
|
2163
|
-
UpdatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
2164
|
-
});
|
|
2165
|
-
};
|
|
2166
|
-
const de_S3SnapshotAsset = (output, context) => {
|
|
2167
|
-
return (0, smithy_client_1.take)(output, {
|
|
2168
|
-
Size: smithy_client_1.limitedParseDouble,
|
|
2169
|
-
});
|
|
2170
|
-
};
|
|
2171
|
-
const deserializeMetadata = (output) => ({
|
|
2172
|
-
httpStatusCode: output.statusCode,
|
|
2173
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
2174
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
2175
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
2176
|
-
});
|
|
2177
|
-
const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
2178
|
-
const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
2179
|
-
value !== null &&
|
|
2180
|
-
value !== "" &&
|
|
2181
|
-
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
2182
|
-
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
2183
|
-
const _AI = "AssetId";
|
|
2184
|
-
const _DSI = "DataSetId";
|
|
2185
|
-
const _ESI = "EventSourceId";
|
|
2186
|
-
const _M = "Method";
|
|
2187
|
-
const _MR = "MaxResults";
|
|
2188
|
-
const _NT = "NextToken";
|
|
2189
|
-
const _O = "Origin";
|
|
2190
|
-
const _P = "Path";
|
|
2191
|
-
const _RI = "RevisionId";
|
|
2192
|
-
const _TK = "TagKeys";
|
|
2193
|
-
const _dSI = "dataSetId";
|
|
2194
|
-
const _eSI = "eventSourceId";
|
|
2195
|
-
const _mR = "maxResults";
|
|
2196
|
-
const _nT = "nextToken";
|
|
2197
|
-
const _o = "origin";
|
|
2198
|
-
const _rI = "revisionId";
|
|
2199
|
-
const _tK = "tagKeys";
|
|
2200
|
-
const _xadai = "x-amzn-dataexchange-asset-id";
|
|
2201
|
-
const _xaddsi = "x-amzn-dataexchange-data-set-id";
|
|
2202
|
-
const _xadhm = "x-amzn-dataexchange-http-method";
|
|
2203
|
-
const _xadp = "x-amzn-dataexchange-path";
|
|
2204
|
-
const _xadri = "x-amzn-dataexchange-revision-id";
|
|
2205
|
-
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
2206
|
-
if (encoded.length) {
|
|
2207
|
-
return JSON.parse(encoded);
|
|
2208
|
-
}
|
|
2209
|
-
return {};
|
|
2210
|
-
});
|
|
2211
|
-
const parseErrorBody = async (errorBody, context) => {
|
|
2212
|
-
const value = await parseBody(errorBody, context);
|
|
2213
|
-
value.message = value.message ?? value.Message;
|
|
2214
|
-
return value;
|
|
2215
|
-
};
|
|
2216
|
-
const loadRestJsonErrorCode = (output, data) => {
|
|
2217
|
-
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
2218
|
-
const sanitizeErrorCode = (rawValue) => {
|
|
2219
|
-
let cleanValue = rawValue;
|
|
2220
|
-
if (typeof cleanValue === "number") {
|
|
2221
|
-
cleanValue = cleanValue.toString();
|
|
2222
|
-
}
|
|
2223
|
-
if (cleanValue.indexOf(",") >= 0) {
|
|
2224
|
-
cleanValue = cleanValue.split(",")[0];
|
|
2225
|
-
}
|
|
2226
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
2227
|
-
cleanValue = cleanValue.split(":")[0];
|
|
2228
|
-
}
|
|
2229
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
2230
|
-
cleanValue = cleanValue.split("#")[1];
|
|
2231
|
-
}
|
|
2232
|
-
return cleanValue;
|
|
2233
|
-
};
|
|
2234
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
2235
|
-
if (headerKey !== undefined) {
|
|
2236
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
2237
|
-
}
|
|
2238
|
-
if (data.code !== undefined) {
|
|
2239
|
-
return sanitizeErrorCode(data.code);
|
|
2240
|
-
}
|
|
2241
|
-
if (data["__type"] !== undefined) {
|
|
2242
|
-
return sanitizeErrorCode(data["__type"]);
|
|
2243
|
-
}
|
|
2244
|
-
};
|
|
1
|
+
module.exports = require("../index.js");
|