mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-09-06 05:47:14 -04:00
more doc updates
This commit is contained in:
parent
39ab10c875
commit
1e8d4bad83
@ -30,21 +30,21 @@ namespace MediaBrowser.Api
|
|||||||
/// Gets or sets a value indicating whether [include files].
|
/// Gets or sets a value indicating whether [include files].
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value><c>true</c> if [include files]; otherwise, <c>false</c>.</value>
|
/// <value><c>true</c> if [include files]; otherwise, <c>false</c>.</value>
|
||||||
[ApiMember(Name = "IncludeFiles", Description = "An optional filter to include or exclude files from the results.", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
[ApiMember(Name = "IncludeFiles", Description = "An optional filter to include or exclude files from the results. true/false", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
||||||
public bool IncludeFiles { get; set; }
|
public bool IncludeFiles { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets a value indicating whether [include directories].
|
/// Gets or sets a value indicating whether [include directories].
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value><c>true</c> if [include directories]; otherwise, <c>false</c>.</value>
|
/// <value><c>true</c> if [include directories]; otherwise, <c>false</c>.</value>
|
||||||
[ApiMember(Name = "IncludeDirectories", Description = "An optional filter to include or exclude folders from the results.", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
[ApiMember(Name = "IncludeDirectories", Description = "An optional filter to include or exclude folders from the results. true/false", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
||||||
public bool IncludeDirectories { get; set; }
|
public bool IncludeDirectories { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets a value indicating whether [include hidden].
|
/// Gets or sets a value indicating whether [include hidden].
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value><c>true</c> if [include hidden]; otherwise, <c>false</c>.</value>
|
/// <value><c>true</c> if [include hidden]; otherwise, <c>false</c>.</value>
|
||||||
[ApiMember(Name = "IncludeHidden", Description = "An optional filter to include or exclude hidden files and folders.", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
[ApiMember(Name = "IncludeHidden", Description = "An optional filter to include or exclude hidden files and folders. true/false", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
||||||
public bool IncludeHidden { get; set; }
|
public bool IncludeHidden { get; set; }
|
||||||
|
|
||||||
public GetDirectoryContents()
|
public GetDirectoryContents()
|
||||||
|
@ -30,7 +30,7 @@ namespace MediaBrowser.Api.Library
|
|||||||
/// Gets or sets a value indicating whether this instance has internet provider.
|
/// Gets or sets a value indicating whether this instance has internet provider.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value><c>true</c> if this instance has internet provider; otherwise, <c>false</c>.</value>
|
/// <value><c>true</c> if this instance has internet provider; otherwise, <c>false</c>.</value>
|
||||||
[ApiMember(Name = "HasInternetProvider", Description = "Optional filter by item types that have internet providers", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
[ApiMember(Name = "HasInternetProvider", Description = "Optional filter by item types that have internet providers. true/false", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
||||||
public bool HasInternetProvider { get; set; }
|
public bool HasInternetProvider { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -184,7 +184,7 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Gets or sets a value indicating whether this <see cref="GetItemsByName" /> is recursive.
|
/// Gets or sets a value indicating whether this <see cref="GetItemsByName" /> is recursive.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value><c>true</c> if recursive; otherwise, <c>false</c>.</value>
|
/// <value><c>true</c> if recursive; otherwise, <c>false</c>.</value>
|
||||||
[ApiMember(Name = "Recursive", Description = "When searching within folders, this determines whether or not the search will be recursive.", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
[ApiMember(Name = "Recursive", Description = "When searching within folders, this determines whether or not the search will be recursive. true/false", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
|
||||||
public bool Recursive { get; set; }
|
public bool Recursive { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -4,13 +4,11 @@ using MediaBrowser.Controller.Library;
|
|||||||
using MediaBrowser.Model.Connectivity;
|
using MediaBrowser.Model.Connectivity;
|
||||||
using MediaBrowser.Model.Dto;
|
using MediaBrowser.Model.Dto;
|
||||||
using MediaBrowser.Model.Entities;
|
using MediaBrowser.Model.Entities;
|
||||||
using MediaBrowser.Model.Serialization;
|
|
||||||
using MediaBrowser.Server.Implementations.HttpServer;
|
using MediaBrowser.Server.Implementations.HttpServer;
|
||||||
using ServiceStack.ServiceHost;
|
using ServiceStack.ServiceHost;
|
||||||
using ServiceStack.Text.Controller;
|
using ServiceStack.Text.Controller;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
@ -21,12 +19,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/Items/{Id}", "GET")]
|
[Route("/Users/{UserId}/Items/{Id}", "GET")]
|
||||||
[Route("/Users/{UserId}/Items/Root", "GET")]
|
[Route("/Users/{UserId}/Items/Root", "GET")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Gets an item from a user's library")]
|
||||||
public class GetItem : IReturn<BaseItemDto>
|
public class GetItem : IReturn<BaseItemDto>
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "GET")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -47,6 +47,7 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "GET")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -74,12 +75,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class MarkFavoriteItem
|
/// Class MarkFavoriteItem
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/FavoriteItems/{Id}", "POST")]
|
[Route("/Users/{UserId}/FavoriteItems/{Id}", "POST")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Marks an item as a favorite")]
|
||||||
public class MarkFavoriteItem : IReturnVoid
|
public class MarkFavoriteItem : IReturnVoid
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "POST")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -93,12 +96,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class UnmarkFavoriteItem
|
/// Class UnmarkFavoriteItem
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/FavoriteItems/{Id}", "DELETE")]
|
[Route("/Users/{UserId}/FavoriteItems/{Id}", "DELETE")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Unmarks an item as a favorite")]
|
||||||
public class UnmarkFavoriteItem : IReturnVoid
|
public class UnmarkFavoriteItem : IReturnVoid
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "DELETE")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -112,12 +117,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class ClearUserItemRating
|
/// Class ClearUserItemRating
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/Items/{Id}/Rating", "DELETE")]
|
[Route("/Users/{UserId}/Items/{Id}/Rating", "DELETE")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Deletes a user's saved personal rating for an item")]
|
||||||
public class DeleteUserItemRating : IReturnVoid
|
public class DeleteUserItemRating : IReturnVoid
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "DELETE")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -131,12 +138,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class UpdateUserItemRating
|
/// Class UpdateUserItemRating
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/Items/{Id}/Rating", "POST")]
|
[Route("/Users/{UserId}/Items/{Id}/Rating", "POST")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Updates a user's rating for an item")]
|
||||||
public class UpdateUserItemRating : IReturnVoid
|
public class UpdateUserItemRating : IReturnVoid
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "POST")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -156,12 +165,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class MarkPlayedItem
|
/// Class MarkPlayedItem
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/PlayedItems/{Id}", "POST")]
|
[Route("/Users/{UserId}/PlayedItems/{Id}", "POST")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Marks an item as played")]
|
||||||
public class MarkPlayedItem : IReturnVoid
|
public class MarkPlayedItem : IReturnVoid
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "POST")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -175,12 +186,14 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class MarkUnplayedItem
|
/// Class MarkUnplayedItem
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/PlayedItems/{Id}", "DELETE")]
|
[Route("/Users/{UserId}/PlayedItems/{Id}", "DELETE")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Marks an item as unplayed")]
|
||||||
public class MarkUnplayedItem : IReturnVoid
|
public class MarkUnplayedItem : IReturnVoid
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "DELETE")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -197,6 +210,7 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "POST")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -213,6 +227,7 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "POST")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -235,6 +250,7 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "DELETE")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -254,18 +270,21 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class GetLocalTrailers
|
/// Class GetLocalTrailers
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/Items/{Id}/LocalTrailers", "GET")]
|
[Route("/Users/{UserId}/Items/{Id}/LocalTrailers", "GET")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Gets local trailers for an item")]
|
||||||
public class GetLocalTrailers : IReturn<List<BaseItemDto>>
|
public class GetLocalTrailers : IReturn<List<BaseItemDto>>
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "GET")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the id.
|
/// Gets or sets the id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The id.</value>
|
/// <value>The id.</value>
|
||||||
|
[ApiMember(Name = "Id", Description = "Item Id", IsRequired = true, DataType = "string", ParameterType = "query", Verb = "GET")]
|
||||||
public string Id { get; set; }
|
public string Id { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -273,18 +292,21 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// Class GetSpecialFeatures
|
/// Class GetSpecialFeatures
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Route("/Users/{UserId}/Items/{Id}/SpecialFeatures", "GET")]
|
[Route("/Users/{UserId}/Items/{Id}/SpecialFeatures", "GET")]
|
||||||
|
[ServiceStack.ServiceHost.Api(Description = "Gets special features for a movie")]
|
||||||
public class GetSpecialFeatures : IReturn<List<BaseItemDto>>
|
public class GetSpecialFeatures : IReturn<List<BaseItemDto>>
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the user id.
|
/// Gets or sets the user id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The user id.</value>
|
/// <value>The user id.</value>
|
||||||
|
[ApiMember(Name = "UserId", Description = "User Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "GET")]
|
||||||
public Guid UserId { get; set; }
|
public Guid UserId { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the id.
|
/// Gets or sets the id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <value>The id.</value>
|
/// <value>The id.</value>
|
||||||
|
[ApiMember(Name = "Id", Description = "Movie Id", IsRequired = true, DataType = "string", ParameterType = "query", Verb = "GET")]
|
||||||
public string Id { get; set; }
|
public string Id { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -294,11 +316,6 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class UserLibraryService : BaseRestService
|
public class UserLibraryService : BaseRestService
|
||||||
{
|
{
|
||||||
/// <summary>
|
|
||||||
/// The _json serializer
|
|
||||||
/// </summary>
|
|
||||||
private readonly IJsonSerializer _jsonSerializer;
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The _user manager
|
/// The _user manager
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -309,17 +326,10 @@ namespace MediaBrowser.Api.UserLibrary
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Initializes a new instance of the <see cref="UserLibraryService" /> class.
|
/// Initializes a new instance of the <see cref="UserLibraryService" /> class.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="jsonSerializer">The json serializer.</param>
|
|
||||||
/// <exception cref="System.ArgumentNullException">jsonSerializer</exception>
|
/// <exception cref="System.ArgumentNullException">jsonSerializer</exception>
|
||||||
public UserLibraryService(IJsonSerializer jsonSerializer, IUserManager userManager, ILibraryManager libraryManager)
|
public UserLibraryService(IUserManager userManager, ILibraryManager libraryManager)
|
||||||
: base()
|
: base()
|
||||||
{
|
{
|
||||||
if (jsonSerializer == null)
|
|
||||||
{
|
|
||||||
throw new ArgumentNullException("jsonSerializer");
|
|
||||||
}
|
|
||||||
|
|
||||||
_jsonSerializer = jsonSerializer;
|
|
||||||
_userManager = userManager;
|
_userManager = userManager;
|
||||||
_libraryManager = libraryManager;
|
_libraryManager = libraryManager;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user