@aws-sdk/client-ivs 3.489.0 → 3.495.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/Ivs.js +1 -71
- package/dist-cjs/IvsClient.js +1 -43
- package/dist-cjs/commands/BatchGetChannelCommand.js +1 -28
- package/dist-cjs/commands/BatchGetStreamKeyCommand.js +1 -29
- package/dist-cjs/commands/BatchStartViewerSessionRevocationCommand.js +1 -28
- package/dist-cjs/commands/CreateChannelCommand.js +1 -29
- package/dist-cjs/commands/CreateRecordingConfigurationCommand.js +1 -28
- package/dist-cjs/commands/CreateStreamKeyCommand.js +1 -29
- package/dist-cjs/commands/DeleteChannelCommand.js +1 -28
- package/dist-cjs/commands/DeletePlaybackKeyPairCommand.js +1 -28
- package/dist-cjs/commands/DeleteRecordingConfigurationCommand.js +1 -28
- package/dist-cjs/commands/DeleteStreamKeyCommand.js +1 -28
- package/dist-cjs/commands/GetChannelCommand.js +1 -28
- package/dist-cjs/commands/GetPlaybackKeyPairCommand.js +1 -28
- package/dist-cjs/commands/GetRecordingConfigurationCommand.js +1 -28
- package/dist-cjs/commands/GetStreamCommand.js +1 -28
- package/dist-cjs/commands/GetStreamKeyCommand.js +1 -29
- package/dist-cjs/commands/GetStreamSessionCommand.js +1 -28
- package/dist-cjs/commands/ImportPlaybackKeyPairCommand.js +1 -28
- package/dist-cjs/commands/ListChannelsCommand.js +1 -28
- package/dist-cjs/commands/ListPlaybackKeyPairsCommand.js +1 -28
- package/dist-cjs/commands/ListRecordingConfigurationsCommand.js +1 -28
- package/dist-cjs/commands/ListStreamKeysCommand.js +1 -28
- package/dist-cjs/commands/ListStreamSessionsCommand.js +1 -28
- package/dist-cjs/commands/ListStreamsCommand.js +1 -28
- package/dist-cjs/commands/ListTagsForResourceCommand.js +1 -28
- package/dist-cjs/commands/PutMetadataCommand.js +1 -29
- package/dist-cjs/commands/StartViewerSessionRevocationCommand.js +1 -28
- package/dist-cjs/commands/StopStreamCommand.js +1 -28
- package/dist-cjs/commands/TagResourceCommand.js +1 -28
- package/dist-cjs/commands/UntagResourceCommand.js +1 -28
- package/dist-cjs/commands/UpdateChannelCommand.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 +3027 -11
- package/dist-cjs/models/IvsServiceException.js +1 -12
- package/dist-cjs/models/index.js +1 -4
- package/dist-cjs/models/models_0.js +1 -228
- package/dist-cjs/pagination/Interfaces.js +1 -2
- package/dist-cjs/pagination/ListChannelsPaginator.js +1 -7
- package/dist-cjs/pagination/ListPlaybackKeyPairsPaginator.js +1 -7
- package/dist-cjs/pagination/ListRecordingConfigurationsPaginator.js +1 -7
- package/dist-cjs/pagination/ListStreamKeysPaginator.js +1 -7
- package/dist-cjs/pagination/ListStreamSessionsPaginator.js +1 -7
- package/dist-cjs/pagination/ListStreamsPaginator.js +1 -7
- package/dist-cjs/pagination/index.js +1 -10
- package/dist-cjs/protocols/Aws_restJson1.js +1 -1943
- package/dist-cjs/runtimeExtensions.js +1 -22
- package/package.json +40 -40
|
@@ -1,1943 +1 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.de_ListRecordingConfigurationsCommand = exports.de_ListPlaybackKeyPairsCommand = exports.de_ListChannelsCommand = exports.de_ImportPlaybackKeyPairCommand = exports.de_GetStreamSessionCommand = exports.de_GetStreamKeyCommand = exports.de_GetStreamCommand = exports.de_GetRecordingConfigurationCommand = exports.de_GetPlaybackKeyPairCommand = exports.de_GetChannelCommand = exports.de_DeleteStreamKeyCommand = exports.de_DeleteRecordingConfigurationCommand = exports.de_DeletePlaybackKeyPairCommand = exports.de_DeleteChannelCommand = exports.de_CreateStreamKeyCommand = exports.de_CreateRecordingConfigurationCommand = exports.de_CreateChannelCommand = exports.de_BatchStartViewerSessionRevocationCommand = exports.de_BatchGetStreamKeyCommand = exports.de_BatchGetChannelCommand = exports.se_UpdateChannelCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_StopStreamCommand = exports.se_StartViewerSessionRevocationCommand = exports.se_PutMetadataCommand = exports.se_ListTagsForResourceCommand = exports.se_ListStreamSessionsCommand = exports.se_ListStreamsCommand = exports.se_ListStreamKeysCommand = exports.se_ListRecordingConfigurationsCommand = exports.se_ListPlaybackKeyPairsCommand = exports.se_ListChannelsCommand = exports.se_ImportPlaybackKeyPairCommand = exports.se_GetStreamSessionCommand = exports.se_GetStreamKeyCommand = exports.se_GetStreamCommand = exports.se_GetRecordingConfigurationCommand = exports.se_GetPlaybackKeyPairCommand = exports.se_GetChannelCommand = exports.se_DeleteStreamKeyCommand = exports.se_DeleteRecordingConfigurationCommand = exports.se_DeletePlaybackKeyPairCommand = exports.se_DeleteChannelCommand = exports.se_CreateStreamKeyCommand = exports.se_CreateRecordingConfigurationCommand = exports.se_CreateChannelCommand = exports.se_BatchStartViewerSessionRevocationCommand = exports.se_BatchGetStreamKeyCommand = exports.se_BatchGetChannelCommand = void 0;
|
|
4
|
-
exports.de_UpdateChannelCommand = exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_StopStreamCommand = exports.de_StartViewerSessionRevocationCommand = exports.de_PutMetadataCommand = exports.de_ListTagsForResourceCommand = exports.de_ListStreamSessionsCommand = exports.de_ListStreamsCommand = exports.de_ListStreamKeysCommand = void 0;
|
|
5
|
-
const core_1 = require("@smithy/core");
|
|
6
|
-
const smithy_client_1 = require("@smithy/smithy-client");
|
|
7
|
-
const IvsServiceException_1 = require("../models/IvsServiceException");
|
|
8
|
-
const models_0_1 = require("../models/models_0");
|
|
9
|
-
const se_BatchGetChannelCommand = async (input, context) => {
|
|
10
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
11
|
-
const headers = {
|
|
12
|
-
"content-type": "application/json",
|
|
13
|
-
};
|
|
14
|
-
b.bp("/BatchGetChannel");
|
|
15
|
-
let body;
|
|
16
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
17
|
-
arns: (_) => (0, smithy_client_1._json)(_),
|
|
18
|
-
}));
|
|
19
|
-
b.m("POST").h(headers).b(body);
|
|
20
|
-
return b.build();
|
|
21
|
-
};
|
|
22
|
-
exports.se_BatchGetChannelCommand = se_BatchGetChannelCommand;
|
|
23
|
-
const se_BatchGetStreamKeyCommand = async (input, context) => {
|
|
24
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
25
|
-
const headers = {
|
|
26
|
-
"content-type": "application/json",
|
|
27
|
-
};
|
|
28
|
-
b.bp("/BatchGetStreamKey");
|
|
29
|
-
let body;
|
|
30
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
31
|
-
arns: (_) => (0, smithy_client_1._json)(_),
|
|
32
|
-
}));
|
|
33
|
-
b.m("POST").h(headers).b(body);
|
|
34
|
-
return b.build();
|
|
35
|
-
};
|
|
36
|
-
exports.se_BatchGetStreamKeyCommand = se_BatchGetStreamKeyCommand;
|
|
37
|
-
const se_BatchStartViewerSessionRevocationCommand = async (input, context) => {
|
|
38
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
39
|
-
const headers = {
|
|
40
|
-
"content-type": "application/json",
|
|
41
|
-
};
|
|
42
|
-
b.bp("/BatchStartViewerSessionRevocation");
|
|
43
|
-
let body;
|
|
44
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
45
|
-
viewerSessions: (_) => (0, smithy_client_1._json)(_),
|
|
46
|
-
}));
|
|
47
|
-
b.m("POST").h(headers).b(body);
|
|
48
|
-
return b.build();
|
|
49
|
-
};
|
|
50
|
-
exports.se_BatchStartViewerSessionRevocationCommand = se_BatchStartViewerSessionRevocationCommand;
|
|
51
|
-
const se_CreateChannelCommand = async (input, context) => {
|
|
52
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
53
|
-
const headers = {
|
|
54
|
-
"content-type": "application/json",
|
|
55
|
-
};
|
|
56
|
-
b.bp("/CreateChannel");
|
|
57
|
-
let body;
|
|
58
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
59
|
-
authorized: [],
|
|
60
|
-
insecureIngest: [],
|
|
61
|
-
latencyMode: [],
|
|
62
|
-
name: [],
|
|
63
|
-
preset: [],
|
|
64
|
-
recordingConfigurationArn: [],
|
|
65
|
-
tags: (_) => (0, smithy_client_1._json)(_),
|
|
66
|
-
type: [],
|
|
67
|
-
}));
|
|
68
|
-
b.m("POST").h(headers).b(body);
|
|
69
|
-
return b.build();
|
|
70
|
-
};
|
|
71
|
-
exports.se_CreateChannelCommand = se_CreateChannelCommand;
|
|
72
|
-
const se_CreateRecordingConfigurationCommand = async (input, context) => {
|
|
73
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
74
|
-
const headers = {
|
|
75
|
-
"content-type": "application/json",
|
|
76
|
-
};
|
|
77
|
-
b.bp("/CreateRecordingConfiguration");
|
|
78
|
-
let body;
|
|
79
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
80
|
-
destinationConfiguration: (_) => (0, smithy_client_1._json)(_),
|
|
81
|
-
name: [],
|
|
82
|
-
recordingReconnectWindowSeconds: [],
|
|
83
|
-
renditionConfiguration: (_) => (0, smithy_client_1._json)(_),
|
|
84
|
-
tags: (_) => (0, smithy_client_1._json)(_),
|
|
85
|
-
thumbnailConfiguration: (_) => (0, smithy_client_1._json)(_),
|
|
86
|
-
}));
|
|
87
|
-
b.m("POST").h(headers).b(body);
|
|
88
|
-
return b.build();
|
|
89
|
-
};
|
|
90
|
-
exports.se_CreateRecordingConfigurationCommand = se_CreateRecordingConfigurationCommand;
|
|
91
|
-
const se_CreateStreamKeyCommand = async (input, context) => {
|
|
92
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
93
|
-
const headers = {
|
|
94
|
-
"content-type": "application/json",
|
|
95
|
-
};
|
|
96
|
-
b.bp("/CreateStreamKey");
|
|
97
|
-
let body;
|
|
98
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
99
|
-
channelArn: [],
|
|
100
|
-
tags: (_) => (0, smithy_client_1._json)(_),
|
|
101
|
-
}));
|
|
102
|
-
b.m("POST").h(headers).b(body);
|
|
103
|
-
return b.build();
|
|
104
|
-
};
|
|
105
|
-
exports.se_CreateStreamKeyCommand = se_CreateStreamKeyCommand;
|
|
106
|
-
const se_DeleteChannelCommand = async (input, context) => {
|
|
107
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
108
|
-
const headers = {
|
|
109
|
-
"content-type": "application/json",
|
|
110
|
-
};
|
|
111
|
-
b.bp("/DeleteChannel");
|
|
112
|
-
let body;
|
|
113
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
114
|
-
arn: [],
|
|
115
|
-
}));
|
|
116
|
-
b.m("POST").h(headers).b(body);
|
|
117
|
-
return b.build();
|
|
118
|
-
};
|
|
119
|
-
exports.se_DeleteChannelCommand = se_DeleteChannelCommand;
|
|
120
|
-
const se_DeletePlaybackKeyPairCommand = async (input, context) => {
|
|
121
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
122
|
-
const headers = {
|
|
123
|
-
"content-type": "application/json",
|
|
124
|
-
};
|
|
125
|
-
b.bp("/DeletePlaybackKeyPair");
|
|
126
|
-
let body;
|
|
127
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
128
|
-
arn: [],
|
|
129
|
-
}));
|
|
130
|
-
b.m("POST").h(headers).b(body);
|
|
131
|
-
return b.build();
|
|
132
|
-
};
|
|
133
|
-
exports.se_DeletePlaybackKeyPairCommand = se_DeletePlaybackKeyPairCommand;
|
|
134
|
-
const se_DeleteRecordingConfigurationCommand = async (input, context) => {
|
|
135
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
136
|
-
const headers = {
|
|
137
|
-
"content-type": "application/json",
|
|
138
|
-
};
|
|
139
|
-
b.bp("/DeleteRecordingConfiguration");
|
|
140
|
-
let body;
|
|
141
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
142
|
-
arn: [],
|
|
143
|
-
}));
|
|
144
|
-
b.m("POST").h(headers).b(body);
|
|
145
|
-
return b.build();
|
|
146
|
-
};
|
|
147
|
-
exports.se_DeleteRecordingConfigurationCommand = se_DeleteRecordingConfigurationCommand;
|
|
148
|
-
const se_DeleteStreamKeyCommand = async (input, context) => {
|
|
149
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
150
|
-
const headers = {
|
|
151
|
-
"content-type": "application/json",
|
|
152
|
-
};
|
|
153
|
-
b.bp("/DeleteStreamKey");
|
|
154
|
-
let body;
|
|
155
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
156
|
-
arn: [],
|
|
157
|
-
}));
|
|
158
|
-
b.m("POST").h(headers).b(body);
|
|
159
|
-
return b.build();
|
|
160
|
-
};
|
|
161
|
-
exports.se_DeleteStreamKeyCommand = se_DeleteStreamKeyCommand;
|
|
162
|
-
const se_GetChannelCommand = async (input, context) => {
|
|
163
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
164
|
-
const headers = {
|
|
165
|
-
"content-type": "application/json",
|
|
166
|
-
};
|
|
167
|
-
b.bp("/GetChannel");
|
|
168
|
-
let body;
|
|
169
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
170
|
-
arn: [],
|
|
171
|
-
}));
|
|
172
|
-
b.m("POST").h(headers).b(body);
|
|
173
|
-
return b.build();
|
|
174
|
-
};
|
|
175
|
-
exports.se_GetChannelCommand = se_GetChannelCommand;
|
|
176
|
-
const se_GetPlaybackKeyPairCommand = async (input, context) => {
|
|
177
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
178
|
-
const headers = {
|
|
179
|
-
"content-type": "application/json",
|
|
180
|
-
};
|
|
181
|
-
b.bp("/GetPlaybackKeyPair");
|
|
182
|
-
let body;
|
|
183
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
184
|
-
arn: [],
|
|
185
|
-
}));
|
|
186
|
-
b.m("POST").h(headers).b(body);
|
|
187
|
-
return b.build();
|
|
188
|
-
};
|
|
189
|
-
exports.se_GetPlaybackKeyPairCommand = se_GetPlaybackKeyPairCommand;
|
|
190
|
-
const se_GetRecordingConfigurationCommand = async (input, context) => {
|
|
191
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
192
|
-
const headers = {
|
|
193
|
-
"content-type": "application/json",
|
|
194
|
-
};
|
|
195
|
-
b.bp("/GetRecordingConfiguration");
|
|
196
|
-
let body;
|
|
197
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
198
|
-
arn: [],
|
|
199
|
-
}));
|
|
200
|
-
b.m("POST").h(headers).b(body);
|
|
201
|
-
return b.build();
|
|
202
|
-
};
|
|
203
|
-
exports.se_GetRecordingConfigurationCommand = se_GetRecordingConfigurationCommand;
|
|
204
|
-
const se_GetStreamCommand = async (input, context) => {
|
|
205
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
206
|
-
const headers = {
|
|
207
|
-
"content-type": "application/json",
|
|
208
|
-
};
|
|
209
|
-
b.bp("/GetStream");
|
|
210
|
-
let body;
|
|
211
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
212
|
-
channelArn: [],
|
|
213
|
-
}));
|
|
214
|
-
b.m("POST").h(headers).b(body);
|
|
215
|
-
return b.build();
|
|
216
|
-
};
|
|
217
|
-
exports.se_GetStreamCommand = se_GetStreamCommand;
|
|
218
|
-
const se_GetStreamKeyCommand = async (input, context) => {
|
|
219
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
220
|
-
const headers = {
|
|
221
|
-
"content-type": "application/json",
|
|
222
|
-
};
|
|
223
|
-
b.bp("/GetStreamKey");
|
|
224
|
-
let body;
|
|
225
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
226
|
-
arn: [],
|
|
227
|
-
}));
|
|
228
|
-
b.m("POST").h(headers).b(body);
|
|
229
|
-
return b.build();
|
|
230
|
-
};
|
|
231
|
-
exports.se_GetStreamKeyCommand = se_GetStreamKeyCommand;
|
|
232
|
-
const se_GetStreamSessionCommand = async (input, context) => {
|
|
233
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
234
|
-
const headers = {
|
|
235
|
-
"content-type": "application/json",
|
|
236
|
-
};
|
|
237
|
-
b.bp("/GetStreamSession");
|
|
238
|
-
let body;
|
|
239
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
240
|
-
channelArn: [],
|
|
241
|
-
streamId: [],
|
|
242
|
-
}));
|
|
243
|
-
b.m("POST").h(headers).b(body);
|
|
244
|
-
return b.build();
|
|
245
|
-
};
|
|
246
|
-
exports.se_GetStreamSessionCommand = se_GetStreamSessionCommand;
|
|
247
|
-
const se_ImportPlaybackKeyPairCommand = async (input, context) => {
|
|
248
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
249
|
-
const headers = {
|
|
250
|
-
"content-type": "application/json",
|
|
251
|
-
};
|
|
252
|
-
b.bp("/ImportPlaybackKeyPair");
|
|
253
|
-
let body;
|
|
254
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
255
|
-
name: [],
|
|
256
|
-
publicKeyMaterial: [],
|
|
257
|
-
tags: (_) => (0, smithy_client_1._json)(_),
|
|
258
|
-
}));
|
|
259
|
-
b.m("POST").h(headers).b(body);
|
|
260
|
-
return b.build();
|
|
261
|
-
};
|
|
262
|
-
exports.se_ImportPlaybackKeyPairCommand = se_ImportPlaybackKeyPairCommand;
|
|
263
|
-
const se_ListChannelsCommand = async (input, context) => {
|
|
264
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
265
|
-
const headers = {
|
|
266
|
-
"content-type": "application/json",
|
|
267
|
-
};
|
|
268
|
-
b.bp("/ListChannels");
|
|
269
|
-
let body;
|
|
270
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
271
|
-
filterByName: [],
|
|
272
|
-
filterByRecordingConfigurationArn: [],
|
|
273
|
-
maxResults: [],
|
|
274
|
-
nextToken: [],
|
|
275
|
-
}));
|
|
276
|
-
b.m("POST").h(headers).b(body);
|
|
277
|
-
return b.build();
|
|
278
|
-
};
|
|
279
|
-
exports.se_ListChannelsCommand = se_ListChannelsCommand;
|
|
280
|
-
const se_ListPlaybackKeyPairsCommand = async (input, context) => {
|
|
281
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
282
|
-
const headers = {
|
|
283
|
-
"content-type": "application/json",
|
|
284
|
-
};
|
|
285
|
-
b.bp("/ListPlaybackKeyPairs");
|
|
286
|
-
let body;
|
|
287
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
288
|
-
maxResults: [],
|
|
289
|
-
nextToken: [],
|
|
290
|
-
}));
|
|
291
|
-
b.m("POST").h(headers).b(body);
|
|
292
|
-
return b.build();
|
|
293
|
-
};
|
|
294
|
-
exports.se_ListPlaybackKeyPairsCommand = se_ListPlaybackKeyPairsCommand;
|
|
295
|
-
const se_ListRecordingConfigurationsCommand = async (input, context) => {
|
|
296
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
297
|
-
const headers = {
|
|
298
|
-
"content-type": "application/json",
|
|
299
|
-
};
|
|
300
|
-
b.bp("/ListRecordingConfigurations");
|
|
301
|
-
let body;
|
|
302
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
303
|
-
maxResults: [],
|
|
304
|
-
nextToken: [],
|
|
305
|
-
}));
|
|
306
|
-
b.m("POST").h(headers).b(body);
|
|
307
|
-
return b.build();
|
|
308
|
-
};
|
|
309
|
-
exports.se_ListRecordingConfigurationsCommand = se_ListRecordingConfigurationsCommand;
|
|
310
|
-
const se_ListStreamKeysCommand = async (input, context) => {
|
|
311
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
312
|
-
const headers = {
|
|
313
|
-
"content-type": "application/json",
|
|
314
|
-
};
|
|
315
|
-
b.bp("/ListStreamKeys");
|
|
316
|
-
let body;
|
|
317
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
318
|
-
channelArn: [],
|
|
319
|
-
maxResults: [],
|
|
320
|
-
nextToken: [],
|
|
321
|
-
}));
|
|
322
|
-
b.m("POST").h(headers).b(body);
|
|
323
|
-
return b.build();
|
|
324
|
-
};
|
|
325
|
-
exports.se_ListStreamKeysCommand = se_ListStreamKeysCommand;
|
|
326
|
-
const se_ListStreamsCommand = async (input, context) => {
|
|
327
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
328
|
-
const headers = {
|
|
329
|
-
"content-type": "application/json",
|
|
330
|
-
};
|
|
331
|
-
b.bp("/ListStreams");
|
|
332
|
-
let body;
|
|
333
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
334
|
-
filterBy: (_) => (0, smithy_client_1._json)(_),
|
|
335
|
-
maxResults: [],
|
|
336
|
-
nextToken: [],
|
|
337
|
-
}));
|
|
338
|
-
b.m("POST").h(headers).b(body);
|
|
339
|
-
return b.build();
|
|
340
|
-
};
|
|
341
|
-
exports.se_ListStreamsCommand = se_ListStreamsCommand;
|
|
342
|
-
const se_ListStreamSessionsCommand = async (input, context) => {
|
|
343
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
344
|
-
const headers = {
|
|
345
|
-
"content-type": "application/json",
|
|
346
|
-
};
|
|
347
|
-
b.bp("/ListStreamSessions");
|
|
348
|
-
let body;
|
|
349
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
350
|
-
channelArn: [],
|
|
351
|
-
maxResults: [],
|
|
352
|
-
nextToken: [],
|
|
353
|
-
}));
|
|
354
|
-
b.m("POST").h(headers).b(body);
|
|
355
|
-
return b.build();
|
|
356
|
-
};
|
|
357
|
-
exports.se_ListStreamSessionsCommand = se_ListStreamSessionsCommand;
|
|
358
|
-
const se_ListTagsForResourceCommand = async (input, context) => {
|
|
359
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
360
|
-
const headers = {};
|
|
361
|
-
b.bp("/tags/{resourceArn}");
|
|
362
|
-
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
363
|
-
let body;
|
|
364
|
-
b.m("GET").h(headers).b(body);
|
|
365
|
-
return b.build();
|
|
366
|
-
};
|
|
367
|
-
exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
|
|
368
|
-
const se_PutMetadataCommand = async (input, context) => {
|
|
369
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
370
|
-
const headers = {
|
|
371
|
-
"content-type": "application/json",
|
|
372
|
-
};
|
|
373
|
-
b.bp("/PutMetadata");
|
|
374
|
-
let body;
|
|
375
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
376
|
-
channelArn: [],
|
|
377
|
-
metadata: [],
|
|
378
|
-
}));
|
|
379
|
-
b.m("POST").h(headers).b(body);
|
|
380
|
-
return b.build();
|
|
381
|
-
};
|
|
382
|
-
exports.se_PutMetadataCommand = se_PutMetadataCommand;
|
|
383
|
-
const se_StartViewerSessionRevocationCommand = async (input, context) => {
|
|
384
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
385
|
-
const headers = {
|
|
386
|
-
"content-type": "application/json",
|
|
387
|
-
};
|
|
388
|
-
b.bp("/StartViewerSessionRevocation");
|
|
389
|
-
let body;
|
|
390
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
391
|
-
channelArn: [],
|
|
392
|
-
viewerId: [],
|
|
393
|
-
viewerSessionVersionsLessThanOrEqualTo: [],
|
|
394
|
-
}));
|
|
395
|
-
b.m("POST").h(headers).b(body);
|
|
396
|
-
return b.build();
|
|
397
|
-
};
|
|
398
|
-
exports.se_StartViewerSessionRevocationCommand = se_StartViewerSessionRevocationCommand;
|
|
399
|
-
const se_StopStreamCommand = async (input, context) => {
|
|
400
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
401
|
-
const headers = {
|
|
402
|
-
"content-type": "application/json",
|
|
403
|
-
};
|
|
404
|
-
b.bp("/StopStream");
|
|
405
|
-
let body;
|
|
406
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
407
|
-
channelArn: [],
|
|
408
|
-
}));
|
|
409
|
-
b.m("POST").h(headers).b(body);
|
|
410
|
-
return b.build();
|
|
411
|
-
};
|
|
412
|
-
exports.se_StopStreamCommand = se_StopStreamCommand;
|
|
413
|
-
const se_TagResourceCommand = async (input, context) => {
|
|
414
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
415
|
-
const headers = {
|
|
416
|
-
"content-type": "application/json",
|
|
417
|
-
};
|
|
418
|
-
b.bp("/tags/{resourceArn}");
|
|
419
|
-
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
420
|
-
let body;
|
|
421
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
422
|
-
tags: (_) => (0, smithy_client_1._json)(_),
|
|
423
|
-
}));
|
|
424
|
-
b.m("POST").h(headers).b(body);
|
|
425
|
-
return b.build();
|
|
426
|
-
};
|
|
427
|
-
exports.se_TagResourceCommand = se_TagResourceCommand;
|
|
428
|
-
const se_UntagResourceCommand = async (input, context) => {
|
|
429
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
430
|
-
const headers = {};
|
|
431
|
-
b.bp("/tags/{resourceArn}");
|
|
432
|
-
b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
|
|
433
|
-
const query = (0, smithy_client_1.map)({
|
|
434
|
-
[_tK]: [
|
|
435
|
-
(0, smithy_client_1.expectNonNull)(input.tagKeys, `tagKeys`) != null,
|
|
436
|
-
() => (input[_tK] || []).map((_entry) => _entry),
|
|
437
|
-
],
|
|
438
|
-
});
|
|
439
|
-
let body;
|
|
440
|
-
b.m("DELETE").h(headers).q(query).b(body);
|
|
441
|
-
return b.build();
|
|
442
|
-
};
|
|
443
|
-
exports.se_UntagResourceCommand = se_UntagResourceCommand;
|
|
444
|
-
const se_UpdateChannelCommand = async (input, context) => {
|
|
445
|
-
const b = (0, core_1.requestBuilder)(input, context);
|
|
446
|
-
const headers = {
|
|
447
|
-
"content-type": "application/json",
|
|
448
|
-
};
|
|
449
|
-
b.bp("/UpdateChannel");
|
|
450
|
-
let body;
|
|
451
|
-
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
452
|
-
arn: [],
|
|
453
|
-
authorized: [],
|
|
454
|
-
insecureIngest: [],
|
|
455
|
-
latencyMode: [],
|
|
456
|
-
name: [],
|
|
457
|
-
preset: [],
|
|
458
|
-
recordingConfigurationArn: [],
|
|
459
|
-
type: [],
|
|
460
|
-
}));
|
|
461
|
-
b.m("POST").h(headers).b(body);
|
|
462
|
-
return b.build();
|
|
463
|
-
};
|
|
464
|
-
exports.se_UpdateChannelCommand = se_UpdateChannelCommand;
|
|
465
|
-
const de_BatchGetChannelCommand = async (output, context) => {
|
|
466
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
467
|
-
return de_BatchGetChannelCommandError(output, context);
|
|
468
|
-
}
|
|
469
|
-
const contents = (0, smithy_client_1.map)({
|
|
470
|
-
$metadata: deserializeMetadata(output),
|
|
471
|
-
});
|
|
472
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
473
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
474
|
-
channels: smithy_client_1._json,
|
|
475
|
-
errors: smithy_client_1._json,
|
|
476
|
-
});
|
|
477
|
-
Object.assign(contents, doc);
|
|
478
|
-
return contents;
|
|
479
|
-
};
|
|
480
|
-
exports.de_BatchGetChannelCommand = de_BatchGetChannelCommand;
|
|
481
|
-
const de_BatchGetChannelCommandError = async (output, context) => {
|
|
482
|
-
const parsedOutput = {
|
|
483
|
-
...output,
|
|
484
|
-
body: await parseErrorBody(output.body, context),
|
|
485
|
-
};
|
|
486
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
487
|
-
const parsedBody = parsedOutput.body;
|
|
488
|
-
return throwDefaultError({
|
|
489
|
-
output,
|
|
490
|
-
parsedBody,
|
|
491
|
-
errorCode,
|
|
492
|
-
});
|
|
493
|
-
};
|
|
494
|
-
const de_BatchGetStreamKeyCommand = async (output, context) => {
|
|
495
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
496
|
-
return de_BatchGetStreamKeyCommandError(output, context);
|
|
497
|
-
}
|
|
498
|
-
const contents = (0, smithy_client_1.map)({
|
|
499
|
-
$metadata: deserializeMetadata(output),
|
|
500
|
-
});
|
|
501
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
502
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
503
|
-
errors: smithy_client_1._json,
|
|
504
|
-
streamKeys: smithy_client_1._json,
|
|
505
|
-
});
|
|
506
|
-
Object.assign(contents, doc);
|
|
507
|
-
return contents;
|
|
508
|
-
};
|
|
509
|
-
exports.de_BatchGetStreamKeyCommand = de_BatchGetStreamKeyCommand;
|
|
510
|
-
const de_BatchGetStreamKeyCommandError = async (output, context) => {
|
|
511
|
-
const parsedOutput = {
|
|
512
|
-
...output,
|
|
513
|
-
body: await parseErrorBody(output.body, context),
|
|
514
|
-
};
|
|
515
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
516
|
-
const parsedBody = parsedOutput.body;
|
|
517
|
-
return throwDefaultError({
|
|
518
|
-
output,
|
|
519
|
-
parsedBody,
|
|
520
|
-
errorCode,
|
|
521
|
-
});
|
|
522
|
-
};
|
|
523
|
-
const de_BatchStartViewerSessionRevocationCommand = async (output, context) => {
|
|
524
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
525
|
-
return de_BatchStartViewerSessionRevocationCommandError(output, context);
|
|
526
|
-
}
|
|
527
|
-
const contents = (0, smithy_client_1.map)({
|
|
528
|
-
$metadata: deserializeMetadata(output),
|
|
529
|
-
});
|
|
530
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
531
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
532
|
-
errors: smithy_client_1._json,
|
|
533
|
-
});
|
|
534
|
-
Object.assign(contents, doc);
|
|
535
|
-
return contents;
|
|
536
|
-
};
|
|
537
|
-
exports.de_BatchStartViewerSessionRevocationCommand = de_BatchStartViewerSessionRevocationCommand;
|
|
538
|
-
const de_BatchStartViewerSessionRevocationCommandError = async (output, context) => {
|
|
539
|
-
const parsedOutput = {
|
|
540
|
-
...output,
|
|
541
|
-
body: await parseErrorBody(output.body, context),
|
|
542
|
-
};
|
|
543
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
544
|
-
switch (errorCode) {
|
|
545
|
-
case "AccessDeniedException":
|
|
546
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
547
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
548
|
-
case "PendingVerification":
|
|
549
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
550
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
551
|
-
case "ThrottlingException":
|
|
552
|
-
case "com.amazonaws.ivs#ThrottlingException":
|
|
553
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
554
|
-
case "ValidationException":
|
|
555
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
556
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
557
|
-
default:
|
|
558
|
-
const parsedBody = parsedOutput.body;
|
|
559
|
-
return throwDefaultError({
|
|
560
|
-
output,
|
|
561
|
-
parsedBody,
|
|
562
|
-
errorCode,
|
|
563
|
-
});
|
|
564
|
-
}
|
|
565
|
-
};
|
|
566
|
-
const de_CreateChannelCommand = async (output, context) => {
|
|
567
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
568
|
-
return de_CreateChannelCommandError(output, context);
|
|
569
|
-
}
|
|
570
|
-
const contents = (0, smithy_client_1.map)({
|
|
571
|
-
$metadata: deserializeMetadata(output),
|
|
572
|
-
});
|
|
573
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
574
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
575
|
-
channel: smithy_client_1._json,
|
|
576
|
-
streamKey: smithy_client_1._json,
|
|
577
|
-
});
|
|
578
|
-
Object.assign(contents, doc);
|
|
579
|
-
return contents;
|
|
580
|
-
};
|
|
581
|
-
exports.de_CreateChannelCommand = de_CreateChannelCommand;
|
|
582
|
-
const de_CreateChannelCommandError = async (output, context) => {
|
|
583
|
-
const parsedOutput = {
|
|
584
|
-
...output,
|
|
585
|
-
body: await parseErrorBody(output.body, context),
|
|
586
|
-
};
|
|
587
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
588
|
-
switch (errorCode) {
|
|
589
|
-
case "AccessDeniedException":
|
|
590
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
591
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
592
|
-
case "PendingVerification":
|
|
593
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
594
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
595
|
-
case "ResourceNotFoundException":
|
|
596
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
597
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
598
|
-
case "ServiceQuotaExceededException":
|
|
599
|
-
case "com.amazonaws.ivs#ServiceQuotaExceededException":
|
|
600
|
-
throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
|
|
601
|
-
case "ValidationException":
|
|
602
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
603
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
604
|
-
default:
|
|
605
|
-
const parsedBody = parsedOutput.body;
|
|
606
|
-
return throwDefaultError({
|
|
607
|
-
output,
|
|
608
|
-
parsedBody,
|
|
609
|
-
errorCode,
|
|
610
|
-
});
|
|
611
|
-
}
|
|
612
|
-
};
|
|
613
|
-
const de_CreateRecordingConfigurationCommand = async (output, context) => {
|
|
614
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
615
|
-
return de_CreateRecordingConfigurationCommandError(output, context);
|
|
616
|
-
}
|
|
617
|
-
const contents = (0, smithy_client_1.map)({
|
|
618
|
-
$metadata: deserializeMetadata(output),
|
|
619
|
-
});
|
|
620
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
621
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
622
|
-
recordingConfiguration: smithy_client_1._json,
|
|
623
|
-
});
|
|
624
|
-
Object.assign(contents, doc);
|
|
625
|
-
return contents;
|
|
626
|
-
};
|
|
627
|
-
exports.de_CreateRecordingConfigurationCommand = de_CreateRecordingConfigurationCommand;
|
|
628
|
-
const de_CreateRecordingConfigurationCommandError = async (output, context) => {
|
|
629
|
-
const parsedOutput = {
|
|
630
|
-
...output,
|
|
631
|
-
body: await parseErrorBody(output.body, context),
|
|
632
|
-
};
|
|
633
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
634
|
-
switch (errorCode) {
|
|
635
|
-
case "AccessDeniedException":
|
|
636
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
637
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
638
|
-
case "ConflictException":
|
|
639
|
-
case "com.amazonaws.ivs#ConflictException":
|
|
640
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
641
|
-
case "InternalServerException":
|
|
642
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
643
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
644
|
-
case "PendingVerification":
|
|
645
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
646
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
647
|
-
case "ServiceQuotaExceededException":
|
|
648
|
-
case "com.amazonaws.ivs#ServiceQuotaExceededException":
|
|
649
|
-
throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
|
|
650
|
-
case "ValidationException":
|
|
651
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
652
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
653
|
-
default:
|
|
654
|
-
const parsedBody = parsedOutput.body;
|
|
655
|
-
return throwDefaultError({
|
|
656
|
-
output,
|
|
657
|
-
parsedBody,
|
|
658
|
-
errorCode,
|
|
659
|
-
});
|
|
660
|
-
}
|
|
661
|
-
};
|
|
662
|
-
const de_CreateStreamKeyCommand = async (output, context) => {
|
|
663
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
664
|
-
return de_CreateStreamKeyCommandError(output, context);
|
|
665
|
-
}
|
|
666
|
-
const contents = (0, smithy_client_1.map)({
|
|
667
|
-
$metadata: deserializeMetadata(output),
|
|
668
|
-
});
|
|
669
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
670
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
671
|
-
streamKey: smithy_client_1._json,
|
|
672
|
-
});
|
|
673
|
-
Object.assign(contents, doc);
|
|
674
|
-
return contents;
|
|
675
|
-
};
|
|
676
|
-
exports.de_CreateStreamKeyCommand = de_CreateStreamKeyCommand;
|
|
677
|
-
const de_CreateStreamKeyCommandError = async (output, context) => {
|
|
678
|
-
const parsedOutput = {
|
|
679
|
-
...output,
|
|
680
|
-
body: await parseErrorBody(output.body, context),
|
|
681
|
-
};
|
|
682
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
683
|
-
switch (errorCode) {
|
|
684
|
-
case "AccessDeniedException":
|
|
685
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
686
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
687
|
-
case "PendingVerification":
|
|
688
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
689
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
690
|
-
case "ResourceNotFoundException":
|
|
691
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
692
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
693
|
-
case "ServiceQuotaExceededException":
|
|
694
|
-
case "com.amazonaws.ivs#ServiceQuotaExceededException":
|
|
695
|
-
throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
|
|
696
|
-
case "ValidationException":
|
|
697
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
698
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
699
|
-
default:
|
|
700
|
-
const parsedBody = parsedOutput.body;
|
|
701
|
-
return throwDefaultError({
|
|
702
|
-
output,
|
|
703
|
-
parsedBody,
|
|
704
|
-
errorCode,
|
|
705
|
-
});
|
|
706
|
-
}
|
|
707
|
-
};
|
|
708
|
-
const de_DeleteChannelCommand = async (output, context) => {
|
|
709
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
710
|
-
return de_DeleteChannelCommandError(output, context);
|
|
711
|
-
}
|
|
712
|
-
const contents = (0, smithy_client_1.map)({
|
|
713
|
-
$metadata: deserializeMetadata(output),
|
|
714
|
-
});
|
|
715
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
716
|
-
return contents;
|
|
717
|
-
};
|
|
718
|
-
exports.de_DeleteChannelCommand = de_DeleteChannelCommand;
|
|
719
|
-
const de_DeleteChannelCommandError = async (output, context) => {
|
|
720
|
-
const parsedOutput = {
|
|
721
|
-
...output,
|
|
722
|
-
body: await parseErrorBody(output.body, context),
|
|
723
|
-
};
|
|
724
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
725
|
-
switch (errorCode) {
|
|
726
|
-
case "AccessDeniedException":
|
|
727
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
728
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
729
|
-
case "ConflictException":
|
|
730
|
-
case "com.amazonaws.ivs#ConflictException":
|
|
731
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
732
|
-
case "PendingVerification":
|
|
733
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
734
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
735
|
-
case "ResourceNotFoundException":
|
|
736
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
737
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
738
|
-
case "ValidationException":
|
|
739
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
740
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
741
|
-
default:
|
|
742
|
-
const parsedBody = parsedOutput.body;
|
|
743
|
-
return throwDefaultError({
|
|
744
|
-
output,
|
|
745
|
-
parsedBody,
|
|
746
|
-
errorCode,
|
|
747
|
-
});
|
|
748
|
-
}
|
|
749
|
-
};
|
|
750
|
-
const de_DeletePlaybackKeyPairCommand = async (output, context) => {
|
|
751
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
752
|
-
return de_DeletePlaybackKeyPairCommandError(output, context);
|
|
753
|
-
}
|
|
754
|
-
const contents = (0, smithy_client_1.map)({
|
|
755
|
-
$metadata: deserializeMetadata(output),
|
|
756
|
-
});
|
|
757
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
758
|
-
return contents;
|
|
759
|
-
};
|
|
760
|
-
exports.de_DeletePlaybackKeyPairCommand = de_DeletePlaybackKeyPairCommand;
|
|
761
|
-
const de_DeletePlaybackKeyPairCommandError = async (output, context) => {
|
|
762
|
-
const parsedOutput = {
|
|
763
|
-
...output,
|
|
764
|
-
body: await parseErrorBody(output.body, context),
|
|
765
|
-
};
|
|
766
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
767
|
-
switch (errorCode) {
|
|
768
|
-
case "AccessDeniedException":
|
|
769
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
770
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
771
|
-
case "PendingVerification":
|
|
772
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
773
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
774
|
-
case "ResourceNotFoundException":
|
|
775
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
776
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
777
|
-
case "ValidationException":
|
|
778
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
779
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
780
|
-
default:
|
|
781
|
-
const parsedBody = parsedOutput.body;
|
|
782
|
-
return throwDefaultError({
|
|
783
|
-
output,
|
|
784
|
-
parsedBody,
|
|
785
|
-
errorCode,
|
|
786
|
-
});
|
|
787
|
-
}
|
|
788
|
-
};
|
|
789
|
-
const de_DeleteRecordingConfigurationCommand = async (output, context) => {
|
|
790
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
791
|
-
return de_DeleteRecordingConfigurationCommandError(output, context);
|
|
792
|
-
}
|
|
793
|
-
const contents = (0, smithy_client_1.map)({
|
|
794
|
-
$metadata: deserializeMetadata(output),
|
|
795
|
-
});
|
|
796
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
797
|
-
return contents;
|
|
798
|
-
};
|
|
799
|
-
exports.de_DeleteRecordingConfigurationCommand = de_DeleteRecordingConfigurationCommand;
|
|
800
|
-
const de_DeleteRecordingConfigurationCommandError = async (output, context) => {
|
|
801
|
-
const parsedOutput = {
|
|
802
|
-
...output,
|
|
803
|
-
body: await parseErrorBody(output.body, context),
|
|
804
|
-
};
|
|
805
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
806
|
-
switch (errorCode) {
|
|
807
|
-
case "AccessDeniedException":
|
|
808
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
809
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
810
|
-
case "ConflictException":
|
|
811
|
-
case "com.amazonaws.ivs#ConflictException":
|
|
812
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
813
|
-
case "InternalServerException":
|
|
814
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
815
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
816
|
-
case "ResourceNotFoundException":
|
|
817
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
818
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
819
|
-
case "ValidationException":
|
|
820
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
821
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
822
|
-
default:
|
|
823
|
-
const parsedBody = parsedOutput.body;
|
|
824
|
-
return throwDefaultError({
|
|
825
|
-
output,
|
|
826
|
-
parsedBody,
|
|
827
|
-
errorCode,
|
|
828
|
-
});
|
|
829
|
-
}
|
|
830
|
-
};
|
|
831
|
-
const de_DeleteStreamKeyCommand = async (output, context) => {
|
|
832
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
833
|
-
return de_DeleteStreamKeyCommandError(output, context);
|
|
834
|
-
}
|
|
835
|
-
const contents = (0, smithy_client_1.map)({
|
|
836
|
-
$metadata: deserializeMetadata(output),
|
|
837
|
-
});
|
|
838
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
839
|
-
return contents;
|
|
840
|
-
};
|
|
841
|
-
exports.de_DeleteStreamKeyCommand = de_DeleteStreamKeyCommand;
|
|
842
|
-
const de_DeleteStreamKeyCommandError = async (output, context) => {
|
|
843
|
-
const parsedOutput = {
|
|
844
|
-
...output,
|
|
845
|
-
body: await parseErrorBody(output.body, context),
|
|
846
|
-
};
|
|
847
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
848
|
-
switch (errorCode) {
|
|
849
|
-
case "AccessDeniedException":
|
|
850
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
851
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
852
|
-
case "PendingVerification":
|
|
853
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
854
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
855
|
-
case "ResourceNotFoundException":
|
|
856
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
857
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
858
|
-
case "ValidationException":
|
|
859
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
860
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
861
|
-
default:
|
|
862
|
-
const parsedBody = parsedOutput.body;
|
|
863
|
-
return throwDefaultError({
|
|
864
|
-
output,
|
|
865
|
-
parsedBody,
|
|
866
|
-
errorCode,
|
|
867
|
-
});
|
|
868
|
-
}
|
|
869
|
-
};
|
|
870
|
-
const de_GetChannelCommand = async (output, context) => {
|
|
871
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
872
|
-
return de_GetChannelCommandError(output, context);
|
|
873
|
-
}
|
|
874
|
-
const contents = (0, smithy_client_1.map)({
|
|
875
|
-
$metadata: deserializeMetadata(output),
|
|
876
|
-
});
|
|
877
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
878
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
879
|
-
channel: smithy_client_1._json,
|
|
880
|
-
});
|
|
881
|
-
Object.assign(contents, doc);
|
|
882
|
-
return contents;
|
|
883
|
-
};
|
|
884
|
-
exports.de_GetChannelCommand = de_GetChannelCommand;
|
|
885
|
-
const de_GetChannelCommandError = async (output, context) => {
|
|
886
|
-
const parsedOutput = {
|
|
887
|
-
...output,
|
|
888
|
-
body: await parseErrorBody(output.body, context),
|
|
889
|
-
};
|
|
890
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
891
|
-
switch (errorCode) {
|
|
892
|
-
case "AccessDeniedException":
|
|
893
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
894
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
895
|
-
case "ResourceNotFoundException":
|
|
896
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
897
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
898
|
-
case "ValidationException":
|
|
899
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
900
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
901
|
-
default:
|
|
902
|
-
const parsedBody = parsedOutput.body;
|
|
903
|
-
return throwDefaultError({
|
|
904
|
-
output,
|
|
905
|
-
parsedBody,
|
|
906
|
-
errorCode,
|
|
907
|
-
});
|
|
908
|
-
}
|
|
909
|
-
};
|
|
910
|
-
const de_GetPlaybackKeyPairCommand = async (output, context) => {
|
|
911
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
912
|
-
return de_GetPlaybackKeyPairCommandError(output, context);
|
|
913
|
-
}
|
|
914
|
-
const contents = (0, smithy_client_1.map)({
|
|
915
|
-
$metadata: deserializeMetadata(output),
|
|
916
|
-
});
|
|
917
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
918
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
919
|
-
keyPair: smithy_client_1._json,
|
|
920
|
-
});
|
|
921
|
-
Object.assign(contents, doc);
|
|
922
|
-
return contents;
|
|
923
|
-
};
|
|
924
|
-
exports.de_GetPlaybackKeyPairCommand = de_GetPlaybackKeyPairCommand;
|
|
925
|
-
const de_GetPlaybackKeyPairCommandError = async (output, context) => {
|
|
926
|
-
const parsedOutput = {
|
|
927
|
-
...output,
|
|
928
|
-
body: await parseErrorBody(output.body, context),
|
|
929
|
-
};
|
|
930
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
931
|
-
switch (errorCode) {
|
|
932
|
-
case "AccessDeniedException":
|
|
933
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
934
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
935
|
-
case "ResourceNotFoundException":
|
|
936
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
937
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
938
|
-
case "ValidationException":
|
|
939
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
940
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
941
|
-
default:
|
|
942
|
-
const parsedBody = parsedOutput.body;
|
|
943
|
-
return throwDefaultError({
|
|
944
|
-
output,
|
|
945
|
-
parsedBody,
|
|
946
|
-
errorCode,
|
|
947
|
-
});
|
|
948
|
-
}
|
|
949
|
-
};
|
|
950
|
-
const de_GetRecordingConfigurationCommand = async (output, context) => {
|
|
951
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
952
|
-
return de_GetRecordingConfigurationCommandError(output, context);
|
|
953
|
-
}
|
|
954
|
-
const contents = (0, smithy_client_1.map)({
|
|
955
|
-
$metadata: deserializeMetadata(output),
|
|
956
|
-
});
|
|
957
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
958
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
959
|
-
recordingConfiguration: smithy_client_1._json,
|
|
960
|
-
});
|
|
961
|
-
Object.assign(contents, doc);
|
|
962
|
-
return contents;
|
|
963
|
-
};
|
|
964
|
-
exports.de_GetRecordingConfigurationCommand = de_GetRecordingConfigurationCommand;
|
|
965
|
-
const de_GetRecordingConfigurationCommandError = async (output, context) => {
|
|
966
|
-
const parsedOutput = {
|
|
967
|
-
...output,
|
|
968
|
-
body: await parseErrorBody(output.body, context),
|
|
969
|
-
};
|
|
970
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
971
|
-
switch (errorCode) {
|
|
972
|
-
case "AccessDeniedException":
|
|
973
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
974
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
975
|
-
case "InternalServerException":
|
|
976
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
977
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
978
|
-
case "ResourceNotFoundException":
|
|
979
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
980
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
981
|
-
case "ValidationException":
|
|
982
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
983
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
984
|
-
default:
|
|
985
|
-
const parsedBody = parsedOutput.body;
|
|
986
|
-
return throwDefaultError({
|
|
987
|
-
output,
|
|
988
|
-
parsedBody,
|
|
989
|
-
errorCode,
|
|
990
|
-
});
|
|
991
|
-
}
|
|
992
|
-
};
|
|
993
|
-
const de_GetStreamCommand = async (output, context) => {
|
|
994
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
995
|
-
return de_GetStreamCommandError(output, context);
|
|
996
|
-
}
|
|
997
|
-
const contents = (0, smithy_client_1.map)({
|
|
998
|
-
$metadata: deserializeMetadata(output),
|
|
999
|
-
});
|
|
1000
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1001
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1002
|
-
stream: (_) => de__Stream(_, context),
|
|
1003
|
-
});
|
|
1004
|
-
Object.assign(contents, doc);
|
|
1005
|
-
return contents;
|
|
1006
|
-
};
|
|
1007
|
-
exports.de_GetStreamCommand = de_GetStreamCommand;
|
|
1008
|
-
const de_GetStreamCommandError = async (output, context) => {
|
|
1009
|
-
const parsedOutput = {
|
|
1010
|
-
...output,
|
|
1011
|
-
body: await parseErrorBody(output.body, context),
|
|
1012
|
-
};
|
|
1013
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1014
|
-
switch (errorCode) {
|
|
1015
|
-
case "AccessDeniedException":
|
|
1016
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1017
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1018
|
-
case "ChannelNotBroadcasting":
|
|
1019
|
-
case "com.amazonaws.ivs#ChannelNotBroadcasting":
|
|
1020
|
-
throw await de_ChannelNotBroadcastingRes(parsedOutput, context);
|
|
1021
|
-
case "ResourceNotFoundException":
|
|
1022
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1023
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1024
|
-
case "ValidationException":
|
|
1025
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1026
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1027
|
-
default:
|
|
1028
|
-
const parsedBody = parsedOutput.body;
|
|
1029
|
-
return throwDefaultError({
|
|
1030
|
-
output,
|
|
1031
|
-
parsedBody,
|
|
1032
|
-
errorCode,
|
|
1033
|
-
});
|
|
1034
|
-
}
|
|
1035
|
-
};
|
|
1036
|
-
const de_GetStreamKeyCommand = async (output, context) => {
|
|
1037
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1038
|
-
return de_GetStreamKeyCommandError(output, context);
|
|
1039
|
-
}
|
|
1040
|
-
const contents = (0, smithy_client_1.map)({
|
|
1041
|
-
$metadata: deserializeMetadata(output),
|
|
1042
|
-
});
|
|
1043
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1044
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1045
|
-
streamKey: smithy_client_1._json,
|
|
1046
|
-
});
|
|
1047
|
-
Object.assign(contents, doc);
|
|
1048
|
-
return contents;
|
|
1049
|
-
};
|
|
1050
|
-
exports.de_GetStreamKeyCommand = de_GetStreamKeyCommand;
|
|
1051
|
-
const de_GetStreamKeyCommandError = async (output, context) => {
|
|
1052
|
-
const parsedOutput = {
|
|
1053
|
-
...output,
|
|
1054
|
-
body: await parseErrorBody(output.body, context),
|
|
1055
|
-
};
|
|
1056
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1057
|
-
switch (errorCode) {
|
|
1058
|
-
case "AccessDeniedException":
|
|
1059
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1060
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1061
|
-
case "ResourceNotFoundException":
|
|
1062
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1063
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1064
|
-
case "ValidationException":
|
|
1065
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1066
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1067
|
-
default:
|
|
1068
|
-
const parsedBody = parsedOutput.body;
|
|
1069
|
-
return throwDefaultError({
|
|
1070
|
-
output,
|
|
1071
|
-
parsedBody,
|
|
1072
|
-
errorCode,
|
|
1073
|
-
});
|
|
1074
|
-
}
|
|
1075
|
-
};
|
|
1076
|
-
const de_GetStreamSessionCommand = async (output, context) => {
|
|
1077
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1078
|
-
return de_GetStreamSessionCommandError(output, context);
|
|
1079
|
-
}
|
|
1080
|
-
const contents = (0, smithy_client_1.map)({
|
|
1081
|
-
$metadata: deserializeMetadata(output),
|
|
1082
|
-
});
|
|
1083
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1084
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1085
|
-
streamSession: (_) => de_StreamSession(_, context),
|
|
1086
|
-
});
|
|
1087
|
-
Object.assign(contents, doc);
|
|
1088
|
-
return contents;
|
|
1089
|
-
};
|
|
1090
|
-
exports.de_GetStreamSessionCommand = de_GetStreamSessionCommand;
|
|
1091
|
-
const de_GetStreamSessionCommandError = async (output, context) => {
|
|
1092
|
-
const parsedOutput = {
|
|
1093
|
-
...output,
|
|
1094
|
-
body: await parseErrorBody(output.body, context),
|
|
1095
|
-
};
|
|
1096
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1097
|
-
switch (errorCode) {
|
|
1098
|
-
case "AccessDeniedException":
|
|
1099
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1100
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1101
|
-
case "ResourceNotFoundException":
|
|
1102
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1103
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1104
|
-
case "ValidationException":
|
|
1105
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1106
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1107
|
-
default:
|
|
1108
|
-
const parsedBody = parsedOutput.body;
|
|
1109
|
-
return throwDefaultError({
|
|
1110
|
-
output,
|
|
1111
|
-
parsedBody,
|
|
1112
|
-
errorCode,
|
|
1113
|
-
});
|
|
1114
|
-
}
|
|
1115
|
-
};
|
|
1116
|
-
const de_ImportPlaybackKeyPairCommand = async (output, context) => {
|
|
1117
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1118
|
-
return de_ImportPlaybackKeyPairCommandError(output, context);
|
|
1119
|
-
}
|
|
1120
|
-
const contents = (0, smithy_client_1.map)({
|
|
1121
|
-
$metadata: deserializeMetadata(output),
|
|
1122
|
-
});
|
|
1123
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1124
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1125
|
-
keyPair: smithy_client_1._json,
|
|
1126
|
-
});
|
|
1127
|
-
Object.assign(contents, doc);
|
|
1128
|
-
return contents;
|
|
1129
|
-
};
|
|
1130
|
-
exports.de_ImportPlaybackKeyPairCommand = de_ImportPlaybackKeyPairCommand;
|
|
1131
|
-
const de_ImportPlaybackKeyPairCommandError = async (output, context) => {
|
|
1132
|
-
const parsedOutput = {
|
|
1133
|
-
...output,
|
|
1134
|
-
body: await parseErrorBody(output.body, context),
|
|
1135
|
-
};
|
|
1136
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1137
|
-
switch (errorCode) {
|
|
1138
|
-
case "AccessDeniedException":
|
|
1139
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1140
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1141
|
-
case "ConflictException":
|
|
1142
|
-
case "com.amazonaws.ivs#ConflictException":
|
|
1143
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1144
|
-
case "PendingVerification":
|
|
1145
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
1146
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
1147
|
-
case "ServiceQuotaExceededException":
|
|
1148
|
-
case "com.amazonaws.ivs#ServiceQuotaExceededException":
|
|
1149
|
-
throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context);
|
|
1150
|
-
case "ValidationException":
|
|
1151
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1152
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1153
|
-
default:
|
|
1154
|
-
const parsedBody = parsedOutput.body;
|
|
1155
|
-
return throwDefaultError({
|
|
1156
|
-
output,
|
|
1157
|
-
parsedBody,
|
|
1158
|
-
errorCode,
|
|
1159
|
-
});
|
|
1160
|
-
}
|
|
1161
|
-
};
|
|
1162
|
-
const de_ListChannelsCommand = async (output, context) => {
|
|
1163
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1164
|
-
return de_ListChannelsCommandError(output, context);
|
|
1165
|
-
}
|
|
1166
|
-
const contents = (0, smithy_client_1.map)({
|
|
1167
|
-
$metadata: deserializeMetadata(output),
|
|
1168
|
-
});
|
|
1169
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1170
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1171
|
-
channels: smithy_client_1._json,
|
|
1172
|
-
nextToken: smithy_client_1.expectString,
|
|
1173
|
-
});
|
|
1174
|
-
Object.assign(contents, doc);
|
|
1175
|
-
return contents;
|
|
1176
|
-
};
|
|
1177
|
-
exports.de_ListChannelsCommand = de_ListChannelsCommand;
|
|
1178
|
-
const de_ListChannelsCommandError = async (output, context) => {
|
|
1179
|
-
const parsedOutput = {
|
|
1180
|
-
...output,
|
|
1181
|
-
body: await parseErrorBody(output.body, context),
|
|
1182
|
-
};
|
|
1183
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1184
|
-
switch (errorCode) {
|
|
1185
|
-
case "AccessDeniedException":
|
|
1186
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1187
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1188
|
-
case "ConflictException":
|
|
1189
|
-
case "com.amazonaws.ivs#ConflictException":
|
|
1190
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1191
|
-
case "ValidationException":
|
|
1192
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1193
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1194
|
-
default:
|
|
1195
|
-
const parsedBody = parsedOutput.body;
|
|
1196
|
-
return throwDefaultError({
|
|
1197
|
-
output,
|
|
1198
|
-
parsedBody,
|
|
1199
|
-
errorCode,
|
|
1200
|
-
});
|
|
1201
|
-
}
|
|
1202
|
-
};
|
|
1203
|
-
const de_ListPlaybackKeyPairsCommand = async (output, context) => {
|
|
1204
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1205
|
-
return de_ListPlaybackKeyPairsCommandError(output, context);
|
|
1206
|
-
}
|
|
1207
|
-
const contents = (0, smithy_client_1.map)({
|
|
1208
|
-
$metadata: deserializeMetadata(output),
|
|
1209
|
-
});
|
|
1210
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1211
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1212
|
-
keyPairs: smithy_client_1._json,
|
|
1213
|
-
nextToken: smithy_client_1.expectString,
|
|
1214
|
-
});
|
|
1215
|
-
Object.assign(contents, doc);
|
|
1216
|
-
return contents;
|
|
1217
|
-
};
|
|
1218
|
-
exports.de_ListPlaybackKeyPairsCommand = de_ListPlaybackKeyPairsCommand;
|
|
1219
|
-
const de_ListPlaybackKeyPairsCommandError = async (output, context) => {
|
|
1220
|
-
const parsedOutput = {
|
|
1221
|
-
...output,
|
|
1222
|
-
body: await parseErrorBody(output.body, context),
|
|
1223
|
-
};
|
|
1224
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1225
|
-
switch (errorCode) {
|
|
1226
|
-
case "AccessDeniedException":
|
|
1227
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1228
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1229
|
-
case "ValidationException":
|
|
1230
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1231
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1232
|
-
default:
|
|
1233
|
-
const parsedBody = parsedOutput.body;
|
|
1234
|
-
return throwDefaultError({
|
|
1235
|
-
output,
|
|
1236
|
-
parsedBody,
|
|
1237
|
-
errorCode,
|
|
1238
|
-
});
|
|
1239
|
-
}
|
|
1240
|
-
};
|
|
1241
|
-
const de_ListRecordingConfigurationsCommand = async (output, context) => {
|
|
1242
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1243
|
-
return de_ListRecordingConfigurationsCommandError(output, context);
|
|
1244
|
-
}
|
|
1245
|
-
const contents = (0, smithy_client_1.map)({
|
|
1246
|
-
$metadata: deserializeMetadata(output),
|
|
1247
|
-
});
|
|
1248
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1249
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1250
|
-
nextToken: smithy_client_1.expectString,
|
|
1251
|
-
recordingConfigurations: smithy_client_1._json,
|
|
1252
|
-
});
|
|
1253
|
-
Object.assign(contents, doc);
|
|
1254
|
-
return contents;
|
|
1255
|
-
};
|
|
1256
|
-
exports.de_ListRecordingConfigurationsCommand = de_ListRecordingConfigurationsCommand;
|
|
1257
|
-
const de_ListRecordingConfigurationsCommandError = async (output, context) => {
|
|
1258
|
-
const parsedOutput = {
|
|
1259
|
-
...output,
|
|
1260
|
-
body: await parseErrorBody(output.body, context),
|
|
1261
|
-
};
|
|
1262
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1263
|
-
switch (errorCode) {
|
|
1264
|
-
case "AccessDeniedException":
|
|
1265
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1266
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1267
|
-
case "InternalServerException":
|
|
1268
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
1269
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1270
|
-
case "ValidationException":
|
|
1271
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1272
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1273
|
-
default:
|
|
1274
|
-
const parsedBody = parsedOutput.body;
|
|
1275
|
-
return throwDefaultError({
|
|
1276
|
-
output,
|
|
1277
|
-
parsedBody,
|
|
1278
|
-
errorCode,
|
|
1279
|
-
});
|
|
1280
|
-
}
|
|
1281
|
-
};
|
|
1282
|
-
const de_ListStreamKeysCommand = async (output, context) => {
|
|
1283
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1284
|
-
return de_ListStreamKeysCommandError(output, context);
|
|
1285
|
-
}
|
|
1286
|
-
const contents = (0, smithy_client_1.map)({
|
|
1287
|
-
$metadata: deserializeMetadata(output),
|
|
1288
|
-
});
|
|
1289
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1290
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1291
|
-
nextToken: smithy_client_1.expectString,
|
|
1292
|
-
streamKeys: smithy_client_1._json,
|
|
1293
|
-
});
|
|
1294
|
-
Object.assign(contents, doc);
|
|
1295
|
-
return contents;
|
|
1296
|
-
};
|
|
1297
|
-
exports.de_ListStreamKeysCommand = de_ListStreamKeysCommand;
|
|
1298
|
-
const de_ListStreamKeysCommandError = async (output, context) => {
|
|
1299
|
-
const parsedOutput = {
|
|
1300
|
-
...output,
|
|
1301
|
-
body: await parseErrorBody(output.body, context),
|
|
1302
|
-
};
|
|
1303
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1304
|
-
switch (errorCode) {
|
|
1305
|
-
case "AccessDeniedException":
|
|
1306
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1307
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1308
|
-
case "ResourceNotFoundException":
|
|
1309
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1310
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1311
|
-
case "ValidationException":
|
|
1312
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1313
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1314
|
-
default:
|
|
1315
|
-
const parsedBody = parsedOutput.body;
|
|
1316
|
-
return throwDefaultError({
|
|
1317
|
-
output,
|
|
1318
|
-
parsedBody,
|
|
1319
|
-
errorCode,
|
|
1320
|
-
});
|
|
1321
|
-
}
|
|
1322
|
-
};
|
|
1323
|
-
const de_ListStreamsCommand = async (output, context) => {
|
|
1324
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1325
|
-
return de_ListStreamsCommandError(output, context);
|
|
1326
|
-
}
|
|
1327
|
-
const contents = (0, smithy_client_1.map)({
|
|
1328
|
-
$metadata: deserializeMetadata(output),
|
|
1329
|
-
});
|
|
1330
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1331
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1332
|
-
nextToken: smithy_client_1.expectString,
|
|
1333
|
-
streams: (_) => de_StreamList(_, context),
|
|
1334
|
-
});
|
|
1335
|
-
Object.assign(contents, doc);
|
|
1336
|
-
return contents;
|
|
1337
|
-
};
|
|
1338
|
-
exports.de_ListStreamsCommand = de_ListStreamsCommand;
|
|
1339
|
-
const de_ListStreamsCommandError = async (output, context) => {
|
|
1340
|
-
const parsedOutput = {
|
|
1341
|
-
...output,
|
|
1342
|
-
body: await parseErrorBody(output.body, context),
|
|
1343
|
-
};
|
|
1344
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1345
|
-
switch (errorCode) {
|
|
1346
|
-
case "AccessDeniedException":
|
|
1347
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1348
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1349
|
-
case "ValidationException":
|
|
1350
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1351
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1352
|
-
default:
|
|
1353
|
-
const parsedBody = parsedOutput.body;
|
|
1354
|
-
return throwDefaultError({
|
|
1355
|
-
output,
|
|
1356
|
-
parsedBody,
|
|
1357
|
-
errorCode,
|
|
1358
|
-
});
|
|
1359
|
-
}
|
|
1360
|
-
};
|
|
1361
|
-
const de_ListStreamSessionsCommand = async (output, context) => {
|
|
1362
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1363
|
-
return de_ListStreamSessionsCommandError(output, context);
|
|
1364
|
-
}
|
|
1365
|
-
const contents = (0, smithy_client_1.map)({
|
|
1366
|
-
$metadata: deserializeMetadata(output),
|
|
1367
|
-
});
|
|
1368
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1369
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1370
|
-
nextToken: smithy_client_1.expectString,
|
|
1371
|
-
streamSessions: (_) => de_StreamSessionList(_, context),
|
|
1372
|
-
});
|
|
1373
|
-
Object.assign(contents, doc);
|
|
1374
|
-
return contents;
|
|
1375
|
-
};
|
|
1376
|
-
exports.de_ListStreamSessionsCommand = de_ListStreamSessionsCommand;
|
|
1377
|
-
const de_ListStreamSessionsCommandError = async (output, context) => {
|
|
1378
|
-
const parsedOutput = {
|
|
1379
|
-
...output,
|
|
1380
|
-
body: await parseErrorBody(output.body, context),
|
|
1381
|
-
};
|
|
1382
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1383
|
-
switch (errorCode) {
|
|
1384
|
-
case "AccessDeniedException":
|
|
1385
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1386
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1387
|
-
case "ResourceNotFoundException":
|
|
1388
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1389
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1390
|
-
case "ValidationException":
|
|
1391
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1392
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1393
|
-
default:
|
|
1394
|
-
const parsedBody = parsedOutput.body;
|
|
1395
|
-
return throwDefaultError({
|
|
1396
|
-
output,
|
|
1397
|
-
parsedBody,
|
|
1398
|
-
errorCode,
|
|
1399
|
-
});
|
|
1400
|
-
}
|
|
1401
|
-
};
|
|
1402
|
-
const de_ListTagsForResourceCommand = async (output, context) => {
|
|
1403
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1404
|
-
return de_ListTagsForResourceCommandError(output, context);
|
|
1405
|
-
}
|
|
1406
|
-
const contents = (0, smithy_client_1.map)({
|
|
1407
|
-
$metadata: deserializeMetadata(output),
|
|
1408
|
-
});
|
|
1409
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1410
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1411
|
-
tags: smithy_client_1._json,
|
|
1412
|
-
});
|
|
1413
|
-
Object.assign(contents, doc);
|
|
1414
|
-
return contents;
|
|
1415
|
-
};
|
|
1416
|
-
exports.de_ListTagsForResourceCommand = de_ListTagsForResourceCommand;
|
|
1417
|
-
const de_ListTagsForResourceCommandError = async (output, context) => {
|
|
1418
|
-
const parsedOutput = {
|
|
1419
|
-
...output,
|
|
1420
|
-
body: await parseErrorBody(output.body, context),
|
|
1421
|
-
};
|
|
1422
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1423
|
-
switch (errorCode) {
|
|
1424
|
-
case "InternalServerException":
|
|
1425
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
1426
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1427
|
-
case "ResourceNotFoundException":
|
|
1428
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1429
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1430
|
-
case "ValidationException":
|
|
1431
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1432
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1433
|
-
default:
|
|
1434
|
-
const parsedBody = parsedOutput.body;
|
|
1435
|
-
return throwDefaultError({
|
|
1436
|
-
output,
|
|
1437
|
-
parsedBody,
|
|
1438
|
-
errorCode,
|
|
1439
|
-
});
|
|
1440
|
-
}
|
|
1441
|
-
};
|
|
1442
|
-
const de_PutMetadataCommand = async (output, context) => {
|
|
1443
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1444
|
-
return de_PutMetadataCommandError(output, context);
|
|
1445
|
-
}
|
|
1446
|
-
const contents = (0, smithy_client_1.map)({
|
|
1447
|
-
$metadata: deserializeMetadata(output),
|
|
1448
|
-
});
|
|
1449
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1450
|
-
return contents;
|
|
1451
|
-
};
|
|
1452
|
-
exports.de_PutMetadataCommand = de_PutMetadataCommand;
|
|
1453
|
-
const de_PutMetadataCommandError = async (output, context) => {
|
|
1454
|
-
const parsedOutput = {
|
|
1455
|
-
...output,
|
|
1456
|
-
body: await parseErrorBody(output.body, context),
|
|
1457
|
-
};
|
|
1458
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1459
|
-
switch (errorCode) {
|
|
1460
|
-
case "AccessDeniedException":
|
|
1461
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1462
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1463
|
-
case "ChannelNotBroadcasting":
|
|
1464
|
-
case "com.amazonaws.ivs#ChannelNotBroadcasting":
|
|
1465
|
-
throw await de_ChannelNotBroadcastingRes(parsedOutput, context);
|
|
1466
|
-
case "ResourceNotFoundException":
|
|
1467
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1468
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1469
|
-
case "ThrottlingException":
|
|
1470
|
-
case "com.amazonaws.ivs#ThrottlingException":
|
|
1471
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1472
|
-
case "ValidationException":
|
|
1473
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1474
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1475
|
-
default:
|
|
1476
|
-
const parsedBody = parsedOutput.body;
|
|
1477
|
-
return throwDefaultError({
|
|
1478
|
-
output,
|
|
1479
|
-
parsedBody,
|
|
1480
|
-
errorCode,
|
|
1481
|
-
});
|
|
1482
|
-
}
|
|
1483
|
-
};
|
|
1484
|
-
const de_StartViewerSessionRevocationCommand = async (output, context) => {
|
|
1485
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1486
|
-
return de_StartViewerSessionRevocationCommandError(output, context);
|
|
1487
|
-
}
|
|
1488
|
-
const contents = (0, smithy_client_1.map)({
|
|
1489
|
-
$metadata: deserializeMetadata(output),
|
|
1490
|
-
});
|
|
1491
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1492
|
-
return contents;
|
|
1493
|
-
};
|
|
1494
|
-
exports.de_StartViewerSessionRevocationCommand = de_StartViewerSessionRevocationCommand;
|
|
1495
|
-
const de_StartViewerSessionRevocationCommandError = async (output, context) => {
|
|
1496
|
-
const parsedOutput = {
|
|
1497
|
-
...output,
|
|
1498
|
-
body: await parseErrorBody(output.body, context),
|
|
1499
|
-
};
|
|
1500
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1501
|
-
switch (errorCode) {
|
|
1502
|
-
case "AccessDeniedException":
|
|
1503
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1504
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1505
|
-
case "InternalServerException":
|
|
1506
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
1507
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1508
|
-
case "PendingVerification":
|
|
1509
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
1510
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
1511
|
-
case "ResourceNotFoundException":
|
|
1512
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1513
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1514
|
-
case "ThrottlingException":
|
|
1515
|
-
case "com.amazonaws.ivs#ThrottlingException":
|
|
1516
|
-
throw await de_ThrottlingExceptionRes(parsedOutput, context);
|
|
1517
|
-
case "ValidationException":
|
|
1518
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1519
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1520
|
-
default:
|
|
1521
|
-
const parsedBody = parsedOutput.body;
|
|
1522
|
-
return throwDefaultError({
|
|
1523
|
-
output,
|
|
1524
|
-
parsedBody,
|
|
1525
|
-
errorCode,
|
|
1526
|
-
});
|
|
1527
|
-
}
|
|
1528
|
-
};
|
|
1529
|
-
const de_StopStreamCommand = async (output, context) => {
|
|
1530
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1531
|
-
return de_StopStreamCommandError(output, context);
|
|
1532
|
-
}
|
|
1533
|
-
const contents = (0, smithy_client_1.map)({
|
|
1534
|
-
$metadata: deserializeMetadata(output),
|
|
1535
|
-
});
|
|
1536
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1537
|
-
return contents;
|
|
1538
|
-
};
|
|
1539
|
-
exports.de_StopStreamCommand = de_StopStreamCommand;
|
|
1540
|
-
const de_StopStreamCommandError = async (output, context) => {
|
|
1541
|
-
const parsedOutput = {
|
|
1542
|
-
...output,
|
|
1543
|
-
body: await parseErrorBody(output.body, context),
|
|
1544
|
-
};
|
|
1545
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1546
|
-
switch (errorCode) {
|
|
1547
|
-
case "AccessDeniedException":
|
|
1548
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1549
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1550
|
-
case "ChannelNotBroadcasting":
|
|
1551
|
-
case "com.amazonaws.ivs#ChannelNotBroadcasting":
|
|
1552
|
-
throw await de_ChannelNotBroadcastingRes(parsedOutput, context);
|
|
1553
|
-
case "ResourceNotFoundException":
|
|
1554
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1555
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1556
|
-
case "StreamUnavailable":
|
|
1557
|
-
case "com.amazonaws.ivs#StreamUnavailable":
|
|
1558
|
-
throw await de_StreamUnavailableRes(parsedOutput, context);
|
|
1559
|
-
case "ValidationException":
|
|
1560
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1561
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1562
|
-
default:
|
|
1563
|
-
const parsedBody = parsedOutput.body;
|
|
1564
|
-
return throwDefaultError({
|
|
1565
|
-
output,
|
|
1566
|
-
parsedBody,
|
|
1567
|
-
errorCode,
|
|
1568
|
-
});
|
|
1569
|
-
}
|
|
1570
|
-
};
|
|
1571
|
-
const de_TagResourceCommand = async (output, context) => {
|
|
1572
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1573
|
-
return de_TagResourceCommandError(output, context);
|
|
1574
|
-
}
|
|
1575
|
-
const contents = (0, smithy_client_1.map)({
|
|
1576
|
-
$metadata: deserializeMetadata(output),
|
|
1577
|
-
});
|
|
1578
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1579
|
-
return contents;
|
|
1580
|
-
};
|
|
1581
|
-
exports.de_TagResourceCommand = de_TagResourceCommand;
|
|
1582
|
-
const de_TagResourceCommandError = async (output, context) => {
|
|
1583
|
-
const parsedOutput = {
|
|
1584
|
-
...output,
|
|
1585
|
-
body: await parseErrorBody(output.body, context),
|
|
1586
|
-
};
|
|
1587
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1588
|
-
switch (errorCode) {
|
|
1589
|
-
case "InternalServerException":
|
|
1590
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
1591
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1592
|
-
case "ResourceNotFoundException":
|
|
1593
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1594
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1595
|
-
case "ValidationException":
|
|
1596
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1597
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1598
|
-
default:
|
|
1599
|
-
const parsedBody = parsedOutput.body;
|
|
1600
|
-
return throwDefaultError({
|
|
1601
|
-
output,
|
|
1602
|
-
parsedBody,
|
|
1603
|
-
errorCode,
|
|
1604
|
-
});
|
|
1605
|
-
}
|
|
1606
|
-
};
|
|
1607
|
-
const de_UntagResourceCommand = async (output, context) => {
|
|
1608
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1609
|
-
return de_UntagResourceCommandError(output, context);
|
|
1610
|
-
}
|
|
1611
|
-
const contents = (0, smithy_client_1.map)({
|
|
1612
|
-
$metadata: deserializeMetadata(output),
|
|
1613
|
-
});
|
|
1614
|
-
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1615
|
-
return contents;
|
|
1616
|
-
};
|
|
1617
|
-
exports.de_UntagResourceCommand = de_UntagResourceCommand;
|
|
1618
|
-
const de_UntagResourceCommandError = async (output, context) => {
|
|
1619
|
-
const parsedOutput = {
|
|
1620
|
-
...output,
|
|
1621
|
-
body: await parseErrorBody(output.body, context),
|
|
1622
|
-
};
|
|
1623
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1624
|
-
switch (errorCode) {
|
|
1625
|
-
case "InternalServerException":
|
|
1626
|
-
case "com.amazonaws.ivs#InternalServerException":
|
|
1627
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
1628
|
-
case "ResourceNotFoundException":
|
|
1629
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1630
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1631
|
-
case "ValidationException":
|
|
1632
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1633
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1634
|
-
default:
|
|
1635
|
-
const parsedBody = parsedOutput.body;
|
|
1636
|
-
return throwDefaultError({
|
|
1637
|
-
output,
|
|
1638
|
-
parsedBody,
|
|
1639
|
-
errorCode,
|
|
1640
|
-
});
|
|
1641
|
-
}
|
|
1642
|
-
};
|
|
1643
|
-
const de_UpdateChannelCommand = async (output, context) => {
|
|
1644
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1645
|
-
return de_UpdateChannelCommandError(output, context);
|
|
1646
|
-
}
|
|
1647
|
-
const contents = (0, smithy_client_1.map)({
|
|
1648
|
-
$metadata: deserializeMetadata(output),
|
|
1649
|
-
});
|
|
1650
|
-
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1651
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1652
|
-
channel: smithy_client_1._json,
|
|
1653
|
-
});
|
|
1654
|
-
Object.assign(contents, doc);
|
|
1655
|
-
return contents;
|
|
1656
|
-
};
|
|
1657
|
-
exports.de_UpdateChannelCommand = de_UpdateChannelCommand;
|
|
1658
|
-
const de_UpdateChannelCommandError = async (output, context) => {
|
|
1659
|
-
const parsedOutput = {
|
|
1660
|
-
...output,
|
|
1661
|
-
body: await parseErrorBody(output.body, context),
|
|
1662
|
-
};
|
|
1663
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1664
|
-
switch (errorCode) {
|
|
1665
|
-
case "AccessDeniedException":
|
|
1666
|
-
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1667
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
1668
|
-
case "ConflictException":
|
|
1669
|
-
case "com.amazonaws.ivs#ConflictException":
|
|
1670
|
-
throw await de_ConflictExceptionRes(parsedOutput, context);
|
|
1671
|
-
case "PendingVerification":
|
|
1672
|
-
case "com.amazonaws.ivs#PendingVerification":
|
|
1673
|
-
throw await de_PendingVerificationRes(parsedOutput, context);
|
|
1674
|
-
case "ResourceNotFoundException":
|
|
1675
|
-
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1676
|
-
throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
|
|
1677
|
-
case "ValidationException":
|
|
1678
|
-
case "com.amazonaws.ivs#ValidationException":
|
|
1679
|
-
throw await de_ValidationExceptionRes(parsedOutput, context);
|
|
1680
|
-
default:
|
|
1681
|
-
const parsedBody = parsedOutput.body;
|
|
1682
|
-
return throwDefaultError({
|
|
1683
|
-
output,
|
|
1684
|
-
parsedBody,
|
|
1685
|
-
errorCode,
|
|
1686
|
-
});
|
|
1687
|
-
}
|
|
1688
|
-
};
|
|
1689
|
-
const throwDefaultError = (0, smithy_client_1.withBaseException)(IvsServiceException_1.IvsServiceException);
|
|
1690
|
-
const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
1691
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1692
|
-
const data = parsedOutput.body;
|
|
1693
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1694
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1695
|
-
});
|
|
1696
|
-
Object.assign(contents, doc);
|
|
1697
|
-
const exception = new models_0_1.AccessDeniedException({
|
|
1698
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1699
|
-
...contents,
|
|
1700
|
-
});
|
|
1701
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1702
|
-
};
|
|
1703
|
-
const de_ChannelNotBroadcastingRes = async (parsedOutput, context) => {
|
|
1704
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1705
|
-
const data = parsedOutput.body;
|
|
1706
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1707
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1708
|
-
});
|
|
1709
|
-
Object.assign(contents, doc);
|
|
1710
|
-
const exception = new models_0_1.ChannelNotBroadcasting({
|
|
1711
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1712
|
-
...contents,
|
|
1713
|
-
});
|
|
1714
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1715
|
-
};
|
|
1716
|
-
const de_ConflictExceptionRes = async (parsedOutput, context) => {
|
|
1717
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1718
|
-
const data = parsedOutput.body;
|
|
1719
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1720
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1721
|
-
});
|
|
1722
|
-
Object.assign(contents, doc);
|
|
1723
|
-
const exception = new models_0_1.ConflictException({
|
|
1724
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1725
|
-
...contents,
|
|
1726
|
-
});
|
|
1727
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1728
|
-
};
|
|
1729
|
-
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
1730
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1731
|
-
const data = parsedOutput.body;
|
|
1732
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1733
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1734
|
-
});
|
|
1735
|
-
Object.assign(contents, doc);
|
|
1736
|
-
const exception = new models_0_1.InternalServerException({
|
|
1737
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1738
|
-
...contents,
|
|
1739
|
-
});
|
|
1740
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1741
|
-
};
|
|
1742
|
-
const de_PendingVerificationRes = async (parsedOutput, context) => {
|
|
1743
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1744
|
-
const data = parsedOutput.body;
|
|
1745
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1746
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1747
|
-
});
|
|
1748
|
-
Object.assign(contents, doc);
|
|
1749
|
-
const exception = new models_0_1.PendingVerification({
|
|
1750
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1751
|
-
...contents,
|
|
1752
|
-
});
|
|
1753
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1754
|
-
};
|
|
1755
|
-
const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
1756
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1757
|
-
const data = parsedOutput.body;
|
|
1758
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1759
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1760
|
-
});
|
|
1761
|
-
Object.assign(contents, doc);
|
|
1762
|
-
const exception = new models_0_1.ResourceNotFoundException({
|
|
1763
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1764
|
-
...contents,
|
|
1765
|
-
});
|
|
1766
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1767
|
-
};
|
|
1768
|
-
const de_ServiceQuotaExceededExceptionRes = async (parsedOutput, context) => {
|
|
1769
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1770
|
-
const data = parsedOutput.body;
|
|
1771
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1772
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1773
|
-
});
|
|
1774
|
-
Object.assign(contents, doc);
|
|
1775
|
-
const exception = new models_0_1.ServiceQuotaExceededException({
|
|
1776
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1777
|
-
...contents,
|
|
1778
|
-
});
|
|
1779
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1780
|
-
};
|
|
1781
|
-
const de_StreamUnavailableRes = async (parsedOutput, context) => {
|
|
1782
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1783
|
-
const data = parsedOutput.body;
|
|
1784
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1785
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1786
|
-
});
|
|
1787
|
-
Object.assign(contents, doc);
|
|
1788
|
-
const exception = new models_0_1.StreamUnavailable({
|
|
1789
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1790
|
-
...contents,
|
|
1791
|
-
});
|
|
1792
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1793
|
-
};
|
|
1794
|
-
const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
|
|
1795
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1796
|
-
const data = parsedOutput.body;
|
|
1797
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1798
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1799
|
-
});
|
|
1800
|
-
Object.assign(contents, doc);
|
|
1801
|
-
const exception = new models_0_1.ThrottlingException({
|
|
1802
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1803
|
-
...contents,
|
|
1804
|
-
});
|
|
1805
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1806
|
-
};
|
|
1807
|
-
const de_ValidationExceptionRes = async (parsedOutput, context) => {
|
|
1808
|
-
const contents = (0, smithy_client_1.map)({});
|
|
1809
|
-
const data = parsedOutput.body;
|
|
1810
|
-
const doc = (0, smithy_client_1.take)(data, {
|
|
1811
|
-
exceptionMessage: smithy_client_1.expectString,
|
|
1812
|
-
});
|
|
1813
|
-
Object.assign(contents, doc);
|
|
1814
|
-
const exception = new models_0_1.ValidationException({
|
|
1815
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
1816
|
-
...contents,
|
|
1817
|
-
});
|
|
1818
|
-
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
1819
|
-
};
|
|
1820
|
-
const de__Stream = (output, context) => {
|
|
1821
|
-
return (0, smithy_client_1.take)(output, {
|
|
1822
|
-
channelArn: smithy_client_1.expectString,
|
|
1823
|
-
health: smithy_client_1.expectString,
|
|
1824
|
-
playbackUrl: smithy_client_1.expectString,
|
|
1825
|
-
startTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1826
|
-
state: smithy_client_1.expectString,
|
|
1827
|
-
streamId: smithy_client_1.expectString,
|
|
1828
|
-
viewerCount: smithy_client_1.expectLong,
|
|
1829
|
-
});
|
|
1830
|
-
};
|
|
1831
|
-
const de_StreamEvent = (output, context) => {
|
|
1832
|
-
return (0, smithy_client_1.take)(output, {
|
|
1833
|
-
eventTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1834
|
-
name: smithy_client_1.expectString,
|
|
1835
|
-
type: smithy_client_1.expectString,
|
|
1836
|
-
});
|
|
1837
|
-
};
|
|
1838
|
-
const de_StreamEvents = (output, context) => {
|
|
1839
|
-
const retVal = (output || [])
|
|
1840
|
-
.filter((e) => e != null)
|
|
1841
|
-
.map((entry) => {
|
|
1842
|
-
return de_StreamEvent(entry, context);
|
|
1843
|
-
});
|
|
1844
|
-
return retVal;
|
|
1845
|
-
};
|
|
1846
|
-
const de_StreamList = (output, context) => {
|
|
1847
|
-
const retVal = (output || [])
|
|
1848
|
-
.filter((e) => e != null)
|
|
1849
|
-
.map((entry) => {
|
|
1850
|
-
return de_StreamSummary(entry, context);
|
|
1851
|
-
});
|
|
1852
|
-
return retVal;
|
|
1853
|
-
};
|
|
1854
|
-
const de_StreamSession = (output, context) => {
|
|
1855
|
-
return (0, smithy_client_1.take)(output, {
|
|
1856
|
-
channel: smithy_client_1._json,
|
|
1857
|
-
endTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1858
|
-
ingestConfiguration: smithy_client_1._json,
|
|
1859
|
-
recordingConfiguration: smithy_client_1._json,
|
|
1860
|
-
startTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1861
|
-
streamId: smithy_client_1.expectString,
|
|
1862
|
-
truncatedEvents: (_) => de_StreamEvents(_, context),
|
|
1863
|
-
});
|
|
1864
|
-
};
|
|
1865
|
-
const de_StreamSessionList = (output, context) => {
|
|
1866
|
-
const retVal = (output || [])
|
|
1867
|
-
.filter((e) => e != null)
|
|
1868
|
-
.map((entry) => {
|
|
1869
|
-
return de_StreamSessionSummary(entry, context);
|
|
1870
|
-
});
|
|
1871
|
-
return retVal;
|
|
1872
|
-
};
|
|
1873
|
-
const de_StreamSessionSummary = (output, context) => {
|
|
1874
|
-
return (0, smithy_client_1.take)(output, {
|
|
1875
|
-
endTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1876
|
-
hasErrorEvent: smithy_client_1.expectBoolean,
|
|
1877
|
-
startTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1878
|
-
streamId: smithy_client_1.expectString,
|
|
1879
|
-
});
|
|
1880
|
-
};
|
|
1881
|
-
const de_StreamSummary = (output, context) => {
|
|
1882
|
-
return (0, smithy_client_1.take)(output, {
|
|
1883
|
-
channelArn: smithy_client_1.expectString,
|
|
1884
|
-
health: smithy_client_1.expectString,
|
|
1885
|
-
startTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseRfc3339DateTimeWithOffset)(_)),
|
|
1886
|
-
state: smithy_client_1.expectString,
|
|
1887
|
-
streamId: smithy_client_1.expectString,
|
|
1888
|
-
viewerCount: smithy_client_1.expectLong,
|
|
1889
|
-
});
|
|
1890
|
-
};
|
|
1891
|
-
const deserializeMetadata = (output) => ({
|
|
1892
|
-
httpStatusCode: output.statusCode,
|
|
1893
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
1894
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
1895
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
1896
|
-
});
|
|
1897
|
-
const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
1898
|
-
const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
1899
|
-
value !== null &&
|
|
1900
|
-
value !== "" &&
|
|
1901
|
-
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
1902
|
-
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
1903
|
-
const _tK = "tagKeys";
|
|
1904
|
-
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
1905
|
-
if (encoded.length) {
|
|
1906
|
-
return JSON.parse(encoded);
|
|
1907
|
-
}
|
|
1908
|
-
return {};
|
|
1909
|
-
});
|
|
1910
|
-
const parseErrorBody = async (errorBody, context) => {
|
|
1911
|
-
const value = await parseBody(errorBody, context);
|
|
1912
|
-
value.message = value.message ?? value.Message;
|
|
1913
|
-
return value;
|
|
1914
|
-
};
|
|
1915
|
-
const loadRestJsonErrorCode = (output, data) => {
|
|
1916
|
-
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
1917
|
-
const sanitizeErrorCode = (rawValue) => {
|
|
1918
|
-
let cleanValue = rawValue;
|
|
1919
|
-
if (typeof cleanValue === "number") {
|
|
1920
|
-
cleanValue = cleanValue.toString();
|
|
1921
|
-
}
|
|
1922
|
-
if (cleanValue.indexOf(",") >= 0) {
|
|
1923
|
-
cleanValue = cleanValue.split(",")[0];
|
|
1924
|
-
}
|
|
1925
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
1926
|
-
cleanValue = cleanValue.split(":")[0];
|
|
1927
|
-
}
|
|
1928
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
1929
|
-
cleanValue = cleanValue.split("#")[1];
|
|
1930
|
-
}
|
|
1931
|
-
return cleanValue;
|
|
1932
|
-
};
|
|
1933
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
1934
|
-
if (headerKey !== undefined) {
|
|
1935
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
1936
|
-
}
|
|
1937
|
-
if (data.code !== undefined) {
|
|
1938
|
-
return sanitizeErrorCode(data.code);
|
|
1939
|
-
}
|
|
1940
|
-
if (data["__type"] !== undefined) {
|
|
1941
|
-
return sanitizeErrorCode(data["__type"]);
|
|
1942
|
-
}
|
|
1943
|
-
};
|
|
1
|
+
module.exports = require("../index.js");
|