@aws-sdk/client-ivs 3.42.0 → 3.43.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 +11 -0
- package/README.md +10 -1
- package/dist-cjs/Ivs.js +30 -0
- package/dist-cjs/commands/GetStreamSessionCommand.js +36 -0
- package/dist-cjs/commands/ListStreamSessionsCommand.js +36 -0
- package/dist-cjs/commands/index.js +2 -0
- package/dist-cjs/models/models_0.js +68 -2
- package/dist-cjs/pagination/ListStreamSessionsPaginator.js +35 -0
- package/dist-cjs/pagination/index.js +1 -0
- package/dist-cjs/protocols/Aws_restJson1.js +282 -2
- package/dist-es/Ivs.js +30 -0
- package/dist-es/commands/GetStreamSessionCommand.js +39 -0
- package/dist-es/commands/ListStreamSessionsCommand.js +39 -0
- package/dist-es/commands/index.js +2 -0
- package/dist-es/models/models_0.js +44 -0
- package/dist-es/pagination/ListStreamSessionsPaginator.js +74 -0
- package/dist-es/pagination/index.js +1 -0
- package/dist-es/protocols/Aws_restJson1.js +309 -1
- package/dist-types/Ivs.d.ts +44 -19
- package/dist-types/IvsClient.d.ts +14 -3
- package/dist-types/commands/CreateRecordingConfigurationCommand.d.ts +9 -9
- package/dist-types/commands/DeleteChannelCommand.d.ts +2 -1
- package/dist-types/commands/GetStreamSessionCommand.d.ts +35 -0
- package/dist-types/commands/ListChannelsCommand.d.ts +3 -3
- package/dist-types/commands/ListRecordingConfigurationsCommand.d.ts +2 -2
- package/dist-types/commands/ListStreamSessionsCommand.d.ts +36 -0
- package/dist-types/commands/ListStreamsCommand.d.ts +2 -2
- package/dist-types/commands/PutMetadataCommand.d.ts +1 -1
- package/dist-types/commands/index.d.ts +2 -0
- package/dist-types/models/models_0.d.ts +289 -6
- package/dist-types/pagination/ListStreamSessionsPaginator.d.ts +4 -0
- package/dist-types/pagination/index.d.ts +1 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +6 -0
- package/dist-types/ts3.4/Ivs.d.ts +10 -0
- package/dist-types/ts3.4/IvsClient.d.ts +4 -2
- package/dist-types/ts3.4/commands/GetStreamSessionCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListStreamSessionsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +2 -0
- package/dist-types/ts3.4/models/models_0.d.ts +153 -0
- package/dist-types/ts3.4/pagination/ListStreamSessionsPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/index.d.ts +1 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +6 -0
- package/package.json +2 -2
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.deserializeAws_restJson1UpdateChannelCommand = exports.deserializeAws_restJson1UntagResourceCommand = void 0;
|
|
3
|
+
exports.deserializeAws_restJson1ListStreamSessionsCommand = exports.deserializeAws_restJson1ListStreamsCommand = exports.deserializeAws_restJson1ListStreamKeysCommand = exports.deserializeAws_restJson1ListRecordingConfigurationsCommand = exports.deserializeAws_restJson1ListPlaybackKeyPairsCommand = exports.deserializeAws_restJson1ListChannelsCommand = exports.deserializeAws_restJson1ImportPlaybackKeyPairCommand = exports.deserializeAws_restJson1GetStreamSessionCommand = exports.deserializeAws_restJson1GetStreamKeyCommand = exports.deserializeAws_restJson1GetStreamCommand = exports.deserializeAws_restJson1GetRecordingConfigurationCommand = exports.deserializeAws_restJson1GetPlaybackKeyPairCommand = exports.deserializeAws_restJson1GetChannelCommand = exports.deserializeAws_restJson1DeleteStreamKeyCommand = exports.deserializeAws_restJson1DeleteRecordingConfigurationCommand = exports.deserializeAws_restJson1DeletePlaybackKeyPairCommand = exports.deserializeAws_restJson1DeleteChannelCommand = exports.deserializeAws_restJson1CreateStreamKeyCommand = exports.deserializeAws_restJson1CreateRecordingConfigurationCommand = exports.deserializeAws_restJson1CreateChannelCommand = exports.deserializeAws_restJson1BatchGetStreamKeyCommand = exports.deserializeAws_restJson1BatchGetChannelCommand = exports.serializeAws_restJson1UpdateChannelCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1StopStreamCommand = exports.serializeAws_restJson1PutMetadataCommand = exports.serializeAws_restJson1ListTagsForResourceCommand = exports.serializeAws_restJson1ListStreamSessionsCommand = exports.serializeAws_restJson1ListStreamsCommand = exports.serializeAws_restJson1ListStreamKeysCommand = exports.serializeAws_restJson1ListRecordingConfigurationsCommand = exports.serializeAws_restJson1ListPlaybackKeyPairsCommand = exports.serializeAws_restJson1ListChannelsCommand = exports.serializeAws_restJson1ImportPlaybackKeyPairCommand = exports.serializeAws_restJson1GetStreamSessionCommand = exports.serializeAws_restJson1GetStreamKeyCommand = exports.serializeAws_restJson1GetStreamCommand = exports.serializeAws_restJson1GetRecordingConfigurationCommand = exports.serializeAws_restJson1GetPlaybackKeyPairCommand = exports.serializeAws_restJson1GetChannelCommand = exports.serializeAws_restJson1DeleteStreamKeyCommand = exports.serializeAws_restJson1DeleteRecordingConfigurationCommand = exports.serializeAws_restJson1DeletePlaybackKeyPairCommand = exports.serializeAws_restJson1DeleteChannelCommand = exports.serializeAws_restJson1CreateStreamKeyCommand = exports.serializeAws_restJson1CreateRecordingConfigurationCommand = exports.serializeAws_restJson1CreateChannelCommand = exports.serializeAws_restJson1BatchGetStreamKeyCommand = exports.serializeAws_restJson1BatchGetChannelCommand = void 0;
|
|
4
|
+
exports.deserializeAws_restJson1UpdateChannelCommand = exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1StopStreamCommand = exports.deserializeAws_restJson1PutMetadataCommand = exports.deserializeAws_restJson1ListTagsForResourceCommand = void 0;
|
|
5
5
|
const protocol_http_1 = require("@aws-sdk/protocol-http");
|
|
6
6
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
7
7
|
const serializeAws_restJson1BatchGetChannelCommand = async (input, context) => {
|
|
@@ -312,6 +312,28 @@ const serializeAws_restJson1GetStreamKeyCommand = async (input, context) => {
|
|
|
312
312
|
});
|
|
313
313
|
};
|
|
314
314
|
exports.serializeAws_restJson1GetStreamKeyCommand = serializeAws_restJson1GetStreamKeyCommand;
|
|
315
|
+
const serializeAws_restJson1GetStreamSessionCommand = async (input, context) => {
|
|
316
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
317
|
+
const headers = {
|
|
318
|
+
"content-type": "application/json",
|
|
319
|
+
};
|
|
320
|
+
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/GetStreamSession";
|
|
321
|
+
let body;
|
|
322
|
+
body = JSON.stringify({
|
|
323
|
+
...(input.channelArn !== undefined && input.channelArn !== null && { channelArn: input.channelArn }),
|
|
324
|
+
...(input.streamId !== undefined && input.streamId !== null && { streamId: input.streamId }),
|
|
325
|
+
});
|
|
326
|
+
return new protocol_http_1.HttpRequest({
|
|
327
|
+
protocol,
|
|
328
|
+
hostname,
|
|
329
|
+
port,
|
|
330
|
+
method: "POST",
|
|
331
|
+
headers,
|
|
332
|
+
path: resolvedPath,
|
|
333
|
+
body,
|
|
334
|
+
});
|
|
335
|
+
};
|
|
336
|
+
exports.serializeAws_restJson1GetStreamSessionCommand = serializeAws_restJson1GetStreamSessionCommand;
|
|
315
337
|
const serializeAws_restJson1ImportPlaybackKeyPairCommand = async (input, context) => {
|
|
316
338
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
317
339
|
const headers = {
|
|
@@ -438,6 +460,8 @@ const serializeAws_restJson1ListStreamsCommand = async (input, context) => {
|
|
|
438
460
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListStreams";
|
|
439
461
|
let body;
|
|
440
462
|
body = JSON.stringify({
|
|
463
|
+
...(input.filterBy !== undefined &&
|
|
464
|
+
input.filterBy !== null && { filterBy: serializeAws_restJson1StreamFilters(input.filterBy, context) }),
|
|
441
465
|
...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
|
|
442
466
|
...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
|
|
443
467
|
});
|
|
@@ -452,6 +476,29 @@ const serializeAws_restJson1ListStreamsCommand = async (input, context) => {
|
|
|
452
476
|
});
|
|
453
477
|
};
|
|
454
478
|
exports.serializeAws_restJson1ListStreamsCommand = serializeAws_restJson1ListStreamsCommand;
|
|
479
|
+
const serializeAws_restJson1ListStreamSessionsCommand = async (input, context) => {
|
|
480
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
481
|
+
const headers = {
|
|
482
|
+
"content-type": "application/json",
|
|
483
|
+
};
|
|
484
|
+
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/ListStreamSessions";
|
|
485
|
+
let body;
|
|
486
|
+
body = JSON.stringify({
|
|
487
|
+
...(input.channelArn !== undefined && input.channelArn !== null && { channelArn: input.channelArn }),
|
|
488
|
+
...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
|
|
489
|
+
...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
|
|
490
|
+
});
|
|
491
|
+
return new protocol_http_1.HttpRequest({
|
|
492
|
+
protocol,
|
|
493
|
+
hostname,
|
|
494
|
+
port,
|
|
495
|
+
method: "POST",
|
|
496
|
+
headers,
|
|
497
|
+
path: resolvedPath,
|
|
498
|
+
body,
|
|
499
|
+
});
|
|
500
|
+
};
|
|
501
|
+
exports.serializeAws_restJson1ListStreamSessionsCommand = serializeAws_restJson1ListStreamSessionsCommand;
|
|
455
502
|
const serializeAws_restJson1ListTagsForResourceCommand = async (input, context) => {
|
|
456
503
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
457
504
|
const headers = {};
|
|
@@ -1573,6 +1620,70 @@ const deserializeAws_restJson1GetStreamKeyCommandError = async (output, context)
|
|
|
1573
1620
|
delete response.Message;
|
|
1574
1621
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
1575
1622
|
};
|
|
1623
|
+
const deserializeAws_restJson1GetStreamSessionCommand = async (output, context) => {
|
|
1624
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1625
|
+
return deserializeAws_restJson1GetStreamSessionCommandError(output, context);
|
|
1626
|
+
}
|
|
1627
|
+
const contents = {
|
|
1628
|
+
$metadata: deserializeMetadata(output),
|
|
1629
|
+
streamSession: undefined,
|
|
1630
|
+
};
|
|
1631
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1632
|
+
if (data.streamSession !== undefined && data.streamSession !== null) {
|
|
1633
|
+
contents.streamSession = deserializeAws_restJson1StreamSession(data.streamSession, context);
|
|
1634
|
+
}
|
|
1635
|
+
return Promise.resolve(contents);
|
|
1636
|
+
};
|
|
1637
|
+
exports.deserializeAws_restJson1GetStreamSessionCommand = deserializeAws_restJson1GetStreamSessionCommand;
|
|
1638
|
+
const deserializeAws_restJson1GetStreamSessionCommandError = async (output, context) => {
|
|
1639
|
+
const parsedOutput = {
|
|
1640
|
+
...output,
|
|
1641
|
+
body: await parseBody(output.body, context),
|
|
1642
|
+
};
|
|
1643
|
+
let response;
|
|
1644
|
+
let errorCode = "UnknownError";
|
|
1645
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1646
|
+
switch (errorCode) {
|
|
1647
|
+
case "AccessDeniedException":
|
|
1648
|
+
case "com.amazonaws.ivs#AccessDeniedException":
|
|
1649
|
+
response = {
|
|
1650
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1651
|
+
name: errorCode,
|
|
1652
|
+
$metadata: deserializeMetadata(output),
|
|
1653
|
+
};
|
|
1654
|
+
break;
|
|
1655
|
+
case "ResourceNotFoundException":
|
|
1656
|
+
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
1657
|
+
response = {
|
|
1658
|
+
...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
1659
|
+
name: errorCode,
|
|
1660
|
+
$metadata: deserializeMetadata(output),
|
|
1661
|
+
};
|
|
1662
|
+
break;
|
|
1663
|
+
case "ValidationException":
|
|
1664
|
+
case "com.amazonaws.ivs#ValidationException":
|
|
1665
|
+
response = {
|
|
1666
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1667
|
+
name: errorCode,
|
|
1668
|
+
$metadata: deserializeMetadata(output),
|
|
1669
|
+
};
|
|
1670
|
+
break;
|
|
1671
|
+
default:
|
|
1672
|
+
const parsedBody = parsedOutput.body;
|
|
1673
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1674
|
+
response = {
|
|
1675
|
+
...parsedBody,
|
|
1676
|
+
name: `${errorCode}`,
|
|
1677
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1678
|
+
$fault: "client",
|
|
1679
|
+
$metadata: deserializeMetadata(output),
|
|
1680
|
+
};
|
|
1681
|
+
}
|
|
1682
|
+
const message = response.message || response.Message || errorCode;
|
|
1683
|
+
response.message = message;
|
|
1684
|
+
delete response.Message;
|
|
1685
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1686
|
+
};
|
|
1576
1687
|
const deserializeAws_restJson1ImportPlaybackKeyPairCommand = async (output, context) => {
|
|
1577
1688
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1578
1689
|
return deserializeAws_restJson1ImportPlaybackKeyPairCommandError(output, context);
|
|
@@ -1969,6 +2080,74 @@ const deserializeAws_restJson1ListStreamsCommandError = async (output, context)
|
|
|
1969
2080
|
delete response.Message;
|
|
1970
2081
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
1971
2082
|
};
|
|
2083
|
+
const deserializeAws_restJson1ListStreamSessionsCommand = async (output, context) => {
|
|
2084
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2085
|
+
return deserializeAws_restJson1ListStreamSessionsCommandError(output, context);
|
|
2086
|
+
}
|
|
2087
|
+
const contents = {
|
|
2088
|
+
$metadata: deserializeMetadata(output),
|
|
2089
|
+
nextToken: undefined,
|
|
2090
|
+
streamSessions: undefined,
|
|
2091
|
+
};
|
|
2092
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
2093
|
+
if (data.nextToken !== undefined && data.nextToken !== null) {
|
|
2094
|
+
contents.nextToken = smithy_client_1.expectString(data.nextToken);
|
|
2095
|
+
}
|
|
2096
|
+
if (data.streamSessions !== undefined && data.streamSessions !== null) {
|
|
2097
|
+
contents.streamSessions = deserializeAws_restJson1StreamSessionList(data.streamSessions, context);
|
|
2098
|
+
}
|
|
2099
|
+
return Promise.resolve(contents);
|
|
2100
|
+
};
|
|
2101
|
+
exports.deserializeAws_restJson1ListStreamSessionsCommand = deserializeAws_restJson1ListStreamSessionsCommand;
|
|
2102
|
+
const deserializeAws_restJson1ListStreamSessionsCommandError = async (output, context) => {
|
|
2103
|
+
const parsedOutput = {
|
|
2104
|
+
...output,
|
|
2105
|
+
body: await parseBody(output.body, context),
|
|
2106
|
+
};
|
|
2107
|
+
let response;
|
|
2108
|
+
let errorCode = "UnknownError";
|
|
2109
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2110
|
+
switch (errorCode) {
|
|
2111
|
+
case "AccessDeniedException":
|
|
2112
|
+
case "com.amazonaws.ivs#AccessDeniedException":
|
|
2113
|
+
response = {
|
|
2114
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
2115
|
+
name: errorCode,
|
|
2116
|
+
$metadata: deserializeMetadata(output),
|
|
2117
|
+
};
|
|
2118
|
+
break;
|
|
2119
|
+
case "ResourceNotFoundException":
|
|
2120
|
+
case "com.amazonaws.ivs#ResourceNotFoundException":
|
|
2121
|
+
response = {
|
|
2122
|
+
...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)),
|
|
2123
|
+
name: errorCode,
|
|
2124
|
+
$metadata: deserializeMetadata(output),
|
|
2125
|
+
};
|
|
2126
|
+
break;
|
|
2127
|
+
case "ValidationException":
|
|
2128
|
+
case "com.amazonaws.ivs#ValidationException":
|
|
2129
|
+
response = {
|
|
2130
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
2131
|
+
name: errorCode,
|
|
2132
|
+
$metadata: deserializeMetadata(output),
|
|
2133
|
+
};
|
|
2134
|
+
break;
|
|
2135
|
+
default:
|
|
2136
|
+
const parsedBody = parsedOutput.body;
|
|
2137
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2138
|
+
response = {
|
|
2139
|
+
...parsedBody,
|
|
2140
|
+
name: `${errorCode}`,
|
|
2141
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2142
|
+
$fault: "client",
|
|
2143
|
+
$metadata: deserializeMetadata(output),
|
|
2144
|
+
};
|
|
2145
|
+
}
|
|
2146
|
+
const message = response.message || response.Message || errorCode;
|
|
2147
|
+
response.message = message;
|
|
2148
|
+
delete response.Message;
|
|
2149
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
2150
|
+
};
|
|
1972
2151
|
const deserializeAws_restJson1ListTagsForResourceCommand = async (output, context) => {
|
|
1973
2152
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1974
2153
|
return deserializeAws_restJson1ListTagsForResourceCommandError(output, context);
|
|
@@ -2536,6 +2715,11 @@ const serializeAws_restJson1S3DestinationConfiguration = (input, context) => {
|
|
|
2536
2715
|
...(input.bucketName !== undefined && input.bucketName !== null && { bucketName: input.bucketName }),
|
|
2537
2716
|
};
|
|
2538
2717
|
};
|
|
2718
|
+
const serializeAws_restJson1StreamFilters = (input, context) => {
|
|
2719
|
+
return {
|
|
2720
|
+
...(input.health !== undefined && input.health !== null && { health: input.health }),
|
|
2721
|
+
};
|
|
2722
|
+
};
|
|
2539
2723
|
const serializeAws_restJson1StreamKeyArnList = (input, context) => {
|
|
2540
2724
|
return input
|
|
2541
2725
|
.filter((e) => e != null)
|
|
@@ -2557,6 +2741,14 @@ const serializeAws_restJson1Tags = (input, context) => {
|
|
|
2557
2741
|
};
|
|
2558
2742
|
}, {});
|
|
2559
2743
|
};
|
|
2744
|
+
const deserializeAws_restJson1AudioConfiguration = (output, context) => {
|
|
2745
|
+
return {
|
|
2746
|
+
channels: smithy_client_1.expectLong(output.channels),
|
|
2747
|
+
codec: smithy_client_1.expectString(output.codec),
|
|
2748
|
+
sampleRate: smithy_client_1.expectLong(output.sampleRate),
|
|
2749
|
+
targetBitrate: smithy_client_1.expectLong(output.targetBitrate),
|
|
2750
|
+
};
|
|
2751
|
+
};
|
|
2560
2752
|
const deserializeAws_restJson1BatchError = (output, context) => {
|
|
2561
2753
|
return {
|
|
2562
2754
|
arn: smithy_client_1.expectString(output.arn),
|
|
@@ -2628,6 +2820,16 @@ const deserializeAws_restJson1DestinationConfiguration = (output, context) => {
|
|
|
2628
2820
|
: undefined,
|
|
2629
2821
|
};
|
|
2630
2822
|
};
|
|
2823
|
+
const deserializeAws_restJson1IngestConfiguration = (output, context) => {
|
|
2824
|
+
return {
|
|
2825
|
+
audio: output.audio !== undefined && output.audio !== null
|
|
2826
|
+
? deserializeAws_restJson1AudioConfiguration(output.audio, context)
|
|
2827
|
+
: undefined,
|
|
2828
|
+
video: output.video !== undefined && output.video !== null
|
|
2829
|
+
? deserializeAws_restJson1VideoConfiguration(output.video, context)
|
|
2830
|
+
: undefined,
|
|
2831
|
+
};
|
|
2832
|
+
};
|
|
2631
2833
|
const deserializeAws_restJson1PlaybackKeyPair = (output, context) => {
|
|
2632
2834
|
return {
|
|
2633
2835
|
arn: smithy_client_1.expectString(output.arn),
|
|
@@ -2707,9 +2909,29 @@ const deserializeAws_restJson1_Stream = (output, context) => {
|
|
|
2707
2909
|
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.startTime))
|
|
2708
2910
|
: undefined,
|
|
2709
2911
|
state: smithy_client_1.expectString(output.state),
|
|
2912
|
+
streamId: smithy_client_1.expectString(output.streamId),
|
|
2710
2913
|
viewerCount: smithy_client_1.expectLong(output.viewerCount),
|
|
2711
2914
|
};
|
|
2712
2915
|
};
|
|
2916
|
+
const deserializeAws_restJson1StreamEvent = (output, context) => {
|
|
2917
|
+
return {
|
|
2918
|
+
eventTime: output.eventTime !== undefined && output.eventTime !== null
|
|
2919
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.eventTime))
|
|
2920
|
+
: undefined,
|
|
2921
|
+
name: smithy_client_1.expectString(output.name),
|
|
2922
|
+
type: smithy_client_1.expectString(output.type),
|
|
2923
|
+
};
|
|
2924
|
+
};
|
|
2925
|
+
const deserializeAws_restJson1StreamEvents = (output, context) => {
|
|
2926
|
+
return (output || [])
|
|
2927
|
+
.filter((e) => e != null)
|
|
2928
|
+
.map((entry) => {
|
|
2929
|
+
if (entry === null) {
|
|
2930
|
+
return null;
|
|
2931
|
+
}
|
|
2932
|
+
return deserializeAws_restJson1StreamEvent(entry, context);
|
|
2933
|
+
});
|
|
2934
|
+
};
|
|
2713
2935
|
const deserializeAws_restJson1StreamKey = (output, context) => {
|
|
2714
2936
|
return {
|
|
2715
2937
|
arn: smithy_client_1.expectString(output.arn),
|
|
@@ -2759,6 +2981,51 @@ const deserializeAws_restJson1StreamList = (output, context) => {
|
|
|
2759
2981
|
return deserializeAws_restJson1StreamSummary(entry, context);
|
|
2760
2982
|
});
|
|
2761
2983
|
};
|
|
2984
|
+
const deserializeAws_restJson1StreamSession = (output, context) => {
|
|
2985
|
+
return {
|
|
2986
|
+
channel: output.channel !== undefined && output.channel !== null
|
|
2987
|
+
? deserializeAws_restJson1Channel(output.channel, context)
|
|
2988
|
+
: undefined,
|
|
2989
|
+
endTime: output.endTime !== undefined && output.endTime !== null
|
|
2990
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.endTime))
|
|
2991
|
+
: undefined,
|
|
2992
|
+
ingestConfiguration: output.ingestConfiguration !== undefined && output.ingestConfiguration !== null
|
|
2993
|
+
? deserializeAws_restJson1IngestConfiguration(output.ingestConfiguration, context)
|
|
2994
|
+
: undefined,
|
|
2995
|
+
recordingConfiguration: output.recordingConfiguration !== undefined && output.recordingConfiguration !== null
|
|
2996
|
+
? deserializeAws_restJson1RecordingConfiguration(output.recordingConfiguration, context)
|
|
2997
|
+
: undefined,
|
|
2998
|
+
startTime: output.startTime !== undefined && output.startTime !== null
|
|
2999
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.startTime))
|
|
3000
|
+
: undefined,
|
|
3001
|
+
streamId: smithy_client_1.expectString(output.streamId),
|
|
3002
|
+
truncatedEvents: output.truncatedEvents !== undefined && output.truncatedEvents !== null
|
|
3003
|
+
? deserializeAws_restJson1StreamEvents(output.truncatedEvents, context)
|
|
3004
|
+
: undefined,
|
|
3005
|
+
};
|
|
3006
|
+
};
|
|
3007
|
+
const deserializeAws_restJson1StreamSessionList = (output, context) => {
|
|
3008
|
+
return (output || [])
|
|
3009
|
+
.filter((e) => e != null)
|
|
3010
|
+
.map((entry) => {
|
|
3011
|
+
if (entry === null) {
|
|
3012
|
+
return null;
|
|
3013
|
+
}
|
|
3014
|
+
return deserializeAws_restJson1StreamSessionSummary(entry, context);
|
|
3015
|
+
});
|
|
3016
|
+
};
|
|
3017
|
+
const deserializeAws_restJson1StreamSessionSummary = (output, context) => {
|
|
3018
|
+
return {
|
|
3019
|
+
endTime: output.endTime !== undefined && output.endTime !== null
|
|
3020
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.endTime))
|
|
3021
|
+
: undefined,
|
|
3022
|
+
hasErrorEvent: smithy_client_1.expectBoolean(output.hasErrorEvent),
|
|
3023
|
+
startTime: output.startTime !== undefined && output.startTime !== null
|
|
3024
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.startTime))
|
|
3025
|
+
: undefined,
|
|
3026
|
+
streamId: smithy_client_1.expectString(output.streamId),
|
|
3027
|
+
};
|
|
3028
|
+
};
|
|
2762
3029
|
const deserializeAws_restJson1StreamSummary = (output, context) => {
|
|
2763
3030
|
return {
|
|
2764
3031
|
channelArn: smithy_client_1.expectString(output.channelArn),
|
|
@@ -2767,6 +3034,7 @@ const deserializeAws_restJson1StreamSummary = (output, context) => {
|
|
|
2767
3034
|
? smithy_client_1.expectNonNull(smithy_client_1.parseRfc3339DateTime(output.startTime))
|
|
2768
3035
|
: undefined,
|
|
2769
3036
|
state: smithy_client_1.expectString(output.state),
|
|
3037
|
+
streamId: smithy_client_1.expectString(output.streamId),
|
|
2770
3038
|
viewerCount: smithy_client_1.expectLong(output.viewerCount),
|
|
2771
3039
|
};
|
|
2772
3040
|
};
|
|
@@ -2781,6 +3049,18 @@ const deserializeAws_restJson1Tags = (output, context) => {
|
|
|
2781
3049
|
};
|
|
2782
3050
|
}, {});
|
|
2783
3051
|
};
|
|
3052
|
+
const deserializeAws_restJson1VideoConfiguration = (output, context) => {
|
|
3053
|
+
return {
|
|
3054
|
+
avcLevel: smithy_client_1.expectString(output.avcLevel),
|
|
3055
|
+
avcProfile: smithy_client_1.expectString(output.avcProfile),
|
|
3056
|
+
codec: smithy_client_1.expectString(output.codec),
|
|
3057
|
+
encoder: smithy_client_1.expectString(output.encoder),
|
|
3058
|
+
targetBitrate: smithy_client_1.expectLong(output.targetBitrate),
|
|
3059
|
+
targetFramerate: smithy_client_1.expectLong(output.targetFramerate),
|
|
3060
|
+
videoHeight: smithy_client_1.expectLong(output.videoHeight),
|
|
3061
|
+
videoWidth: smithy_client_1.expectLong(output.videoWidth),
|
|
3062
|
+
};
|
|
3063
|
+
};
|
|
2784
3064
|
const deserializeMetadata = (output) => {
|
|
2785
3065
|
var _a;
|
|
2786
3066
|
return ({
|
package/dist-es/Ivs.js
CHANGED
|
@@ -13,12 +13,14 @@ import { GetPlaybackKeyPairCommand, } from "./commands/GetPlaybackKeyPairCommand
|
|
|
13
13
|
import { GetRecordingConfigurationCommand, } from "./commands/GetRecordingConfigurationCommand";
|
|
14
14
|
import { GetStreamCommand } from "./commands/GetStreamCommand";
|
|
15
15
|
import { GetStreamKeyCommand, } from "./commands/GetStreamKeyCommand";
|
|
16
|
+
import { GetStreamSessionCommand, } from "./commands/GetStreamSessionCommand";
|
|
16
17
|
import { ImportPlaybackKeyPairCommand, } from "./commands/ImportPlaybackKeyPairCommand";
|
|
17
18
|
import { ListChannelsCommand, } from "./commands/ListChannelsCommand";
|
|
18
19
|
import { ListPlaybackKeyPairsCommand, } from "./commands/ListPlaybackKeyPairsCommand";
|
|
19
20
|
import { ListRecordingConfigurationsCommand, } from "./commands/ListRecordingConfigurationsCommand";
|
|
20
21
|
import { ListStreamKeysCommand, } from "./commands/ListStreamKeysCommand";
|
|
21
22
|
import { ListStreamsCommand } from "./commands/ListStreamsCommand";
|
|
23
|
+
import { ListStreamSessionsCommand, } from "./commands/ListStreamSessionsCommand";
|
|
22
24
|
import { ListTagsForResourceCommand, } from "./commands/ListTagsForResourceCommand";
|
|
23
25
|
import { PutMetadataCommand } from "./commands/PutMetadataCommand";
|
|
24
26
|
import { StopStreamCommand } from "./commands/StopStreamCommand";
|
|
@@ -227,6 +229,20 @@ var Ivs = (function (_super) {
|
|
|
227
229
|
return this.send(command, optionsOrCb);
|
|
228
230
|
}
|
|
229
231
|
};
|
|
232
|
+
Ivs.prototype.getStreamSession = function (args, optionsOrCb, cb) {
|
|
233
|
+
var command = new GetStreamSessionCommand(args);
|
|
234
|
+
if (typeof optionsOrCb === "function") {
|
|
235
|
+
this.send(command, optionsOrCb);
|
|
236
|
+
}
|
|
237
|
+
else if (typeof cb === "function") {
|
|
238
|
+
if (typeof optionsOrCb !== "object")
|
|
239
|
+
throw new Error("Expect http options but get " + typeof optionsOrCb);
|
|
240
|
+
this.send(command, optionsOrCb || {}, cb);
|
|
241
|
+
}
|
|
242
|
+
else {
|
|
243
|
+
return this.send(command, optionsOrCb);
|
|
244
|
+
}
|
|
245
|
+
};
|
|
230
246
|
Ivs.prototype.importPlaybackKeyPair = function (args, optionsOrCb, cb) {
|
|
231
247
|
var command = new ImportPlaybackKeyPairCommand(args);
|
|
232
248
|
if (typeof optionsOrCb === "function") {
|
|
@@ -311,6 +327,20 @@ var Ivs = (function (_super) {
|
|
|
311
327
|
return this.send(command, optionsOrCb);
|
|
312
328
|
}
|
|
313
329
|
};
|
|
330
|
+
Ivs.prototype.listStreamSessions = function (args, optionsOrCb, cb) {
|
|
331
|
+
var command = new ListStreamSessionsCommand(args);
|
|
332
|
+
if (typeof optionsOrCb === "function") {
|
|
333
|
+
this.send(command, optionsOrCb);
|
|
334
|
+
}
|
|
335
|
+
else if (typeof cb === "function") {
|
|
336
|
+
if (typeof optionsOrCb !== "object")
|
|
337
|
+
throw new Error("Expect http options but get " + typeof optionsOrCb);
|
|
338
|
+
this.send(command, optionsOrCb || {}, cb);
|
|
339
|
+
}
|
|
340
|
+
else {
|
|
341
|
+
return this.send(command, optionsOrCb);
|
|
342
|
+
}
|
|
343
|
+
};
|
|
314
344
|
Ivs.prototype.listTagsForResource = function (args, optionsOrCb, cb) {
|
|
315
345
|
var command = new ListTagsForResourceCommand(args);
|
|
316
346
|
if (typeof optionsOrCb === "function") {
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { __extends } from "tslib";
|
|
2
|
+
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
3
|
+
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
+
import { GetStreamSessionRequest, GetStreamSessionResponse } from "../models/models_0";
|
|
5
|
+
import { deserializeAws_restJson1GetStreamSessionCommand, serializeAws_restJson1GetStreamSessionCommand, } from "../protocols/Aws_restJson1";
|
|
6
|
+
var GetStreamSessionCommand = (function (_super) {
|
|
7
|
+
__extends(GetStreamSessionCommand, _super);
|
|
8
|
+
function GetStreamSessionCommand(input) {
|
|
9
|
+
var _this = _super.call(this) || this;
|
|
10
|
+
_this.input = input;
|
|
11
|
+
return _this;
|
|
12
|
+
}
|
|
13
|
+
GetStreamSessionCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
14
|
+
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
15
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
16
|
+
var logger = configuration.logger;
|
|
17
|
+
var clientName = "IvsClient";
|
|
18
|
+
var commandName = "GetStreamSessionCommand";
|
|
19
|
+
var handlerExecutionContext = {
|
|
20
|
+
logger: logger,
|
|
21
|
+
clientName: clientName,
|
|
22
|
+
commandName: commandName,
|
|
23
|
+
inputFilterSensitiveLog: GetStreamSessionRequest.filterSensitiveLog,
|
|
24
|
+
outputFilterSensitiveLog: GetStreamSessionResponse.filterSensitiveLog,
|
|
25
|
+
};
|
|
26
|
+
var requestHandler = configuration.requestHandler;
|
|
27
|
+
return stack.resolve(function (request) {
|
|
28
|
+
return requestHandler.handle(request.request, options || {});
|
|
29
|
+
}, handlerExecutionContext);
|
|
30
|
+
};
|
|
31
|
+
GetStreamSessionCommand.prototype.serialize = function (input, context) {
|
|
32
|
+
return serializeAws_restJson1GetStreamSessionCommand(input, context);
|
|
33
|
+
};
|
|
34
|
+
GetStreamSessionCommand.prototype.deserialize = function (output, context) {
|
|
35
|
+
return deserializeAws_restJson1GetStreamSessionCommand(output, context);
|
|
36
|
+
};
|
|
37
|
+
return GetStreamSessionCommand;
|
|
38
|
+
}($Command));
|
|
39
|
+
export { GetStreamSessionCommand };
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { __extends } from "tslib";
|
|
2
|
+
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
3
|
+
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
+
import { ListStreamSessionsRequest, ListStreamSessionsResponse } from "../models/models_0";
|
|
5
|
+
import { deserializeAws_restJson1ListStreamSessionsCommand, serializeAws_restJson1ListStreamSessionsCommand, } from "../protocols/Aws_restJson1";
|
|
6
|
+
var ListStreamSessionsCommand = (function (_super) {
|
|
7
|
+
__extends(ListStreamSessionsCommand, _super);
|
|
8
|
+
function ListStreamSessionsCommand(input) {
|
|
9
|
+
var _this = _super.call(this) || this;
|
|
10
|
+
_this.input = input;
|
|
11
|
+
return _this;
|
|
12
|
+
}
|
|
13
|
+
ListStreamSessionsCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
14
|
+
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
15
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
16
|
+
var logger = configuration.logger;
|
|
17
|
+
var clientName = "IvsClient";
|
|
18
|
+
var commandName = "ListStreamSessionsCommand";
|
|
19
|
+
var handlerExecutionContext = {
|
|
20
|
+
logger: logger,
|
|
21
|
+
clientName: clientName,
|
|
22
|
+
commandName: commandName,
|
|
23
|
+
inputFilterSensitiveLog: ListStreamSessionsRequest.filterSensitiveLog,
|
|
24
|
+
outputFilterSensitiveLog: ListStreamSessionsResponse.filterSensitiveLog,
|
|
25
|
+
};
|
|
26
|
+
var requestHandler = configuration.requestHandler;
|
|
27
|
+
return stack.resolve(function (request) {
|
|
28
|
+
return requestHandler.handle(request.request, options || {});
|
|
29
|
+
}, handlerExecutionContext);
|
|
30
|
+
};
|
|
31
|
+
ListStreamSessionsCommand.prototype.serialize = function (input, context) {
|
|
32
|
+
return serializeAws_restJson1ListStreamSessionsCommand(input, context);
|
|
33
|
+
};
|
|
34
|
+
ListStreamSessionsCommand.prototype.deserialize = function (output, context) {
|
|
35
|
+
return deserializeAws_restJson1ListStreamSessionsCommand(output, context);
|
|
36
|
+
};
|
|
37
|
+
return ListStreamSessionsCommand;
|
|
38
|
+
}($Command));
|
|
39
|
+
export { ListStreamSessionsCommand };
|
|
@@ -12,11 +12,13 @@ export * from "./GetPlaybackKeyPairCommand";
|
|
|
12
12
|
export * from "./GetRecordingConfigurationCommand";
|
|
13
13
|
export * from "./GetStreamCommand";
|
|
14
14
|
export * from "./GetStreamKeyCommand";
|
|
15
|
+
export * from "./GetStreamSessionCommand";
|
|
15
16
|
export * from "./ImportPlaybackKeyPairCommand";
|
|
16
17
|
export * from "./ListChannelsCommand";
|
|
17
18
|
export * from "./ListPlaybackKeyPairsCommand";
|
|
18
19
|
export * from "./ListRecordingConfigurationsCommand";
|
|
19
20
|
export * from "./ListStreamKeysCommand";
|
|
21
|
+
export * from "./ListStreamSessionsCommand";
|
|
20
22
|
export * from "./ListStreamsCommand";
|
|
21
23
|
export * from "./ListTagsForResourceCommand";
|
|
22
24
|
export * from "./PutMetadataCommand";
|
|
@@ -191,6 +191,34 @@ export var GetStreamKeyResponse;
|
|
|
191
191
|
(function (GetStreamKeyResponse) {
|
|
192
192
|
GetStreamKeyResponse.filterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.streamKey && { streamKey: StreamKey.filterSensitiveLog(obj.streamKey) }))); };
|
|
193
193
|
})(GetStreamKeyResponse || (GetStreamKeyResponse = {}));
|
|
194
|
+
export var GetStreamSessionRequest;
|
|
195
|
+
(function (GetStreamSessionRequest) {
|
|
196
|
+
GetStreamSessionRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
197
|
+
})(GetStreamSessionRequest || (GetStreamSessionRequest = {}));
|
|
198
|
+
export var AudioConfiguration;
|
|
199
|
+
(function (AudioConfiguration) {
|
|
200
|
+
AudioConfiguration.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
201
|
+
})(AudioConfiguration || (AudioConfiguration = {}));
|
|
202
|
+
export var VideoConfiguration;
|
|
203
|
+
(function (VideoConfiguration) {
|
|
204
|
+
VideoConfiguration.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
205
|
+
})(VideoConfiguration || (VideoConfiguration = {}));
|
|
206
|
+
export var IngestConfiguration;
|
|
207
|
+
(function (IngestConfiguration) {
|
|
208
|
+
IngestConfiguration.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
209
|
+
})(IngestConfiguration || (IngestConfiguration = {}));
|
|
210
|
+
export var StreamEvent;
|
|
211
|
+
(function (StreamEvent) {
|
|
212
|
+
StreamEvent.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
213
|
+
})(StreamEvent || (StreamEvent = {}));
|
|
214
|
+
export var StreamSession;
|
|
215
|
+
(function (StreamSession) {
|
|
216
|
+
StreamSession.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
217
|
+
})(StreamSession || (StreamSession = {}));
|
|
218
|
+
export var GetStreamSessionResponse;
|
|
219
|
+
(function (GetStreamSessionResponse) {
|
|
220
|
+
GetStreamSessionResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
221
|
+
})(GetStreamSessionResponse || (GetStreamSessionResponse = {}));
|
|
194
222
|
export var ImportPlaybackKeyPairRequest;
|
|
195
223
|
(function (ImportPlaybackKeyPairRequest) {
|
|
196
224
|
ImportPlaybackKeyPairRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -247,6 +275,10 @@ export var ListStreamKeysResponse;
|
|
|
247
275
|
(function (ListStreamKeysResponse) {
|
|
248
276
|
ListStreamKeysResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
249
277
|
})(ListStreamKeysResponse || (ListStreamKeysResponse = {}));
|
|
278
|
+
export var StreamFilters;
|
|
279
|
+
(function (StreamFilters) {
|
|
280
|
+
StreamFilters.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
281
|
+
})(StreamFilters || (StreamFilters = {}));
|
|
250
282
|
export var ListStreamsRequest;
|
|
251
283
|
(function (ListStreamsRequest) {
|
|
252
284
|
ListStreamsRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
@@ -259,6 +291,18 @@ export var ListStreamsResponse;
|
|
|
259
291
|
(function (ListStreamsResponse) {
|
|
260
292
|
ListStreamsResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
261
293
|
})(ListStreamsResponse || (ListStreamsResponse = {}));
|
|
294
|
+
export var ListStreamSessionsRequest;
|
|
295
|
+
(function (ListStreamSessionsRequest) {
|
|
296
|
+
ListStreamSessionsRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
297
|
+
})(ListStreamSessionsRequest || (ListStreamSessionsRequest = {}));
|
|
298
|
+
export var StreamSessionSummary;
|
|
299
|
+
(function (StreamSessionSummary) {
|
|
300
|
+
StreamSessionSummary.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
301
|
+
})(StreamSessionSummary || (StreamSessionSummary = {}));
|
|
302
|
+
export var ListStreamSessionsResponse;
|
|
303
|
+
(function (ListStreamSessionsResponse) {
|
|
304
|
+
ListStreamSessionsResponse.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|
|
305
|
+
})(ListStreamSessionsResponse || (ListStreamSessionsResponse = {}));
|
|
262
306
|
export var ListTagsForResourceRequest;
|
|
263
307
|
(function (ListTagsForResourceRequest) {
|
|
264
308
|
ListTagsForResourceRequest.filterSensitiveLog = function (obj) { return (__assign({}, obj)); };
|