DynamiX is an automation tool for dynamically managing Plex collections pinning. It pins and unpins library collections based on configurable time blocks, ensuring fresh and relevant content is featured. This repository includes the Python script and its packaged .exe
version for easier execution. It is important to note that CURRENTLY this tool does not actually create collections, that feature will be available soon!
Find the latest release of the .exe on the releases page https://github.com/TheImaginear/dynamiX/releases
- Dynamic Pinning: Automatically pin collections based on time and day configurations.
- Exclusion Handling: Avoid re-pinning the same collection for a configurable period.
- User Exemptions: Allow manual exclusion of specific collections.
- GUI Control: Includes an intuitive graphical interface for configuration and monitoring.
- Robust Logging: Provides clear logs of actions and issues.
- Python 3.8+ (for running the script)
- Plex Media Server
- Plex API Token (to authenticate and access the server)
- Required Libraries:
plexapi
,requests
, andttkbootstrap
- Download the latest
script.exe
from the Releases Page. - Place it in a directory of your choice.
- Double-click the
script.exe
to launch the application.
- Clone this repository:
git clone https://github.com/YourUsername/DynamiX.git cd DynamiX
- Install the required dependencies:
pip install -r requirements.txt
- Run the script:
python src/script.py
1a. Grab the latest docker image:
docker pull clharrel/dynamix:latest
1b. Grab it from the Repo Page: (https://hub.docker.com/repository/docker/clharrel/dynamix/general)
- Configure the config.json file with your preferences: I highly recommend using the windows application with GUI to generate your config files! The docker build is the exact functions of the application version without the gui and an automatic run on start!
Upon the first run, the application will prompt you to fill in required configuration details:
- Plex URL: The address of your Plex Media Server (e.g.,
http://<server_ip>:32400
). - Plex Token: A valid Plex API Token (refer to instructions below).
- Libraries: Comma-separated list of Plex libraries to manage (e.g.,
Movies, TV Shows
). - Pinning Interval: How often the program pins/unpins collections (in minutes).
The following files are generated and updated dynamically:
config.json
- Stores the main configuration settings.used_collections.json
- Tracks recently pinned collections to avoid immediate repeats.user_exemptions.json
- Maintains a list of collections manually exempted by the user.
To access the Plex API, you need a valid token. Follow these steps to retrieve it:
- Open the Plex Web App and log in to your Plex server.
- Select any media item (e.g., a movie or TV episode).
- Click the
Get Info
button (3-dot menu) and chooseView XML
. - A new tab will open. In the URL, find the part after
X-Plex-Token=
. - Copy the token and paste it into the configuration.
- Launch the application (
script.exe
orpython src/script.py
). - Use the intuitive GUI to:
- Configure Plex server details and dynamic pinning settings.
- Manage exclusions and user exemptions.
- Add Seasonal Pinning Rules (V1.1+)
- View activity logs in real-time.
- Start the automation process by clicking "Run Main Function" on the Logs tab.
The running program:
Dynamic Exclusions list updated in the GUI:
User-Set Exemptions:
Server Configuration Tab:
Settings Tab:
Automatically Updates Home Screen, Shared Home, and/or library screen:
Tab | Description |
---|---|
Plex Server | Configure Plex server URL and API token. Display server name for confirmation. |
Settings | Configure libraries, time blocks, season blocks, and pinning settings. |
Logs | View real-time activity logs for debugging and monitoring. |
Dynamic Exclusions | Manage collections that are temporarily excluded after being pinned. |
User Exemptions | Manually exempt specific collections from being pinned. |
Customize the number of collections pinned during specific times of the day. For example:
Day | Time Block | Start Time | End Time | Limit |
---|---|---|---|---|
Monday | Morning | 06:00 | 12:00 | 3 |
Monday | Evening | 18:00 | 22:00 | 5 |
- Collections that are pinned are excluded for a configurable number of days.
- If not enough valid collections are found, the exclusion list can be reset.
Manually exempt specific collections from being pinned using the User Exemptions tab.
- Initial Release
- Introduced dynamic pinning of Plex collections.
- Added exclusion handling and user exemption management.
- Provided a GUI for configuration and log monitoring.
Required libraries are listed in requirements.txt
:
plexapi
requests
ttkbootstrap
Install them with:
pip install -r requirements.txt
We welcome contributions! Please follow these steps:
- Fork the repository.
- Create a feature branch:
git checkout -b feature-branch-name
- Commit your changes with descriptive messages.
- Push your changes:
git push origin feature-branch-name
- Open a Pull Request with details about your changes.
See the full contributing guidelines in CONTRIBUTING.md.
This project is licensed under the MIT License. See the LICENSE file for details.
If you encounter issues, please open a ticket in the Issues section.
For general questions and feedback, feel free to reach out!