Files
FATrace/FATrace.OEMApp/Model/Jellyfin/JellyfinModels.cs
2025-10-10 17:54:53 +08:00

66 lines
1.6 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
using System.Collections.Generic;
using System.Text.Json.Serialization;
namespace FATrace.OEMApp.Model.Jellyfin
{
/// <summary>
/// Jellyfin /Items 接口响应模型
/// </summary>
public sealed class JellyfinItemsResponse
{
/// <summary>
/// 返回的项目集合
/// </summary>
[JsonPropertyName("Items")]
public List<JellyfinItem> Items { get; set; } = new();
/// <summary>
/// 记录总数
/// </summary>
[JsonPropertyName("TotalRecordCount")]
public int TotalRecordCount { get; set; }
/// <summary>
/// 起始索引
/// </summary>
[JsonPropertyName("StartIndex")]
public int StartIndex { get; set; }
}
/// <summary>
/// Jellyfin 媒体条目最小字段模型
/// </summary>
public sealed class JellyfinItem
{
/// <summary>
/// 名称
/// </summary>
[JsonPropertyName("Name")]
public string? Name { get; set; }
/// <summary>
/// 服务器 ID
/// </summary>
[JsonPropertyName("ServerId")]
public string? ServerId { get; set; }
/// <summary>
/// 项目 ID
/// </summary>
[JsonPropertyName("Id")]
public string? Id { get; set; }
/// <summary>
/// 频道 ID可能为 null
/// </summary>
[JsonPropertyName("ChannelId")]
public string? ChannelId { get; set; }
/// <summary>
/// 类型,如 Movie、Series
/// </summary>
[JsonPropertyName("Type")]
public string? Type { get; set; }
}
}