@aws-sdk/client-oam 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.
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.de_UpdateLinkCommand = exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_PutSinkPolicyCommand = exports.de_ListTagsForResourceCommand = exports.de_ListSinksCommand = exports.de_ListLinksCommand = exports.de_ListAttachedLinksCommand = exports.de_GetSinkPolicyCommand = exports.de_GetSinkCommand = exports.de_GetLinkCommand = exports.de_DeleteSinkCommand = exports.de_DeleteLinkCommand = exports.de_CreateSinkCommand = exports.de_CreateLinkCommand = exports.se_UpdateLinkCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_PutSinkPolicyCommand = exports.se_ListTagsForResourceCommand = exports.se_ListSinksCommand = exports.se_ListLinksCommand = exports.se_ListAttachedLinksCommand = exports.se_GetSinkPolicyCommand = exports.se_GetSinkCommand = exports.se_GetLinkCommand = exports.se_DeleteSinkCommand = exports.se_DeleteLinkCommand = exports.se_CreateSinkCommand = exports.se_CreateLinkCommand = void 0;
|
|
4
|
-
const
|
|
4
|
+
const core_1 = require("@smithy/core");
|
|
5
5
|
const smithy_client_1 = require("@smithy/smithy-client");
|
|
6
6
|
const models_0_1 = require("../models/models_0");
|
|
7
7
|
const OAMServiceException_1 = require("../models/OAMServiceException");
|
|
8
8
|
const se_CreateLinkCommand = async (input, context) => {
|
|
9
|
-
const
|
|
9
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
10
10
|
const headers = {
|
|
11
11
|
"content-type": "application/json",
|
|
12
12
|
};
|
|
13
|
-
|
|
13
|
+
b.bp("/CreateLink");
|
|
14
14
|
let body;
|
|
15
15
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
16
16
|
LabelTemplate: [],
|
|
@@ -18,316 +18,210 @@ const se_CreateLinkCommand = async (input, context) => {
|
|
|
18
18
|
SinkIdentifier: [],
|
|
19
19
|
Tags: (_) => (0, smithy_client_1._json)(_),
|
|
20
20
|
}));
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
hostname,
|
|
24
|
-
port,
|
|
25
|
-
method: "POST",
|
|
26
|
-
headers,
|
|
27
|
-
path: resolvedPath,
|
|
28
|
-
body,
|
|
29
|
-
});
|
|
21
|
+
b.m("POST").h(headers).b(body);
|
|
22
|
+
return b.build();
|
|
30
23
|
};
|
|
31
24
|
exports.se_CreateLinkCommand = se_CreateLinkCommand;
|
|
32
25
|
const se_CreateSinkCommand = async (input, context) => {
|
|
33
|
-
const
|
|
26
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
34
27
|
const headers = {
|
|
35
28
|
"content-type": "application/json",
|
|
36
29
|
};
|
|
37
|
-
|
|
30
|
+
b.bp("/CreateSink");
|
|
38
31
|
let body;
|
|
39
32
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
40
33
|
Name: [],
|
|
41
34
|
Tags: (_) => (0, smithy_client_1._json)(_),
|
|
42
35
|
}));
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
hostname,
|
|
46
|
-
port,
|
|
47
|
-
method: "POST",
|
|
48
|
-
headers,
|
|
49
|
-
path: resolvedPath,
|
|
50
|
-
body,
|
|
51
|
-
});
|
|
36
|
+
b.m("POST").h(headers).b(body);
|
|
37
|
+
return b.build();
|
|
52
38
|
};
|
|
53
39
|
exports.se_CreateSinkCommand = se_CreateSinkCommand;
|
|
54
40
|
const se_DeleteLinkCommand = async (input, context) => {
|
|
55
|
-
const
|
|
41
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
56
42
|
const headers = {
|
|
57
43
|
"content-type": "application/json",
|
|
58
44
|
};
|
|
59
|
-
|
|
45
|
+
b.bp("/DeleteLink");
|
|
60
46
|
let body;
|
|
61
47
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
62
48
|
Identifier: [],
|
|
63
49
|
}));
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
hostname,
|
|
67
|
-
port,
|
|
68
|
-
method: "POST",
|
|
69
|
-
headers,
|
|
70
|
-
path: resolvedPath,
|
|
71
|
-
body,
|
|
72
|
-
});
|
|
50
|
+
b.m("POST").h(headers).b(body);
|
|
51
|
+
return b.build();
|
|
73
52
|
};
|
|
74
53
|
exports.se_DeleteLinkCommand = se_DeleteLinkCommand;
|
|
75
54
|
const se_DeleteSinkCommand = async (input, context) => {
|
|
76
|
-
const
|
|
55
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
77
56
|
const headers = {
|
|
78
57
|
"content-type": "application/json",
|
|
79
58
|
};
|
|
80
|
-
|
|
59
|
+
b.bp("/DeleteSink");
|
|
81
60
|
let body;
|
|
82
61
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
83
62
|
Identifier: [],
|
|
84
63
|
}));
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
hostname,
|
|
88
|
-
port,
|
|
89
|
-
method: "POST",
|
|
90
|
-
headers,
|
|
91
|
-
path: resolvedPath,
|
|
92
|
-
body,
|
|
93
|
-
});
|
|
64
|
+
b.m("POST").h(headers).b(body);
|
|
65
|
+
return b.build();
|
|
94
66
|
};
|
|
95
67
|
exports.se_DeleteSinkCommand = se_DeleteSinkCommand;
|
|
96
68
|
const se_GetLinkCommand = async (input, context) => {
|
|
97
|
-
const
|
|
69
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
98
70
|
const headers = {
|
|
99
71
|
"content-type": "application/json",
|
|
100
72
|
};
|
|
101
|
-
|
|
73
|
+
b.bp("/GetLink");
|
|
102
74
|
let body;
|
|
103
75
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
104
76
|
Identifier: [],
|
|
105
77
|
}));
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
hostname,
|
|
109
|
-
port,
|
|
110
|
-
method: "POST",
|
|
111
|
-
headers,
|
|
112
|
-
path: resolvedPath,
|
|
113
|
-
body,
|
|
114
|
-
});
|
|
78
|
+
b.m("POST").h(headers).b(body);
|
|
79
|
+
return b.build();
|
|
115
80
|
};
|
|
116
81
|
exports.se_GetLinkCommand = se_GetLinkCommand;
|
|
117
82
|
const se_GetSinkCommand = async (input, context) => {
|
|
118
|
-
const
|
|
83
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
119
84
|
const headers = {
|
|
120
85
|
"content-type": "application/json",
|
|
121
86
|
};
|
|
122
|
-
|
|
87
|
+
b.bp("/GetSink");
|
|
123
88
|
let body;
|
|
124
89
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
125
90
|
Identifier: [],
|
|
126
91
|
}));
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
hostname,
|
|
130
|
-
port,
|
|
131
|
-
method: "POST",
|
|
132
|
-
headers,
|
|
133
|
-
path: resolvedPath,
|
|
134
|
-
body,
|
|
135
|
-
});
|
|
92
|
+
b.m("POST").h(headers).b(body);
|
|
93
|
+
return b.build();
|
|
136
94
|
};
|
|
137
95
|
exports.se_GetSinkCommand = se_GetSinkCommand;
|
|
138
96
|
const se_GetSinkPolicyCommand = async (input, context) => {
|
|
139
|
-
const
|
|
97
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
140
98
|
const headers = {
|
|
141
99
|
"content-type": "application/json",
|
|
142
100
|
};
|
|
143
|
-
|
|
101
|
+
b.bp("/GetSinkPolicy");
|
|
144
102
|
let body;
|
|
145
103
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
146
104
|
SinkIdentifier: [],
|
|
147
105
|
}));
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
hostname,
|
|
151
|
-
port,
|
|
152
|
-
method: "POST",
|
|
153
|
-
headers,
|
|
154
|
-
path: resolvedPath,
|
|
155
|
-
body,
|
|
156
|
-
});
|
|
106
|
+
b.m("POST").h(headers).b(body);
|
|
107
|
+
return b.build();
|
|
157
108
|
};
|
|
158
109
|
exports.se_GetSinkPolicyCommand = se_GetSinkPolicyCommand;
|
|
159
110
|
const se_ListAttachedLinksCommand = async (input, context) => {
|
|
160
|
-
const
|
|
111
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
161
112
|
const headers = {
|
|
162
113
|
"content-type": "application/json",
|
|
163
114
|
};
|
|
164
|
-
|
|
115
|
+
b.bp("/ListAttachedLinks");
|
|
165
116
|
let body;
|
|
166
117
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
167
118
|
MaxResults: [],
|
|
168
119
|
NextToken: [],
|
|
169
120
|
SinkIdentifier: [],
|
|
170
121
|
}));
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
hostname,
|
|
174
|
-
port,
|
|
175
|
-
method: "POST",
|
|
176
|
-
headers,
|
|
177
|
-
path: resolvedPath,
|
|
178
|
-
body,
|
|
179
|
-
});
|
|
122
|
+
b.m("POST").h(headers).b(body);
|
|
123
|
+
return b.build();
|
|
180
124
|
};
|
|
181
125
|
exports.se_ListAttachedLinksCommand = se_ListAttachedLinksCommand;
|
|
182
126
|
const se_ListLinksCommand = async (input, context) => {
|
|
183
|
-
const
|
|
127
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
184
128
|
const headers = {
|
|
185
129
|
"content-type": "application/json",
|
|
186
130
|
};
|
|
187
|
-
|
|
131
|
+
b.bp("/ListLinks");
|
|
188
132
|
let body;
|
|
189
133
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
190
134
|
MaxResults: [],
|
|
191
135
|
NextToken: [],
|
|
192
136
|
}));
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
hostname,
|
|
196
|
-
port,
|
|
197
|
-
method: "POST",
|
|
198
|
-
headers,
|
|
199
|
-
path: resolvedPath,
|
|
200
|
-
body,
|
|
201
|
-
});
|
|
137
|
+
b.m("POST").h(headers).b(body);
|
|
138
|
+
return b.build();
|
|
202
139
|
};
|
|
203
140
|
exports.se_ListLinksCommand = se_ListLinksCommand;
|
|
204
141
|
const se_ListSinksCommand = async (input, context) => {
|
|
205
|
-
const
|
|
142
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
206
143
|
const headers = {
|
|
207
144
|
"content-type": "application/json",
|
|
208
145
|
};
|
|
209
|
-
|
|
146
|
+
b.bp("/ListSinks");
|
|
210
147
|
let body;
|
|
211
148
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
212
149
|
MaxResults: [],
|
|
213
150
|
NextToken: [],
|
|
214
151
|
}));
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
hostname,
|
|
218
|
-
port,
|
|
219
|
-
method: "POST",
|
|
220
|
-
headers,
|
|
221
|
-
path: resolvedPath,
|
|
222
|
-
body,
|
|
223
|
-
});
|
|
152
|
+
b.m("POST").h(headers).b(body);
|
|
153
|
+
return b.build();
|
|
224
154
|
};
|
|
225
155
|
exports.se_ListSinksCommand = se_ListSinksCommand;
|
|
226
156
|
const se_ListTagsForResourceCommand = async (input, context) => {
|
|
227
|
-
const
|
|
157
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
228
158
|
const headers = {};
|
|
229
|
-
|
|
230
|
-
|
|
159
|
+
b.bp("/tags/{ResourceArn}");
|
|
160
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
231
161
|
let body;
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
hostname,
|
|
235
|
-
port,
|
|
236
|
-
method: "GET",
|
|
237
|
-
headers,
|
|
238
|
-
path: resolvedPath,
|
|
239
|
-
body,
|
|
240
|
-
});
|
|
162
|
+
b.m("GET").h(headers).b(body);
|
|
163
|
+
return b.build();
|
|
241
164
|
};
|
|
242
165
|
exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
|
|
243
166
|
const se_PutSinkPolicyCommand = async (input, context) => {
|
|
244
|
-
const
|
|
167
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
245
168
|
const headers = {
|
|
246
169
|
"content-type": "application/json",
|
|
247
170
|
};
|
|
248
|
-
|
|
171
|
+
b.bp("/PutSinkPolicy");
|
|
249
172
|
let body;
|
|
250
173
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
251
174
|
Policy: [],
|
|
252
175
|
SinkIdentifier: [],
|
|
253
176
|
}));
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
hostname,
|
|
257
|
-
port,
|
|
258
|
-
method: "POST",
|
|
259
|
-
headers,
|
|
260
|
-
path: resolvedPath,
|
|
261
|
-
body,
|
|
262
|
-
});
|
|
177
|
+
b.m("POST").h(headers).b(body);
|
|
178
|
+
return b.build();
|
|
263
179
|
};
|
|
264
180
|
exports.se_PutSinkPolicyCommand = se_PutSinkPolicyCommand;
|
|
265
181
|
const se_TagResourceCommand = async (input, context) => {
|
|
266
|
-
const
|
|
182
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
267
183
|
const headers = {
|
|
268
184
|
"content-type": "application/json",
|
|
269
185
|
};
|
|
270
|
-
|
|
271
|
-
|
|
186
|
+
b.bp("/tags/{ResourceArn}");
|
|
187
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
272
188
|
let body;
|
|
273
189
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
274
190
|
Tags: (_) => (0, smithy_client_1._json)(_),
|
|
275
191
|
}));
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
hostname,
|
|
279
|
-
port,
|
|
280
|
-
method: "PUT",
|
|
281
|
-
headers,
|
|
282
|
-
path: resolvedPath,
|
|
283
|
-
body,
|
|
284
|
-
});
|
|
192
|
+
b.m("PUT").h(headers).b(body);
|
|
193
|
+
return b.build();
|
|
285
194
|
};
|
|
286
195
|
exports.se_TagResourceCommand = se_TagResourceCommand;
|
|
287
196
|
const se_UntagResourceCommand = async (input, context) => {
|
|
288
|
-
const
|
|
197
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
289
198
|
const headers = {};
|
|
290
|
-
|
|
291
|
-
|
|
199
|
+
b.bp("/tags/{ResourceArn}");
|
|
200
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
292
201
|
const query = (0, smithy_client_1.map)({
|
|
293
|
-
|
|
202
|
+
[_tK]: [
|
|
294
203
|
(0, smithy_client_1.expectNonNull)(input.TagKeys, `TagKeys`) != null,
|
|
295
|
-
() => (input
|
|
204
|
+
() => (input[_TK] || []).map((_entry) => _entry),
|
|
296
205
|
],
|
|
297
206
|
});
|
|
298
207
|
let body;
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
hostname,
|
|
302
|
-
port,
|
|
303
|
-
method: "DELETE",
|
|
304
|
-
headers,
|
|
305
|
-
path: resolvedPath,
|
|
306
|
-
query,
|
|
307
|
-
body,
|
|
308
|
-
});
|
|
208
|
+
b.m("DELETE").h(headers).q(query).b(body);
|
|
209
|
+
return b.build();
|
|
309
210
|
};
|
|
310
211
|
exports.se_UntagResourceCommand = se_UntagResourceCommand;
|
|
311
212
|
const se_UpdateLinkCommand = async (input, context) => {
|
|
312
|
-
const
|
|
213
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
313
214
|
const headers = {
|
|
314
215
|
"content-type": "application/json",
|
|
315
216
|
};
|
|
316
|
-
|
|
217
|
+
b.bp("/UpdateLink");
|
|
317
218
|
let body;
|
|
318
219
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
319
220
|
Identifier: [],
|
|
320
221
|
ResourceTypes: (_) => (0, smithy_client_1._json)(_),
|
|
321
222
|
}));
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
hostname,
|
|
325
|
-
port,
|
|
326
|
-
method: "POST",
|
|
327
|
-
headers,
|
|
328
|
-
path: resolvedPath,
|
|
329
|
-
body,
|
|
330
|
-
});
|
|
223
|
+
b.m("POST").h(headers).b(body);
|
|
224
|
+
return b.build();
|
|
331
225
|
};
|
|
332
226
|
exports.se_UpdateLinkCommand = se_UpdateLinkCommand;
|
|
333
227
|
const de_CreateLinkCommand = async (output, context) => {
|
|
@@ -981,7 +875,7 @@ const de_UpdateLinkCommandError = async (output, context) => {
|
|
|
981
875
|
const throwDefaultError = (0, smithy_client_1.withBaseException)(OAMServiceException_1.OAMServiceException);
|
|
982
876
|
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
983
877
|
const contents = (0, smithy_client_1.map)({
|
|
984
|
-
|
|
878
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
985
879
|
});
|
|
986
880
|
const data = parsedOutput.body;
|
|
987
881
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -996,7 +890,7 @@ const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
|
996
890
|
};
|
|
997
891
|
const de_InternalServiceFaultRes = async (parsedOutput, context) => {
|
|
998
892
|
const contents = (0, smithy_client_1.map)({
|
|
999
|
-
|
|
893
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1000
894
|
});
|
|
1001
895
|
const data = parsedOutput.body;
|
|
1002
896
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -1011,7 +905,7 @@ const de_InternalServiceFaultRes = async (parsedOutput, context) => {
|
|
|
1011
905
|
};
|
|
1012
906
|
const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
|
|
1013
907
|
const contents = (0, smithy_client_1.map)({
|
|
1014
|
-
|
|
908
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1015
909
|
});
|
|
1016
910
|
const data = parsedOutput.body;
|
|
1017
911
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -1026,7 +920,7 @@ const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
|
|
|
1026
920
|
};
|
|
1027
921
|
const de_MissingRequiredParameterExceptionRes = async (parsedOutput, context) => {
|
|
1028
922
|
const contents = (0, smithy_client_1.map)({
|
|
1029
|
-
|
|
923
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1030
924
|
});
|
|
1031
925
|
const data = parsedOutput.body;
|
|
1032
926
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -1041,7 +935,7 @@ const de_MissingRequiredParameterExceptionRes = async (parsedOutput, context) =>
|
|
|
1041
935
|
};
|
|
1042
936
|
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
1043
937
|
const contents = (0, smithy_client_1.map)({
|
|
1044
|
-
|
|
938
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1045
939
|
});
|
|
1046
940
|
const data = parsedOutput.body;
|
|
1047
941
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -1056,7 +950,7 @@ const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
|
1056
950
|
};
|
|
1057
951
|
const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
|
|
1058
952
|
const contents = (0, smithy_client_1.map)({
|
|
1059
|
-
|
|
953
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1060
954
|
});
|
|
1061
955
|
const data = parsedOutput.body;
|
|
1062
956
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -1107,6 +1001,10 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
|
1107
1001
|
value !== "" &&
|
|
1108
1002
|
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
1109
1003
|
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
1004
|
+
const _TK = "TagKeys";
|
|
1005
|
+
const _aET = "amznErrorType";
|
|
1006
|
+
const _tK = "tagKeys";
|
|
1007
|
+
const _xae = "x-amzn-errortype";
|
|
1110
1008
|
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
1111
1009
|
if (encoded.length) {
|
|
1112
1010
|
return JSON.parse(encoded);
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map,
|
|
1
|
+
import { requestBuilder as rb } from "@smithy/core";
|
|
2
|
+
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map, take, withBaseException, } from "@smithy/smithy-client";
|
|
3
3
|
import { ConflictException, InternalServiceFault, InvalidParameterException, MissingRequiredParameterException, ResourceNotFoundException, ServiceQuotaExceededException, TooManyTagsException, ValidationException, } from "../models/models_0";
|
|
4
4
|
import { OAMServiceException as __BaseException } from "../models/OAMServiceException";
|
|
5
5
|
export const se_CreateLinkCommand = async (input, context) => {
|
|
6
|
-
const
|
|
6
|
+
const b = rb(input, context);
|
|
7
7
|
const headers = {
|
|
8
8
|
"content-type": "application/json",
|
|
9
9
|
};
|
|
10
|
-
|
|
10
|
+
b.bp("/CreateLink");
|
|
11
11
|
let body;
|
|
12
12
|
body = JSON.stringify(take(input, {
|
|
13
13
|
LabelTemplate: [],
|
|
@@ -15,302 +15,196 @@ export const se_CreateLinkCommand = async (input, context) => {
|
|
|
15
15
|
SinkIdentifier: [],
|
|
16
16
|
Tags: (_) => _json(_),
|
|
17
17
|
}));
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
hostname,
|
|
21
|
-
port,
|
|
22
|
-
method: "POST",
|
|
23
|
-
headers,
|
|
24
|
-
path: resolvedPath,
|
|
25
|
-
body,
|
|
26
|
-
});
|
|
18
|
+
b.m("POST").h(headers).b(body);
|
|
19
|
+
return b.build();
|
|
27
20
|
};
|
|
28
21
|
export const se_CreateSinkCommand = async (input, context) => {
|
|
29
|
-
const
|
|
22
|
+
const b = rb(input, context);
|
|
30
23
|
const headers = {
|
|
31
24
|
"content-type": "application/json",
|
|
32
25
|
};
|
|
33
|
-
|
|
26
|
+
b.bp("/CreateSink");
|
|
34
27
|
let body;
|
|
35
28
|
body = JSON.stringify(take(input, {
|
|
36
29
|
Name: [],
|
|
37
30
|
Tags: (_) => _json(_),
|
|
38
31
|
}));
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
hostname,
|
|
42
|
-
port,
|
|
43
|
-
method: "POST",
|
|
44
|
-
headers,
|
|
45
|
-
path: resolvedPath,
|
|
46
|
-
body,
|
|
47
|
-
});
|
|
32
|
+
b.m("POST").h(headers).b(body);
|
|
33
|
+
return b.build();
|
|
48
34
|
};
|
|
49
35
|
export const se_DeleteLinkCommand = async (input, context) => {
|
|
50
|
-
const
|
|
36
|
+
const b = rb(input, context);
|
|
51
37
|
const headers = {
|
|
52
38
|
"content-type": "application/json",
|
|
53
39
|
};
|
|
54
|
-
|
|
40
|
+
b.bp("/DeleteLink");
|
|
55
41
|
let body;
|
|
56
42
|
body = JSON.stringify(take(input, {
|
|
57
43
|
Identifier: [],
|
|
58
44
|
}));
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
hostname,
|
|
62
|
-
port,
|
|
63
|
-
method: "POST",
|
|
64
|
-
headers,
|
|
65
|
-
path: resolvedPath,
|
|
66
|
-
body,
|
|
67
|
-
});
|
|
45
|
+
b.m("POST").h(headers).b(body);
|
|
46
|
+
return b.build();
|
|
68
47
|
};
|
|
69
48
|
export const se_DeleteSinkCommand = async (input, context) => {
|
|
70
|
-
const
|
|
49
|
+
const b = rb(input, context);
|
|
71
50
|
const headers = {
|
|
72
51
|
"content-type": "application/json",
|
|
73
52
|
};
|
|
74
|
-
|
|
53
|
+
b.bp("/DeleteSink");
|
|
75
54
|
let body;
|
|
76
55
|
body = JSON.stringify(take(input, {
|
|
77
56
|
Identifier: [],
|
|
78
57
|
}));
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
hostname,
|
|
82
|
-
port,
|
|
83
|
-
method: "POST",
|
|
84
|
-
headers,
|
|
85
|
-
path: resolvedPath,
|
|
86
|
-
body,
|
|
87
|
-
});
|
|
58
|
+
b.m("POST").h(headers).b(body);
|
|
59
|
+
return b.build();
|
|
88
60
|
};
|
|
89
61
|
export const se_GetLinkCommand = async (input, context) => {
|
|
90
|
-
const
|
|
62
|
+
const b = rb(input, context);
|
|
91
63
|
const headers = {
|
|
92
64
|
"content-type": "application/json",
|
|
93
65
|
};
|
|
94
|
-
|
|
66
|
+
b.bp("/GetLink");
|
|
95
67
|
let body;
|
|
96
68
|
body = JSON.stringify(take(input, {
|
|
97
69
|
Identifier: [],
|
|
98
70
|
}));
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
hostname,
|
|
102
|
-
port,
|
|
103
|
-
method: "POST",
|
|
104
|
-
headers,
|
|
105
|
-
path: resolvedPath,
|
|
106
|
-
body,
|
|
107
|
-
});
|
|
71
|
+
b.m("POST").h(headers).b(body);
|
|
72
|
+
return b.build();
|
|
108
73
|
};
|
|
109
74
|
export const se_GetSinkCommand = async (input, context) => {
|
|
110
|
-
const
|
|
75
|
+
const b = rb(input, context);
|
|
111
76
|
const headers = {
|
|
112
77
|
"content-type": "application/json",
|
|
113
78
|
};
|
|
114
|
-
|
|
79
|
+
b.bp("/GetSink");
|
|
115
80
|
let body;
|
|
116
81
|
body = JSON.stringify(take(input, {
|
|
117
82
|
Identifier: [],
|
|
118
83
|
}));
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
hostname,
|
|
122
|
-
port,
|
|
123
|
-
method: "POST",
|
|
124
|
-
headers,
|
|
125
|
-
path: resolvedPath,
|
|
126
|
-
body,
|
|
127
|
-
});
|
|
84
|
+
b.m("POST").h(headers).b(body);
|
|
85
|
+
return b.build();
|
|
128
86
|
};
|
|
129
87
|
export const se_GetSinkPolicyCommand = async (input, context) => {
|
|
130
|
-
const
|
|
88
|
+
const b = rb(input, context);
|
|
131
89
|
const headers = {
|
|
132
90
|
"content-type": "application/json",
|
|
133
91
|
};
|
|
134
|
-
|
|
92
|
+
b.bp("/GetSinkPolicy");
|
|
135
93
|
let body;
|
|
136
94
|
body = JSON.stringify(take(input, {
|
|
137
95
|
SinkIdentifier: [],
|
|
138
96
|
}));
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
hostname,
|
|
142
|
-
port,
|
|
143
|
-
method: "POST",
|
|
144
|
-
headers,
|
|
145
|
-
path: resolvedPath,
|
|
146
|
-
body,
|
|
147
|
-
});
|
|
97
|
+
b.m("POST").h(headers).b(body);
|
|
98
|
+
return b.build();
|
|
148
99
|
};
|
|
149
100
|
export const se_ListAttachedLinksCommand = async (input, context) => {
|
|
150
|
-
const
|
|
101
|
+
const b = rb(input, context);
|
|
151
102
|
const headers = {
|
|
152
103
|
"content-type": "application/json",
|
|
153
104
|
};
|
|
154
|
-
|
|
105
|
+
b.bp("/ListAttachedLinks");
|
|
155
106
|
let body;
|
|
156
107
|
body = JSON.stringify(take(input, {
|
|
157
108
|
MaxResults: [],
|
|
158
109
|
NextToken: [],
|
|
159
110
|
SinkIdentifier: [],
|
|
160
111
|
}));
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
hostname,
|
|
164
|
-
port,
|
|
165
|
-
method: "POST",
|
|
166
|
-
headers,
|
|
167
|
-
path: resolvedPath,
|
|
168
|
-
body,
|
|
169
|
-
});
|
|
112
|
+
b.m("POST").h(headers).b(body);
|
|
113
|
+
return b.build();
|
|
170
114
|
};
|
|
171
115
|
export const se_ListLinksCommand = async (input, context) => {
|
|
172
|
-
const
|
|
116
|
+
const b = rb(input, context);
|
|
173
117
|
const headers = {
|
|
174
118
|
"content-type": "application/json",
|
|
175
119
|
};
|
|
176
|
-
|
|
120
|
+
b.bp("/ListLinks");
|
|
177
121
|
let body;
|
|
178
122
|
body = JSON.stringify(take(input, {
|
|
179
123
|
MaxResults: [],
|
|
180
124
|
NextToken: [],
|
|
181
125
|
}));
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
hostname,
|
|
185
|
-
port,
|
|
186
|
-
method: "POST",
|
|
187
|
-
headers,
|
|
188
|
-
path: resolvedPath,
|
|
189
|
-
body,
|
|
190
|
-
});
|
|
126
|
+
b.m("POST").h(headers).b(body);
|
|
127
|
+
return b.build();
|
|
191
128
|
};
|
|
192
129
|
export const se_ListSinksCommand = async (input, context) => {
|
|
193
|
-
const
|
|
130
|
+
const b = rb(input, context);
|
|
194
131
|
const headers = {
|
|
195
132
|
"content-type": "application/json",
|
|
196
133
|
};
|
|
197
|
-
|
|
134
|
+
b.bp("/ListSinks");
|
|
198
135
|
let body;
|
|
199
136
|
body = JSON.stringify(take(input, {
|
|
200
137
|
MaxResults: [],
|
|
201
138
|
NextToken: [],
|
|
202
139
|
}));
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
hostname,
|
|
206
|
-
port,
|
|
207
|
-
method: "POST",
|
|
208
|
-
headers,
|
|
209
|
-
path: resolvedPath,
|
|
210
|
-
body,
|
|
211
|
-
});
|
|
140
|
+
b.m("POST").h(headers).b(body);
|
|
141
|
+
return b.build();
|
|
212
142
|
};
|
|
213
143
|
export const se_ListTagsForResourceCommand = async (input, context) => {
|
|
214
|
-
const
|
|
144
|
+
const b = rb(input, context);
|
|
215
145
|
const headers = {};
|
|
216
|
-
|
|
217
|
-
|
|
146
|
+
b.bp("/tags/{ResourceArn}");
|
|
147
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
218
148
|
let body;
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
hostname,
|
|
222
|
-
port,
|
|
223
|
-
method: "GET",
|
|
224
|
-
headers,
|
|
225
|
-
path: resolvedPath,
|
|
226
|
-
body,
|
|
227
|
-
});
|
|
149
|
+
b.m("GET").h(headers).b(body);
|
|
150
|
+
return b.build();
|
|
228
151
|
};
|
|
229
152
|
export const se_PutSinkPolicyCommand = async (input, context) => {
|
|
230
|
-
const
|
|
153
|
+
const b = rb(input, context);
|
|
231
154
|
const headers = {
|
|
232
155
|
"content-type": "application/json",
|
|
233
156
|
};
|
|
234
|
-
|
|
157
|
+
b.bp("/PutSinkPolicy");
|
|
235
158
|
let body;
|
|
236
159
|
body = JSON.stringify(take(input, {
|
|
237
160
|
Policy: [],
|
|
238
161
|
SinkIdentifier: [],
|
|
239
162
|
}));
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
hostname,
|
|
243
|
-
port,
|
|
244
|
-
method: "POST",
|
|
245
|
-
headers,
|
|
246
|
-
path: resolvedPath,
|
|
247
|
-
body,
|
|
248
|
-
});
|
|
163
|
+
b.m("POST").h(headers).b(body);
|
|
164
|
+
return b.build();
|
|
249
165
|
};
|
|
250
166
|
export const se_TagResourceCommand = async (input, context) => {
|
|
251
|
-
const
|
|
167
|
+
const b = rb(input, context);
|
|
252
168
|
const headers = {
|
|
253
169
|
"content-type": "application/json",
|
|
254
170
|
};
|
|
255
|
-
|
|
256
|
-
|
|
171
|
+
b.bp("/tags/{ResourceArn}");
|
|
172
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
257
173
|
let body;
|
|
258
174
|
body = JSON.stringify(take(input, {
|
|
259
175
|
Tags: (_) => _json(_),
|
|
260
176
|
}));
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
hostname,
|
|
264
|
-
port,
|
|
265
|
-
method: "PUT",
|
|
266
|
-
headers,
|
|
267
|
-
path: resolvedPath,
|
|
268
|
-
body,
|
|
269
|
-
});
|
|
177
|
+
b.m("PUT").h(headers).b(body);
|
|
178
|
+
return b.build();
|
|
270
179
|
};
|
|
271
180
|
export const se_UntagResourceCommand = async (input, context) => {
|
|
272
|
-
const
|
|
181
|
+
const b = rb(input, context);
|
|
273
182
|
const headers = {};
|
|
274
|
-
|
|
275
|
-
|
|
183
|
+
b.bp("/tags/{ResourceArn}");
|
|
184
|
+
b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
276
185
|
const query = map({
|
|
277
|
-
|
|
186
|
+
[_tK]: [
|
|
278
187
|
__expectNonNull(input.TagKeys, `TagKeys`) != null,
|
|
279
|
-
() => (input
|
|
188
|
+
() => (input[_TK] || []).map((_entry) => _entry),
|
|
280
189
|
],
|
|
281
190
|
});
|
|
282
191
|
let body;
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
hostname,
|
|
286
|
-
port,
|
|
287
|
-
method: "DELETE",
|
|
288
|
-
headers,
|
|
289
|
-
path: resolvedPath,
|
|
290
|
-
query,
|
|
291
|
-
body,
|
|
292
|
-
});
|
|
192
|
+
b.m("DELETE").h(headers).q(query).b(body);
|
|
193
|
+
return b.build();
|
|
293
194
|
};
|
|
294
195
|
export const se_UpdateLinkCommand = async (input, context) => {
|
|
295
|
-
const
|
|
196
|
+
const b = rb(input, context);
|
|
296
197
|
const headers = {
|
|
297
198
|
"content-type": "application/json",
|
|
298
199
|
};
|
|
299
|
-
|
|
200
|
+
b.bp("/UpdateLink");
|
|
300
201
|
let body;
|
|
301
202
|
body = JSON.stringify(take(input, {
|
|
302
203
|
Identifier: [],
|
|
303
204
|
ResourceTypes: (_) => _json(_),
|
|
304
205
|
}));
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
hostname,
|
|
308
|
-
port,
|
|
309
|
-
method: "POST",
|
|
310
|
-
headers,
|
|
311
|
-
path: resolvedPath,
|
|
312
|
-
body,
|
|
313
|
-
});
|
|
206
|
+
b.m("POST").h(headers).b(body);
|
|
207
|
+
return b.build();
|
|
314
208
|
};
|
|
315
209
|
export const de_CreateLinkCommand = async (output, context) => {
|
|
316
210
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
@@ -948,7 +842,7 @@ const de_UpdateLinkCommandError = async (output, context) => {
|
|
|
948
842
|
const throwDefaultError = withBaseException(__BaseException);
|
|
949
843
|
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
950
844
|
const contents = map({
|
|
951
|
-
|
|
845
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
952
846
|
});
|
|
953
847
|
const data = parsedOutput.body;
|
|
954
848
|
const doc = take(data, {
|
|
@@ -963,7 +857,7 @@ const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
|
963
857
|
};
|
|
964
858
|
const de_InternalServiceFaultRes = async (parsedOutput, context) => {
|
|
965
859
|
const contents = map({
|
|
966
|
-
|
|
860
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
967
861
|
});
|
|
968
862
|
const data = parsedOutput.body;
|
|
969
863
|
const doc = take(data, {
|
|
@@ -978,7 +872,7 @@ const de_InternalServiceFaultRes = async (parsedOutput, context) => {
|
|
|
978
872
|
};
|
|
979
873
|
const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
|
|
980
874
|
const contents = map({
|
|
981
|
-
|
|
875
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
982
876
|
});
|
|
983
877
|
const data = parsedOutput.body;
|
|
984
878
|
const doc = take(data, {
|
|
@@ -993,7 +887,7 @@ const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
|
|
|
993
887
|
};
|
|
994
888
|
const de_MissingRequiredParameterExceptionRes = async (parsedOutput, context) => {
|
|
995
889
|
const contents = map({
|
|
996
|
-
|
|
890
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
997
891
|
});
|
|
998
892
|
const data = parsedOutput.body;
|
|
999
893
|
const doc = take(data, {
|
|
@@ -1008,7 +902,7 @@ const de_MissingRequiredParameterExceptionRes = async (parsedOutput, context) =>
|
|
|
1008
902
|
};
|
|
1009
903
|
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
1010
904
|
const contents = map({
|
|
1011
|
-
|
|
905
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1012
906
|
});
|
|
1013
907
|
const data = parsedOutput.body;
|
|
1014
908
|
const doc = take(data, {
|
|
@@ -1023,7 +917,7 @@ const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
|
1023
917
|
};
|
|
1024
918
|
const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
|
|
1025
919
|
const contents = map({
|
|
1026
|
-
|
|
920
|
+
[_aET]: [, parsedOutput.headers[_xae]],
|
|
1027
921
|
});
|
|
1028
922
|
const data = parsedOutput.body;
|
|
1029
923
|
const doc = take(data, {
|
|
@@ -1074,6 +968,10 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
|
1074
968
|
value !== "" &&
|
|
1075
969
|
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
1076
970
|
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
971
|
+
const _TK = "TagKeys";
|
|
972
|
+
const _aET = "amznErrorType";
|
|
973
|
+
const _tK = "tagKeys";
|
|
974
|
+
const _xae = "x-amzn-errortype";
|
|
1077
975
|
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
1078
976
|
if (encoded.length) {
|
|
1079
977
|
return JSON.parse(encoded);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-oam",
|
|
3
3
|
"description": "AWS SDK for JavaScript Oam Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.477.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
@@ -20,9 +20,9 @@
|
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@aws-crypto/sha256-browser": "3.0.0",
|
|
22
22
|
"@aws-crypto/sha256-js": "3.0.0",
|
|
23
|
-
"@aws-sdk/client-sts": "3.
|
|
24
|
-
"@aws-sdk/core": "3.
|
|
25
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
23
|
+
"@aws-sdk/client-sts": "3.477.0",
|
|
24
|
+
"@aws-sdk/core": "3.477.0",
|
|
25
|
+
"@aws-sdk/credential-provider-node": "3.477.0",
|
|
26
26
|
"@aws-sdk/middleware-host-header": "3.468.0",
|
|
27
27
|
"@aws-sdk/middleware-logger": "3.468.0",
|
|
28
28
|
"@aws-sdk/middleware-recursion-detection": "3.468.0",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"@aws-sdk/util-user-agent-browser": "3.468.0",
|
|
35
35
|
"@aws-sdk/util-user-agent-node": "3.470.0",
|
|
36
36
|
"@smithy/config-resolver": "^2.0.21",
|
|
37
|
+
"@smithy/core": "^1.2.0",
|
|
37
38
|
"@smithy/fetch-http-handler": "^2.3.1",
|
|
38
39
|
"@smithy/hash-node": "^2.0.17",
|
|
39
40
|
"@smithy/invalid-dependency": "^2.0.15",
|