Methods
(static) AppearsOnList(id) → {dynamic}
Get list of albums an artist appears on as a contributing artist (not album artist). Uses ContributingArtistIds which Jellyfin defines as artists who appear on the album but are NOT tagged as the album artist — so this row is mutually exclusive with MusicAlbumList(). Sorted by year descending.
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) ArtistOverview(name) → {dynamic}
Music Artist Data
| Name | Type | Description |
|---|---|---|
name | string |
- Source
- Type:
- dynamic
(static) AudioItem(id) → {dynamic}
Get audio item metadata (raw, no transform)
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) AudioStream(id) → {dynamic}
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) BackdropImage(id) → {dynamic}
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) GetIntroVideos(id) → {dynamic}
Get Intro Videos for an item
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) GetItemLyrics(itemId) → {dynamic}
Get lyrics for an Audio item.
| Name | Type | Description |
|---|---|---|
itemId | string | The Audio item ID |
- Source
LyricDto: { Metadata: {...}, Lyrics: [{Start: ticks, Text: string}] }, or invalid
- Type:
- dynamic
(static) GetMediaSegments(id) → {dynamic}
GetMediaSegments: Fetches media segments for an item (Intro, Outro, Recap, etc.).
Only available on Jellyfin 10.10.0+ servers. Returns invalid for older servers.
| Name | Type | Description |
|---|---|---|
id | string | The item ID |
- Source
- { Items: [MediaSegmentDto], TotalRecordCount } or invalid
- Type:
- dynamic
(static) GetSongsByArtist(id, paramsopt) → {dynamic}
Get list of songs belonging to an artist
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
id | string | |||
params | object | <optional> | {} |
- Source
- Type:
- dynamic
(static) GetSongsByArtistBroad(id) → {dynamic}
Get all Audio tracks by an artist in any capacity (album artist OR contributing artist). Broader than GetSongsByArtist (which uses AlbumArtistIds). Used for the artist Songs row so songs on compilation albums or items with mismatched album-level tags still surface.
| Name | Type | Description |
|---|---|---|
id | string | MusicArtist item ID |
- Source
- Type:
- dynamic
(static) ItemDetailsMetaData(id, forceRefreshopt) → {dynamic}
MetaData for an item detail screen — includes People, Genres, and Studios in addition to Chapters and Trickplay. Use this instead of ItemMetaData() when populating a detail view.
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
id | string | |||
forceRefresh | boolean | <optional> | false |
- Source
- Type:
- dynamic
(static) ItemMetaData(id, fieldsopt, forceRefreshopt) → {dynamic}
MetaData about an item — returns a JellyfinBaseItem node.
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
id | string | |||
fields | string | <optional> | "Chapters,Trickplay" | Comma-separated Jellyfin fields to request. Defaults to Chapters and Trickplay only. |
forceRefresh | boolean | <optional> | false |
- Source
- Type:
- dynamic
(static) ItemPostPlaybackInfo(id, mediaSourceIdopt, audioTrackIndexopt, subtitleTrackIndexopt, startTimeTicksopt, videoMetadataopt, bypassDoviPreservationopt, forceTranscodingopt) → {dynamic}
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
id | string | |||
mediaSourceId | string | <optional> | "" | |
audioTrackIndex | integer | <optional> | -1 | |
subtitleTrackIndex | integer | <optional> | SubtitleSelection.NONE | |
startTimeTicks | longinteger | <optional> | 0& | |
videoMetadata | dynamic | <optional> | invalid | |
bypassDoviPreservation | boolean | <optional> | false | |
forceTranscoding | boolean | <optional> | false |
- Source
- Type:
- dynamic
(static) MusicAlbumList(id) → {dynamic}
Get list of albums where this artist is the album artist (strict: AlbumArtistIds only). Sorted by year descending so the discography reads newest-first. Does NOT include albums the artist merely contributes to — see AppearsOnList().
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) MusicSongList(id) → {dynamic}
Get Songs that are on an Album
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) TVSeasons(id) → {dynamic}
Seasons for a TV Show
| Name | Type | Description |
|---|---|---|
id | string |
- Source
- Type:
- dynamic
(static) applyLiveTvMinSegments(postData) → {void}
applyLiveTvMinSegments: For HLS transcodes that report no source duration (live channels), request ≥8 segments per Roku's recommendation. Gives ~48 s seekable DVR window.
| Name | Type | Description |
|---|---|---|
postData | object |
- Source
- Type:
- void
(static) applyMediaSourceToPostData(postData, mediaSourceId, forceTranscoding) → {void}
applyMediaSourceToPostData: Applies the media source ID or live TV retry flags to a postData object. Live TV is detected by an empty mediaSourceId. On the first attempt, direct play is not disabled so the server can evaluate compatibility (matching web client behaviour). On retry, forceTranscoding=true sets EnableDirectPlay=false so the server provides a transcode URL instead.
| Name | Type | Description |
|---|---|---|
postData | object | The request body assoc array to modify |
mediaSourceId | string | Media source ID, or "" for live TV |
forceTranscoding | boolean | True when retrying with forced transcoding |
- Source
- Type:
- void
(static) optimizeAudioCodecListForSource(deviceProfile, channelCount, preferredMultichannelCodecopt) → {void}
Tailors a video transcoding profile's AudioCodec list to the current source's channel count so the server (and downstream HLS variant selection) can't fall back to a less-desirable codec.
Multichannel source (>2ch): Strips ALL stereo-output codecs (aac, mp3, flac, alac, pcm, lpcm, wav, vorbis). Without this, Jellyfin's HLS muxer offers BOTH the surround codec AND a stereo fallback as separate variants in the master playlist, and Roku's HLS player has been observed (via in-house testing on physical hardware; no upstream tracking issue at time of writing) to pick the stereo variant — defeating the entire point of having surround passthrough hardware. Caller must already have verified the device has surround passthrough before invoking with channelCount > 2.
Stereo source (≤2ch): Strips surround passthrough codecs (eac3, ac3, dts) plus aac so transcoding falls through to mp3. Avoids handing the server a surround target codec for content that's only 2ch anyway. If filtering empties a previously non-empty list, falls back to "mp3" (the intended target).
Multichannel surround target (issue #573): For a >2ch source, the stripped list MUST lead with a server-encodeable surround codec. Two failure modes this prevents, both observed on Jellyfin 10.11 via PlaybackInfo probes:
- Empty list: Jellyfin's StreamBuilder omits the audioCodec query param, the server's InferAudioCodec falls through to the container name ("m3u8"), ffmpeg gets
-codec:a:0 m3u8and exits 8. Happens when passthrough is detected only via codecs not in surroundPriority (truehd/dtshd-only) so no surround codec is in the list. - On-device-decode leak: a list like "truehd,opus" (truehd un-encodeable for a non-truehd source; opus on-device-decode only) resolves server-side to opus, silently abandoning the user's surround/passthrough intent for a decoded stereo-ish path. Fix: prepend the user's preferred multichannel codec (playbackPreferredMultichannelCodec), clamped to a reliably-encodeable HLS surround target — eac3 or ac3 (dts is excluded: the server emits no audio stream for a dts transcode target). This is a no-op for healthy profiles (their stripped list already leads with eac3/ac3) and only rescues the degenerate truehd/dtshd-only shape.
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
deviceProfile | object | |||
channelCount | integer | |||
preferredMultichannelCodec | string | <optional> | "eac3" |
- Source
- Type:
- void
(static) resolveMultichannelSurroundTarget(preferredMultichannelCodec) → {string}
Resolve the surround transcode target for a multichannel source from the user's preferred multichannel codec setting (playbackPreferredMultichannelCodec). Clamped to the reliably- encodeable HLS surround targets: eac3 (default) and ac3. dts is intentionally excluded — the Jellyfin server emits no audio stream for a dts transcode target (verified on 10.11), so a dts fallback would itself re-trigger the issue #573 failure. Both eac3 and ac3 are valid HLS audio targets in every video transcoding container (ts and mp4), so no per-container clamp is needed.
| Name | Type | Description |
|---|---|---|
preferredMultichannelCodec | string |
- Source
- Type:
- string
(static) searchMedia(query) → {object}
Render-thread wrapper: delegates search to SearchTask (task thread) and blocks until complete. Used by Main.bs SearchBox flow which shows a ProgressDialog while waiting.
| Name | Type | Description |
|---|---|---|
query | string |
- Source
- Type:
- object
(static) supportsLyrics() → {boolean}
supportsLyrics: Checks if the connected Jellyfin server supports the Lyrics API.
The /Audio/{itemId}/Lyrics endpoint was introduced in Jellyfin 10.9.0. Servers below 10.9.0 do not have this endpoint and will return 404. Guarding the request mirrors supportsMediaSegments() (source/utils/mediaSegments.bs) and lets the endpoint-availability ledger record this as a validated version-guard.
- Source
- true if server supports lyrics
- Type:
- boolean
(static) useTranscodeAudioStream(playbackInfo) → {dynamic}
| Name | Type | Description |
|---|---|---|
playbackInfo | dynamic |
- Source
- Type:
- dynamic