aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/LiveTv/LiveTvService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Api/LiveTv/LiveTvService.cs')
-rw-r--r--MediaBrowser.Api/LiveTv/LiveTvService.cs14
1 files changed, 14 insertions, 0 deletions
diff --git a/MediaBrowser.Api/LiveTv/LiveTvService.cs b/MediaBrowser.Api/LiveTv/LiveTvService.cs
index 588fad8bd..61883ddaa 100644
--- a/MediaBrowser.Api/LiveTv/LiveTvService.cs
+++ b/MediaBrowser.Api/LiveTv/LiveTvService.cs
@@ -198,6 +198,13 @@ namespace MediaBrowser.Api.LiveTv
public string Id { get; set; }
}
+ [Route("/LiveTv/Channels/{Id}/Stream", "GET")]
+ public class GetInternalChannelStream
+ {
+ [ApiMember(Name = "Id", Description = "Channel Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "GET")]
+ public string Id { get; set; }
+ }
+
public class LiveTvService : BaseApiService
{
private readonly ILiveTvManager _liveTvManager;
@@ -399,6 +406,13 @@ namespace MediaBrowser.Api.LiveTv
return ToStreamResult(stream.Stream, stream.MimeType);
}
+ public object Get(GetInternalChannelStream request)
+ {
+ var stream = _liveTvManager.GetChannelStream(request.Id, CancellationToken.None).Result;
+
+ return ToStreamResult(stream.Stream, stream.MimeType);
+ }
+
public object Get(GetRecordingGroups request)
{
var result = _liveTvManager.GetRecordingGroups(new RecordingGroupQuery