Playlist Files¶
Playlist files are used to create and maintain playlists on the Plex Server.
If utilized to their fullest, these files can be used to maintain the entire server's collections and playlists, and can be used as a backup for these in the event of a restore requirement.
Tip
Playlists are defined in one or more Playlist files that are mapped in the Playlist Files Attribute within the Configuration File.
You can use the playlist_report setting to get a list of your playlists
printed out in your log.
Example¶
This example is a Playlist file with a basic playlist which is saved in a file called MyPlaylists.yml within the
location mapped as config in my setup.
Example "MyPlaylists.yml"
Click the icon to learn more
playlists: #(1)!
Marvel Cinematic Universe Chronological Order:
sync_mode: sync
libraries: Movies, TV Shows #(2)!
sync_to_users: User1, someone@somewhere.com, User3 #(3)!
trakt_list: https://trakt.tv/users/donxy/lists/marvel-cinematic-universe
summary: Marvel Cinematic Universe In Chronological Order
- This must appear once and only once in any Playlist file
- These libraries must exist in your Plex library
- Leave this blank if you only only want the Playlist to sync to the server owner's account
This file would then be defined in my config.yml file as a playlist_files item:
Important Note
Playlist files are not called within the libraries section, they are defined at the root identation as you can see
in the below example.
config.yml Example Playlists Addition
Click the icon to learn more
libraries:
Movies:
# Metadata and Overlay files here
TV Shows:
# Metadata and Overlay files here
playlist_files: #(1)!
- file: config/MyPlaylists.yml #(2)!
- Note that Playlist files are not called within the
librariessection, they are defined at the root identation as you can see here configrefers to the location that you mapped toconfigwhen following the Kometa Installation Guides.
Playlist Attributes¶
Kometa can automatically build and update playlists defined within the playlists attribute.
These are the attributes which can be utilized within the Playlist File:
| Attribute | Description |
|---|---|
playlists |
contains definitions of playlists you wish to add to the server |
templates |
contains definitions of templates that can be leveraged by multiple playlists |
external_templates |
contains file blocks that point to external templates that can be leveraged by multiple playlists |
playlistsis required in order to run the Playlist File.- You can find example Playlist Files in the Kometa Community Configs Repository
- Plex does not support the "Continue Watching" feature for playlists, you can vote for the feature here
Each playlist requires its own section within the playlists attribute and unlike collections, playlists can only be
built using one Builder as their ordering is inherited from the Builder; it is not possible to combine builders.
playlists:
Marvel Cinematic Universe Chronological Order:
# ... builder, details, and filters for this playlist
Star Wars Clone Wars Chronological Order:
# ... builder, details, and filters for this playlist
etc:
# ... builder, details, and filters for this playlist
There are multiple types of attributes that can be utilized within a playlist:
NOTE: these lists are references for collections and playlists, not everything applies to both:
Special Playlist Attributes¶
| Attribute | Description | Required |
|---|---|---|
delete_playlist |
Will delete this playlist for the users defined by sync_to_users. Options: true or false |
|
exclude_users |
Determine which Users will be excluded from having the playlist synced. This will override the global playlist_excude_users Setting.Options: Comma-separated string or list of users, all for every user who has server access, or leave blank for just the server owner. |
|
libraries |
Determine which libraries the playlist will be built from. Options: Comma-separated string or list of library mapping names defined in the libraries attribute in the base of your Configuration File. |
|
sync_to_users |
Determine which Users have the playlist synced. This will override the global playlist_sync_to_users Setting.Options: Comma-separated string or list of users, all for every user who has server access, or leave blank for just the server owner. |
- Any defined playlist will be always be visible by The Plex Media Server owner, so it doesn't need to be defined within
sync_to_users.
Example Playlists¶
In the following example, media is pulled from the Movies and TV Shows libraries into the one Playlist, and the
playlist is shared with a specific set of users:
playlists:
Marvel Cinematic Universe Chronological Order:
sync_mode: sync
libraries: Movies, TV Shows
sync_to_users: User1, someone@somewhere.com, User3
trakt_list: https://trakt.tv/users/donxy/lists/marvel-cinematic-universe?sort=rank,asc
summary: Marvel Cinematic Universe In Chronological Order
Star Wars Clone Wars Chronological Order:
sync_to_users: all
sync_mode: sync
libraries: Movies, TV Shows
trakt_list: https://trakt.tv/users/tomfin46/lists/star-wars-the-clone-wars-chronological-episode-order