@aws-sdk/client-dataexchange 3.474.0 → 3.477.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/protocols/Aws_restJson1.js +199 -400
- package/dist-es/protocols/Aws_restJson1.js +201 -402
- package/package.json +5 -4
|
@@ -1,30 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { requestBuilder as rb } from "@smithy/core";
|
|
2
|
+
import { isValidHostname as __isValidHostname, } from "@smithy/protocol-http";
|
|
3
|
+
import { _json, collectBody, convertMap, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, limitedParseDouble as __limitedParseDouble, map, parseRfc3339DateTimeWithOffset as __parseRfc3339DateTimeWithOffset, take, withBaseException, } from "@smithy/smithy-client";
|
|
3
4
|
import { v4 as generateIdempotencyToken } from "uuid";
|
|
4
5
|
import { DataExchangeServiceException as __BaseException } from "../models/DataExchangeServiceException";
|
|
5
6
|
import { AccessDeniedException, ConflictException, InternalServerException, ResourceNotFoundException, ServiceLimitExceededException, ThrottlingException, ValidationException, } from "../models/models_0";
|
|
6
7
|
export const se_CancelJobCommand = async (input, context) => {
|
|
7
|
-
const
|
|
8
|
+
const b = rb(input, context);
|
|
8
9
|
const headers = {};
|
|
9
|
-
|
|
10
|
-
|
|
10
|
+
b.bp("/v1/jobs/{JobId}");
|
|
11
|
+
b.p("JobId", () => input.JobId, "{JobId}", false);
|
|
11
12
|
let body;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
hostname,
|
|
15
|
-
port,
|
|
16
|
-
method: "DELETE",
|
|
17
|
-
headers,
|
|
18
|
-
path: resolvedPath,
|
|
19
|
-
body,
|
|
20
|
-
});
|
|
13
|
+
b.m("DELETE").h(headers).b(body);
|
|
14
|
+
return b.build();
|
|
21
15
|
};
|
|
22
16
|
export const se_CreateDataSetCommand = async (input, context) => {
|
|
23
|
-
const
|
|
17
|
+
const b = rb(input, context);
|
|
24
18
|
const headers = {
|
|
25
19
|
"content-type": "application/json",
|
|
26
20
|
};
|
|
27
|
-
|
|
21
|
+
b.bp("/v1/data-sets");
|
|
28
22
|
let body;
|
|
29
23
|
body = JSON.stringify(take(input, {
|
|
30
24
|
AssetType: [],
|
|
@@ -32,397 +26,246 @@ export const se_CreateDataSetCommand = async (input, context) => {
|
|
|
32
26
|
Name: [],
|
|
33
27
|
Tags: (_) => _json(_),
|
|
34
28
|
}));
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
hostname,
|
|
38
|
-
port,
|
|
39
|
-
method: "POST",
|
|
40
|
-
headers,
|
|
41
|
-
path: resolvedPath,
|
|
42
|
-
body,
|
|
43
|
-
});
|
|
29
|
+
b.m("POST").h(headers).b(body);
|
|
30
|
+
return b.build();
|
|
44
31
|
};
|
|
45
32
|
export const se_CreateEventActionCommand = async (input, context) => {
|
|
46
|
-
const
|
|
33
|
+
const b = rb(input, context);
|
|
47
34
|
const headers = {
|
|
48
35
|
"content-type": "application/json",
|
|
49
36
|
};
|
|
50
|
-
|
|
37
|
+
b.bp("/v1/event-actions");
|
|
51
38
|
let body;
|
|
52
39
|
body = JSON.stringify(take(input, {
|
|
53
40
|
Action: (_) => _json(_),
|
|
54
41
|
Event: (_) => _json(_),
|
|
55
42
|
}));
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
hostname,
|
|
59
|
-
port,
|
|
60
|
-
method: "POST",
|
|
61
|
-
headers,
|
|
62
|
-
path: resolvedPath,
|
|
63
|
-
body,
|
|
64
|
-
});
|
|
43
|
+
b.m("POST").h(headers).b(body);
|
|
44
|
+
return b.build();
|
|
65
45
|
};
|
|
66
46
|
export const se_CreateJobCommand = async (input, context) => {
|
|
67
|
-
const
|
|
47
|
+
const b = rb(input, context);
|
|
68
48
|
const headers = {
|
|
69
49
|
"content-type": "application/json",
|
|
70
50
|
};
|
|
71
|
-
|
|
51
|
+
b.bp("/v1/jobs");
|
|
72
52
|
let body;
|
|
73
53
|
body = JSON.stringify(take(input, {
|
|
74
54
|
Details: (_) => _json(_),
|
|
75
55
|
Type: [],
|
|
76
56
|
}));
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
hostname,
|
|
80
|
-
port,
|
|
81
|
-
method: "POST",
|
|
82
|
-
headers,
|
|
83
|
-
path: resolvedPath,
|
|
84
|
-
body,
|
|
85
|
-
});
|
|
57
|
+
b.m("POST").h(headers).b(body);
|
|
58
|
+
return b.build();
|
|
86
59
|
};
|
|
87
60
|
export const se_CreateRevisionCommand = async (input, context) => {
|
|
88
|
-
const
|
|
61
|
+
const b = rb(input, context);
|
|
89
62
|
const headers = {
|
|
90
63
|
"content-type": "application/json",
|
|
91
64
|
};
|
|
92
|
-
|
|
93
|
-
|
|
65
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions");
|
|
66
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
94
67
|
let body;
|
|
95
68
|
body = JSON.stringify(take(input, {
|
|
96
69
|
Comment: [],
|
|
97
70
|
Tags: (_) => _json(_),
|
|
98
71
|
}));
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
hostname,
|
|
102
|
-
port,
|
|
103
|
-
method: "POST",
|
|
104
|
-
headers,
|
|
105
|
-
path: resolvedPath,
|
|
106
|
-
body,
|
|
107
|
-
});
|
|
72
|
+
b.m("POST").h(headers).b(body);
|
|
73
|
+
return b.build();
|
|
108
74
|
};
|
|
109
75
|
export const se_DeleteAssetCommand = async (input, context) => {
|
|
110
|
-
const
|
|
76
|
+
const b = rb(input, context);
|
|
111
77
|
const headers = {};
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
78
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}");
|
|
79
|
+
b.p("AssetId", () => input.AssetId, "{AssetId}", false);
|
|
80
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
81
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
117
82
|
let body;
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
hostname,
|
|
121
|
-
port,
|
|
122
|
-
method: "DELETE",
|
|
123
|
-
headers,
|
|
124
|
-
path: resolvedPath,
|
|
125
|
-
body,
|
|
126
|
-
});
|
|
83
|
+
b.m("DELETE").h(headers).b(body);
|
|
84
|
+
return b.build();
|
|
127
85
|
};
|
|
128
86
|
export const se_DeleteDataSetCommand = async (input, context) => {
|
|
129
|
-
const
|
|
87
|
+
const b = rb(input, context);
|
|
130
88
|
const headers = {};
|
|
131
|
-
|
|
132
|
-
|
|
89
|
+
b.bp("/v1/data-sets/{DataSetId}");
|
|
90
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
133
91
|
let body;
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
hostname,
|
|
137
|
-
port,
|
|
138
|
-
method: "DELETE",
|
|
139
|
-
headers,
|
|
140
|
-
path: resolvedPath,
|
|
141
|
-
body,
|
|
142
|
-
});
|
|
92
|
+
b.m("DELETE").h(headers).b(body);
|
|
93
|
+
return b.build();
|
|
143
94
|
};
|
|
144
95
|
export const se_DeleteEventActionCommand = async (input, context) => {
|
|
145
|
-
const
|
|
96
|
+
const b = rb(input, context);
|
|
146
97
|
const headers = {};
|
|
147
|
-
|
|
148
|
-
|
|
98
|
+
b.bp("/v1/event-actions/{EventActionId}");
|
|
99
|
+
b.p("EventActionId", () => input.EventActionId, "{EventActionId}", false);
|
|
149
100
|
let body;
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
hostname,
|
|
153
|
-
port,
|
|
154
|
-
method: "DELETE",
|
|
155
|
-
headers,
|
|
156
|
-
path: resolvedPath,
|
|
157
|
-
body,
|
|
158
|
-
});
|
|
101
|
+
b.m("DELETE").h(headers).b(body);
|
|
102
|
+
return b.build();
|
|
159
103
|
};
|
|
160
104
|
export const se_DeleteRevisionCommand = async (input, context) => {
|
|
161
|
-
const
|
|
105
|
+
const b = rb(input, context);
|
|
162
106
|
const headers = {};
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
107
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}");
|
|
108
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
109
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
167
110
|
let body;
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
hostname,
|
|
171
|
-
port,
|
|
172
|
-
method: "DELETE",
|
|
173
|
-
headers,
|
|
174
|
-
path: resolvedPath,
|
|
175
|
-
body,
|
|
176
|
-
});
|
|
111
|
+
b.m("DELETE").h(headers).b(body);
|
|
112
|
+
return b.build();
|
|
177
113
|
};
|
|
178
114
|
export const se_GetAssetCommand = async (input, context) => {
|
|
179
|
-
const
|
|
115
|
+
const b = rb(input, context);
|
|
180
116
|
const headers = {};
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
117
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}");
|
|
118
|
+
b.p("AssetId", () => input.AssetId, "{AssetId}", false);
|
|
119
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
120
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
186
121
|
let body;
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
hostname,
|
|
190
|
-
port,
|
|
191
|
-
method: "GET",
|
|
192
|
-
headers,
|
|
193
|
-
path: resolvedPath,
|
|
194
|
-
body,
|
|
195
|
-
});
|
|
122
|
+
b.m("GET").h(headers).b(body);
|
|
123
|
+
return b.build();
|
|
196
124
|
};
|
|
197
125
|
export const se_GetDataSetCommand = async (input, context) => {
|
|
198
|
-
const
|
|
126
|
+
const b = rb(input, context);
|
|
199
127
|
const headers = {};
|
|
200
|
-
|
|
201
|
-
|
|
128
|
+
b.bp("/v1/data-sets/{DataSetId}");
|
|
129
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
202
130
|
let body;
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
hostname,
|
|
206
|
-
port,
|
|
207
|
-
method: "GET",
|
|
208
|
-
headers,
|
|
209
|
-
path: resolvedPath,
|
|
210
|
-
body,
|
|
211
|
-
});
|
|
131
|
+
b.m("GET").h(headers).b(body);
|
|
132
|
+
return b.build();
|
|
212
133
|
};
|
|
213
134
|
export const se_GetEventActionCommand = async (input, context) => {
|
|
214
|
-
const
|
|
135
|
+
const b = rb(input, context);
|
|
215
136
|
const headers = {};
|
|
216
|
-
|
|
217
|
-
|
|
137
|
+
b.bp("/v1/event-actions/{EventActionId}");
|
|
138
|
+
b.p("EventActionId", () => input.EventActionId, "{EventActionId}", false);
|
|
218
139
|
let body;
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
hostname,
|
|
222
|
-
port,
|
|
223
|
-
method: "GET",
|
|
224
|
-
headers,
|
|
225
|
-
path: resolvedPath,
|
|
226
|
-
body,
|
|
227
|
-
});
|
|
140
|
+
b.m("GET").h(headers).b(body);
|
|
141
|
+
return b.build();
|
|
228
142
|
};
|
|
229
143
|
export const se_GetJobCommand = async (input, context) => {
|
|
230
|
-
const
|
|
144
|
+
const b = rb(input, context);
|
|
231
145
|
const headers = {};
|
|
232
|
-
|
|
233
|
-
|
|
146
|
+
b.bp("/v1/jobs/{JobId}");
|
|
147
|
+
b.p("JobId", () => input.JobId, "{JobId}", false);
|
|
234
148
|
let body;
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
hostname,
|
|
238
|
-
port,
|
|
239
|
-
method: "GET",
|
|
240
|
-
headers,
|
|
241
|
-
path: resolvedPath,
|
|
242
|
-
body,
|
|
243
|
-
});
|
|
149
|
+
b.m("GET").h(headers).b(body);
|
|
150
|
+
return b.build();
|
|
244
151
|
};
|
|
245
152
|
export const se_GetRevisionCommand = async (input, context) => {
|
|
246
|
-
const
|
|
153
|
+
const b = rb(input, context);
|
|
247
154
|
const headers = {};
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
155
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}");
|
|
156
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
157
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
252
158
|
let body;
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
hostname,
|
|
256
|
-
port,
|
|
257
|
-
method: "GET",
|
|
258
|
-
headers,
|
|
259
|
-
path: resolvedPath,
|
|
260
|
-
body,
|
|
261
|
-
});
|
|
159
|
+
b.m("GET").h(headers).b(body);
|
|
160
|
+
return b.build();
|
|
262
161
|
};
|
|
263
162
|
export const se_ListDataSetRevisionsCommand = async (input, context) => {
|
|
264
|
-
const
|
|
163
|
+
const b = rb(input, context);
|
|
265
164
|
const headers = {};
|
|
266
|
-
|
|
267
|
-
|
|
165
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions");
|
|
166
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
268
167
|
const query = map({
|
|
269
|
-
|
|
270
|
-
|
|
168
|
+
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
169
|
+
[_nT]: [, input[_NT]],
|
|
271
170
|
});
|
|
272
171
|
let body;
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
hostname,
|
|
276
|
-
port,
|
|
277
|
-
method: "GET",
|
|
278
|
-
headers,
|
|
279
|
-
path: resolvedPath,
|
|
280
|
-
query,
|
|
281
|
-
body,
|
|
282
|
-
});
|
|
172
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
173
|
+
return b.build();
|
|
283
174
|
};
|
|
284
175
|
export const se_ListDataSetsCommand = async (input, context) => {
|
|
285
|
-
const
|
|
176
|
+
const b = rb(input, context);
|
|
286
177
|
const headers = {};
|
|
287
|
-
|
|
178
|
+
b.bp("/v1/data-sets");
|
|
288
179
|
const query = map({
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
180
|
+
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
181
|
+
[_nT]: [, input[_NT]],
|
|
182
|
+
[_o]: [, input[_O]],
|
|
292
183
|
});
|
|
293
184
|
let body;
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
hostname,
|
|
297
|
-
port,
|
|
298
|
-
method: "GET",
|
|
299
|
-
headers,
|
|
300
|
-
path: resolvedPath,
|
|
301
|
-
query,
|
|
302
|
-
body,
|
|
303
|
-
});
|
|
185
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
186
|
+
return b.build();
|
|
304
187
|
};
|
|
305
188
|
export const se_ListEventActionsCommand = async (input, context) => {
|
|
306
|
-
const
|
|
189
|
+
const b = rb(input, context);
|
|
307
190
|
const headers = {};
|
|
308
|
-
|
|
191
|
+
b.bp("/v1/event-actions");
|
|
309
192
|
const query = map({
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
193
|
+
[_eSI]: [, input[_ESI]],
|
|
194
|
+
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
195
|
+
[_nT]: [, input[_NT]],
|
|
313
196
|
});
|
|
314
197
|
let body;
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
hostname,
|
|
318
|
-
port,
|
|
319
|
-
method: "GET",
|
|
320
|
-
headers,
|
|
321
|
-
path: resolvedPath,
|
|
322
|
-
query,
|
|
323
|
-
body,
|
|
324
|
-
});
|
|
198
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
199
|
+
return b.build();
|
|
325
200
|
};
|
|
326
201
|
export const se_ListJobsCommand = async (input, context) => {
|
|
327
|
-
const
|
|
202
|
+
const b = rb(input, context);
|
|
328
203
|
const headers = {};
|
|
329
|
-
|
|
204
|
+
b.bp("/v1/jobs");
|
|
330
205
|
const query = map({
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
206
|
+
[_dSI]: [, input[_DSI]],
|
|
207
|
+
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
208
|
+
[_nT]: [, input[_NT]],
|
|
209
|
+
[_rI]: [, input[_RI]],
|
|
335
210
|
});
|
|
336
211
|
let body;
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
hostname,
|
|
340
|
-
port,
|
|
341
|
-
method: "GET",
|
|
342
|
-
headers,
|
|
343
|
-
path: resolvedPath,
|
|
344
|
-
query,
|
|
345
|
-
body,
|
|
346
|
-
});
|
|
212
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
213
|
+
return b.build();
|
|
347
214
|
};
|
|
348
215
|
export const se_ListRevisionAssetsCommand = async (input, context) => {
|
|
349
|
-
const
|
|
216
|
+
const b = rb(input, context);
|
|
350
217
|
const headers = {};
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
218
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets");
|
|
219
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
220
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
355
221
|
const query = map({
|
|
356
|
-
|
|
357
|
-
|
|
222
|
+
[_mR]: [() => input.MaxResults !== void 0, () => input[_MR].toString()],
|
|
223
|
+
[_nT]: [, input[_NT]],
|
|
358
224
|
});
|
|
359
225
|
let body;
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
hostname,
|
|
363
|
-
port,
|
|
364
|
-
method: "GET",
|
|
365
|
-
headers,
|
|
366
|
-
path: resolvedPath,
|
|
367
|
-
query,
|
|
368
|
-
body,
|
|
369
|
-
});
|
|
226
|
+
b.m("GET").h(headers).q(query).b(body);
|
|
227
|
+
return b.build();
|
|
370
228
|
};
|
|
371
229
|
export const se_ListTagsForResourceCommand = async (input, context) => {
|
|
372
|
-
const
|
|
230
|
+
const b = rb(input, context);
|
|
373
231
|
const headers = {};
|
|
374
|
-
|
|
375
|
-
|
|
232
|
+
b.bp("/tags/{ResourceArn}");
|
|
233
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
376
234
|
let body;
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
hostname,
|
|
380
|
-
port,
|
|
381
|
-
method: "GET",
|
|
382
|
-
headers,
|
|
383
|
-
path: resolvedPath,
|
|
384
|
-
body,
|
|
385
|
-
});
|
|
235
|
+
b.m("GET").h(headers).b(body);
|
|
236
|
+
return b.build();
|
|
386
237
|
};
|
|
387
238
|
export const se_RevokeRevisionCommand = async (input, context) => {
|
|
388
|
-
const
|
|
239
|
+
const b = rb(input, context);
|
|
389
240
|
const headers = {
|
|
390
241
|
"content-type": "application/json",
|
|
391
242
|
};
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
243
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/revoke");
|
|
244
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
245
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
396
246
|
let body;
|
|
397
247
|
body = JSON.stringify(take(input, {
|
|
398
248
|
RevocationComment: [],
|
|
399
249
|
}));
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
hostname,
|
|
403
|
-
port,
|
|
404
|
-
method: "POST",
|
|
405
|
-
headers,
|
|
406
|
-
path: resolvedPath,
|
|
407
|
-
body,
|
|
408
|
-
});
|
|
250
|
+
b.m("POST").h(headers).b(body);
|
|
251
|
+
return b.build();
|
|
409
252
|
};
|
|
410
253
|
export const se_SendApiAssetCommand = async (input, context) => {
|
|
411
|
-
const
|
|
254
|
+
const b = rb(input, context);
|
|
412
255
|
const headers = map({}, isSerializableHeaderValue, {
|
|
413
256
|
"content-type": "text/plain",
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
257
|
+
[_xadai]: input[_AI],
|
|
258
|
+
[_xaddsi]: input[_DSI],
|
|
259
|
+
[_xadhm]: input[_M],
|
|
260
|
+
[_xadp]: input[_P],
|
|
261
|
+
[_xadri]: input[_RI],
|
|
419
262
|
...(input.RequestHeaders !== undefined &&
|
|
420
263
|
Object.keys(input.RequestHeaders).reduce((acc, suffix) => {
|
|
421
264
|
acc[`x-amzn-dataexchange-header-${suffix.toLowerCase()}`] = input.RequestHeaders[suffix];
|
|
422
265
|
return acc;
|
|
423
266
|
}, {})),
|
|
424
267
|
});
|
|
425
|
-
|
|
268
|
+
b.bp("/v1");
|
|
426
269
|
const query = map({
|
|
427
270
|
...convertMap(input.QueryStringParameters),
|
|
428
271
|
});
|
|
@@ -437,24 +280,17 @@ export const se_SendApiAssetCommand = async (input, context) => {
|
|
|
437
280
|
throw new Error("ValidationError: prefixed hostname must be hostname compatible.");
|
|
438
281
|
}
|
|
439
282
|
}
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
port,
|
|
444
|
-
method: "POST",
|
|
445
|
-
headers,
|
|
446
|
-
path: resolvedPath,
|
|
447
|
-
query,
|
|
448
|
-
body,
|
|
449
|
-
});
|
|
283
|
+
b.hn(resolvedHostname);
|
|
284
|
+
b.m("POST").h(headers).q(query).b(body);
|
|
285
|
+
return b.build();
|
|
450
286
|
};
|
|
451
287
|
export const se_SendDataSetNotificationCommand = async (input, context) => {
|
|
452
|
-
const
|
|
288
|
+
const b = rb(input, context);
|
|
453
289
|
const headers = {
|
|
454
290
|
"content-type": "application/json",
|
|
455
291
|
};
|
|
456
|
-
|
|
457
|
-
|
|
292
|
+
b.bp("/v1/data-sets/{DataSetId}/notification");
|
|
293
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
458
294
|
let body;
|
|
459
295
|
body = JSON.stringify(take(input, {
|
|
460
296
|
ClientToken: [true, (_) => _ ?? generateIdempotencyToken()],
|
|
@@ -463,166 +299,107 @@ export const se_SendDataSetNotificationCommand = async (input, context) => {
|
|
|
463
299
|
Scope: (_) => _json(_),
|
|
464
300
|
Type: [],
|
|
465
301
|
}));
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
hostname,
|
|
469
|
-
port,
|
|
470
|
-
method: "POST",
|
|
471
|
-
headers,
|
|
472
|
-
path: resolvedPath,
|
|
473
|
-
body,
|
|
474
|
-
});
|
|
302
|
+
b.m("POST").h(headers).b(body);
|
|
303
|
+
return b.build();
|
|
475
304
|
};
|
|
476
305
|
export const se_StartJobCommand = async (input, context) => {
|
|
477
|
-
const
|
|
306
|
+
const b = rb(input, context);
|
|
478
307
|
const headers = {};
|
|
479
|
-
|
|
480
|
-
|
|
308
|
+
b.bp("/v1/jobs/{JobId}");
|
|
309
|
+
b.p("JobId", () => input.JobId, "{JobId}", false);
|
|
481
310
|
let body;
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
hostname,
|
|
485
|
-
port,
|
|
486
|
-
method: "PATCH",
|
|
487
|
-
headers,
|
|
488
|
-
path: resolvedPath,
|
|
489
|
-
body,
|
|
490
|
-
});
|
|
311
|
+
b.m("PATCH").h(headers).b(body);
|
|
312
|
+
return b.build();
|
|
491
313
|
};
|
|
492
314
|
export const se_TagResourceCommand = async (input, context) => {
|
|
493
|
-
const
|
|
315
|
+
const b = rb(input, context);
|
|
494
316
|
const headers = {
|
|
495
317
|
"content-type": "application/json",
|
|
496
318
|
};
|
|
497
|
-
|
|
498
|
-
|
|
319
|
+
b.bp("/tags/{ResourceArn}");
|
|
320
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
499
321
|
let body;
|
|
500
322
|
body = JSON.stringify(take(input, {
|
|
501
323
|
tags: [, (_) => _json(_), `Tags`],
|
|
502
324
|
}));
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
hostname,
|
|
506
|
-
port,
|
|
507
|
-
method: "POST",
|
|
508
|
-
headers,
|
|
509
|
-
path: resolvedPath,
|
|
510
|
-
body,
|
|
511
|
-
});
|
|
325
|
+
b.m("POST").h(headers).b(body);
|
|
326
|
+
return b.build();
|
|
512
327
|
};
|
|
513
328
|
export const se_UntagResourceCommand = async (input, context) => {
|
|
514
|
-
const
|
|
329
|
+
const b = rb(input, context);
|
|
515
330
|
const headers = {};
|
|
516
|
-
|
|
517
|
-
|
|
331
|
+
b.bp("/tags/{ResourceArn}");
|
|
332
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
518
333
|
const query = map({
|
|
519
|
-
|
|
334
|
+
[_tK]: [
|
|
520
335
|
__expectNonNull(input.TagKeys, `TagKeys`) != null,
|
|
521
|
-
() => (input
|
|
336
|
+
() => (input[_TK] || []).map((_entry) => _entry),
|
|
522
337
|
],
|
|
523
338
|
});
|
|
524
339
|
let body;
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
hostname,
|
|
528
|
-
port,
|
|
529
|
-
method: "DELETE",
|
|
530
|
-
headers,
|
|
531
|
-
path: resolvedPath,
|
|
532
|
-
query,
|
|
533
|
-
body,
|
|
534
|
-
});
|
|
340
|
+
b.m("DELETE").h(headers).q(query).b(body);
|
|
341
|
+
return b.build();
|
|
535
342
|
};
|
|
536
343
|
export const se_UpdateAssetCommand = async (input, context) => {
|
|
537
|
-
const
|
|
344
|
+
const b = rb(input, context);
|
|
538
345
|
const headers = {
|
|
539
346
|
"content-type": "application/json",
|
|
540
347
|
};
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
348
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}");
|
|
349
|
+
b.p("AssetId", () => input.AssetId, "{AssetId}", false);
|
|
350
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
351
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
546
352
|
let body;
|
|
547
353
|
body = JSON.stringify(take(input, {
|
|
548
354
|
Name: [],
|
|
549
355
|
}));
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
hostname,
|
|
553
|
-
port,
|
|
554
|
-
method: "PATCH",
|
|
555
|
-
headers,
|
|
556
|
-
path: resolvedPath,
|
|
557
|
-
body,
|
|
558
|
-
});
|
|
356
|
+
b.m("PATCH").h(headers).b(body);
|
|
357
|
+
return b.build();
|
|
559
358
|
};
|
|
560
359
|
export const se_UpdateDataSetCommand = async (input, context) => {
|
|
561
|
-
const
|
|
360
|
+
const b = rb(input, context);
|
|
562
361
|
const headers = {
|
|
563
362
|
"content-type": "application/json",
|
|
564
363
|
};
|
|
565
|
-
|
|
566
|
-
|
|
364
|
+
b.bp("/v1/data-sets/{DataSetId}");
|
|
365
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
567
366
|
let body;
|
|
568
367
|
body = JSON.stringify(take(input, {
|
|
569
368
|
Description: [],
|
|
570
369
|
Name: [],
|
|
571
370
|
}));
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
hostname,
|
|
575
|
-
port,
|
|
576
|
-
method: "PATCH",
|
|
577
|
-
headers,
|
|
578
|
-
path: resolvedPath,
|
|
579
|
-
body,
|
|
580
|
-
});
|
|
371
|
+
b.m("PATCH").h(headers).b(body);
|
|
372
|
+
return b.build();
|
|
581
373
|
};
|
|
582
374
|
export const se_UpdateEventActionCommand = async (input, context) => {
|
|
583
|
-
const
|
|
375
|
+
const b = rb(input, context);
|
|
584
376
|
const headers = {
|
|
585
377
|
"content-type": "application/json",
|
|
586
378
|
};
|
|
587
|
-
|
|
588
|
-
|
|
379
|
+
b.bp("/v1/event-actions/{EventActionId}");
|
|
380
|
+
b.p("EventActionId", () => input.EventActionId, "{EventActionId}", false);
|
|
589
381
|
let body;
|
|
590
382
|
body = JSON.stringify(take(input, {
|
|
591
383
|
Action: (_) => _json(_),
|
|
592
384
|
}));
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
hostname,
|
|
596
|
-
port,
|
|
597
|
-
method: "PATCH",
|
|
598
|
-
headers,
|
|
599
|
-
path: resolvedPath,
|
|
600
|
-
body,
|
|
601
|
-
});
|
|
385
|
+
b.m("PATCH").h(headers).b(body);
|
|
386
|
+
return b.build();
|
|
602
387
|
};
|
|
603
388
|
export const se_UpdateRevisionCommand = async (input, context) => {
|
|
604
|
-
const
|
|
389
|
+
const b = rb(input, context);
|
|
605
390
|
const headers = {
|
|
606
391
|
"content-type": "application/json",
|
|
607
392
|
};
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
393
|
+
b.bp("/v1/data-sets/{DataSetId}/revisions/{RevisionId}");
|
|
394
|
+
b.p("DataSetId", () => input.DataSetId, "{DataSetId}", false);
|
|
395
|
+
b.p("RevisionId", () => input.RevisionId, "{RevisionId}", false);
|
|
612
396
|
let body;
|
|
613
397
|
body = JSON.stringify(take(input, {
|
|
614
398
|
Comment: [],
|
|
615
399
|
Finalized: [],
|
|
616
400
|
}));
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
hostname,
|
|
620
|
-
port,
|
|
621
|
-
method: "PATCH",
|
|
622
|
-
headers,
|
|
623
|
-
path: resolvedPath,
|
|
624
|
-
body,
|
|
625
|
-
});
|
|
401
|
+
b.m("PATCH").h(headers).b(body);
|
|
402
|
+
return b.build();
|
|
626
403
|
};
|
|
627
404
|
export const de_CancelJobCommand = async (output, context) => {
|
|
628
405
|
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
@@ -2339,6 +2116,28 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
|
2339
2116
|
value !== "" &&
|
|
2340
2117
|
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
2341
2118
|
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
2119
|
+
const _AI = "AssetId";
|
|
2120
|
+
const _DSI = "DataSetId";
|
|
2121
|
+
const _ESI = "EventSourceId";
|
|
2122
|
+
const _M = "Method";
|
|
2123
|
+
const _MR = "MaxResults";
|
|
2124
|
+
const _NT = "NextToken";
|
|
2125
|
+
const _O = "Origin";
|
|
2126
|
+
const _P = "Path";
|
|
2127
|
+
const _RI = "RevisionId";
|
|
2128
|
+
const _TK = "TagKeys";
|
|
2129
|
+
const _dSI = "dataSetId";
|
|
2130
|
+
const _eSI = "eventSourceId";
|
|
2131
|
+
const _mR = "maxResults";
|
|
2132
|
+
const _nT = "nextToken";
|
|
2133
|
+
const _o = "origin";
|
|
2134
|
+
const _rI = "revisionId";
|
|
2135
|
+
const _tK = "tagKeys";
|
|
2136
|
+
const _xadai = "x-amzn-dataexchange-asset-id";
|
|
2137
|
+
const _xaddsi = "x-amzn-dataexchange-data-set-id";
|
|
2138
|
+
const _xadhm = "x-amzn-dataexchange-http-method";
|
|
2139
|
+
const _xadp = "x-amzn-dataexchange-path";
|
|
2140
|
+
const _xadri = "x-amzn-dataexchange-revision-id";
|
|
2342
2141
|
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
2343
2142
|
if (encoded.length) {
|
|
2344
2143
|
return JSON.parse(encoded);
|