//------------------------------------------------------------------------------ // // This code was generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. // // Changes to this file may cause incorrect behavior and will be lost when // the code is regenerated. // //------------------------------------------------------------------------------ #nullable enable namespace LukeHagar.PlexAPI.SDK.Models.Components { using LukeHagar.PlexAPI.SDK.Models.Components; using LukeHagar.PlexAPI.SDK.Utils; /// /// A querystring-based filtering language used to select subsets of media. When provided as an object, properties are serialized as a querystring using form style with explode.
/// /// ///
/// Only the defined properties below are allowed. The object serializes to a querystring format like: `type=4&sourceType=2&sort=duration:desc,index`
/// ///
///
public class MediaQuery { /// /// The type of media to retrieve or filter by.
/// /// ///
/// 1 = movie
/// 2 = show
/// 3 = season
/// 4 = episode
/// 5 = artist
/// 6 = album
/// 7 = track
/// 8 = photo_album
/// 9 = photo
///
/// E.g. A movie library will not return anything with type 3 as there are no seasons for movie libraries
/// ///
///
[SpeakeasyMetadata("queryParam:name=type")] public MediaType? Type { get; set; } /// /// Change the default level to which fields refer (used with type for hierarchical queries) /// [SpeakeasyMetadata("queryParam:name=sourceType")] public long? SourceType { get; set; } /// /// Field(s) to sort by, with optional modifiers. Use comma to separate multiple fields, and :desc or :nullsLast for modifiers (e.g., "duration:desc,index") /// [SpeakeasyMetadata("queryParam:name=sort")] public string? Sort { get; set; } /// /// Field to group results by (similar to SQL GROUP BY) /// [SpeakeasyMetadata("queryParam:name=group")] public string? Group { get; set; } /// /// Maximum number of results to return /// [SpeakeasyMetadata("queryParam:name=limit")] public long? Limit { get; set; } } }