@aws-sdk/client-mediapackage 3.180.0 → 3.183.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/CHANGELOG.md +20 -0
- package/dist-cjs/protocols/Aws_restJson1.js +25 -19
- package/dist-es/MediaPackage.js +78 -85
- package/dist-es/MediaPackageClient.js +22 -28
- package/dist-es/commands/ConfigureLogsCommand.js +21 -28
- package/dist-es/commands/CreateChannelCommand.js +21 -28
- package/dist-es/commands/CreateHarvestJobCommand.js +21 -28
- package/dist-es/commands/CreateOriginEndpointCommand.js +21 -28
- package/dist-es/commands/DeleteChannelCommand.js +21 -28
- package/dist-es/commands/DeleteOriginEndpointCommand.js +21 -28
- package/dist-es/commands/DescribeChannelCommand.js +21 -28
- package/dist-es/commands/DescribeHarvestJobCommand.js +21 -28
- package/dist-es/commands/DescribeOriginEndpointCommand.js +21 -28
- package/dist-es/commands/ListChannelsCommand.js +21 -28
- package/dist-es/commands/ListHarvestJobsCommand.js +21 -28
- package/dist-es/commands/ListOriginEndpointsCommand.js +21 -28
- package/dist-es/commands/ListTagsForResourceCommand.js +21 -28
- package/dist-es/commands/RotateChannelCredentialsCommand.js +21 -28
- package/dist-es/commands/RotateIngestEndpointCredentialsCommand.js +21 -28
- package/dist-es/commands/TagResourceCommand.js +22 -29
- package/dist-es/commands/UntagResourceCommand.js +22 -29
- package/dist-es/commands/UpdateChannelCommand.js +21 -28
- package/dist-es/commands/UpdateOriginEndpointCommand.js +21 -28
- package/dist-es/endpoints.js +8 -8
- package/dist-es/models/MediaPackageServiceException.js +5 -10
- package/dist-es/models/models_0.js +249 -132
- package/dist-es/pagination/ListChannelsPaginator.js +25 -68
- package/dist-es/pagination/ListHarvestJobsPaginator.js +25 -68
- package/dist-es/pagination/ListOriginEndpointsPaginator.js +25 -68
- package/dist-es/protocols/Aws_restJson1.js +1853 -2330
- package/dist-es/runtimeConfig.browser.js +26 -12
- package/dist-es/runtimeConfig.js +30 -12
- package/dist-es/runtimeConfig.native.js +8 -5
- package/dist-es/runtimeConfig.shared.js +8 -11
- package/package.json +33 -33
|
@@ -1,2318 +1,1844 @@
|
|
|
1
|
-
import { __assign, __awaiter, __generator, __read } from "tslib";
|
|
2
1
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
2
|
import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map as __map, resolvedPath as __resolvedPath, throwDefaultError, } from "@aws-sdk/smithy-client";
|
|
4
3
|
import { MediaPackageServiceException as __BaseException } from "../models/MediaPackageServiceException";
|
|
5
4
|
import { ForbiddenException, InternalServerErrorException, NotFoundException, ServiceUnavailableException, TooManyRequestsException, UnprocessableEntityException, } from "../models/models_0";
|
|
6
|
-
export
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
body: body,
|
|
31
|
-
})];
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
}); };
|
|
35
|
-
export var serializeAws_restJson1CreateChannelCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
36
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
37
|
-
return __generator(this, function (_c) {
|
|
38
|
-
switch (_c.label) {
|
|
39
|
-
case 0: return [4, context.endpoint()];
|
|
40
|
-
case 1:
|
|
41
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
42
|
-
headers = {
|
|
43
|
-
"content-type": "application/json",
|
|
44
|
-
};
|
|
45
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/channels";
|
|
46
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.Description != null && { description: input.Description })), (input.Id != null && { id: input.Id })), (input.Tags != null && { tags: serializeAws_restJson1Tags(input.Tags, context) })));
|
|
47
|
-
return [2, new __HttpRequest({
|
|
48
|
-
protocol: protocol,
|
|
49
|
-
hostname: hostname,
|
|
50
|
-
port: port,
|
|
51
|
-
method: "POST",
|
|
52
|
-
headers: headers,
|
|
53
|
-
path: resolvedPath,
|
|
54
|
-
body: body,
|
|
55
|
-
})];
|
|
56
|
-
}
|
|
57
|
-
});
|
|
58
|
-
}); };
|
|
59
|
-
export var serializeAws_restJson1CreateHarvestJobCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
60
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
61
|
-
return __generator(this, function (_c) {
|
|
62
|
-
switch (_c.label) {
|
|
63
|
-
case 0: return [4, context.endpoint()];
|
|
64
|
-
case 1:
|
|
65
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
66
|
-
headers = {
|
|
67
|
-
"content-type": "application/json",
|
|
68
|
-
};
|
|
69
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/harvest_jobs";
|
|
70
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign({}, (input.EndTime != null && { endTime: input.EndTime })), (input.Id != null && { id: input.Id })), (input.OriginEndpointId != null && { originEndpointId: input.OriginEndpointId })), (input.S3Destination != null && {
|
|
71
|
-
s3Destination: serializeAws_restJson1S3Destination(input.S3Destination, context),
|
|
72
|
-
})), (input.StartTime != null && { startTime: input.StartTime })));
|
|
73
|
-
return [2, new __HttpRequest({
|
|
74
|
-
protocol: protocol,
|
|
75
|
-
hostname: hostname,
|
|
76
|
-
port: port,
|
|
77
|
-
method: "POST",
|
|
78
|
-
headers: headers,
|
|
79
|
-
path: resolvedPath,
|
|
80
|
-
body: body,
|
|
81
|
-
})];
|
|
82
|
-
}
|
|
83
|
-
});
|
|
84
|
-
}); };
|
|
85
|
-
export var serializeAws_restJson1CreateOriginEndpointCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
86
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
87
|
-
return __generator(this, function (_c) {
|
|
88
|
-
switch (_c.label) {
|
|
89
|
-
case 0: return [4, context.endpoint()];
|
|
90
|
-
case 1:
|
|
91
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
92
|
-
headers = {
|
|
93
|
-
"content-type": "application/json",
|
|
94
|
-
};
|
|
95
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/origin_endpoints";
|
|
96
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.Authorization != null && {
|
|
97
|
-
authorization: serializeAws_restJson1Authorization(input.Authorization, context),
|
|
98
|
-
})), (input.ChannelId != null && { channelId: input.ChannelId })), (input.CmafPackage != null && {
|
|
99
|
-
cmafPackage: serializeAws_restJson1CmafPackageCreateOrUpdateParameters(input.CmafPackage, context),
|
|
100
|
-
})), (input.DashPackage != null && { dashPackage: serializeAws_restJson1DashPackage(input.DashPackage, context) })), (input.Description != null && { description: input.Description })), (input.HlsPackage != null && { hlsPackage: serializeAws_restJson1HlsPackage(input.HlsPackage, context) })), (input.Id != null && { id: input.Id })), (input.ManifestName != null && { manifestName: input.ManifestName })), (input.MssPackage != null && { mssPackage: serializeAws_restJson1MssPackage(input.MssPackage, context) })), (input.Origination != null && { origination: input.Origination })), (input.StartoverWindowSeconds != null && { startoverWindowSeconds: input.StartoverWindowSeconds })), (input.Tags != null && { tags: serializeAws_restJson1Tags(input.Tags, context) })), (input.TimeDelaySeconds != null && { timeDelaySeconds: input.TimeDelaySeconds })), (input.Whitelist != null && { whitelist: serializeAws_restJson1__listOf__string(input.Whitelist, context) })));
|
|
101
|
-
return [2, new __HttpRequest({
|
|
102
|
-
protocol: protocol,
|
|
103
|
-
hostname: hostname,
|
|
104
|
-
port: port,
|
|
105
|
-
method: "POST",
|
|
106
|
-
headers: headers,
|
|
107
|
-
path: resolvedPath,
|
|
108
|
-
body: body,
|
|
109
|
-
})];
|
|
110
|
-
}
|
|
111
|
-
});
|
|
112
|
-
}); };
|
|
113
|
-
export var serializeAws_restJson1DeleteChannelCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
114
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
115
|
-
return __generator(this, function (_c) {
|
|
116
|
-
switch (_c.label) {
|
|
117
|
-
case 0: return [4, context.endpoint()];
|
|
118
|
-
case 1:
|
|
119
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
120
|
-
headers = {};
|
|
121
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/channels/{Id}";
|
|
122
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "Id", function () { return input.Id; }, "{Id}", false);
|
|
123
|
-
return [2, new __HttpRequest({
|
|
124
|
-
protocol: protocol,
|
|
125
|
-
hostname: hostname,
|
|
126
|
-
port: port,
|
|
127
|
-
method: "DELETE",
|
|
128
|
-
headers: headers,
|
|
129
|
-
path: resolvedPath,
|
|
130
|
-
body: body,
|
|
131
|
-
})];
|
|
132
|
-
}
|
|
133
|
-
});
|
|
134
|
-
}); };
|
|
135
|
-
export var serializeAws_restJson1DeleteOriginEndpointCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
136
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
137
|
-
return __generator(this, function (_c) {
|
|
138
|
-
switch (_c.label) {
|
|
139
|
-
case 0: return [4, context.endpoint()];
|
|
140
|
-
case 1:
|
|
141
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
142
|
-
headers = {};
|
|
143
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/origin_endpoints/{Id}";
|
|
144
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "Id", function () { return input.Id; }, "{Id}", false);
|
|
145
|
-
return [2, new __HttpRequest({
|
|
146
|
-
protocol: protocol,
|
|
147
|
-
hostname: hostname,
|
|
148
|
-
port: port,
|
|
149
|
-
method: "DELETE",
|
|
150
|
-
headers: headers,
|
|
151
|
-
path: resolvedPath,
|
|
152
|
-
body: body,
|
|
153
|
-
})];
|
|
154
|
-
}
|
|
155
|
-
});
|
|
156
|
-
}); };
|
|
157
|
-
export var serializeAws_restJson1DescribeChannelCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
158
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
159
|
-
return __generator(this, function (_c) {
|
|
160
|
-
switch (_c.label) {
|
|
161
|
-
case 0: return [4, context.endpoint()];
|
|
162
|
-
case 1:
|
|
163
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
164
|
-
headers = {};
|
|
165
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/channels/{Id}";
|
|
166
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "Id", function () { return input.Id; }, "{Id}", false);
|
|
167
|
-
return [2, new __HttpRequest({
|
|
168
|
-
protocol: protocol,
|
|
169
|
-
hostname: hostname,
|
|
170
|
-
port: port,
|
|
171
|
-
method: "GET",
|
|
172
|
-
headers: headers,
|
|
173
|
-
path: resolvedPath,
|
|
174
|
-
body: body,
|
|
175
|
-
})];
|
|
176
|
-
}
|
|
177
|
-
});
|
|
178
|
-
}); };
|
|
179
|
-
export var serializeAws_restJson1DescribeHarvestJobCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
180
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
181
|
-
return __generator(this, function (_c) {
|
|
182
|
-
switch (_c.label) {
|
|
183
|
-
case 0: return [4, context.endpoint()];
|
|
184
|
-
case 1:
|
|
185
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
186
|
-
headers = {};
|
|
187
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/harvest_jobs/{Id}";
|
|
188
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "Id", function () { return input.Id; }, "{Id}", false);
|
|
189
|
-
return [2, new __HttpRequest({
|
|
190
|
-
protocol: protocol,
|
|
191
|
-
hostname: hostname,
|
|
192
|
-
port: port,
|
|
193
|
-
method: "GET",
|
|
194
|
-
headers: headers,
|
|
195
|
-
path: resolvedPath,
|
|
196
|
-
body: body,
|
|
197
|
-
})];
|
|
198
|
-
}
|
|
199
|
-
});
|
|
200
|
-
}); };
|
|
201
|
-
export var serializeAws_restJson1DescribeOriginEndpointCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
202
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
203
|
-
return __generator(this, function (_c) {
|
|
204
|
-
switch (_c.label) {
|
|
205
|
-
case 0: return [4, context.endpoint()];
|
|
206
|
-
case 1:
|
|
207
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
208
|
-
headers = {};
|
|
209
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/origin_endpoints/{Id}";
|
|
210
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "Id", function () { return input.Id; }, "{Id}", false);
|
|
211
|
-
return [2, new __HttpRequest({
|
|
212
|
-
protocol: protocol,
|
|
213
|
-
hostname: hostname,
|
|
214
|
-
port: port,
|
|
215
|
-
method: "GET",
|
|
216
|
-
headers: headers,
|
|
217
|
-
path: resolvedPath,
|
|
218
|
-
body: body,
|
|
219
|
-
})];
|
|
220
|
-
}
|
|
221
|
-
});
|
|
222
|
-
}); };
|
|
223
|
-
export var serializeAws_restJson1ListChannelsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
224
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
225
|
-
return __generator(this, function (_c) {
|
|
226
|
-
switch (_c.label) {
|
|
227
|
-
case 0: return [4, context.endpoint()];
|
|
228
|
-
case 1:
|
|
229
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
230
|
-
headers = {};
|
|
231
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/channels";
|
|
232
|
-
query = map({
|
|
233
|
-
maxResults: [function () { return input.MaxResults !== void 0; }, function () { return input.MaxResults.toString(); }],
|
|
234
|
-
nextToken: [, input.NextToken],
|
|
235
|
-
});
|
|
236
|
-
return [2, new __HttpRequest({
|
|
237
|
-
protocol: protocol,
|
|
238
|
-
hostname: hostname,
|
|
239
|
-
port: port,
|
|
240
|
-
method: "GET",
|
|
241
|
-
headers: headers,
|
|
242
|
-
path: resolvedPath,
|
|
243
|
-
query: query,
|
|
244
|
-
body: body,
|
|
245
|
-
})];
|
|
246
|
-
}
|
|
247
|
-
});
|
|
248
|
-
}); };
|
|
249
|
-
export var serializeAws_restJson1ListHarvestJobsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
250
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
251
|
-
return __generator(this, function (_c) {
|
|
252
|
-
switch (_c.label) {
|
|
253
|
-
case 0: return [4, context.endpoint()];
|
|
254
|
-
case 1:
|
|
255
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
256
|
-
headers = {};
|
|
257
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/harvest_jobs";
|
|
258
|
-
query = map({
|
|
259
|
-
includeChannelId: [, input.IncludeChannelId],
|
|
260
|
-
includeStatus: [, input.IncludeStatus],
|
|
261
|
-
maxResults: [function () { return input.MaxResults !== void 0; }, function () { return input.MaxResults.toString(); }],
|
|
262
|
-
nextToken: [, input.NextToken],
|
|
263
|
-
});
|
|
264
|
-
return [2, new __HttpRequest({
|
|
265
|
-
protocol: protocol,
|
|
266
|
-
hostname: hostname,
|
|
267
|
-
port: port,
|
|
268
|
-
method: "GET",
|
|
269
|
-
headers: headers,
|
|
270
|
-
path: resolvedPath,
|
|
271
|
-
query: query,
|
|
272
|
-
body: body,
|
|
273
|
-
})];
|
|
274
|
-
}
|
|
275
|
-
});
|
|
276
|
-
}); };
|
|
277
|
-
export var serializeAws_restJson1ListOriginEndpointsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
278
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
279
|
-
return __generator(this, function (_c) {
|
|
280
|
-
switch (_c.label) {
|
|
281
|
-
case 0: return [4, context.endpoint()];
|
|
282
|
-
case 1:
|
|
283
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
284
|
-
headers = {};
|
|
285
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/origin_endpoints";
|
|
286
|
-
query = map({
|
|
287
|
-
channelId: [, input.ChannelId],
|
|
288
|
-
maxResults: [function () { return input.MaxResults !== void 0; }, function () { return input.MaxResults.toString(); }],
|
|
289
|
-
nextToken: [, input.NextToken],
|
|
290
|
-
});
|
|
291
|
-
return [2, new __HttpRequest({
|
|
292
|
-
protocol: protocol,
|
|
293
|
-
hostname: hostname,
|
|
294
|
-
port: port,
|
|
295
|
-
method: "GET",
|
|
296
|
-
headers: headers,
|
|
297
|
-
path: resolvedPath,
|
|
298
|
-
query: query,
|
|
299
|
-
body: body,
|
|
300
|
-
})];
|
|
301
|
-
}
|
|
5
|
+
export const serializeAws_restJson1ConfigureLogsCommand = async (input, context) => {
|
|
6
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
7
|
+
const headers = {
|
|
8
|
+
"content-type": "application/json",
|
|
9
|
+
};
|
|
10
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels/{Id}/configure_logs";
|
|
11
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
12
|
+
let body;
|
|
13
|
+
body = JSON.stringify({
|
|
14
|
+
...(input.EgressAccessLogs != null && {
|
|
15
|
+
egressAccessLogs: serializeAws_restJson1EgressAccessLogs(input.EgressAccessLogs, context),
|
|
16
|
+
}),
|
|
17
|
+
...(input.IngressAccessLogs != null && {
|
|
18
|
+
ingressAccessLogs: serializeAws_restJson1IngressAccessLogs(input.IngressAccessLogs, context),
|
|
19
|
+
}),
|
|
20
|
+
});
|
|
21
|
+
return new __HttpRequest({
|
|
22
|
+
protocol,
|
|
23
|
+
hostname,
|
|
24
|
+
port,
|
|
25
|
+
method: "PUT",
|
|
26
|
+
headers,
|
|
27
|
+
path: resolvedPath,
|
|
28
|
+
body,
|
|
302
29
|
});
|
|
303
|
-
}
|
|
304
|
-
export
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
30
|
+
};
|
|
31
|
+
export const serializeAws_restJson1CreateChannelCommand = async (input, context) => {
|
|
32
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
33
|
+
const headers = {
|
|
34
|
+
"content-type": "application/json",
|
|
35
|
+
};
|
|
36
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels";
|
|
37
|
+
let body;
|
|
38
|
+
body = JSON.stringify({
|
|
39
|
+
...(input.Description != null && { description: input.Description }),
|
|
40
|
+
...(input.Id != null && { id: input.Id }),
|
|
41
|
+
...(input.Tags != null && { tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
42
|
+
});
|
|
43
|
+
return new __HttpRequest({
|
|
44
|
+
protocol,
|
|
45
|
+
hostname,
|
|
46
|
+
port,
|
|
47
|
+
method: "POST",
|
|
48
|
+
headers,
|
|
49
|
+
path: resolvedPath,
|
|
50
|
+
body,
|
|
324
51
|
});
|
|
325
|
-
}
|
|
326
|
-
export
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
52
|
+
};
|
|
53
|
+
export const serializeAws_restJson1CreateHarvestJobCommand = async (input, context) => {
|
|
54
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
55
|
+
const headers = {
|
|
56
|
+
"content-type": "application/json",
|
|
57
|
+
};
|
|
58
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/harvest_jobs";
|
|
59
|
+
let body;
|
|
60
|
+
body = JSON.stringify({
|
|
61
|
+
...(input.EndTime != null && { endTime: input.EndTime }),
|
|
62
|
+
...(input.Id != null && { id: input.Id }),
|
|
63
|
+
...(input.OriginEndpointId != null && { originEndpointId: input.OriginEndpointId }),
|
|
64
|
+
...(input.S3Destination != null && {
|
|
65
|
+
s3Destination: serializeAws_restJson1S3Destination(input.S3Destination, context),
|
|
66
|
+
}),
|
|
67
|
+
...(input.StartTime != null && { startTime: input.StartTime }),
|
|
68
|
+
});
|
|
69
|
+
return new __HttpRequest({
|
|
70
|
+
protocol,
|
|
71
|
+
hostname,
|
|
72
|
+
port,
|
|
73
|
+
method: "POST",
|
|
74
|
+
headers,
|
|
75
|
+
path: resolvedPath,
|
|
76
|
+
body,
|
|
346
77
|
});
|
|
347
|
-
}
|
|
348
|
-
export
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
}
|
|
78
|
+
};
|
|
79
|
+
export const serializeAws_restJson1CreateOriginEndpointCommand = async (input, context) => {
|
|
80
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
81
|
+
const headers = {
|
|
82
|
+
"content-type": "application/json",
|
|
83
|
+
};
|
|
84
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/origin_endpoints";
|
|
85
|
+
let body;
|
|
86
|
+
body = JSON.stringify({
|
|
87
|
+
...(input.Authorization != null && {
|
|
88
|
+
authorization: serializeAws_restJson1Authorization(input.Authorization, context),
|
|
89
|
+
}),
|
|
90
|
+
...(input.ChannelId != null && { channelId: input.ChannelId }),
|
|
91
|
+
...(input.CmafPackage != null && {
|
|
92
|
+
cmafPackage: serializeAws_restJson1CmafPackageCreateOrUpdateParameters(input.CmafPackage, context),
|
|
93
|
+
}),
|
|
94
|
+
...(input.DashPackage != null && { dashPackage: serializeAws_restJson1DashPackage(input.DashPackage, context) }),
|
|
95
|
+
...(input.Description != null && { description: input.Description }),
|
|
96
|
+
...(input.HlsPackage != null && { hlsPackage: serializeAws_restJson1HlsPackage(input.HlsPackage, context) }),
|
|
97
|
+
...(input.Id != null && { id: input.Id }),
|
|
98
|
+
...(input.ManifestName != null && { manifestName: input.ManifestName }),
|
|
99
|
+
...(input.MssPackage != null && { mssPackage: serializeAws_restJson1MssPackage(input.MssPackage, context) }),
|
|
100
|
+
...(input.Origination != null && { origination: input.Origination }),
|
|
101
|
+
...(input.StartoverWindowSeconds != null && { startoverWindowSeconds: input.StartoverWindowSeconds }),
|
|
102
|
+
...(input.Tags != null && { tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
103
|
+
...(input.TimeDelaySeconds != null && { timeDelaySeconds: input.TimeDelaySeconds }),
|
|
104
|
+
...(input.Whitelist != null && { whitelist: serializeAws_restJson1__listOf__string(input.Whitelist, context) }),
|
|
105
|
+
});
|
|
106
|
+
return new __HttpRequest({
|
|
107
|
+
protocol,
|
|
108
|
+
hostname,
|
|
109
|
+
port,
|
|
110
|
+
method: "POST",
|
|
111
|
+
headers,
|
|
112
|
+
path: resolvedPath,
|
|
113
|
+
body,
|
|
370
114
|
});
|
|
371
|
-
}
|
|
372
|
-
export
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
protocol: protocol,
|
|
387
|
-
hostname: hostname,
|
|
388
|
-
port: port,
|
|
389
|
-
method: "POST",
|
|
390
|
-
headers: headers,
|
|
391
|
-
path: resolvedPath,
|
|
392
|
-
body: body,
|
|
393
|
-
})];
|
|
394
|
-
}
|
|
115
|
+
};
|
|
116
|
+
export const serializeAws_restJson1DeleteChannelCommand = async (input, context) => {
|
|
117
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
118
|
+
const headers = {};
|
|
119
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels/{Id}";
|
|
120
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
121
|
+
let body;
|
|
122
|
+
return new __HttpRequest({
|
|
123
|
+
protocol,
|
|
124
|
+
hostname,
|
|
125
|
+
port,
|
|
126
|
+
method: "DELETE",
|
|
127
|
+
headers,
|
|
128
|
+
path: resolvedPath,
|
|
129
|
+
body,
|
|
395
130
|
});
|
|
396
|
-
}
|
|
397
|
-
export
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
protocol: protocol,
|
|
412
|
-
hostname: hostname,
|
|
413
|
-
port: port,
|
|
414
|
-
method: "DELETE",
|
|
415
|
-
headers: headers,
|
|
416
|
-
path: resolvedPath,
|
|
417
|
-
query: query,
|
|
418
|
-
body: body,
|
|
419
|
-
})];
|
|
420
|
-
}
|
|
131
|
+
};
|
|
132
|
+
export const serializeAws_restJson1DeleteOriginEndpointCommand = async (input, context) => {
|
|
133
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
134
|
+
const headers = {};
|
|
135
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/origin_endpoints/{Id}";
|
|
136
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
137
|
+
let body;
|
|
138
|
+
return new __HttpRequest({
|
|
139
|
+
protocol,
|
|
140
|
+
hostname,
|
|
141
|
+
port,
|
|
142
|
+
method: "DELETE",
|
|
143
|
+
headers,
|
|
144
|
+
path: resolvedPath,
|
|
145
|
+
body,
|
|
421
146
|
});
|
|
422
|
-
}
|
|
423
|
-
export
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
protocol: protocol,
|
|
438
|
-
hostname: hostname,
|
|
439
|
-
port: port,
|
|
440
|
-
method: "PUT",
|
|
441
|
-
headers: headers,
|
|
442
|
-
path: resolvedPath,
|
|
443
|
-
body: body,
|
|
444
|
-
})];
|
|
445
|
-
}
|
|
147
|
+
};
|
|
148
|
+
export const serializeAws_restJson1DescribeChannelCommand = async (input, context) => {
|
|
149
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
150
|
+
const headers = {};
|
|
151
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels/{Id}";
|
|
152
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
153
|
+
let body;
|
|
154
|
+
return new __HttpRequest({
|
|
155
|
+
protocol,
|
|
156
|
+
hostname,
|
|
157
|
+
port,
|
|
158
|
+
method: "GET",
|
|
159
|
+
headers,
|
|
160
|
+
path: resolvedPath,
|
|
161
|
+
body,
|
|
446
162
|
});
|
|
447
|
-
}
|
|
448
|
-
export
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
})), (input.CmafPackage != null && {
|
|
463
|
-
cmafPackage: serializeAws_restJson1CmafPackageCreateOrUpdateParameters(input.CmafPackage, context),
|
|
464
|
-
})), (input.DashPackage != null && { dashPackage: serializeAws_restJson1DashPackage(input.DashPackage, context) })), (input.Description != null && { description: input.Description })), (input.HlsPackage != null && { hlsPackage: serializeAws_restJson1HlsPackage(input.HlsPackage, context) })), (input.ManifestName != null && { manifestName: input.ManifestName })), (input.MssPackage != null && { mssPackage: serializeAws_restJson1MssPackage(input.MssPackage, context) })), (input.Origination != null && { origination: input.Origination })), (input.StartoverWindowSeconds != null && { startoverWindowSeconds: input.StartoverWindowSeconds })), (input.TimeDelaySeconds != null && { timeDelaySeconds: input.TimeDelaySeconds })), (input.Whitelist != null && { whitelist: serializeAws_restJson1__listOf__string(input.Whitelist, context) })));
|
|
465
|
-
return [2, new __HttpRequest({
|
|
466
|
-
protocol: protocol,
|
|
467
|
-
hostname: hostname,
|
|
468
|
-
port: port,
|
|
469
|
-
method: "PUT",
|
|
470
|
-
headers: headers,
|
|
471
|
-
path: resolvedPath,
|
|
472
|
-
body: body,
|
|
473
|
-
})];
|
|
474
|
-
}
|
|
163
|
+
};
|
|
164
|
+
export const serializeAws_restJson1DescribeHarvestJobCommand = async (input, context) => {
|
|
165
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
166
|
+
const headers = {};
|
|
167
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/harvest_jobs/{Id}";
|
|
168
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
169
|
+
let body;
|
|
170
|
+
return new __HttpRequest({
|
|
171
|
+
protocol,
|
|
172
|
+
hostname,
|
|
173
|
+
port,
|
|
174
|
+
method: "GET",
|
|
175
|
+
headers,
|
|
176
|
+
path: resolvedPath,
|
|
177
|
+
body,
|
|
475
178
|
});
|
|
476
|
-
}
|
|
477
|
-
export
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
case 1:
|
|
492
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
493
|
-
if (data.arn != null) {
|
|
494
|
-
contents.Arn = __expectString(data.arn);
|
|
495
|
-
}
|
|
496
|
-
if (data.description != null) {
|
|
497
|
-
contents.Description = __expectString(data.description);
|
|
498
|
-
}
|
|
499
|
-
if (data.egressAccessLogs != null) {
|
|
500
|
-
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
501
|
-
}
|
|
502
|
-
if (data.hlsIngest != null) {
|
|
503
|
-
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
504
|
-
}
|
|
505
|
-
if (data.id != null) {
|
|
506
|
-
contents.Id = __expectString(data.id);
|
|
507
|
-
}
|
|
508
|
-
if (data.ingressAccessLogs != null) {
|
|
509
|
-
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
510
|
-
}
|
|
511
|
-
if (data.tags != null) {
|
|
512
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
513
|
-
}
|
|
514
|
-
return [2, contents];
|
|
515
|
-
}
|
|
179
|
+
};
|
|
180
|
+
export const serializeAws_restJson1DescribeOriginEndpointCommand = async (input, context) => {
|
|
181
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
182
|
+
const headers = {};
|
|
183
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/origin_endpoints/{Id}";
|
|
184
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
185
|
+
let body;
|
|
186
|
+
return new __HttpRequest({
|
|
187
|
+
protocol,
|
|
188
|
+
hostname,
|
|
189
|
+
port,
|
|
190
|
+
method: "GET",
|
|
191
|
+
headers,
|
|
192
|
+
path: resolvedPath,
|
|
193
|
+
body,
|
|
516
194
|
});
|
|
517
|
-
}
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
case "NotFoundException": return [3, 6];
|
|
537
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
538
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
539
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
540
|
-
case "TooManyRequestsException": return [3, 10];
|
|
541
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
542
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
543
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
544
|
-
}
|
|
545
|
-
return [3, 14];
|
|
546
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
547
|
-
case 3: throw _d.sent();
|
|
548
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
549
|
-
case 5: throw _d.sent();
|
|
550
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
551
|
-
case 7: throw _d.sent();
|
|
552
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
553
|
-
case 9: throw _d.sent();
|
|
554
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
555
|
-
case 11: throw _d.sent();
|
|
556
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
557
|
-
case 13: throw _d.sent();
|
|
558
|
-
case 14:
|
|
559
|
-
parsedBody = parsedOutput.body;
|
|
560
|
-
throwDefaultError({
|
|
561
|
-
output: output,
|
|
562
|
-
parsedBody: parsedBody,
|
|
563
|
-
exceptionCtor: __BaseException,
|
|
564
|
-
errorCode: errorCode,
|
|
565
|
-
});
|
|
566
|
-
_d.label = 15;
|
|
567
|
-
case 15: return [2];
|
|
568
|
-
}
|
|
195
|
+
};
|
|
196
|
+
export const serializeAws_restJson1ListChannelsCommand = async (input, context) => {
|
|
197
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
198
|
+
const headers = {};
|
|
199
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels";
|
|
200
|
+
const query = map({
|
|
201
|
+
maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
|
|
202
|
+
nextToken: [, input.NextToken],
|
|
203
|
+
});
|
|
204
|
+
let body;
|
|
205
|
+
return new __HttpRequest({
|
|
206
|
+
protocol,
|
|
207
|
+
hostname,
|
|
208
|
+
port,
|
|
209
|
+
method: "GET",
|
|
210
|
+
headers,
|
|
211
|
+
path: resolvedPath,
|
|
212
|
+
query,
|
|
213
|
+
body,
|
|
569
214
|
});
|
|
570
|
-
}
|
|
571
|
-
export
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
contents.Description = __expectString(data.description);
|
|
592
|
-
}
|
|
593
|
-
if (data.egressAccessLogs != null) {
|
|
594
|
-
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
595
|
-
}
|
|
596
|
-
if (data.hlsIngest != null) {
|
|
597
|
-
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
598
|
-
}
|
|
599
|
-
if (data.id != null) {
|
|
600
|
-
contents.Id = __expectString(data.id);
|
|
601
|
-
}
|
|
602
|
-
if (data.ingressAccessLogs != null) {
|
|
603
|
-
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
604
|
-
}
|
|
605
|
-
if (data.tags != null) {
|
|
606
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
607
|
-
}
|
|
608
|
-
return [2, contents];
|
|
609
|
-
}
|
|
215
|
+
};
|
|
216
|
+
export const serializeAws_restJson1ListHarvestJobsCommand = async (input, context) => {
|
|
217
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
218
|
+
const headers = {};
|
|
219
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/harvest_jobs";
|
|
220
|
+
const query = map({
|
|
221
|
+
includeChannelId: [, input.IncludeChannelId],
|
|
222
|
+
includeStatus: [, input.IncludeStatus],
|
|
223
|
+
maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
|
|
224
|
+
nextToken: [, input.NextToken],
|
|
225
|
+
});
|
|
226
|
+
let body;
|
|
227
|
+
return new __HttpRequest({
|
|
228
|
+
protocol,
|
|
229
|
+
hostname,
|
|
230
|
+
port,
|
|
231
|
+
method: "GET",
|
|
232
|
+
headers,
|
|
233
|
+
path: resolvedPath,
|
|
234
|
+
query,
|
|
235
|
+
body,
|
|
610
236
|
});
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
632
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
633
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
634
|
-
case "TooManyRequestsException": return [3, 10];
|
|
635
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
636
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
637
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
638
|
-
}
|
|
639
|
-
return [3, 14];
|
|
640
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
641
|
-
case 3: throw _d.sent();
|
|
642
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
643
|
-
case 5: throw _d.sent();
|
|
644
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
645
|
-
case 7: throw _d.sent();
|
|
646
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
647
|
-
case 9: throw _d.sent();
|
|
648
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
649
|
-
case 11: throw _d.sent();
|
|
650
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
651
|
-
case 13: throw _d.sent();
|
|
652
|
-
case 14:
|
|
653
|
-
parsedBody = parsedOutput.body;
|
|
654
|
-
throwDefaultError({
|
|
655
|
-
output: output,
|
|
656
|
-
parsedBody: parsedBody,
|
|
657
|
-
exceptionCtor: __BaseException,
|
|
658
|
-
errorCode: errorCode,
|
|
659
|
-
});
|
|
660
|
-
_d.label = 15;
|
|
661
|
-
case 15: return [2];
|
|
662
|
-
}
|
|
237
|
+
};
|
|
238
|
+
export const serializeAws_restJson1ListOriginEndpointsCommand = async (input, context) => {
|
|
239
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
240
|
+
const headers = {};
|
|
241
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/origin_endpoints";
|
|
242
|
+
const query = map({
|
|
243
|
+
channelId: [, input.ChannelId],
|
|
244
|
+
maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults.toString()],
|
|
245
|
+
nextToken: [, input.NextToken],
|
|
246
|
+
});
|
|
247
|
+
let body;
|
|
248
|
+
return new __HttpRequest({
|
|
249
|
+
protocol,
|
|
250
|
+
hostname,
|
|
251
|
+
port,
|
|
252
|
+
method: "GET",
|
|
253
|
+
headers,
|
|
254
|
+
path: resolvedPath,
|
|
255
|
+
query,
|
|
256
|
+
body,
|
|
663
257
|
});
|
|
664
|
-
}
|
|
665
|
-
export
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
case 1:
|
|
680
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
681
|
-
if (data.arn != null) {
|
|
682
|
-
contents.Arn = __expectString(data.arn);
|
|
683
|
-
}
|
|
684
|
-
if (data.channelId != null) {
|
|
685
|
-
contents.ChannelId = __expectString(data.channelId);
|
|
686
|
-
}
|
|
687
|
-
if (data.createdAt != null) {
|
|
688
|
-
contents.CreatedAt = __expectString(data.createdAt);
|
|
689
|
-
}
|
|
690
|
-
if (data.endTime != null) {
|
|
691
|
-
contents.EndTime = __expectString(data.endTime);
|
|
692
|
-
}
|
|
693
|
-
if (data.id != null) {
|
|
694
|
-
contents.Id = __expectString(data.id);
|
|
695
|
-
}
|
|
696
|
-
if (data.originEndpointId != null) {
|
|
697
|
-
contents.OriginEndpointId = __expectString(data.originEndpointId);
|
|
698
|
-
}
|
|
699
|
-
if (data.s3Destination != null) {
|
|
700
|
-
contents.S3Destination = deserializeAws_restJson1S3Destination(data.s3Destination, context);
|
|
701
|
-
}
|
|
702
|
-
if (data.startTime != null) {
|
|
703
|
-
contents.StartTime = __expectString(data.startTime);
|
|
704
|
-
}
|
|
705
|
-
if (data.status != null) {
|
|
706
|
-
contents.Status = __expectString(data.status);
|
|
707
|
-
}
|
|
708
|
-
return [2, contents];
|
|
709
|
-
}
|
|
258
|
+
};
|
|
259
|
+
export const serializeAws_restJson1ListTagsForResourceCommand = async (input, context) => {
|
|
260
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
261
|
+
const headers = {};
|
|
262
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}";
|
|
263
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
264
|
+
let body;
|
|
265
|
+
return new __HttpRequest({
|
|
266
|
+
protocol,
|
|
267
|
+
hostname,
|
|
268
|
+
port,
|
|
269
|
+
method: "GET",
|
|
270
|
+
headers,
|
|
271
|
+
path: resolvedPath,
|
|
272
|
+
body,
|
|
710
273
|
});
|
|
711
|
-
}
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
case "ForbiddenException": return [3, 2];
|
|
727
|
-
case "com.amazonaws.mediapackage#ForbiddenException": return [3, 2];
|
|
728
|
-
case "InternalServerErrorException": return [3, 4];
|
|
729
|
-
case "com.amazonaws.mediapackage#InternalServerErrorException": return [3, 4];
|
|
730
|
-
case "NotFoundException": return [3, 6];
|
|
731
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
732
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
733
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
734
|
-
case "TooManyRequestsException": return [3, 10];
|
|
735
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
736
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
737
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
738
|
-
}
|
|
739
|
-
return [3, 14];
|
|
740
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
741
|
-
case 3: throw _d.sent();
|
|
742
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
743
|
-
case 5: throw _d.sent();
|
|
744
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
745
|
-
case 7: throw _d.sent();
|
|
746
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
747
|
-
case 9: throw _d.sent();
|
|
748
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
749
|
-
case 11: throw _d.sent();
|
|
750
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
751
|
-
case 13: throw _d.sent();
|
|
752
|
-
case 14:
|
|
753
|
-
parsedBody = parsedOutput.body;
|
|
754
|
-
throwDefaultError({
|
|
755
|
-
output: output,
|
|
756
|
-
parsedBody: parsedBody,
|
|
757
|
-
exceptionCtor: __BaseException,
|
|
758
|
-
errorCode: errorCode,
|
|
759
|
-
});
|
|
760
|
-
_d.label = 15;
|
|
761
|
-
case 15: return [2];
|
|
762
|
-
}
|
|
274
|
+
};
|
|
275
|
+
export const serializeAws_restJson1RotateChannelCredentialsCommand = async (input, context) => {
|
|
276
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
277
|
+
const headers = {};
|
|
278
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels/{Id}/credentials";
|
|
279
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
280
|
+
let body;
|
|
281
|
+
return new __HttpRequest({
|
|
282
|
+
protocol,
|
|
283
|
+
hostname,
|
|
284
|
+
port,
|
|
285
|
+
method: "PUT",
|
|
286
|
+
headers,
|
|
287
|
+
path: resolvedPath,
|
|
288
|
+
body,
|
|
763
289
|
});
|
|
764
|
-
}
|
|
765
|
-
export
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
if (data.arn != null) {
|
|
782
|
-
contents.Arn = __expectString(data.arn);
|
|
783
|
-
}
|
|
784
|
-
if (data.authorization != null) {
|
|
785
|
-
contents.Authorization = deserializeAws_restJson1Authorization(data.authorization, context);
|
|
786
|
-
}
|
|
787
|
-
if (data.channelId != null) {
|
|
788
|
-
contents.ChannelId = __expectString(data.channelId);
|
|
789
|
-
}
|
|
790
|
-
if (data.cmafPackage != null) {
|
|
791
|
-
contents.CmafPackage = deserializeAws_restJson1CmafPackage(data.cmafPackage, context);
|
|
792
|
-
}
|
|
793
|
-
if (data.dashPackage != null) {
|
|
794
|
-
contents.DashPackage = deserializeAws_restJson1DashPackage(data.dashPackage, context);
|
|
795
|
-
}
|
|
796
|
-
if (data.description != null) {
|
|
797
|
-
contents.Description = __expectString(data.description);
|
|
798
|
-
}
|
|
799
|
-
if (data.hlsPackage != null) {
|
|
800
|
-
contents.HlsPackage = deserializeAws_restJson1HlsPackage(data.hlsPackage, context);
|
|
801
|
-
}
|
|
802
|
-
if (data.id != null) {
|
|
803
|
-
contents.Id = __expectString(data.id);
|
|
804
|
-
}
|
|
805
|
-
if (data.manifestName != null) {
|
|
806
|
-
contents.ManifestName = __expectString(data.manifestName);
|
|
807
|
-
}
|
|
808
|
-
if (data.mssPackage != null) {
|
|
809
|
-
contents.MssPackage = deserializeAws_restJson1MssPackage(data.mssPackage, context);
|
|
810
|
-
}
|
|
811
|
-
if (data.origination != null) {
|
|
812
|
-
contents.Origination = __expectString(data.origination);
|
|
813
|
-
}
|
|
814
|
-
if (data.startoverWindowSeconds != null) {
|
|
815
|
-
contents.StartoverWindowSeconds = __expectInt32(data.startoverWindowSeconds);
|
|
816
|
-
}
|
|
817
|
-
if (data.tags != null) {
|
|
818
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
819
|
-
}
|
|
820
|
-
if (data.timeDelaySeconds != null) {
|
|
821
|
-
contents.TimeDelaySeconds = __expectInt32(data.timeDelaySeconds);
|
|
822
|
-
}
|
|
823
|
-
if (data.url != null) {
|
|
824
|
-
contents.Url = __expectString(data.url);
|
|
825
|
-
}
|
|
826
|
-
if (data.whitelist != null) {
|
|
827
|
-
contents.Whitelist = deserializeAws_restJson1__listOf__string(data.whitelist, context);
|
|
828
|
-
}
|
|
829
|
-
return [2, contents];
|
|
830
|
-
}
|
|
290
|
+
};
|
|
291
|
+
export const serializeAws_restJson1RotateIngestEndpointCredentialsCommand = async (input, context) => {
|
|
292
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
293
|
+
const headers = {};
|
|
294
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
295
|
+
"/channels/{Id}/ingest_endpoints/{IngestEndpointId}/credentials";
|
|
296
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
297
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "IngestEndpointId", () => input.IngestEndpointId, "{IngestEndpointId}", false);
|
|
298
|
+
let body;
|
|
299
|
+
return new __HttpRequest({
|
|
300
|
+
protocol,
|
|
301
|
+
hostname,
|
|
302
|
+
port,
|
|
303
|
+
method: "PUT",
|
|
304
|
+
headers,
|
|
305
|
+
path: resolvedPath,
|
|
306
|
+
body,
|
|
831
307
|
});
|
|
832
|
-
}
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
853
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
854
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
855
|
-
case "TooManyRequestsException": return [3, 10];
|
|
856
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
857
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
858
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
859
|
-
}
|
|
860
|
-
return [3, 14];
|
|
861
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
862
|
-
case 3: throw _d.sent();
|
|
863
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
864
|
-
case 5: throw _d.sent();
|
|
865
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
866
|
-
case 7: throw _d.sent();
|
|
867
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
868
|
-
case 9: throw _d.sent();
|
|
869
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
870
|
-
case 11: throw _d.sent();
|
|
871
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
872
|
-
case 13: throw _d.sent();
|
|
873
|
-
case 14:
|
|
874
|
-
parsedBody = parsedOutput.body;
|
|
875
|
-
throwDefaultError({
|
|
876
|
-
output: output,
|
|
877
|
-
parsedBody: parsedBody,
|
|
878
|
-
exceptionCtor: __BaseException,
|
|
879
|
-
errorCode: errorCode,
|
|
880
|
-
});
|
|
881
|
-
_d.label = 15;
|
|
882
|
-
case 15: return [2];
|
|
883
|
-
}
|
|
308
|
+
};
|
|
309
|
+
export const serializeAws_restJson1TagResourceCommand = async (input, context) => {
|
|
310
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
311
|
+
const headers = {
|
|
312
|
+
"content-type": "application/json",
|
|
313
|
+
};
|
|
314
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}";
|
|
315
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
316
|
+
let body;
|
|
317
|
+
body = JSON.stringify({
|
|
318
|
+
...(input.Tags != null && { tags: serializeAws_restJson1__mapOf__string(input.Tags, context) }),
|
|
319
|
+
});
|
|
320
|
+
return new __HttpRequest({
|
|
321
|
+
protocol,
|
|
322
|
+
hostname,
|
|
323
|
+
port,
|
|
324
|
+
method: "POST",
|
|
325
|
+
headers,
|
|
326
|
+
path: resolvedPath,
|
|
327
|
+
body,
|
|
884
328
|
});
|
|
885
|
-
}
|
|
886
|
-
export
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
329
|
+
};
|
|
330
|
+
export const serializeAws_restJson1UntagResourceCommand = async (input, context) => {
|
|
331
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
332
|
+
const headers = {};
|
|
333
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}";
|
|
334
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
|
|
335
|
+
const query = map({
|
|
336
|
+
tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys || []).map((_entry) => _entry)],
|
|
337
|
+
});
|
|
338
|
+
let body;
|
|
339
|
+
return new __HttpRequest({
|
|
340
|
+
protocol,
|
|
341
|
+
hostname,
|
|
342
|
+
port,
|
|
343
|
+
method: "DELETE",
|
|
344
|
+
headers,
|
|
345
|
+
path: resolvedPath,
|
|
346
|
+
query,
|
|
347
|
+
body,
|
|
902
348
|
});
|
|
903
|
-
}
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
924
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
925
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
926
|
-
case "TooManyRequestsException": return [3, 10];
|
|
927
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
928
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
929
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
930
|
-
}
|
|
931
|
-
return [3, 14];
|
|
932
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
933
|
-
case 3: throw _d.sent();
|
|
934
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
935
|
-
case 5: throw _d.sent();
|
|
936
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
937
|
-
case 7: throw _d.sent();
|
|
938
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
939
|
-
case 9: throw _d.sent();
|
|
940
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
941
|
-
case 11: throw _d.sent();
|
|
942
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
943
|
-
case 13: throw _d.sent();
|
|
944
|
-
case 14:
|
|
945
|
-
parsedBody = parsedOutput.body;
|
|
946
|
-
throwDefaultError({
|
|
947
|
-
output: output,
|
|
948
|
-
parsedBody: parsedBody,
|
|
949
|
-
exceptionCtor: __BaseException,
|
|
950
|
-
errorCode: errorCode,
|
|
951
|
-
});
|
|
952
|
-
_d.label = 15;
|
|
953
|
-
case 15: return [2];
|
|
954
|
-
}
|
|
349
|
+
};
|
|
350
|
+
export const serializeAws_restJson1UpdateChannelCommand = async (input, context) => {
|
|
351
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
352
|
+
const headers = {
|
|
353
|
+
"content-type": "application/json",
|
|
354
|
+
};
|
|
355
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels/{Id}";
|
|
356
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
357
|
+
let body;
|
|
358
|
+
body = JSON.stringify({
|
|
359
|
+
...(input.Description != null && { description: input.Description }),
|
|
360
|
+
});
|
|
361
|
+
return new __HttpRequest({
|
|
362
|
+
protocol,
|
|
363
|
+
hostname,
|
|
364
|
+
port,
|
|
365
|
+
method: "PUT",
|
|
366
|
+
headers,
|
|
367
|
+
path: resolvedPath,
|
|
368
|
+
body,
|
|
955
369
|
});
|
|
956
|
-
}
|
|
957
|
-
export
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
}
|
|
370
|
+
};
|
|
371
|
+
export const serializeAws_restJson1UpdateOriginEndpointCommand = async (input, context) => {
|
|
372
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
373
|
+
const headers = {
|
|
374
|
+
"content-type": "application/json",
|
|
375
|
+
};
|
|
376
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/origin_endpoints/{Id}";
|
|
377
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id, "{Id}", false);
|
|
378
|
+
let body;
|
|
379
|
+
body = JSON.stringify({
|
|
380
|
+
...(input.Authorization != null && {
|
|
381
|
+
authorization: serializeAws_restJson1Authorization(input.Authorization, context),
|
|
382
|
+
}),
|
|
383
|
+
...(input.CmafPackage != null && {
|
|
384
|
+
cmafPackage: serializeAws_restJson1CmafPackageCreateOrUpdateParameters(input.CmafPackage, context),
|
|
385
|
+
}),
|
|
386
|
+
...(input.DashPackage != null && { dashPackage: serializeAws_restJson1DashPackage(input.DashPackage, context) }),
|
|
387
|
+
...(input.Description != null && { description: input.Description }),
|
|
388
|
+
...(input.HlsPackage != null && { hlsPackage: serializeAws_restJson1HlsPackage(input.HlsPackage, context) }),
|
|
389
|
+
...(input.ManifestName != null && { manifestName: input.ManifestName }),
|
|
390
|
+
...(input.MssPackage != null && { mssPackage: serializeAws_restJson1MssPackage(input.MssPackage, context) }),
|
|
391
|
+
...(input.Origination != null && { origination: input.Origination }),
|
|
392
|
+
...(input.StartoverWindowSeconds != null && { startoverWindowSeconds: input.StartoverWindowSeconds }),
|
|
393
|
+
...(input.TimeDelaySeconds != null && { timeDelaySeconds: input.TimeDelaySeconds }),
|
|
394
|
+
...(input.Whitelist != null && { whitelist: serializeAws_restJson1__listOf__string(input.Whitelist, context) }),
|
|
395
|
+
});
|
|
396
|
+
return new __HttpRequest({
|
|
397
|
+
protocol,
|
|
398
|
+
hostname,
|
|
399
|
+
port,
|
|
400
|
+
method: "PUT",
|
|
401
|
+
headers,
|
|
402
|
+
path: resolvedPath,
|
|
403
|
+
body,
|
|
973
404
|
});
|
|
974
|
-
}
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
_a = [__assign({}, output)];
|
|
982
|
-
_c = {};
|
|
983
|
-
return [4, parseBody(output.body, context)];
|
|
984
|
-
case 1:
|
|
985
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
986
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
987
|
-
_b = errorCode;
|
|
988
|
-
switch (_b) {
|
|
989
|
-
case "ForbiddenException": return [3, 2];
|
|
990
|
-
case "com.amazonaws.mediapackage#ForbiddenException": return [3, 2];
|
|
991
|
-
case "InternalServerErrorException": return [3, 4];
|
|
992
|
-
case "com.amazonaws.mediapackage#InternalServerErrorException": return [3, 4];
|
|
993
|
-
case "NotFoundException": return [3, 6];
|
|
994
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
995
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
996
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
997
|
-
case "TooManyRequestsException": return [3, 10];
|
|
998
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
999
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
1000
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
1001
|
-
}
|
|
1002
|
-
return [3, 14];
|
|
1003
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
1004
|
-
case 3: throw _d.sent();
|
|
1005
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
1006
|
-
case 5: throw _d.sent();
|
|
1007
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
1008
|
-
case 7: throw _d.sent();
|
|
1009
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
1010
|
-
case 9: throw _d.sent();
|
|
1011
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
1012
|
-
case 11: throw _d.sent();
|
|
1013
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
1014
|
-
case 13: throw _d.sent();
|
|
1015
|
-
case 14:
|
|
1016
|
-
parsedBody = parsedOutput.body;
|
|
1017
|
-
throwDefaultError({
|
|
1018
|
-
output: output,
|
|
1019
|
-
parsedBody: parsedBody,
|
|
1020
|
-
exceptionCtor: __BaseException,
|
|
1021
|
-
errorCode: errorCode,
|
|
1022
|
-
});
|
|
1023
|
-
_d.label = 15;
|
|
1024
|
-
case 15: return [2];
|
|
1025
|
-
}
|
|
405
|
+
};
|
|
406
|
+
export const deserializeAws_restJson1ConfigureLogsCommand = async (output, context) => {
|
|
407
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
408
|
+
return deserializeAws_restJson1ConfigureLogsCommandError(output, context);
|
|
409
|
+
}
|
|
410
|
+
const contents = map({
|
|
411
|
+
$metadata: deserializeMetadata(output),
|
|
1026
412
|
});
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
413
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
414
|
+
if (data.arn != null) {
|
|
415
|
+
contents.Arn = __expectString(data.arn);
|
|
416
|
+
}
|
|
417
|
+
if (data.description != null) {
|
|
418
|
+
contents.Description = __expectString(data.description);
|
|
419
|
+
}
|
|
420
|
+
if (data.egressAccessLogs != null) {
|
|
421
|
+
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
422
|
+
}
|
|
423
|
+
if (data.hlsIngest != null) {
|
|
424
|
+
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
425
|
+
}
|
|
426
|
+
if (data.id != null) {
|
|
427
|
+
contents.Id = __expectString(data.id);
|
|
428
|
+
}
|
|
429
|
+
if (data.ingressAccessLogs != null) {
|
|
430
|
+
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
431
|
+
}
|
|
432
|
+
if (data.tags != null) {
|
|
433
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
434
|
+
}
|
|
435
|
+
return contents;
|
|
436
|
+
};
|
|
437
|
+
const deserializeAws_restJson1ConfigureLogsCommandError = async (output, context) => {
|
|
438
|
+
const parsedOutput = {
|
|
439
|
+
...output,
|
|
440
|
+
body: await parseErrorBody(output.body, context),
|
|
441
|
+
};
|
|
442
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
443
|
+
switch (errorCode) {
|
|
444
|
+
case "ForbiddenException":
|
|
445
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
446
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
447
|
+
case "InternalServerErrorException":
|
|
448
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
449
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
450
|
+
case "NotFoundException":
|
|
451
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
452
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
453
|
+
case "ServiceUnavailableException":
|
|
454
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
455
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
456
|
+
case "TooManyRequestsException":
|
|
457
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
458
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
459
|
+
case "UnprocessableEntityException":
|
|
460
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
461
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
462
|
+
default:
|
|
463
|
+
const parsedBody = parsedOutput.body;
|
|
464
|
+
throwDefaultError({
|
|
465
|
+
output,
|
|
466
|
+
parsedBody,
|
|
467
|
+
exceptionCtor: __BaseException,
|
|
468
|
+
errorCode,
|
|
469
|
+
});
|
|
470
|
+
}
|
|
471
|
+
};
|
|
472
|
+
export const deserializeAws_restJson1CreateChannelCommand = async (output, context) => {
|
|
473
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
474
|
+
return deserializeAws_restJson1CreateChannelCommandError(output, context);
|
|
475
|
+
}
|
|
476
|
+
const contents = map({
|
|
477
|
+
$metadata: deserializeMetadata(output),
|
|
1067
478
|
});
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
479
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
480
|
+
if (data.arn != null) {
|
|
481
|
+
contents.Arn = __expectString(data.arn);
|
|
482
|
+
}
|
|
483
|
+
if (data.description != null) {
|
|
484
|
+
contents.Description = __expectString(data.description);
|
|
485
|
+
}
|
|
486
|
+
if (data.egressAccessLogs != null) {
|
|
487
|
+
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
488
|
+
}
|
|
489
|
+
if (data.hlsIngest != null) {
|
|
490
|
+
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
491
|
+
}
|
|
492
|
+
if (data.id != null) {
|
|
493
|
+
contents.Id = __expectString(data.id);
|
|
494
|
+
}
|
|
495
|
+
if (data.ingressAccessLogs != null) {
|
|
496
|
+
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
497
|
+
}
|
|
498
|
+
if (data.tags != null) {
|
|
499
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
500
|
+
}
|
|
501
|
+
return contents;
|
|
502
|
+
};
|
|
503
|
+
const deserializeAws_restJson1CreateChannelCommandError = async (output, context) => {
|
|
504
|
+
const parsedOutput = {
|
|
505
|
+
...output,
|
|
506
|
+
body: await parseErrorBody(output.body, context),
|
|
507
|
+
};
|
|
508
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
509
|
+
switch (errorCode) {
|
|
510
|
+
case "ForbiddenException":
|
|
511
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
512
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
513
|
+
case "InternalServerErrorException":
|
|
514
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
515
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
516
|
+
case "NotFoundException":
|
|
517
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
518
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
519
|
+
case "ServiceUnavailableException":
|
|
520
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
521
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
522
|
+
case "TooManyRequestsException":
|
|
523
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
524
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
525
|
+
case "UnprocessableEntityException":
|
|
526
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
527
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
528
|
+
default:
|
|
529
|
+
const parsedBody = parsedOutput.body;
|
|
530
|
+
throwDefaultError({
|
|
531
|
+
output,
|
|
532
|
+
parsedBody,
|
|
533
|
+
exceptionCtor: __BaseException,
|
|
534
|
+
errorCode,
|
|
535
|
+
});
|
|
536
|
+
}
|
|
537
|
+
};
|
|
538
|
+
export const deserializeAws_restJson1CreateHarvestJobCommand = async (output, context) => {
|
|
539
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
540
|
+
return deserializeAws_restJson1CreateHarvestJobCommandError(output, context);
|
|
541
|
+
}
|
|
542
|
+
const contents = map({
|
|
543
|
+
$metadata: deserializeMetadata(output),
|
|
1120
544
|
});
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
545
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
546
|
+
if (data.arn != null) {
|
|
547
|
+
contents.Arn = __expectString(data.arn);
|
|
548
|
+
}
|
|
549
|
+
if (data.channelId != null) {
|
|
550
|
+
contents.ChannelId = __expectString(data.channelId);
|
|
551
|
+
}
|
|
552
|
+
if (data.createdAt != null) {
|
|
553
|
+
contents.CreatedAt = __expectString(data.createdAt);
|
|
554
|
+
}
|
|
555
|
+
if (data.endTime != null) {
|
|
556
|
+
contents.EndTime = __expectString(data.endTime);
|
|
557
|
+
}
|
|
558
|
+
if (data.id != null) {
|
|
559
|
+
contents.Id = __expectString(data.id);
|
|
560
|
+
}
|
|
561
|
+
if (data.originEndpointId != null) {
|
|
562
|
+
contents.OriginEndpointId = __expectString(data.originEndpointId);
|
|
563
|
+
}
|
|
564
|
+
if (data.s3Destination != null) {
|
|
565
|
+
contents.S3Destination = deserializeAws_restJson1S3Destination(data.s3Destination, context);
|
|
566
|
+
}
|
|
567
|
+
if (data.startTime != null) {
|
|
568
|
+
contents.StartTime = __expectString(data.startTime);
|
|
569
|
+
}
|
|
570
|
+
if (data.status != null) {
|
|
571
|
+
contents.Status = __expectString(data.status);
|
|
572
|
+
}
|
|
573
|
+
return contents;
|
|
574
|
+
};
|
|
575
|
+
const deserializeAws_restJson1CreateHarvestJobCommandError = async (output, context) => {
|
|
576
|
+
const parsedOutput = {
|
|
577
|
+
...output,
|
|
578
|
+
body: await parseErrorBody(output.body, context),
|
|
579
|
+
};
|
|
580
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
581
|
+
switch (errorCode) {
|
|
582
|
+
case "ForbiddenException":
|
|
583
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
584
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
585
|
+
case "InternalServerErrorException":
|
|
586
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
587
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
588
|
+
case "NotFoundException":
|
|
589
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
590
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
591
|
+
case "ServiceUnavailableException":
|
|
592
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
593
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
594
|
+
case "TooManyRequestsException":
|
|
595
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
596
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
597
|
+
case "UnprocessableEntityException":
|
|
598
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
599
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
600
|
+
default:
|
|
601
|
+
const parsedBody = parsedOutput.body;
|
|
602
|
+
throwDefaultError({
|
|
603
|
+
output,
|
|
604
|
+
parsedBody,
|
|
605
|
+
exceptionCtor: __BaseException,
|
|
606
|
+
errorCode,
|
|
607
|
+
});
|
|
608
|
+
}
|
|
609
|
+
};
|
|
610
|
+
export const deserializeAws_restJson1CreateOriginEndpointCommand = async (output, context) => {
|
|
611
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
612
|
+
return deserializeAws_restJson1CreateOriginEndpointCommandError(output, context);
|
|
613
|
+
}
|
|
614
|
+
const contents = map({
|
|
615
|
+
$metadata: deserializeMetadata(output),
|
|
1167
616
|
});
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
617
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
618
|
+
if (data.arn != null) {
|
|
619
|
+
contents.Arn = __expectString(data.arn);
|
|
620
|
+
}
|
|
621
|
+
if (data.authorization != null) {
|
|
622
|
+
contents.Authorization = deserializeAws_restJson1Authorization(data.authorization, context);
|
|
623
|
+
}
|
|
624
|
+
if (data.channelId != null) {
|
|
625
|
+
contents.ChannelId = __expectString(data.channelId);
|
|
626
|
+
}
|
|
627
|
+
if (data.cmafPackage != null) {
|
|
628
|
+
contents.CmafPackage = deserializeAws_restJson1CmafPackage(data.cmafPackage, context);
|
|
629
|
+
}
|
|
630
|
+
if (data.dashPackage != null) {
|
|
631
|
+
contents.DashPackage = deserializeAws_restJson1DashPackage(data.dashPackage, context);
|
|
632
|
+
}
|
|
633
|
+
if (data.description != null) {
|
|
634
|
+
contents.Description = __expectString(data.description);
|
|
635
|
+
}
|
|
636
|
+
if (data.hlsPackage != null) {
|
|
637
|
+
contents.HlsPackage = deserializeAws_restJson1HlsPackage(data.hlsPackage, context);
|
|
638
|
+
}
|
|
639
|
+
if (data.id != null) {
|
|
640
|
+
contents.Id = __expectString(data.id);
|
|
641
|
+
}
|
|
642
|
+
if (data.manifestName != null) {
|
|
643
|
+
contents.ManifestName = __expectString(data.manifestName);
|
|
644
|
+
}
|
|
645
|
+
if (data.mssPackage != null) {
|
|
646
|
+
contents.MssPackage = deserializeAws_restJson1MssPackage(data.mssPackage, context);
|
|
647
|
+
}
|
|
648
|
+
if (data.origination != null) {
|
|
649
|
+
contents.Origination = __expectString(data.origination);
|
|
650
|
+
}
|
|
651
|
+
if (data.startoverWindowSeconds != null) {
|
|
652
|
+
contents.StartoverWindowSeconds = __expectInt32(data.startoverWindowSeconds);
|
|
653
|
+
}
|
|
654
|
+
if (data.tags != null) {
|
|
655
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
656
|
+
}
|
|
657
|
+
if (data.timeDelaySeconds != null) {
|
|
658
|
+
contents.TimeDelaySeconds = __expectInt32(data.timeDelaySeconds);
|
|
659
|
+
}
|
|
660
|
+
if (data.url != null) {
|
|
661
|
+
contents.Url = __expectString(data.url);
|
|
662
|
+
}
|
|
663
|
+
if (data.whitelist != null) {
|
|
664
|
+
contents.Whitelist = deserializeAws_restJson1__listOf__string(data.whitelist, context);
|
|
665
|
+
}
|
|
666
|
+
return contents;
|
|
667
|
+
};
|
|
668
|
+
const deserializeAws_restJson1CreateOriginEndpointCommandError = async (output, context) => {
|
|
669
|
+
const parsedOutput = {
|
|
670
|
+
...output,
|
|
671
|
+
body: await parseErrorBody(output.body, context),
|
|
672
|
+
};
|
|
673
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
674
|
+
switch (errorCode) {
|
|
675
|
+
case "ForbiddenException":
|
|
676
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
677
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
678
|
+
case "InternalServerErrorException":
|
|
679
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
680
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
681
|
+
case "NotFoundException":
|
|
682
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
683
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
684
|
+
case "ServiceUnavailableException":
|
|
685
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
686
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
687
|
+
case "TooManyRequestsException":
|
|
688
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
689
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
690
|
+
case "UnprocessableEntityException":
|
|
691
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
692
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
693
|
+
default:
|
|
694
|
+
const parsedBody = parsedOutput.body;
|
|
695
|
+
throwDefaultError({
|
|
696
|
+
output,
|
|
697
|
+
parsedBody,
|
|
698
|
+
exceptionCtor: __BaseException,
|
|
699
|
+
errorCode,
|
|
700
|
+
});
|
|
701
|
+
}
|
|
702
|
+
};
|
|
703
|
+
export const deserializeAws_restJson1DeleteChannelCommand = async (output, context) => {
|
|
704
|
+
if (output.statusCode !== 202 && output.statusCode >= 300) {
|
|
705
|
+
return deserializeAws_restJson1DeleteChannelCommandError(output, context);
|
|
706
|
+
}
|
|
707
|
+
const contents = map({
|
|
708
|
+
$metadata: deserializeMetadata(output),
|
|
1220
709
|
});
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
if (data.mssPackage != null) {
|
|
1266
|
-
contents.MssPackage = deserializeAws_restJson1MssPackage(data.mssPackage, context);
|
|
1267
|
-
}
|
|
1268
|
-
if (data.origination != null) {
|
|
1269
|
-
contents.Origination = __expectString(data.origination);
|
|
1270
|
-
}
|
|
1271
|
-
if (data.startoverWindowSeconds != null) {
|
|
1272
|
-
contents.StartoverWindowSeconds = __expectInt32(data.startoverWindowSeconds);
|
|
1273
|
-
}
|
|
1274
|
-
if (data.tags != null) {
|
|
1275
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1276
|
-
}
|
|
1277
|
-
if (data.timeDelaySeconds != null) {
|
|
1278
|
-
contents.TimeDelaySeconds = __expectInt32(data.timeDelaySeconds);
|
|
1279
|
-
}
|
|
1280
|
-
if (data.url != null) {
|
|
1281
|
-
contents.Url = __expectString(data.url);
|
|
1282
|
-
}
|
|
1283
|
-
if (data.whitelist != null) {
|
|
1284
|
-
contents.Whitelist = deserializeAws_restJson1__listOf__string(data.whitelist, context);
|
|
1285
|
-
}
|
|
1286
|
-
return [2, contents];
|
|
1287
|
-
}
|
|
710
|
+
await collectBody(output.body, context);
|
|
711
|
+
return contents;
|
|
712
|
+
};
|
|
713
|
+
const deserializeAws_restJson1DeleteChannelCommandError = async (output, context) => {
|
|
714
|
+
const parsedOutput = {
|
|
715
|
+
...output,
|
|
716
|
+
body: await parseErrorBody(output.body, context),
|
|
717
|
+
};
|
|
718
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
719
|
+
switch (errorCode) {
|
|
720
|
+
case "ForbiddenException":
|
|
721
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
722
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
723
|
+
case "InternalServerErrorException":
|
|
724
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
725
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
726
|
+
case "NotFoundException":
|
|
727
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
728
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
729
|
+
case "ServiceUnavailableException":
|
|
730
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
731
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
732
|
+
case "TooManyRequestsException":
|
|
733
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
734
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
735
|
+
case "UnprocessableEntityException":
|
|
736
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
737
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
738
|
+
default:
|
|
739
|
+
const parsedBody = parsedOutput.body;
|
|
740
|
+
throwDefaultError({
|
|
741
|
+
output,
|
|
742
|
+
parsedBody,
|
|
743
|
+
exceptionCtor: __BaseException,
|
|
744
|
+
errorCode,
|
|
745
|
+
});
|
|
746
|
+
}
|
|
747
|
+
};
|
|
748
|
+
export const deserializeAws_restJson1DeleteOriginEndpointCommand = async (output, context) => {
|
|
749
|
+
if (output.statusCode !== 202 && output.statusCode >= 300) {
|
|
750
|
+
return deserializeAws_restJson1DeleteOriginEndpointCommandError(output, context);
|
|
751
|
+
}
|
|
752
|
+
const contents = map({
|
|
753
|
+
$metadata: deserializeMetadata(output),
|
|
1288
754
|
});
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
output: output,
|
|
1334
|
-
parsedBody: parsedBody,
|
|
1335
|
-
exceptionCtor: __BaseException,
|
|
1336
|
-
errorCode: errorCode,
|
|
1337
|
-
});
|
|
1338
|
-
_d.label = 15;
|
|
1339
|
-
case 15: return [2];
|
|
1340
|
-
}
|
|
755
|
+
await collectBody(output.body, context);
|
|
756
|
+
return contents;
|
|
757
|
+
};
|
|
758
|
+
const deserializeAws_restJson1DeleteOriginEndpointCommandError = async (output, context) => {
|
|
759
|
+
const parsedOutput = {
|
|
760
|
+
...output,
|
|
761
|
+
body: await parseErrorBody(output.body, context),
|
|
762
|
+
};
|
|
763
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
764
|
+
switch (errorCode) {
|
|
765
|
+
case "ForbiddenException":
|
|
766
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
767
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
768
|
+
case "InternalServerErrorException":
|
|
769
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
770
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
771
|
+
case "NotFoundException":
|
|
772
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
773
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
774
|
+
case "ServiceUnavailableException":
|
|
775
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
776
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
777
|
+
case "TooManyRequestsException":
|
|
778
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
779
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
780
|
+
case "UnprocessableEntityException":
|
|
781
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
782
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
783
|
+
default:
|
|
784
|
+
const parsedBody = parsedOutput.body;
|
|
785
|
+
throwDefaultError({
|
|
786
|
+
output,
|
|
787
|
+
parsedBody,
|
|
788
|
+
exceptionCtor: __BaseException,
|
|
789
|
+
errorCode,
|
|
790
|
+
});
|
|
791
|
+
}
|
|
792
|
+
};
|
|
793
|
+
export const deserializeAws_restJson1DescribeChannelCommand = async (output, context) => {
|
|
794
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
795
|
+
return deserializeAws_restJson1DescribeChannelCommandError(output, context);
|
|
796
|
+
}
|
|
797
|
+
const contents = map({
|
|
798
|
+
$metadata: deserializeMetadata(output),
|
|
1341
799
|
});
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
800
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
801
|
+
if (data.arn != null) {
|
|
802
|
+
contents.Arn = __expectString(data.arn);
|
|
803
|
+
}
|
|
804
|
+
if (data.description != null) {
|
|
805
|
+
contents.Description = __expectString(data.description);
|
|
806
|
+
}
|
|
807
|
+
if (data.egressAccessLogs != null) {
|
|
808
|
+
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
809
|
+
}
|
|
810
|
+
if (data.hlsIngest != null) {
|
|
811
|
+
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
812
|
+
}
|
|
813
|
+
if (data.id != null) {
|
|
814
|
+
contents.Id = __expectString(data.id);
|
|
815
|
+
}
|
|
816
|
+
if (data.ingressAccessLogs != null) {
|
|
817
|
+
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
818
|
+
}
|
|
819
|
+
if (data.tags != null) {
|
|
820
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
821
|
+
}
|
|
822
|
+
return contents;
|
|
823
|
+
};
|
|
824
|
+
const deserializeAws_restJson1DescribeChannelCommandError = async (output, context) => {
|
|
825
|
+
const parsedOutput = {
|
|
826
|
+
...output,
|
|
827
|
+
body: await parseErrorBody(output.body, context),
|
|
828
|
+
};
|
|
829
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
830
|
+
switch (errorCode) {
|
|
831
|
+
case "ForbiddenException":
|
|
832
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
833
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
834
|
+
case "InternalServerErrorException":
|
|
835
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
836
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
837
|
+
case "NotFoundException":
|
|
838
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
839
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
840
|
+
case "ServiceUnavailableException":
|
|
841
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
842
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
843
|
+
case "TooManyRequestsException":
|
|
844
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
845
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
846
|
+
case "UnprocessableEntityException":
|
|
847
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
848
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
849
|
+
default:
|
|
850
|
+
const parsedBody = parsedOutput.body;
|
|
851
|
+
throwDefaultError({
|
|
852
|
+
output,
|
|
853
|
+
parsedBody,
|
|
854
|
+
exceptionCtor: __BaseException,
|
|
855
|
+
errorCode,
|
|
856
|
+
});
|
|
857
|
+
}
|
|
858
|
+
};
|
|
859
|
+
export const deserializeAws_restJson1DescribeHarvestJobCommand = async (output, context) => {
|
|
860
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
861
|
+
return deserializeAws_restJson1DescribeHarvestJobCommandError(output, context);
|
|
862
|
+
}
|
|
863
|
+
const contents = map({
|
|
864
|
+
$metadata: deserializeMetadata(output),
|
|
1367
865
|
});
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
866
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
867
|
+
if (data.arn != null) {
|
|
868
|
+
contents.Arn = __expectString(data.arn);
|
|
869
|
+
}
|
|
870
|
+
if (data.channelId != null) {
|
|
871
|
+
contents.ChannelId = __expectString(data.channelId);
|
|
872
|
+
}
|
|
873
|
+
if (data.createdAt != null) {
|
|
874
|
+
contents.CreatedAt = __expectString(data.createdAt);
|
|
875
|
+
}
|
|
876
|
+
if (data.endTime != null) {
|
|
877
|
+
contents.EndTime = __expectString(data.endTime);
|
|
878
|
+
}
|
|
879
|
+
if (data.id != null) {
|
|
880
|
+
contents.Id = __expectString(data.id);
|
|
881
|
+
}
|
|
882
|
+
if (data.originEndpointId != null) {
|
|
883
|
+
contents.OriginEndpointId = __expectString(data.originEndpointId);
|
|
884
|
+
}
|
|
885
|
+
if (data.s3Destination != null) {
|
|
886
|
+
contents.S3Destination = deserializeAws_restJson1S3Destination(data.s3Destination, context);
|
|
887
|
+
}
|
|
888
|
+
if (data.startTime != null) {
|
|
889
|
+
contents.StartTime = __expectString(data.startTime);
|
|
890
|
+
}
|
|
891
|
+
if (data.status != null) {
|
|
892
|
+
contents.Status = __expectString(data.status);
|
|
893
|
+
}
|
|
894
|
+
return contents;
|
|
895
|
+
};
|
|
896
|
+
const deserializeAws_restJson1DescribeHarvestJobCommandError = async (output, context) => {
|
|
897
|
+
const parsedOutput = {
|
|
898
|
+
...output,
|
|
899
|
+
body: await parseErrorBody(output.body, context),
|
|
900
|
+
};
|
|
901
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
902
|
+
switch (errorCode) {
|
|
903
|
+
case "ForbiddenException":
|
|
904
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
905
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
906
|
+
case "InternalServerErrorException":
|
|
907
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
908
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
909
|
+
case "NotFoundException":
|
|
910
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
911
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
912
|
+
case "ServiceUnavailableException":
|
|
913
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
914
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
915
|
+
case "TooManyRequestsException":
|
|
916
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
917
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
918
|
+
case "UnprocessableEntityException":
|
|
919
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
920
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
921
|
+
default:
|
|
922
|
+
const parsedBody = parsedOutput.body;
|
|
923
|
+
throwDefaultError({
|
|
924
|
+
output,
|
|
925
|
+
parsedBody,
|
|
926
|
+
exceptionCtor: __BaseException,
|
|
927
|
+
errorCode,
|
|
928
|
+
});
|
|
929
|
+
}
|
|
930
|
+
};
|
|
931
|
+
export const deserializeAws_restJson1DescribeOriginEndpointCommand = async (output, context) => {
|
|
932
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
933
|
+
return deserializeAws_restJson1DescribeOriginEndpointCommandError(output, context);
|
|
934
|
+
}
|
|
935
|
+
const contents = map({
|
|
936
|
+
$metadata: deserializeMetadata(output),
|
|
1420
937
|
});
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
938
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
939
|
+
if (data.arn != null) {
|
|
940
|
+
contents.Arn = __expectString(data.arn);
|
|
941
|
+
}
|
|
942
|
+
if (data.authorization != null) {
|
|
943
|
+
contents.Authorization = deserializeAws_restJson1Authorization(data.authorization, context);
|
|
944
|
+
}
|
|
945
|
+
if (data.channelId != null) {
|
|
946
|
+
contents.ChannelId = __expectString(data.channelId);
|
|
947
|
+
}
|
|
948
|
+
if (data.cmafPackage != null) {
|
|
949
|
+
contents.CmafPackage = deserializeAws_restJson1CmafPackage(data.cmafPackage, context);
|
|
950
|
+
}
|
|
951
|
+
if (data.dashPackage != null) {
|
|
952
|
+
contents.DashPackage = deserializeAws_restJson1DashPackage(data.dashPackage, context);
|
|
953
|
+
}
|
|
954
|
+
if (data.description != null) {
|
|
955
|
+
contents.Description = __expectString(data.description);
|
|
956
|
+
}
|
|
957
|
+
if (data.hlsPackage != null) {
|
|
958
|
+
contents.HlsPackage = deserializeAws_restJson1HlsPackage(data.hlsPackage, context);
|
|
959
|
+
}
|
|
960
|
+
if (data.id != null) {
|
|
961
|
+
contents.Id = __expectString(data.id);
|
|
962
|
+
}
|
|
963
|
+
if (data.manifestName != null) {
|
|
964
|
+
contents.ManifestName = __expectString(data.manifestName);
|
|
965
|
+
}
|
|
966
|
+
if (data.mssPackage != null) {
|
|
967
|
+
contents.MssPackage = deserializeAws_restJson1MssPackage(data.mssPackage, context);
|
|
968
|
+
}
|
|
969
|
+
if (data.origination != null) {
|
|
970
|
+
contents.Origination = __expectString(data.origination);
|
|
971
|
+
}
|
|
972
|
+
if (data.startoverWindowSeconds != null) {
|
|
973
|
+
contents.StartoverWindowSeconds = __expectInt32(data.startoverWindowSeconds);
|
|
974
|
+
}
|
|
975
|
+
if (data.tags != null) {
|
|
976
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
977
|
+
}
|
|
978
|
+
if (data.timeDelaySeconds != null) {
|
|
979
|
+
contents.TimeDelaySeconds = __expectInt32(data.timeDelaySeconds);
|
|
980
|
+
}
|
|
981
|
+
if (data.url != null) {
|
|
982
|
+
contents.Url = __expectString(data.url);
|
|
983
|
+
}
|
|
984
|
+
if (data.whitelist != null) {
|
|
985
|
+
contents.Whitelist = deserializeAws_restJson1__listOf__string(data.whitelist, context);
|
|
986
|
+
}
|
|
987
|
+
return contents;
|
|
988
|
+
};
|
|
989
|
+
const deserializeAws_restJson1DescribeOriginEndpointCommandError = async (output, context) => {
|
|
990
|
+
const parsedOutput = {
|
|
991
|
+
...output,
|
|
992
|
+
body: await parseErrorBody(output.body, context),
|
|
993
|
+
};
|
|
994
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
995
|
+
switch (errorCode) {
|
|
996
|
+
case "ForbiddenException":
|
|
997
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
998
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
999
|
+
case "InternalServerErrorException":
|
|
1000
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1001
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1002
|
+
case "NotFoundException":
|
|
1003
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1004
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1005
|
+
case "ServiceUnavailableException":
|
|
1006
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1007
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1008
|
+
case "TooManyRequestsException":
|
|
1009
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1010
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1011
|
+
case "UnprocessableEntityException":
|
|
1012
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1013
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1014
|
+
default:
|
|
1015
|
+
const parsedBody = parsedOutput.body;
|
|
1016
|
+
throwDefaultError({
|
|
1017
|
+
output,
|
|
1018
|
+
parsedBody,
|
|
1019
|
+
exceptionCtor: __BaseException,
|
|
1020
|
+
errorCode,
|
|
1021
|
+
});
|
|
1022
|
+
}
|
|
1023
|
+
};
|
|
1024
|
+
export const deserializeAws_restJson1ListChannelsCommand = async (output, context) => {
|
|
1025
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1026
|
+
return deserializeAws_restJson1ListChannelsCommandError(output, context);
|
|
1027
|
+
}
|
|
1028
|
+
const contents = map({
|
|
1029
|
+
$metadata: deserializeMetadata(output),
|
|
1446
1030
|
});
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
case 15: return [2];
|
|
1498
|
-
}
|
|
1031
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1032
|
+
if (data.channels != null) {
|
|
1033
|
+
contents.Channels = deserializeAws_restJson1__listOfChannel(data.channels, context);
|
|
1034
|
+
}
|
|
1035
|
+
if (data.nextToken != null) {
|
|
1036
|
+
contents.NextToken = __expectString(data.nextToken);
|
|
1037
|
+
}
|
|
1038
|
+
return contents;
|
|
1039
|
+
};
|
|
1040
|
+
const deserializeAws_restJson1ListChannelsCommandError = async (output, context) => {
|
|
1041
|
+
const parsedOutput = {
|
|
1042
|
+
...output,
|
|
1043
|
+
body: await parseErrorBody(output.body, context),
|
|
1044
|
+
};
|
|
1045
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1046
|
+
switch (errorCode) {
|
|
1047
|
+
case "ForbiddenException":
|
|
1048
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1049
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1050
|
+
case "InternalServerErrorException":
|
|
1051
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1052
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1053
|
+
case "NotFoundException":
|
|
1054
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1055
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1056
|
+
case "ServiceUnavailableException":
|
|
1057
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1058
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1059
|
+
case "TooManyRequestsException":
|
|
1060
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1061
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1062
|
+
case "UnprocessableEntityException":
|
|
1063
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1064
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1065
|
+
default:
|
|
1066
|
+
const parsedBody = parsedOutput.body;
|
|
1067
|
+
throwDefaultError({
|
|
1068
|
+
output,
|
|
1069
|
+
parsedBody,
|
|
1070
|
+
exceptionCtor: __BaseException,
|
|
1071
|
+
errorCode,
|
|
1072
|
+
});
|
|
1073
|
+
}
|
|
1074
|
+
};
|
|
1075
|
+
export const deserializeAws_restJson1ListHarvestJobsCommand = async (output, context) => {
|
|
1076
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1077
|
+
return deserializeAws_restJson1ListHarvestJobsCommandError(output, context);
|
|
1078
|
+
}
|
|
1079
|
+
const contents = map({
|
|
1080
|
+
$metadata: deserializeMetadata(output),
|
|
1499
1081
|
});
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1082
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1083
|
+
if (data.harvestJobs != null) {
|
|
1084
|
+
contents.HarvestJobs = deserializeAws_restJson1__listOfHarvestJob(data.harvestJobs, context);
|
|
1085
|
+
}
|
|
1086
|
+
if (data.nextToken != null) {
|
|
1087
|
+
contents.NextToken = __expectString(data.nextToken);
|
|
1088
|
+
}
|
|
1089
|
+
return contents;
|
|
1090
|
+
};
|
|
1091
|
+
const deserializeAws_restJson1ListHarvestJobsCommandError = 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 "ForbiddenException":
|
|
1099
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1100
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1101
|
+
case "InternalServerErrorException":
|
|
1102
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1103
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1104
|
+
case "NotFoundException":
|
|
1105
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1106
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1107
|
+
case "ServiceUnavailableException":
|
|
1108
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1109
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1110
|
+
case "TooManyRequestsException":
|
|
1111
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1112
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1113
|
+
case "UnprocessableEntityException":
|
|
1114
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1115
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1116
|
+
default:
|
|
1117
|
+
const parsedBody = parsedOutput.body;
|
|
1118
|
+
throwDefaultError({
|
|
1119
|
+
output,
|
|
1120
|
+
parsedBody,
|
|
1121
|
+
exceptionCtor: __BaseException,
|
|
1122
|
+
errorCode,
|
|
1123
|
+
});
|
|
1124
|
+
}
|
|
1125
|
+
};
|
|
1126
|
+
export const deserializeAws_restJson1ListOriginEndpointsCommand = async (output, context) => {
|
|
1127
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1128
|
+
return deserializeAws_restJson1ListOriginEndpointsCommandError(output, context);
|
|
1129
|
+
}
|
|
1130
|
+
const contents = map({
|
|
1131
|
+
$metadata: deserializeMetadata(output),
|
|
1525
1132
|
});
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
case 15: return [2];
|
|
1577
|
-
}
|
|
1133
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1134
|
+
if (data.nextToken != null) {
|
|
1135
|
+
contents.NextToken = __expectString(data.nextToken);
|
|
1136
|
+
}
|
|
1137
|
+
if (data.originEndpoints != null) {
|
|
1138
|
+
contents.OriginEndpoints = deserializeAws_restJson1__listOfOriginEndpoint(data.originEndpoints, context);
|
|
1139
|
+
}
|
|
1140
|
+
return contents;
|
|
1141
|
+
};
|
|
1142
|
+
const deserializeAws_restJson1ListOriginEndpointsCommandError = async (output, context) => {
|
|
1143
|
+
const parsedOutput = {
|
|
1144
|
+
...output,
|
|
1145
|
+
body: await parseErrorBody(output.body, context),
|
|
1146
|
+
};
|
|
1147
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1148
|
+
switch (errorCode) {
|
|
1149
|
+
case "ForbiddenException":
|
|
1150
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1151
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1152
|
+
case "InternalServerErrorException":
|
|
1153
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1154
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1155
|
+
case "NotFoundException":
|
|
1156
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1157
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1158
|
+
case "ServiceUnavailableException":
|
|
1159
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1160
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1161
|
+
case "TooManyRequestsException":
|
|
1162
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1163
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1164
|
+
case "UnprocessableEntityException":
|
|
1165
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1166
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1167
|
+
default:
|
|
1168
|
+
const parsedBody = parsedOutput.body;
|
|
1169
|
+
throwDefaultError({
|
|
1170
|
+
output,
|
|
1171
|
+
parsedBody,
|
|
1172
|
+
exceptionCtor: __BaseException,
|
|
1173
|
+
errorCode,
|
|
1174
|
+
});
|
|
1175
|
+
}
|
|
1176
|
+
};
|
|
1177
|
+
export const deserializeAws_restJson1ListTagsForResourceCommand = async (output, context) => {
|
|
1178
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1179
|
+
return deserializeAws_restJson1ListTagsForResourceCommandError(output, context);
|
|
1180
|
+
}
|
|
1181
|
+
const contents = map({
|
|
1182
|
+
$metadata: deserializeMetadata(output),
|
|
1578
1183
|
});
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
contents.Tags = deserializeAws_restJson1__mapOf__string(data.tags, context);
|
|
1598
|
-
}
|
|
1599
|
-
return [2, contents];
|
|
1600
|
-
}
|
|
1184
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1185
|
+
if (data.tags != null) {
|
|
1186
|
+
contents.Tags = deserializeAws_restJson1__mapOf__string(data.tags, context);
|
|
1187
|
+
}
|
|
1188
|
+
return contents;
|
|
1189
|
+
};
|
|
1190
|
+
const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, context) => {
|
|
1191
|
+
const parsedOutput = {
|
|
1192
|
+
...output,
|
|
1193
|
+
body: await parseErrorBody(output.body, context),
|
|
1194
|
+
};
|
|
1195
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1196
|
+
const parsedBody = parsedOutput.body;
|
|
1197
|
+
throwDefaultError({
|
|
1198
|
+
output,
|
|
1199
|
+
parsedBody,
|
|
1200
|
+
exceptionCtor: __BaseException,
|
|
1201
|
+
errorCode,
|
|
1601
1202
|
});
|
|
1602
|
-
}
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
_a = [__assign({}, output)];
|
|
1610
|
-
_b = {};
|
|
1611
|
-
return [4, parseBody(output.body, context)];
|
|
1612
|
-
case 1:
|
|
1613
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_b.body = _c.sent(), _b)]));
|
|
1614
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1615
|
-
parsedBody = parsedOutput.body;
|
|
1616
|
-
throwDefaultError({
|
|
1617
|
-
output: output,
|
|
1618
|
-
parsedBody: parsedBody,
|
|
1619
|
-
exceptionCtor: __BaseException,
|
|
1620
|
-
errorCode: errorCode,
|
|
1621
|
-
});
|
|
1622
|
-
return [2];
|
|
1623
|
-
}
|
|
1203
|
+
};
|
|
1204
|
+
export const deserializeAws_restJson1RotateChannelCredentialsCommand = async (output, context) => {
|
|
1205
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1206
|
+
return deserializeAws_restJson1RotateChannelCredentialsCommandError(output, context);
|
|
1207
|
+
}
|
|
1208
|
+
const contents = map({
|
|
1209
|
+
$metadata: deserializeMetadata(output),
|
|
1624
1210
|
});
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1211
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1212
|
+
if (data.arn != null) {
|
|
1213
|
+
contents.Arn = __expectString(data.arn);
|
|
1214
|
+
}
|
|
1215
|
+
if (data.description != null) {
|
|
1216
|
+
contents.Description = __expectString(data.description);
|
|
1217
|
+
}
|
|
1218
|
+
if (data.egressAccessLogs != null) {
|
|
1219
|
+
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
1220
|
+
}
|
|
1221
|
+
if (data.hlsIngest != null) {
|
|
1222
|
+
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
1223
|
+
}
|
|
1224
|
+
if (data.id != null) {
|
|
1225
|
+
contents.Id = __expectString(data.id);
|
|
1226
|
+
}
|
|
1227
|
+
if (data.ingressAccessLogs != null) {
|
|
1228
|
+
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
1229
|
+
}
|
|
1230
|
+
if (data.tags != null) {
|
|
1231
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1232
|
+
}
|
|
1233
|
+
return contents;
|
|
1234
|
+
};
|
|
1235
|
+
const deserializeAws_restJson1RotateChannelCredentialsCommandError = async (output, context) => {
|
|
1236
|
+
const parsedOutput = {
|
|
1237
|
+
...output,
|
|
1238
|
+
body: await parseErrorBody(output.body, context),
|
|
1239
|
+
};
|
|
1240
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1241
|
+
switch (errorCode) {
|
|
1242
|
+
case "ForbiddenException":
|
|
1243
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1244
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1245
|
+
case "InternalServerErrorException":
|
|
1246
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1247
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1248
|
+
case "NotFoundException":
|
|
1249
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1250
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1251
|
+
case "ServiceUnavailableException":
|
|
1252
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1253
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1254
|
+
case "TooManyRequestsException":
|
|
1255
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1256
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1257
|
+
case "UnprocessableEntityException":
|
|
1258
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1259
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1260
|
+
default:
|
|
1261
|
+
const parsedBody = parsedOutput.body;
|
|
1262
|
+
throwDefaultError({
|
|
1263
|
+
output,
|
|
1264
|
+
parsedBody,
|
|
1265
|
+
exceptionCtor: __BaseException,
|
|
1266
|
+
errorCode,
|
|
1267
|
+
});
|
|
1268
|
+
}
|
|
1269
|
+
};
|
|
1270
|
+
export const deserializeAws_restJson1RotateIngestEndpointCredentialsCommand = async (output, context) => {
|
|
1271
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1272
|
+
return deserializeAws_restJson1RotateIngestEndpointCredentialsCommandError(output, context);
|
|
1273
|
+
}
|
|
1274
|
+
const contents = map({
|
|
1275
|
+
$metadata: deserializeMetadata(output),
|
|
1665
1276
|
});
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1277
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1278
|
+
if (data.arn != null) {
|
|
1279
|
+
contents.Arn = __expectString(data.arn);
|
|
1280
|
+
}
|
|
1281
|
+
if (data.description != null) {
|
|
1282
|
+
contents.Description = __expectString(data.description);
|
|
1283
|
+
}
|
|
1284
|
+
if (data.egressAccessLogs != null) {
|
|
1285
|
+
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
1286
|
+
}
|
|
1287
|
+
if (data.hlsIngest != null) {
|
|
1288
|
+
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
1289
|
+
}
|
|
1290
|
+
if (data.id != null) {
|
|
1291
|
+
contents.Id = __expectString(data.id);
|
|
1292
|
+
}
|
|
1293
|
+
if (data.ingressAccessLogs != null) {
|
|
1294
|
+
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
1295
|
+
}
|
|
1296
|
+
if (data.tags != null) {
|
|
1297
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1298
|
+
}
|
|
1299
|
+
return contents;
|
|
1300
|
+
};
|
|
1301
|
+
const deserializeAws_restJson1RotateIngestEndpointCredentialsCommandError = async (output, context) => {
|
|
1302
|
+
const parsedOutput = {
|
|
1303
|
+
...output,
|
|
1304
|
+
body: await parseErrorBody(output.body, context),
|
|
1305
|
+
};
|
|
1306
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1307
|
+
switch (errorCode) {
|
|
1308
|
+
case "ForbiddenException":
|
|
1309
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1310
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1311
|
+
case "InternalServerErrorException":
|
|
1312
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1313
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1314
|
+
case "NotFoundException":
|
|
1315
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1316
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1317
|
+
case "ServiceUnavailableException":
|
|
1318
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1319
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1320
|
+
case "TooManyRequestsException":
|
|
1321
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1322
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1323
|
+
case "UnprocessableEntityException":
|
|
1324
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1325
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1326
|
+
default:
|
|
1327
|
+
const parsedBody = parsedOutput.body;
|
|
1328
|
+
throwDefaultError({
|
|
1329
|
+
output,
|
|
1330
|
+
parsedBody,
|
|
1331
|
+
exceptionCtor: __BaseException,
|
|
1332
|
+
errorCode,
|
|
1333
|
+
});
|
|
1334
|
+
}
|
|
1335
|
+
};
|
|
1336
|
+
export const deserializeAws_restJson1TagResourceCommand = async (output, context) => {
|
|
1337
|
+
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1338
|
+
return deserializeAws_restJson1TagResourceCommandError(output, context);
|
|
1339
|
+
}
|
|
1340
|
+
const contents = map({
|
|
1341
|
+
$metadata: deserializeMetadata(output),
|
|
1718
1342
|
});
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
case 1:
|
|
1735
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1736
|
-
if (data.arn != null) {
|
|
1737
|
-
contents.Arn = __expectString(data.arn);
|
|
1738
|
-
}
|
|
1739
|
-
if (data.description != null) {
|
|
1740
|
-
contents.Description = __expectString(data.description);
|
|
1741
|
-
}
|
|
1742
|
-
if (data.egressAccessLogs != null) {
|
|
1743
|
-
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
1744
|
-
}
|
|
1745
|
-
if (data.hlsIngest != null) {
|
|
1746
|
-
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
1747
|
-
}
|
|
1748
|
-
if (data.id != null) {
|
|
1749
|
-
contents.Id = __expectString(data.id);
|
|
1750
|
-
}
|
|
1751
|
-
if (data.ingressAccessLogs != null) {
|
|
1752
|
-
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
1753
|
-
}
|
|
1754
|
-
if (data.tags != null) {
|
|
1755
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1756
|
-
}
|
|
1757
|
-
return [2, contents];
|
|
1758
|
-
}
|
|
1343
|
+
await collectBody(output.body, context);
|
|
1344
|
+
return contents;
|
|
1345
|
+
};
|
|
1346
|
+
const deserializeAws_restJson1TagResourceCommandError = async (output, context) => {
|
|
1347
|
+
const parsedOutput = {
|
|
1348
|
+
...output,
|
|
1349
|
+
body: await parseErrorBody(output.body, context),
|
|
1350
|
+
};
|
|
1351
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1352
|
+
const parsedBody = parsedOutput.body;
|
|
1353
|
+
throwDefaultError({
|
|
1354
|
+
output,
|
|
1355
|
+
parsedBody,
|
|
1356
|
+
exceptionCtor: __BaseException,
|
|
1357
|
+
errorCode,
|
|
1759
1358
|
});
|
|
1760
|
-
}
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
_a = [__assign({}, output)];
|
|
1768
|
-
_c = {};
|
|
1769
|
-
return [4, parseBody(output.body, context)];
|
|
1770
|
-
case 1:
|
|
1771
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1772
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1773
|
-
_b = errorCode;
|
|
1774
|
-
switch (_b) {
|
|
1775
|
-
case "ForbiddenException": return [3, 2];
|
|
1776
|
-
case "com.amazonaws.mediapackage#ForbiddenException": return [3, 2];
|
|
1777
|
-
case "InternalServerErrorException": return [3, 4];
|
|
1778
|
-
case "com.amazonaws.mediapackage#InternalServerErrorException": return [3, 4];
|
|
1779
|
-
case "NotFoundException": return [3, 6];
|
|
1780
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
1781
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
1782
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
1783
|
-
case "TooManyRequestsException": return [3, 10];
|
|
1784
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
1785
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
1786
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
1787
|
-
}
|
|
1788
|
-
return [3, 14];
|
|
1789
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
1790
|
-
case 3: throw _d.sent();
|
|
1791
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
1792
|
-
case 5: throw _d.sent();
|
|
1793
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
1794
|
-
case 7: throw _d.sent();
|
|
1795
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
1796
|
-
case 9: throw _d.sent();
|
|
1797
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
1798
|
-
case 11: throw _d.sent();
|
|
1799
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
1800
|
-
case 13: throw _d.sent();
|
|
1801
|
-
case 14:
|
|
1802
|
-
parsedBody = parsedOutput.body;
|
|
1803
|
-
throwDefaultError({
|
|
1804
|
-
output: output,
|
|
1805
|
-
parsedBody: parsedBody,
|
|
1806
|
-
exceptionCtor: __BaseException,
|
|
1807
|
-
errorCode: errorCode,
|
|
1808
|
-
});
|
|
1809
|
-
_d.label = 15;
|
|
1810
|
-
case 15: return [2];
|
|
1811
|
-
}
|
|
1359
|
+
};
|
|
1360
|
+
export const deserializeAws_restJson1UntagResourceCommand = async (output, context) => {
|
|
1361
|
+
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1362
|
+
return deserializeAws_restJson1UntagResourceCommandError(output, context);
|
|
1363
|
+
}
|
|
1364
|
+
const contents = map({
|
|
1365
|
+
$metadata: deserializeMetadata(output),
|
|
1812
1366
|
});
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
return [2, contents];
|
|
1829
|
-
}
|
|
1367
|
+
await collectBody(output.body, context);
|
|
1368
|
+
return contents;
|
|
1369
|
+
};
|
|
1370
|
+
const deserializeAws_restJson1UntagResourceCommandError = async (output, context) => {
|
|
1371
|
+
const parsedOutput = {
|
|
1372
|
+
...output,
|
|
1373
|
+
body: await parseErrorBody(output.body, context),
|
|
1374
|
+
};
|
|
1375
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1376
|
+
const parsedBody = parsedOutput.body;
|
|
1377
|
+
throwDefaultError({
|
|
1378
|
+
output,
|
|
1379
|
+
parsedBody,
|
|
1380
|
+
exceptionCtor: __BaseException,
|
|
1381
|
+
errorCode,
|
|
1830
1382
|
});
|
|
1831
|
-
}
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
_a = [__assign({}, output)];
|
|
1839
|
-
_b = {};
|
|
1840
|
-
return [4, parseBody(output.body, context)];
|
|
1841
|
-
case 1:
|
|
1842
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_b.body = _c.sent(), _b)]));
|
|
1843
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1844
|
-
parsedBody = parsedOutput.body;
|
|
1845
|
-
throwDefaultError({
|
|
1846
|
-
output: output,
|
|
1847
|
-
parsedBody: parsedBody,
|
|
1848
|
-
exceptionCtor: __BaseException,
|
|
1849
|
-
errorCode: errorCode,
|
|
1850
|
-
});
|
|
1851
|
-
return [2];
|
|
1852
|
-
}
|
|
1383
|
+
};
|
|
1384
|
+
export const deserializeAws_restJson1UpdateChannelCommand = async (output, context) => {
|
|
1385
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1386
|
+
return deserializeAws_restJson1UpdateChannelCommandError(output, context);
|
|
1387
|
+
}
|
|
1388
|
+
const contents = map({
|
|
1389
|
+
$metadata: deserializeMetadata(output),
|
|
1853
1390
|
});
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1391
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1392
|
+
if (data.arn != null) {
|
|
1393
|
+
contents.Arn = __expectString(data.arn);
|
|
1394
|
+
}
|
|
1395
|
+
if (data.description != null) {
|
|
1396
|
+
contents.Description = __expectString(data.description);
|
|
1397
|
+
}
|
|
1398
|
+
if (data.egressAccessLogs != null) {
|
|
1399
|
+
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
1400
|
+
}
|
|
1401
|
+
if (data.hlsIngest != null) {
|
|
1402
|
+
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
1403
|
+
}
|
|
1404
|
+
if (data.id != null) {
|
|
1405
|
+
contents.Id = __expectString(data.id);
|
|
1406
|
+
}
|
|
1407
|
+
if (data.ingressAccessLogs != null) {
|
|
1408
|
+
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
1409
|
+
}
|
|
1410
|
+
if (data.tags != null) {
|
|
1411
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1412
|
+
}
|
|
1413
|
+
return contents;
|
|
1414
|
+
};
|
|
1415
|
+
const deserializeAws_restJson1UpdateChannelCommandError = async (output, context) => {
|
|
1416
|
+
const parsedOutput = {
|
|
1417
|
+
...output,
|
|
1418
|
+
body: await parseErrorBody(output.body, context),
|
|
1419
|
+
};
|
|
1420
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1421
|
+
switch (errorCode) {
|
|
1422
|
+
case "ForbiddenException":
|
|
1423
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1424
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1425
|
+
case "InternalServerErrorException":
|
|
1426
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1427
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1428
|
+
case "NotFoundException":
|
|
1429
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1430
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1431
|
+
case "ServiceUnavailableException":
|
|
1432
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1433
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1434
|
+
case "TooManyRequestsException":
|
|
1435
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1436
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1437
|
+
case "UnprocessableEntityException":
|
|
1438
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1439
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1440
|
+
default:
|
|
1441
|
+
const parsedBody = parsedOutput.body;
|
|
1442
|
+
throwDefaultError({
|
|
1443
|
+
output,
|
|
1444
|
+
parsedBody,
|
|
1445
|
+
exceptionCtor: __BaseException,
|
|
1446
|
+
errorCode,
|
|
1447
|
+
});
|
|
1448
|
+
}
|
|
1449
|
+
};
|
|
1450
|
+
export const deserializeAws_restJson1UpdateOriginEndpointCommand = async (output, context) => {
|
|
1451
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1452
|
+
return deserializeAws_restJson1UpdateOriginEndpointCommandError(output, context);
|
|
1453
|
+
}
|
|
1454
|
+
const contents = map({
|
|
1455
|
+
$metadata: deserializeMetadata(output),
|
|
1871
1456
|
});
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1457
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1458
|
+
if (data.arn != null) {
|
|
1459
|
+
contents.Arn = __expectString(data.arn);
|
|
1460
|
+
}
|
|
1461
|
+
if (data.authorization != null) {
|
|
1462
|
+
contents.Authorization = deserializeAws_restJson1Authorization(data.authorization, context);
|
|
1463
|
+
}
|
|
1464
|
+
if (data.channelId != null) {
|
|
1465
|
+
contents.ChannelId = __expectString(data.channelId);
|
|
1466
|
+
}
|
|
1467
|
+
if (data.cmafPackage != null) {
|
|
1468
|
+
contents.CmafPackage = deserializeAws_restJson1CmafPackage(data.cmafPackage, context);
|
|
1469
|
+
}
|
|
1470
|
+
if (data.dashPackage != null) {
|
|
1471
|
+
contents.DashPackage = deserializeAws_restJson1DashPackage(data.dashPackage, context);
|
|
1472
|
+
}
|
|
1473
|
+
if (data.description != null) {
|
|
1474
|
+
contents.Description = __expectString(data.description);
|
|
1475
|
+
}
|
|
1476
|
+
if (data.hlsPackage != null) {
|
|
1477
|
+
contents.HlsPackage = deserializeAws_restJson1HlsPackage(data.hlsPackage, context);
|
|
1478
|
+
}
|
|
1479
|
+
if (data.id != null) {
|
|
1480
|
+
contents.Id = __expectString(data.id);
|
|
1481
|
+
}
|
|
1482
|
+
if (data.manifestName != null) {
|
|
1483
|
+
contents.ManifestName = __expectString(data.manifestName);
|
|
1484
|
+
}
|
|
1485
|
+
if (data.mssPackage != null) {
|
|
1486
|
+
contents.MssPackage = deserializeAws_restJson1MssPackage(data.mssPackage, context);
|
|
1487
|
+
}
|
|
1488
|
+
if (data.origination != null) {
|
|
1489
|
+
contents.Origination = __expectString(data.origination);
|
|
1490
|
+
}
|
|
1491
|
+
if (data.startoverWindowSeconds != null) {
|
|
1492
|
+
contents.StartoverWindowSeconds = __expectInt32(data.startoverWindowSeconds);
|
|
1493
|
+
}
|
|
1494
|
+
if (data.tags != null) {
|
|
1495
|
+
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1496
|
+
}
|
|
1497
|
+
if (data.timeDelaySeconds != null) {
|
|
1498
|
+
contents.TimeDelaySeconds = __expectInt32(data.timeDelaySeconds);
|
|
1499
|
+
}
|
|
1500
|
+
if (data.url != null) {
|
|
1501
|
+
contents.Url = __expectString(data.url);
|
|
1502
|
+
}
|
|
1503
|
+
if (data.whitelist != null) {
|
|
1504
|
+
contents.Whitelist = deserializeAws_restJson1__listOf__string(data.whitelist, context);
|
|
1505
|
+
}
|
|
1506
|
+
return contents;
|
|
1507
|
+
};
|
|
1508
|
+
const deserializeAws_restJson1UpdateOriginEndpointCommandError = async (output, context) => {
|
|
1509
|
+
const parsedOutput = {
|
|
1510
|
+
...output,
|
|
1511
|
+
body: await parseErrorBody(output.body, context),
|
|
1512
|
+
};
|
|
1513
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1514
|
+
switch (errorCode) {
|
|
1515
|
+
case "ForbiddenException":
|
|
1516
|
+
case "com.amazonaws.mediapackage#ForbiddenException":
|
|
1517
|
+
throw await deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context);
|
|
1518
|
+
case "InternalServerErrorException":
|
|
1519
|
+
case "com.amazonaws.mediapackage#InternalServerErrorException":
|
|
1520
|
+
throw await deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context);
|
|
1521
|
+
case "NotFoundException":
|
|
1522
|
+
case "com.amazonaws.mediapackage#NotFoundException":
|
|
1523
|
+
throw await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context);
|
|
1524
|
+
case "ServiceUnavailableException":
|
|
1525
|
+
case "com.amazonaws.mediapackage#ServiceUnavailableException":
|
|
1526
|
+
throw await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context);
|
|
1527
|
+
case "TooManyRequestsException":
|
|
1528
|
+
case "com.amazonaws.mediapackage#TooManyRequestsException":
|
|
1529
|
+
throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
|
|
1530
|
+
case "UnprocessableEntityException":
|
|
1531
|
+
case "com.amazonaws.mediapackage#UnprocessableEntityException":
|
|
1532
|
+
throw await deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context);
|
|
1533
|
+
default:
|
|
1534
|
+
const parsedBody = parsedOutput.body;
|
|
1535
|
+
throwDefaultError({
|
|
1536
|
+
output,
|
|
1537
|
+
parsedBody,
|
|
1538
|
+
exceptionCtor: __BaseException,
|
|
1539
|
+
errorCode,
|
|
1540
|
+
});
|
|
1541
|
+
}
|
|
1542
|
+
};
|
|
1543
|
+
const map = __map;
|
|
1544
|
+
const deserializeAws_restJson1ForbiddenExceptionResponse = async (parsedOutput, context) => {
|
|
1545
|
+
const contents = map({});
|
|
1546
|
+
const data = parsedOutput.body;
|
|
1547
|
+
if (data.message != null) {
|
|
1548
|
+
contents.Message = __expectString(data.message);
|
|
1549
|
+
}
|
|
1550
|
+
const exception = new ForbiddenException({
|
|
1551
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1552
|
+
...contents,
|
|
1894
1553
|
});
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
});
|
|
1907
|
-
_a = __expectNonNull;
|
|
1908
|
-
_b = __expectObject;
|
|
1909
|
-
return [4, parseBody(output.body, context)];
|
|
1910
|
-
case 1:
|
|
1911
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1912
|
-
if (data.arn != null) {
|
|
1913
|
-
contents.Arn = __expectString(data.arn);
|
|
1914
|
-
}
|
|
1915
|
-
if (data.description != null) {
|
|
1916
|
-
contents.Description = __expectString(data.description);
|
|
1917
|
-
}
|
|
1918
|
-
if (data.egressAccessLogs != null) {
|
|
1919
|
-
contents.EgressAccessLogs = deserializeAws_restJson1EgressAccessLogs(data.egressAccessLogs, context);
|
|
1920
|
-
}
|
|
1921
|
-
if (data.hlsIngest != null) {
|
|
1922
|
-
contents.HlsIngest = deserializeAws_restJson1HlsIngest(data.hlsIngest, context);
|
|
1923
|
-
}
|
|
1924
|
-
if (data.id != null) {
|
|
1925
|
-
contents.Id = __expectString(data.id);
|
|
1926
|
-
}
|
|
1927
|
-
if (data.ingressAccessLogs != null) {
|
|
1928
|
-
contents.IngressAccessLogs = deserializeAws_restJson1IngressAccessLogs(data.ingressAccessLogs, context);
|
|
1929
|
-
}
|
|
1930
|
-
if (data.tags != null) {
|
|
1931
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
1932
|
-
}
|
|
1933
|
-
return [2, contents];
|
|
1934
|
-
}
|
|
1554
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1555
|
+
};
|
|
1556
|
+
const deserializeAws_restJson1InternalServerErrorExceptionResponse = async (parsedOutput, context) => {
|
|
1557
|
+
const contents = map({});
|
|
1558
|
+
const data = parsedOutput.body;
|
|
1559
|
+
if (data.message != null) {
|
|
1560
|
+
contents.Message = __expectString(data.message);
|
|
1561
|
+
}
|
|
1562
|
+
const exception = new InternalServerErrorException({
|
|
1563
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1564
|
+
...contents,
|
|
1935
1565
|
});
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1948
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1949
|
-
_b = errorCode;
|
|
1950
|
-
switch (_b) {
|
|
1951
|
-
case "ForbiddenException": return [3, 2];
|
|
1952
|
-
case "com.amazonaws.mediapackage#ForbiddenException": return [3, 2];
|
|
1953
|
-
case "InternalServerErrorException": return [3, 4];
|
|
1954
|
-
case "com.amazonaws.mediapackage#InternalServerErrorException": return [3, 4];
|
|
1955
|
-
case "NotFoundException": return [3, 6];
|
|
1956
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
1957
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
1958
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
1959
|
-
case "TooManyRequestsException": return [3, 10];
|
|
1960
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
1961
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
1962
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
1963
|
-
}
|
|
1964
|
-
return [3, 14];
|
|
1965
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
1966
|
-
case 3: throw _d.sent();
|
|
1967
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
1968
|
-
case 5: throw _d.sent();
|
|
1969
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
1970
|
-
case 7: throw _d.sent();
|
|
1971
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
1972
|
-
case 9: throw _d.sent();
|
|
1973
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
1974
|
-
case 11: throw _d.sent();
|
|
1975
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
1976
|
-
case 13: throw _d.sent();
|
|
1977
|
-
case 14:
|
|
1978
|
-
parsedBody = parsedOutput.body;
|
|
1979
|
-
throwDefaultError({
|
|
1980
|
-
output: output,
|
|
1981
|
-
parsedBody: parsedBody,
|
|
1982
|
-
exceptionCtor: __BaseException,
|
|
1983
|
-
errorCode: errorCode,
|
|
1984
|
-
});
|
|
1985
|
-
_d.label = 15;
|
|
1986
|
-
case 15: return [2];
|
|
1987
|
-
}
|
|
1566
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1567
|
+
};
|
|
1568
|
+
const deserializeAws_restJson1NotFoundExceptionResponse = async (parsedOutput, context) => {
|
|
1569
|
+
const contents = map({});
|
|
1570
|
+
const data = parsedOutput.body;
|
|
1571
|
+
if (data.message != null) {
|
|
1572
|
+
contents.Message = __expectString(data.message);
|
|
1573
|
+
}
|
|
1574
|
+
const exception = new NotFoundException({
|
|
1575
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1576
|
+
...contents,
|
|
1988
1577
|
});
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
});
|
|
2001
|
-
_a = __expectNonNull;
|
|
2002
|
-
_b = __expectObject;
|
|
2003
|
-
return [4, parseBody(output.body, context)];
|
|
2004
|
-
case 1:
|
|
2005
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
2006
|
-
if (data.arn != null) {
|
|
2007
|
-
contents.Arn = __expectString(data.arn);
|
|
2008
|
-
}
|
|
2009
|
-
if (data.authorization != null) {
|
|
2010
|
-
contents.Authorization = deserializeAws_restJson1Authorization(data.authorization, context);
|
|
2011
|
-
}
|
|
2012
|
-
if (data.channelId != null) {
|
|
2013
|
-
contents.ChannelId = __expectString(data.channelId);
|
|
2014
|
-
}
|
|
2015
|
-
if (data.cmafPackage != null) {
|
|
2016
|
-
contents.CmafPackage = deserializeAws_restJson1CmafPackage(data.cmafPackage, context);
|
|
2017
|
-
}
|
|
2018
|
-
if (data.dashPackage != null) {
|
|
2019
|
-
contents.DashPackage = deserializeAws_restJson1DashPackage(data.dashPackage, context);
|
|
2020
|
-
}
|
|
2021
|
-
if (data.description != null) {
|
|
2022
|
-
contents.Description = __expectString(data.description);
|
|
2023
|
-
}
|
|
2024
|
-
if (data.hlsPackage != null) {
|
|
2025
|
-
contents.HlsPackage = deserializeAws_restJson1HlsPackage(data.hlsPackage, context);
|
|
2026
|
-
}
|
|
2027
|
-
if (data.id != null) {
|
|
2028
|
-
contents.Id = __expectString(data.id);
|
|
2029
|
-
}
|
|
2030
|
-
if (data.manifestName != null) {
|
|
2031
|
-
contents.ManifestName = __expectString(data.manifestName);
|
|
2032
|
-
}
|
|
2033
|
-
if (data.mssPackage != null) {
|
|
2034
|
-
contents.MssPackage = deserializeAws_restJson1MssPackage(data.mssPackage, context);
|
|
2035
|
-
}
|
|
2036
|
-
if (data.origination != null) {
|
|
2037
|
-
contents.Origination = __expectString(data.origination);
|
|
2038
|
-
}
|
|
2039
|
-
if (data.startoverWindowSeconds != null) {
|
|
2040
|
-
contents.StartoverWindowSeconds = __expectInt32(data.startoverWindowSeconds);
|
|
2041
|
-
}
|
|
2042
|
-
if (data.tags != null) {
|
|
2043
|
-
contents.Tags = deserializeAws_restJson1Tags(data.tags, context);
|
|
2044
|
-
}
|
|
2045
|
-
if (data.timeDelaySeconds != null) {
|
|
2046
|
-
contents.TimeDelaySeconds = __expectInt32(data.timeDelaySeconds);
|
|
2047
|
-
}
|
|
2048
|
-
if (data.url != null) {
|
|
2049
|
-
contents.Url = __expectString(data.url);
|
|
2050
|
-
}
|
|
2051
|
-
if (data.whitelist != null) {
|
|
2052
|
-
contents.Whitelist = deserializeAws_restJson1__listOf__string(data.whitelist, context);
|
|
2053
|
-
}
|
|
2054
|
-
return [2, contents];
|
|
2055
|
-
}
|
|
1578
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1579
|
+
};
|
|
1580
|
+
const deserializeAws_restJson1ServiceUnavailableExceptionResponse = async (parsedOutput, context) => {
|
|
1581
|
+
const contents = map({});
|
|
1582
|
+
const data = parsedOutput.body;
|
|
1583
|
+
if (data.message != null) {
|
|
1584
|
+
contents.Message = __expectString(data.message);
|
|
1585
|
+
}
|
|
1586
|
+
const exception = new ServiceUnavailableException({
|
|
1587
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1588
|
+
...contents,
|
|
2056
1589
|
});
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2069
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2070
|
-
_b = errorCode;
|
|
2071
|
-
switch (_b) {
|
|
2072
|
-
case "ForbiddenException": return [3, 2];
|
|
2073
|
-
case "com.amazonaws.mediapackage#ForbiddenException": return [3, 2];
|
|
2074
|
-
case "InternalServerErrorException": return [3, 4];
|
|
2075
|
-
case "com.amazonaws.mediapackage#InternalServerErrorException": return [3, 4];
|
|
2076
|
-
case "NotFoundException": return [3, 6];
|
|
2077
|
-
case "com.amazonaws.mediapackage#NotFoundException": return [3, 6];
|
|
2078
|
-
case "ServiceUnavailableException": return [3, 8];
|
|
2079
|
-
case "com.amazonaws.mediapackage#ServiceUnavailableException": return [3, 8];
|
|
2080
|
-
case "TooManyRequestsException": return [3, 10];
|
|
2081
|
-
case "com.amazonaws.mediapackage#TooManyRequestsException": return [3, 10];
|
|
2082
|
-
case "UnprocessableEntityException": return [3, 12];
|
|
2083
|
-
case "com.amazonaws.mediapackage#UnprocessableEntityException": return [3, 12];
|
|
2084
|
-
}
|
|
2085
|
-
return [3, 14];
|
|
2086
|
-
case 2: return [4, deserializeAws_restJson1ForbiddenExceptionResponse(parsedOutput, context)];
|
|
2087
|
-
case 3: throw _d.sent();
|
|
2088
|
-
case 4: return [4, deserializeAws_restJson1InternalServerErrorExceptionResponse(parsedOutput, context)];
|
|
2089
|
-
case 5: throw _d.sent();
|
|
2090
|
-
case 6: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
2091
|
-
case 7: throw _d.sent();
|
|
2092
|
-
case 8: return [4, deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)];
|
|
2093
|
-
case 9: throw _d.sent();
|
|
2094
|
-
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
2095
|
-
case 11: throw _d.sent();
|
|
2096
|
-
case 12: return [4, deserializeAws_restJson1UnprocessableEntityExceptionResponse(parsedOutput, context)];
|
|
2097
|
-
case 13: throw _d.sent();
|
|
2098
|
-
case 14:
|
|
2099
|
-
parsedBody = parsedOutput.body;
|
|
2100
|
-
throwDefaultError({
|
|
2101
|
-
output: output,
|
|
2102
|
-
parsedBody: parsedBody,
|
|
2103
|
-
exceptionCtor: __BaseException,
|
|
2104
|
-
errorCode: errorCode,
|
|
2105
|
-
});
|
|
2106
|
-
_d.label = 15;
|
|
2107
|
-
case 15: return [2];
|
|
2108
|
-
}
|
|
1590
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1591
|
+
};
|
|
1592
|
+
const deserializeAws_restJson1TooManyRequestsExceptionResponse = async (parsedOutput, context) => {
|
|
1593
|
+
const contents = map({});
|
|
1594
|
+
const data = parsedOutput.body;
|
|
1595
|
+
if (data.message != null) {
|
|
1596
|
+
contents.Message = __expectString(data.message);
|
|
1597
|
+
}
|
|
1598
|
+
const exception = new TooManyRequestsException({
|
|
1599
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1600
|
+
...contents,
|
|
2109
1601
|
});
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2122
|
-
});
|
|
2123
|
-
}); };
|
|
2124
|
-
var deserializeAws_restJson1InternalServerErrorExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2125
|
-
var contents, data, exception;
|
|
2126
|
-
return __generator(this, function (_a) {
|
|
2127
|
-
contents = map({});
|
|
2128
|
-
data = parsedOutput.body;
|
|
2129
|
-
if (data.message != null) {
|
|
2130
|
-
contents.Message = __expectString(data.message);
|
|
2131
|
-
}
|
|
2132
|
-
exception = new InternalServerErrorException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2133
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2134
|
-
});
|
|
2135
|
-
}); };
|
|
2136
|
-
var deserializeAws_restJson1NotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2137
|
-
var contents, data, exception;
|
|
2138
|
-
return __generator(this, function (_a) {
|
|
2139
|
-
contents = map({});
|
|
2140
|
-
data = parsedOutput.body;
|
|
2141
|
-
if (data.message != null) {
|
|
2142
|
-
contents.Message = __expectString(data.message);
|
|
2143
|
-
}
|
|
2144
|
-
exception = new NotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2145
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2146
|
-
});
|
|
2147
|
-
}); };
|
|
2148
|
-
var deserializeAws_restJson1ServiceUnavailableExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2149
|
-
var contents, data, exception;
|
|
2150
|
-
return __generator(this, function (_a) {
|
|
2151
|
-
contents = map({});
|
|
2152
|
-
data = parsedOutput.body;
|
|
2153
|
-
if (data.message != null) {
|
|
2154
|
-
contents.Message = __expectString(data.message);
|
|
2155
|
-
}
|
|
2156
|
-
exception = new ServiceUnavailableException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2157
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2158
|
-
});
|
|
2159
|
-
}); };
|
|
2160
|
-
var deserializeAws_restJson1TooManyRequestsExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2161
|
-
var contents, data, exception;
|
|
2162
|
-
return __generator(this, function (_a) {
|
|
2163
|
-
contents = map({});
|
|
2164
|
-
data = parsedOutput.body;
|
|
2165
|
-
if (data.message != null) {
|
|
2166
|
-
contents.Message = __expectString(data.message);
|
|
2167
|
-
}
|
|
2168
|
-
exception = new TooManyRequestsException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2169
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2170
|
-
});
|
|
2171
|
-
}); };
|
|
2172
|
-
var deserializeAws_restJson1UnprocessableEntityExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2173
|
-
var contents, data, exception;
|
|
2174
|
-
return __generator(this, function (_a) {
|
|
2175
|
-
contents = map({});
|
|
2176
|
-
data = parsedOutput.body;
|
|
2177
|
-
if (data.message != null) {
|
|
2178
|
-
contents.Message = __expectString(data.message);
|
|
2179
|
-
}
|
|
2180
|
-
exception = new UnprocessableEntityException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2181
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
1602
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1603
|
+
};
|
|
1604
|
+
const deserializeAws_restJson1UnprocessableEntityExceptionResponse = async (parsedOutput, context) => {
|
|
1605
|
+
const contents = map({});
|
|
1606
|
+
const data = parsedOutput.body;
|
|
1607
|
+
if (data.message != null) {
|
|
1608
|
+
contents.Message = __expectString(data.message);
|
|
1609
|
+
}
|
|
1610
|
+
const exception = new UnprocessableEntityException({
|
|
1611
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1612
|
+
...contents,
|
|
2182
1613
|
});
|
|
2183
|
-
|
|
2184
|
-
|
|
1614
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1615
|
+
};
|
|
1616
|
+
const serializeAws_restJson1__listOf__PeriodTriggersElement = (input, context) => {
|
|
2185
1617
|
return input
|
|
2186
|
-
.filter(
|
|
2187
|
-
.map(
|
|
1618
|
+
.filter((e) => e != null)
|
|
1619
|
+
.map((entry) => {
|
|
2188
1620
|
return entry;
|
|
2189
1621
|
});
|
|
2190
1622
|
};
|
|
2191
|
-
|
|
1623
|
+
const serializeAws_restJson1__listOf__string = (input, context) => {
|
|
2192
1624
|
return input
|
|
2193
|
-
.filter(
|
|
2194
|
-
.map(
|
|
1625
|
+
.filter((e) => e != null)
|
|
1626
|
+
.map((entry) => {
|
|
2195
1627
|
return entry;
|
|
2196
1628
|
});
|
|
2197
1629
|
};
|
|
2198
|
-
|
|
1630
|
+
const serializeAws_restJson1__listOfHlsManifestCreateOrUpdateParameters = (input, context) => {
|
|
2199
1631
|
return input
|
|
2200
|
-
.filter(
|
|
2201
|
-
.map(
|
|
1632
|
+
.filter((e) => e != null)
|
|
1633
|
+
.map((entry) => {
|
|
2202
1634
|
return serializeAws_restJson1HlsManifestCreateOrUpdateParameters(entry, context);
|
|
2203
1635
|
});
|
|
2204
1636
|
};
|
|
2205
|
-
|
|
2206
|
-
return Object.entries(input).reduce(
|
|
2207
|
-
var _b;
|
|
2208
|
-
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
1637
|
+
const serializeAws_restJson1__mapOf__string = (input, context) => {
|
|
1638
|
+
return Object.entries(input).reduce((acc, [key, value]) => {
|
|
2209
1639
|
if (value === null) {
|
|
2210
1640
|
return acc;
|
|
2211
1641
|
}
|
|
2212
|
-
return
|
|
1642
|
+
return {
|
|
1643
|
+
...acc,
|
|
1644
|
+
[key]: value,
|
|
1645
|
+
};
|
|
2213
1646
|
}, {});
|
|
2214
1647
|
};
|
|
2215
|
-
|
|
1648
|
+
const serializeAws_restJson1AdTriggers = (input, context) => {
|
|
2216
1649
|
return input
|
|
2217
|
-
.filter(
|
|
2218
|
-
.map(
|
|
1650
|
+
.filter((e) => e != null)
|
|
1651
|
+
.map((entry) => {
|
|
2219
1652
|
return entry;
|
|
2220
1653
|
});
|
|
2221
1654
|
};
|
|
2222
|
-
|
|
2223
|
-
return
|
|
2224
|
-
}
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
};
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
|
|
2246
|
-
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
|
|
2251
|
-
}
|
|
2252
|
-
};
|
|
2253
|
-
|
|
2254
|
-
return
|
|
2255
|
-
}
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
}
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
}
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
}
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
};
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
};
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
1655
|
+
const serializeAws_restJson1Authorization = (input, context) => {
|
|
1656
|
+
return {
|
|
1657
|
+
...(input.CdnIdentifierSecret != null && { cdnIdentifierSecret: input.CdnIdentifierSecret }),
|
|
1658
|
+
...(input.SecretsRoleArn != null && { secretsRoleArn: input.SecretsRoleArn }),
|
|
1659
|
+
};
|
|
1660
|
+
};
|
|
1661
|
+
const serializeAws_restJson1CmafEncryption = (input, context) => {
|
|
1662
|
+
return {
|
|
1663
|
+
...(input.ConstantInitializationVector != null && {
|
|
1664
|
+
constantInitializationVector: input.ConstantInitializationVector,
|
|
1665
|
+
}),
|
|
1666
|
+
...(input.EncryptionMethod != null && { encryptionMethod: input.EncryptionMethod }),
|
|
1667
|
+
...(input.KeyRotationIntervalSeconds != null && { keyRotationIntervalSeconds: input.KeyRotationIntervalSeconds }),
|
|
1668
|
+
...(input.SpekeKeyProvider != null && {
|
|
1669
|
+
spekeKeyProvider: serializeAws_restJson1SpekeKeyProvider(input.SpekeKeyProvider, context),
|
|
1670
|
+
}),
|
|
1671
|
+
};
|
|
1672
|
+
};
|
|
1673
|
+
const serializeAws_restJson1CmafPackageCreateOrUpdateParameters = (input, context) => {
|
|
1674
|
+
return {
|
|
1675
|
+
...(input.Encryption != null && { encryption: serializeAws_restJson1CmafEncryption(input.Encryption, context) }),
|
|
1676
|
+
...(input.HlsManifests != null && {
|
|
1677
|
+
hlsManifests: serializeAws_restJson1__listOfHlsManifestCreateOrUpdateParameters(input.HlsManifests, context),
|
|
1678
|
+
}),
|
|
1679
|
+
...(input.SegmentDurationSeconds != null && { segmentDurationSeconds: input.SegmentDurationSeconds }),
|
|
1680
|
+
...(input.SegmentPrefix != null && { segmentPrefix: input.SegmentPrefix }),
|
|
1681
|
+
...(input.StreamSelection != null && {
|
|
1682
|
+
streamSelection: serializeAws_restJson1StreamSelection(input.StreamSelection, context),
|
|
1683
|
+
}),
|
|
1684
|
+
};
|
|
1685
|
+
};
|
|
1686
|
+
const serializeAws_restJson1DashEncryption = (input, context) => {
|
|
1687
|
+
return {
|
|
1688
|
+
...(input.KeyRotationIntervalSeconds != null && { keyRotationIntervalSeconds: input.KeyRotationIntervalSeconds }),
|
|
1689
|
+
...(input.SpekeKeyProvider != null && {
|
|
1690
|
+
spekeKeyProvider: serializeAws_restJson1SpekeKeyProvider(input.SpekeKeyProvider, context),
|
|
1691
|
+
}),
|
|
1692
|
+
};
|
|
1693
|
+
};
|
|
1694
|
+
const serializeAws_restJson1DashPackage = (input, context) => {
|
|
1695
|
+
return {
|
|
1696
|
+
...(input.AdTriggers != null && { adTriggers: serializeAws_restJson1AdTriggers(input.AdTriggers, context) }),
|
|
1697
|
+
...(input.AdsOnDeliveryRestrictions != null && { adsOnDeliveryRestrictions: input.AdsOnDeliveryRestrictions }),
|
|
1698
|
+
...(input.Encryption != null && { encryption: serializeAws_restJson1DashEncryption(input.Encryption, context) }),
|
|
1699
|
+
...(input.IncludeIframeOnlyStream != null && { includeIframeOnlyStream: input.IncludeIframeOnlyStream }),
|
|
1700
|
+
...(input.ManifestLayout != null && { manifestLayout: input.ManifestLayout }),
|
|
1701
|
+
...(input.ManifestWindowSeconds != null && { manifestWindowSeconds: input.ManifestWindowSeconds }),
|
|
1702
|
+
...(input.MinBufferTimeSeconds != null && { minBufferTimeSeconds: input.MinBufferTimeSeconds }),
|
|
1703
|
+
...(input.MinUpdatePeriodSeconds != null && { minUpdatePeriodSeconds: input.MinUpdatePeriodSeconds }),
|
|
1704
|
+
...(input.PeriodTriggers != null && {
|
|
1705
|
+
periodTriggers: serializeAws_restJson1__listOf__PeriodTriggersElement(input.PeriodTriggers, context),
|
|
1706
|
+
}),
|
|
1707
|
+
...(input.Profile != null && { profile: input.Profile }),
|
|
1708
|
+
...(input.SegmentDurationSeconds != null && { segmentDurationSeconds: input.SegmentDurationSeconds }),
|
|
1709
|
+
...(input.SegmentTemplateFormat != null && { segmentTemplateFormat: input.SegmentTemplateFormat }),
|
|
1710
|
+
...(input.StreamSelection != null && {
|
|
1711
|
+
streamSelection: serializeAws_restJson1StreamSelection(input.StreamSelection, context),
|
|
1712
|
+
}),
|
|
1713
|
+
...(input.SuggestedPresentationDelaySeconds != null && {
|
|
1714
|
+
suggestedPresentationDelaySeconds: input.SuggestedPresentationDelaySeconds,
|
|
1715
|
+
}),
|
|
1716
|
+
...(input.UtcTiming != null && { utcTiming: input.UtcTiming }),
|
|
1717
|
+
...(input.UtcTimingUri != null && { utcTimingUri: input.UtcTimingUri }),
|
|
1718
|
+
};
|
|
1719
|
+
};
|
|
1720
|
+
const serializeAws_restJson1EgressAccessLogs = (input, context) => {
|
|
1721
|
+
return {
|
|
1722
|
+
...(input.LogGroupName != null && { logGroupName: input.LogGroupName }),
|
|
1723
|
+
};
|
|
1724
|
+
};
|
|
1725
|
+
const serializeAws_restJson1EncryptionContractConfiguration = (input, context) => {
|
|
1726
|
+
return {
|
|
1727
|
+
...(input.PresetSpeke20Audio != null && { presetSpeke20Audio: input.PresetSpeke20Audio }),
|
|
1728
|
+
...(input.PresetSpeke20Video != null && { presetSpeke20Video: input.PresetSpeke20Video }),
|
|
1729
|
+
};
|
|
1730
|
+
};
|
|
1731
|
+
const serializeAws_restJson1HlsEncryption = (input, context) => {
|
|
1732
|
+
return {
|
|
1733
|
+
...(input.ConstantInitializationVector != null && {
|
|
1734
|
+
constantInitializationVector: input.ConstantInitializationVector,
|
|
1735
|
+
}),
|
|
1736
|
+
...(input.EncryptionMethod != null && { encryptionMethod: input.EncryptionMethod }),
|
|
1737
|
+
...(input.KeyRotationIntervalSeconds != null && { keyRotationIntervalSeconds: input.KeyRotationIntervalSeconds }),
|
|
1738
|
+
...(input.RepeatExtXKey != null && { repeatExtXKey: input.RepeatExtXKey }),
|
|
1739
|
+
...(input.SpekeKeyProvider != null && {
|
|
1740
|
+
spekeKeyProvider: serializeAws_restJson1SpekeKeyProvider(input.SpekeKeyProvider, context),
|
|
1741
|
+
}),
|
|
1742
|
+
};
|
|
1743
|
+
};
|
|
1744
|
+
const serializeAws_restJson1HlsManifestCreateOrUpdateParameters = (input, context) => {
|
|
1745
|
+
return {
|
|
1746
|
+
...(input.AdMarkers != null && { adMarkers: input.AdMarkers }),
|
|
1747
|
+
...(input.AdTriggers != null && { adTriggers: serializeAws_restJson1AdTriggers(input.AdTriggers, context) }),
|
|
1748
|
+
...(input.AdsOnDeliveryRestrictions != null && { adsOnDeliveryRestrictions: input.AdsOnDeliveryRestrictions }),
|
|
1749
|
+
...(input.Id != null && { id: input.Id }),
|
|
1750
|
+
...(input.IncludeIframeOnlyStream != null && { includeIframeOnlyStream: input.IncludeIframeOnlyStream }),
|
|
1751
|
+
...(input.ManifestName != null && { manifestName: input.ManifestName }),
|
|
1752
|
+
...(input.PlaylistType != null && { playlistType: input.PlaylistType }),
|
|
1753
|
+
...(input.PlaylistWindowSeconds != null && { playlistWindowSeconds: input.PlaylistWindowSeconds }),
|
|
1754
|
+
...(input.ProgramDateTimeIntervalSeconds != null && {
|
|
1755
|
+
programDateTimeIntervalSeconds: input.ProgramDateTimeIntervalSeconds,
|
|
1756
|
+
}),
|
|
1757
|
+
};
|
|
1758
|
+
};
|
|
1759
|
+
const serializeAws_restJson1HlsPackage = (input, context) => {
|
|
1760
|
+
return {
|
|
1761
|
+
...(input.AdMarkers != null && { adMarkers: input.AdMarkers }),
|
|
1762
|
+
...(input.AdTriggers != null && { adTriggers: serializeAws_restJson1AdTriggers(input.AdTriggers, context) }),
|
|
1763
|
+
...(input.AdsOnDeliveryRestrictions != null && { adsOnDeliveryRestrictions: input.AdsOnDeliveryRestrictions }),
|
|
1764
|
+
...(input.Encryption != null && { encryption: serializeAws_restJson1HlsEncryption(input.Encryption, context) }),
|
|
1765
|
+
...(input.IncludeDvbSubtitles != null && { includeDvbSubtitles: input.IncludeDvbSubtitles }),
|
|
1766
|
+
...(input.IncludeIframeOnlyStream != null && { includeIframeOnlyStream: input.IncludeIframeOnlyStream }),
|
|
1767
|
+
...(input.PlaylistType != null && { playlistType: input.PlaylistType }),
|
|
1768
|
+
...(input.PlaylistWindowSeconds != null && { playlistWindowSeconds: input.PlaylistWindowSeconds }),
|
|
1769
|
+
...(input.ProgramDateTimeIntervalSeconds != null && {
|
|
1770
|
+
programDateTimeIntervalSeconds: input.ProgramDateTimeIntervalSeconds,
|
|
1771
|
+
}),
|
|
1772
|
+
...(input.SegmentDurationSeconds != null && { segmentDurationSeconds: input.SegmentDurationSeconds }),
|
|
1773
|
+
...(input.StreamSelection != null && {
|
|
1774
|
+
streamSelection: serializeAws_restJson1StreamSelection(input.StreamSelection, context),
|
|
1775
|
+
}),
|
|
1776
|
+
...(input.UseAudioRenditionGroup != null && { useAudioRenditionGroup: input.UseAudioRenditionGroup }),
|
|
1777
|
+
};
|
|
1778
|
+
};
|
|
1779
|
+
const serializeAws_restJson1IngressAccessLogs = (input, context) => {
|
|
1780
|
+
return {
|
|
1781
|
+
...(input.LogGroupName != null && { logGroupName: input.LogGroupName }),
|
|
1782
|
+
};
|
|
1783
|
+
};
|
|
1784
|
+
const serializeAws_restJson1MssEncryption = (input, context) => {
|
|
1785
|
+
return {
|
|
1786
|
+
...(input.SpekeKeyProvider != null && {
|
|
1787
|
+
spekeKeyProvider: serializeAws_restJson1SpekeKeyProvider(input.SpekeKeyProvider, context),
|
|
1788
|
+
}),
|
|
1789
|
+
};
|
|
1790
|
+
};
|
|
1791
|
+
const serializeAws_restJson1MssPackage = (input, context) => {
|
|
1792
|
+
return {
|
|
1793
|
+
...(input.Encryption != null && { encryption: serializeAws_restJson1MssEncryption(input.Encryption, context) }),
|
|
1794
|
+
...(input.ManifestWindowSeconds != null && { manifestWindowSeconds: input.ManifestWindowSeconds }),
|
|
1795
|
+
...(input.SegmentDurationSeconds != null && { segmentDurationSeconds: input.SegmentDurationSeconds }),
|
|
1796
|
+
...(input.StreamSelection != null && {
|
|
1797
|
+
streamSelection: serializeAws_restJson1StreamSelection(input.StreamSelection, context),
|
|
1798
|
+
}),
|
|
1799
|
+
};
|
|
1800
|
+
};
|
|
1801
|
+
const serializeAws_restJson1S3Destination = (input, context) => {
|
|
1802
|
+
return {
|
|
1803
|
+
...(input.BucketName != null && { bucketName: input.BucketName }),
|
|
1804
|
+
...(input.ManifestKey != null && { manifestKey: input.ManifestKey }),
|
|
1805
|
+
...(input.RoleArn != null && { roleArn: input.RoleArn }),
|
|
1806
|
+
};
|
|
1807
|
+
};
|
|
1808
|
+
const serializeAws_restJson1SpekeKeyProvider = (input, context) => {
|
|
1809
|
+
return {
|
|
1810
|
+
...(input.CertificateArn != null && { certificateArn: input.CertificateArn }),
|
|
1811
|
+
...(input.EncryptionContractConfiguration != null && {
|
|
1812
|
+
encryptionContractConfiguration: serializeAws_restJson1EncryptionContractConfiguration(input.EncryptionContractConfiguration, context),
|
|
1813
|
+
}),
|
|
1814
|
+
...(input.ResourceId != null && { resourceId: input.ResourceId }),
|
|
1815
|
+
...(input.RoleArn != null && { roleArn: input.RoleArn }),
|
|
1816
|
+
...(input.SystemIds != null && { systemIds: serializeAws_restJson1__listOf__string(input.SystemIds, context) }),
|
|
1817
|
+
...(input.Url != null && { url: input.Url }),
|
|
1818
|
+
};
|
|
1819
|
+
};
|
|
1820
|
+
const serializeAws_restJson1StreamSelection = (input, context) => {
|
|
1821
|
+
return {
|
|
1822
|
+
...(input.MaxVideoBitsPerSecond != null && { maxVideoBitsPerSecond: input.MaxVideoBitsPerSecond }),
|
|
1823
|
+
...(input.MinVideoBitsPerSecond != null && { minVideoBitsPerSecond: input.MinVideoBitsPerSecond }),
|
|
1824
|
+
...(input.StreamOrder != null && { streamOrder: input.StreamOrder }),
|
|
1825
|
+
};
|
|
1826
|
+
};
|
|
1827
|
+
const serializeAws_restJson1Tags = (input, context) => {
|
|
1828
|
+
return Object.entries(input).reduce((acc, [key, value]) => {
|
|
2306
1829
|
if (value === null) {
|
|
2307
1830
|
return acc;
|
|
2308
1831
|
}
|
|
2309
|
-
return
|
|
1832
|
+
return {
|
|
1833
|
+
...acc,
|
|
1834
|
+
[key]: value,
|
|
1835
|
+
};
|
|
2310
1836
|
}, {});
|
|
2311
1837
|
};
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
.filter(
|
|
2315
|
-
.map(
|
|
1838
|
+
const deserializeAws_restJson1__listOf__PeriodTriggersElement = (output, context) => {
|
|
1839
|
+
const retVal = (output || [])
|
|
1840
|
+
.filter((e) => e != null)
|
|
1841
|
+
.map((entry) => {
|
|
2316
1842
|
if (entry === null) {
|
|
2317
1843
|
return null;
|
|
2318
1844
|
}
|
|
@@ -2320,10 +1846,10 @@ var deserializeAws_restJson1__listOf__PeriodTriggersElement = function (output,
|
|
|
2320
1846
|
});
|
|
2321
1847
|
return retVal;
|
|
2322
1848
|
};
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
.filter(
|
|
2326
|
-
.map(
|
|
1849
|
+
const deserializeAws_restJson1__listOf__string = (output, context) => {
|
|
1850
|
+
const retVal = (output || [])
|
|
1851
|
+
.filter((e) => e != null)
|
|
1852
|
+
.map((entry) => {
|
|
2327
1853
|
if (entry === null) {
|
|
2328
1854
|
return null;
|
|
2329
1855
|
}
|
|
@@ -2331,10 +1857,10 @@ var deserializeAws_restJson1__listOf__string = function (output, context) {
|
|
|
2331
1857
|
});
|
|
2332
1858
|
return retVal;
|
|
2333
1859
|
};
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
.filter(
|
|
2337
|
-
.map(
|
|
1860
|
+
const deserializeAws_restJson1__listOfChannel = (output, context) => {
|
|
1861
|
+
const retVal = (output || [])
|
|
1862
|
+
.filter((e) => e != null)
|
|
1863
|
+
.map((entry) => {
|
|
2338
1864
|
if (entry === null) {
|
|
2339
1865
|
return null;
|
|
2340
1866
|
}
|
|
@@ -2342,10 +1868,10 @@ var deserializeAws_restJson1__listOfChannel = function (output, context) {
|
|
|
2342
1868
|
});
|
|
2343
1869
|
return retVal;
|
|
2344
1870
|
};
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
.filter(
|
|
2348
|
-
.map(
|
|
1871
|
+
const deserializeAws_restJson1__listOfHarvestJob = (output, context) => {
|
|
1872
|
+
const retVal = (output || [])
|
|
1873
|
+
.filter((e) => e != null)
|
|
1874
|
+
.map((entry) => {
|
|
2349
1875
|
if (entry === null) {
|
|
2350
1876
|
return null;
|
|
2351
1877
|
}
|
|
@@ -2353,10 +1879,10 @@ var deserializeAws_restJson1__listOfHarvestJob = function (output, context) {
|
|
|
2353
1879
|
});
|
|
2354
1880
|
return retVal;
|
|
2355
1881
|
};
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
.filter(
|
|
2359
|
-
.map(
|
|
1882
|
+
const deserializeAws_restJson1__listOfHlsManifest = (output, context) => {
|
|
1883
|
+
const retVal = (output || [])
|
|
1884
|
+
.filter((e) => e != null)
|
|
1885
|
+
.map((entry) => {
|
|
2360
1886
|
if (entry === null) {
|
|
2361
1887
|
return null;
|
|
2362
1888
|
}
|
|
@@ -2364,10 +1890,10 @@ var deserializeAws_restJson1__listOfHlsManifest = function (output, context) {
|
|
|
2364
1890
|
});
|
|
2365
1891
|
return retVal;
|
|
2366
1892
|
};
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
.filter(
|
|
2370
|
-
.map(
|
|
1893
|
+
const deserializeAws_restJson1__listOfIngestEndpoint = (output, context) => {
|
|
1894
|
+
const retVal = (output || [])
|
|
1895
|
+
.filter((e) => e != null)
|
|
1896
|
+
.map((entry) => {
|
|
2371
1897
|
if (entry === null) {
|
|
2372
1898
|
return null;
|
|
2373
1899
|
}
|
|
@@ -2375,10 +1901,10 @@ var deserializeAws_restJson1__listOfIngestEndpoint = function (output, context)
|
|
|
2375
1901
|
});
|
|
2376
1902
|
return retVal;
|
|
2377
1903
|
};
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
.filter(
|
|
2381
|
-
.map(
|
|
1904
|
+
const deserializeAws_restJson1__listOfOriginEndpoint = (output, context) => {
|
|
1905
|
+
const retVal = (output || [])
|
|
1906
|
+
.filter((e) => e != null)
|
|
1907
|
+
.map((entry) => {
|
|
2382
1908
|
if (entry === null) {
|
|
2383
1909
|
return null;
|
|
2384
1910
|
}
|
|
@@ -2386,20 +1912,21 @@ var deserializeAws_restJson1__listOfOriginEndpoint = function (output, context)
|
|
|
2386
1912
|
});
|
|
2387
1913
|
return retVal;
|
|
2388
1914
|
};
|
|
2389
|
-
|
|
2390
|
-
return Object.entries(output).reduce(
|
|
2391
|
-
var _b;
|
|
2392
|
-
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
1915
|
+
const deserializeAws_restJson1__mapOf__string = (output, context) => {
|
|
1916
|
+
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
2393
1917
|
if (value === null) {
|
|
2394
1918
|
return acc;
|
|
2395
1919
|
}
|
|
2396
|
-
return
|
|
1920
|
+
return {
|
|
1921
|
+
...acc,
|
|
1922
|
+
[key]: __expectString(value),
|
|
1923
|
+
};
|
|
2397
1924
|
}, {});
|
|
2398
1925
|
};
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
.filter(
|
|
2402
|
-
.map(
|
|
1926
|
+
const deserializeAws_restJson1AdTriggers = (output, context) => {
|
|
1927
|
+
const retVal = (output || [])
|
|
1928
|
+
.filter((e) => e != null)
|
|
1929
|
+
.map((entry) => {
|
|
2403
1930
|
if (entry === null) {
|
|
2404
1931
|
return null;
|
|
2405
1932
|
}
|
|
@@ -2407,13 +1934,13 @@ var deserializeAws_restJson1AdTriggers = function (output, context) {
|
|
|
2407
1934
|
});
|
|
2408
1935
|
return retVal;
|
|
2409
1936
|
};
|
|
2410
|
-
|
|
1937
|
+
const deserializeAws_restJson1Authorization = (output, context) => {
|
|
2411
1938
|
return {
|
|
2412
1939
|
CdnIdentifierSecret: __expectString(output.cdnIdentifierSecret),
|
|
2413
1940
|
SecretsRoleArn: __expectString(output.secretsRoleArn),
|
|
2414
1941
|
};
|
|
2415
1942
|
};
|
|
2416
|
-
|
|
1943
|
+
const deserializeAws_restJson1Channel = (output, context) => {
|
|
2417
1944
|
return {
|
|
2418
1945
|
Arn: __expectString(output.arn),
|
|
2419
1946
|
Description: __expectString(output.description),
|
|
@@ -2428,7 +1955,7 @@ var deserializeAws_restJson1Channel = function (output, context) {
|
|
|
2428
1955
|
Tags: output.tags != null ? deserializeAws_restJson1Tags(output.tags, context) : undefined,
|
|
2429
1956
|
};
|
|
2430
1957
|
};
|
|
2431
|
-
|
|
1958
|
+
const deserializeAws_restJson1CmafEncryption = (output, context) => {
|
|
2432
1959
|
return {
|
|
2433
1960
|
ConstantInitializationVector: __expectString(output.constantInitializationVector),
|
|
2434
1961
|
EncryptionMethod: __expectString(output.encryptionMethod),
|
|
@@ -2438,7 +1965,7 @@ var deserializeAws_restJson1CmafEncryption = function (output, context) {
|
|
|
2438
1965
|
: undefined,
|
|
2439
1966
|
};
|
|
2440
1967
|
};
|
|
2441
|
-
|
|
1968
|
+
const deserializeAws_restJson1CmafPackage = (output, context) => {
|
|
2442
1969
|
return {
|
|
2443
1970
|
Encryption: output.encryption != null ? deserializeAws_restJson1CmafEncryption(output.encryption, context) : undefined,
|
|
2444
1971
|
HlsManifests: output.hlsManifests != null
|
|
@@ -2451,7 +1978,7 @@ var deserializeAws_restJson1CmafPackage = function (output, context) {
|
|
|
2451
1978
|
: undefined,
|
|
2452
1979
|
};
|
|
2453
1980
|
};
|
|
2454
|
-
|
|
1981
|
+
const deserializeAws_restJson1DashEncryption = (output, context) => {
|
|
2455
1982
|
return {
|
|
2456
1983
|
KeyRotationIntervalSeconds: __expectInt32(output.keyRotationIntervalSeconds),
|
|
2457
1984
|
SpekeKeyProvider: output.spekeKeyProvider != null
|
|
@@ -2459,7 +1986,7 @@ var deserializeAws_restJson1DashEncryption = function (output, context) {
|
|
|
2459
1986
|
: undefined,
|
|
2460
1987
|
};
|
|
2461
1988
|
};
|
|
2462
|
-
|
|
1989
|
+
const deserializeAws_restJson1DashPackage = (output, context) => {
|
|
2463
1990
|
return {
|
|
2464
1991
|
AdTriggers: output.adTriggers != null ? deserializeAws_restJson1AdTriggers(output.adTriggers, context) : undefined,
|
|
2465
1992
|
AdsOnDeliveryRestrictions: __expectString(output.adsOnDeliveryRestrictions),
|
|
@@ -2483,18 +2010,18 @@ var deserializeAws_restJson1DashPackage = function (output, context) {
|
|
|
2483
2010
|
UtcTimingUri: __expectString(output.utcTimingUri),
|
|
2484
2011
|
};
|
|
2485
2012
|
};
|
|
2486
|
-
|
|
2013
|
+
const deserializeAws_restJson1EgressAccessLogs = (output, context) => {
|
|
2487
2014
|
return {
|
|
2488
2015
|
LogGroupName: __expectString(output.logGroupName),
|
|
2489
2016
|
};
|
|
2490
2017
|
};
|
|
2491
|
-
|
|
2018
|
+
const deserializeAws_restJson1EncryptionContractConfiguration = (output, context) => {
|
|
2492
2019
|
return {
|
|
2493
2020
|
PresetSpeke20Audio: __expectString(output.presetSpeke20Audio),
|
|
2494
2021
|
PresetSpeke20Video: __expectString(output.presetSpeke20Video),
|
|
2495
2022
|
};
|
|
2496
2023
|
};
|
|
2497
|
-
|
|
2024
|
+
const deserializeAws_restJson1HarvestJob = (output, context) => {
|
|
2498
2025
|
return {
|
|
2499
2026
|
Arn: __expectString(output.arn),
|
|
2500
2027
|
ChannelId: __expectString(output.channelId),
|
|
@@ -2507,7 +2034,7 @@ var deserializeAws_restJson1HarvestJob = function (output, context) {
|
|
|
2507
2034
|
Status: __expectString(output.status),
|
|
2508
2035
|
};
|
|
2509
2036
|
};
|
|
2510
|
-
|
|
2037
|
+
const deserializeAws_restJson1HlsEncryption = (output, context) => {
|
|
2511
2038
|
return {
|
|
2512
2039
|
ConstantInitializationVector: __expectString(output.constantInitializationVector),
|
|
2513
2040
|
EncryptionMethod: __expectString(output.encryptionMethod),
|
|
@@ -2518,14 +2045,14 @@ var deserializeAws_restJson1HlsEncryption = function (output, context) {
|
|
|
2518
2045
|
: undefined,
|
|
2519
2046
|
};
|
|
2520
2047
|
};
|
|
2521
|
-
|
|
2048
|
+
const deserializeAws_restJson1HlsIngest = (output, context) => {
|
|
2522
2049
|
return {
|
|
2523
2050
|
IngestEndpoints: output.ingestEndpoints != null
|
|
2524
2051
|
? deserializeAws_restJson1__listOfIngestEndpoint(output.ingestEndpoints, context)
|
|
2525
2052
|
: undefined,
|
|
2526
2053
|
};
|
|
2527
2054
|
};
|
|
2528
|
-
|
|
2055
|
+
const deserializeAws_restJson1HlsManifest = (output, context) => {
|
|
2529
2056
|
return {
|
|
2530
2057
|
AdMarkers: __expectString(output.adMarkers),
|
|
2531
2058
|
AdTriggers: output.adTriggers != null ? deserializeAws_restJson1AdTriggers(output.adTriggers, context) : undefined,
|
|
@@ -2539,7 +2066,7 @@ var deserializeAws_restJson1HlsManifest = function (output, context) {
|
|
|
2539
2066
|
Url: __expectString(output.url),
|
|
2540
2067
|
};
|
|
2541
2068
|
};
|
|
2542
|
-
|
|
2069
|
+
const deserializeAws_restJson1HlsPackage = (output, context) => {
|
|
2543
2070
|
return {
|
|
2544
2071
|
AdMarkers: __expectString(output.adMarkers),
|
|
2545
2072
|
AdTriggers: output.adTriggers != null ? deserializeAws_restJson1AdTriggers(output.adTriggers, context) : undefined,
|
|
@@ -2557,7 +2084,7 @@ var deserializeAws_restJson1HlsPackage = function (output, context) {
|
|
|
2557
2084
|
UseAudioRenditionGroup: __expectBoolean(output.useAudioRenditionGroup),
|
|
2558
2085
|
};
|
|
2559
2086
|
};
|
|
2560
|
-
|
|
2087
|
+
const deserializeAws_restJson1IngestEndpoint = (output, context) => {
|
|
2561
2088
|
return {
|
|
2562
2089
|
Id: __expectString(output.id),
|
|
2563
2090
|
Password: __expectString(output.password),
|
|
@@ -2565,19 +2092,19 @@ var deserializeAws_restJson1IngestEndpoint = function (output, context) {
|
|
|
2565
2092
|
Username: __expectString(output.username),
|
|
2566
2093
|
};
|
|
2567
2094
|
};
|
|
2568
|
-
|
|
2095
|
+
const deserializeAws_restJson1IngressAccessLogs = (output, context) => {
|
|
2569
2096
|
return {
|
|
2570
2097
|
LogGroupName: __expectString(output.logGroupName),
|
|
2571
2098
|
};
|
|
2572
2099
|
};
|
|
2573
|
-
|
|
2100
|
+
const deserializeAws_restJson1MssEncryption = (output, context) => {
|
|
2574
2101
|
return {
|
|
2575
2102
|
SpekeKeyProvider: output.spekeKeyProvider != null
|
|
2576
2103
|
? deserializeAws_restJson1SpekeKeyProvider(output.spekeKeyProvider, context)
|
|
2577
2104
|
: undefined,
|
|
2578
2105
|
};
|
|
2579
2106
|
};
|
|
2580
|
-
|
|
2107
|
+
const deserializeAws_restJson1MssPackage = (output, context) => {
|
|
2581
2108
|
return {
|
|
2582
2109
|
Encryption: output.encryption != null ? deserializeAws_restJson1MssEncryption(output.encryption, context) : undefined,
|
|
2583
2110
|
ManifestWindowSeconds: __expectInt32(output.manifestWindowSeconds),
|
|
@@ -2587,7 +2114,7 @@ var deserializeAws_restJson1MssPackage = function (output, context) {
|
|
|
2587
2114
|
: undefined,
|
|
2588
2115
|
};
|
|
2589
2116
|
};
|
|
2590
|
-
|
|
2117
|
+
const deserializeAws_restJson1OriginEndpoint = (output, context) => {
|
|
2591
2118
|
return {
|
|
2592
2119
|
Arn: __expectString(output.arn),
|
|
2593
2120
|
Authorization: output.authorization != null ? deserializeAws_restJson1Authorization(output.authorization, context) : undefined,
|
|
@@ -2607,14 +2134,14 @@ var deserializeAws_restJson1OriginEndpoint = function (output, context) {
|
|
|
2607
2134
|
Whitelist: output.whitelist != null ? deserializeAws_restJson1__listOf__string(output.whitelist, context) : undefined,
|
|
2608
2135
|
};
|
|
2609
2136
|
};
|
|
2610
|
-
|
|
2137
|
+
const deserializeAws_restJson1S3Destination = (output, context) => {
|
|
2611
2138
|
return {
|
|
2612
2139
|
BucketName: __expectString(output.bucketName),
|
|
2613
2140
|
ManifestKey: __expectString(output.manifestKey),
|
|
2614
2141
|
RoleArn: __expectString(output.roleArn),
|
|
2615
2142
|
};
|
|
2616
2143
|
};
|
|
2617
|
-
|
|
2144
|
+
const deserializeAws_restJson1SpekeKeyProvider = (output, context) => {
|
|
2618
2145
|
return {
|
|
2619
2146
|
CertificateArn: __expectString(output.certificateArn),
|
|
2620
2147
|
EncryptionContractConfiguration: output.encryptionContractConfiguration != null
|
|
@@ -2626,61 +2153,57 @@ var deserializeAws_restJson1SpekeKeyProvider = function (output, context) {
|
|
|
2626
2153
|
Url: __expectString(output.url),
|
|
2627
2154
|
};
|
|
2628
2155
|
};
|
|
2629
|
-
|
|
2156
|
+
const deserializeAws_restJson1StreamSelection = (output, context) => {
|
|
2630
2157
|
return {
|
|
2631
2158
|
MaxVideoBitsPerSecond: __expectInt32(output.maxVideoBitsPerSecond),
|
|
2632
2159
|
MinVideoBitsPerSecond: __expectInt32(output.minVideoBitsPerSecond),
|
|
2633
2160
|
StreamOrder: __expectString(output.streamOrder),
|
|
2634
2161
|
};
|
|
2635
2162
|
};
|
|
2636
|
-
|
|
2637
|
-
return Object.entries(output).reduce(
|
|
2638
|
-
var _b;
|
|
2639
|
-
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
2163
|
+
const deserializeAws_restJson1Tags = (output, context) => {
|
|
2164
|
+
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
2640
2165
|
if (value === null) {
|
|
2641
2166
|
return acc;
|
|
2642
2167
|
}
|
|
2643
|
-
return
|
|
2168
|
+
return {
|
|
2169
|
+
...acc,
|
|
2170
|
+
[key]: __expectString(value),
|
|
2171
|
+
};
|
|
2644
2172
|
}, {});
|
|
2645
2173
|
};
|
|
2646
|
-
|
|
2647
|
-
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
});
|
|
2654
|
-
};
|
|
2655
|
-
var collectBody = function (streamBody, context) {
|
|
2656
|
-
if (streamBody === void 0) { streamBody = new Uint8Array(); }
|
|
2174
|
+
const deserializeMetadata = (output) => ({
|
|
2175
|
+
httpStatusCode: output.statusCode,
|
|
2176
|
+
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"],
|
|
2177
|
+
extendedRequestId: output.headers["x-amz-id-2"],
|
|
2178
|
+
cfId: output.headers["x-amz-cf-id"],
|
|
2179
|
+
});
|
|
2180
|
+
const collectBody = (streamBody = new Uint8Array(), context) => {
|
|
2657
2181
|
if (streamBody instanceof Uint8Array) {
|
|
2658
2182
|
return Promise.resolve(streamBody);
|
|
2659
2183
|
}
|
|
2660
2184
|
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
2661
2185
|
};
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
}
|
|
2672
|
-
|
|
2673
|
-
|
|
2674
|
-
|
|
2675
|
-
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
});
|
|
2186
|
+
const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
2187
|
+
const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
2188
|
+
value !== null &&
|
|
2189
|
+
value !== "" &&
|
|
2190
|
+
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
2191
|
+
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
2192
|
+
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
2193
|
+
if (encoded.length) {
|
|
2194
|
+
return JSON.parse(encoded);
|
|
2195
|
+
}
|
|
2196
|
+
return {};
|
|
2197
|
+
});
|
|
2198
|
+
const parseErrorBody = async (errorBody, context) => {
|
|
2199
|
+
const value = await parseBody(errorBody, context);
|
|
2200
|
+
value.message = value.message ?? value.Message;
|
|
2201
|
+
return value;
|
|
2679
2202
|
};
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2203
|
+
const loadRestJsonErrorCode = (output, data) => {
|
|
2204
|
+
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
2205
|
+
const sanitizeErrorCode = (rawValue) => {
|
|
2206
|
+
let cleanValue = rawValue;
|
|
2684
2207
|
if (typeof cleanValue === "number") {
|
|
2685
2208
|
cleanValue = cleanValue.toString();
|
|
2686
2209
|
}
|
|
@@ -2695,7 +2218,7 @@ var loadRestJsonErrorCode = function (output, data) {
|
|
|
2695
2218
|
}
|
|
2696
2219
|
return cleanValue;
|
|
2697
2220
|
};
|
|
2698
|
-
|
|
2221
|
+
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
2699
2222
|
if (headerKey !== undefined) {
|
|
2700
2223
|
return sanitizeErrorCode(output.headers[headerKey]);
|
|
2701
2224
|
}
|