• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting Howto access playlist data through API?

     
    • 0 Vote(s) - 0 Average

    Howto access playlist data through API?

    Stubbie
    Offline

    Junior Member

    Posts: 4
    Threads: 2
    Joined: 2025 Mar
    Reputation: 0
    Country:Netherlands
    #1
    2025-03-21, 06:25 PM (This post was last modified: 2025-03-22, 05:38 PM by Stubbie. Edited 1 time in total.)
    Hi, I am trying to synchronize playlists in Jellyfin with Music Assistant (a Home Assistant add-on).
    "Native" Jellyfin playlist sync fine, but playlists from m3u files either sync empty, or don't sync at all, seemingly depending on how the paths inside are formed.

    Anyway, I was curious to see what Jellyfin transmits over the API, but cannot seem to get the GET /Playlists/{playlistId} to work. Using Bruno (an API explorer) I get an 404/"Error processing request." error.

    These are my steps:
    - GET http://172.16.XXX.XXX:8096/Users to get the user Id
    - GET http://172.16.XXX.XXX:8096/Users/<userId>/Items?IncludeItemTypes=ManualPlaylistsFolder to get the Id of the Playlist library
    - GET http://172.16.XXX.XXX:8096/Users/<userId>/Items?ParentId=<playlistFolderId> to get a list of playlists. The returned json:

    Code:
    {
      "Items": [
        {
          "Name": "JF-NATIVE-TEST",
          "ServerId": "db2bc2f8a74649089ee7bf18b3af2023",
          "Id": "1710350a4974e666176baabd410b3339",
          "ChannelId": null,
          "RunTimeTicks": 29178514270,
          "IsFolder": true,
          "Type": "Playlist",
          "UserData": {
            "PlaybackPositionTicks": 0,
            "PlayCount": 0,
            "IsFavorite": false,
            "Played": false,
            "Key": "1710350a-4974-e666-176b-aabd410b3339",
            "ItemId": "00000000000000000000000000000000"
          },
          "ChildCount": 11,
          "ImageTags": {
            "Primary": "fafc487dd1790326e4d67dbde32db8c1"
          },
          "BackdropImageTags": [],
          "ImageBlurHashes": {
            "Primary": {
              "fafc487dd1790326e4d67dbde32db8c1": "eaNu-ZoffQt7J7?Hj[fQfks:fQfQfQfQfQ~Wj[fQkC%2Ioj[fQofoL"
            }
          },
          "LocationType": "FileSystem",
          "MediaType": "Audio"
        },

    Finally, I attempt to have a peek inside the playlist, but this GET call fails:
    - http://172.16.XXX.XXX:8096/Playlists/adf...5217/Items

    Probably something stupid... any ideas?

    I am on Jellyfin 10.10.6.
    No error messages in the log.
    xaque
    Offline

    Member

    Posts: 76
    Threads: 1
    Joined: 2023 Jun
    Reputation: 3
    Country:United States
    #2
    2025-03-21, 11:48 PM (This post was last modified: 2025-03-21, 11:49 PM by xaque. Edited 1 time in total.)
    The api docs have this to say, https://api.jellyfin.org/#tag/Playlists/...ylistItems


    You try this endpoint?

    http://localhost/Playlists/{playlistId}/Items
    Stubbie
    Offline

    Junior Member

    Posts: 4
    Threads: 2
    Joined: 2025 Mar
    Reputation: 0
    Country:Netherlands
    #3
    2025-03-22, 05:39 PM
    Yeah, I did add the "/Items", my last attempt was without it, and that is what I accidentally copy-pasted above (now corrected).
    Stubbie
    Offline

    Junior Member

    Posts: 4
    Threads: 2
    Joined: 2025 Mar
    Reputation: 0
    Country:Netherlands
    #4
    2025-03-22, 05:46 PM
    Oh, I just accidentally stumbled on a workaround/solution... It's odd, but this returns me the contents of the playlist. Odd because the intended call to Playlist/../Items doesn't return anything.

    Returns contents of playlist:
    http://172.16.XXX.XXX:8096/Users/fd6e1bc...laylistId>

    This does not:
    http://172.16.XXX.XXX:8096/Playlists/<PlaylistId/Items
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode