red-plex


Namered-plex JSON
Version 1.11.2 PyPI version JSON
download
home_pagehttps://github.com/marceljungle/red-plex
SummaryA CLI and web GUI tool for creating Plex collections from RED and OPS collages and bookmarks
upload_time2025-07-15 21:26:11
maintainerNone
docs_urlNone
authormarceljungle
requires_python>=3.8
licenseNone
keywords plex music collections red ops redacted orpheus gazelle tracker
VCS
bugtrack_url
requirements plexapi requests pyrate-limiter tenacity click pyyaml flask flask-socketio gunicorn eventlet
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # red-plex

[![PyPI version](https://badge.fury.io/py/red-plex.svg)](https://badge.fury.io/py/red-plex)
[![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

A command-line tool and web interface for creating and updating Plex collections based on collages and bookmarks from Gazelle-based music trackers like **Redacted** ("RED") and **Orpheus Network** ("OPS"). 

red-plex bridges the gap between your curated music collections on private trackers and your personal Plex media server, automatically creating and maintaining Plex collections that mirror your tracker collages and bookmarks.

## Quick Start

1. **Install red-plex**: `pip install red-plex`
2. **Configure your API keys**: `red-plex config edit`
3. **Create your first collection**: 
   - **CLI**: `red-plex collages convert 12345 --site red`
   - **Web GUI**: `red-plex gui` (then visit http://127.0.0.1:8000)

## Web Interface

red-plex now includes a comprehensive web-based GUI for users who prefer a visual interface over command-line operations.

### Features

- **🌐 Dashboard**: Clean overview with feature cards and navigation
- **⚙️ Configuration Management**: View and edit all settings (API keys, Plex config, rate limits) through web forms
- **🎨 Collage Operations**: Convert new collages and view existing collections
- **🔖 Bookmark Operations**: Convert bookmarks from RED and OPS trackers
- **🗄️ Database Management**: View statistics, update albums, reset tables
- **⚡ Real-time Updates**: Live status updates during long operations via WebSocket
- **📱 Mobile-Responsive**: Bootstrap-based design that works on all devices

### Usage

```bash
# Launch GUI server (default: http://127.0.0.1:8000)
red-plex gui

# Custom host/port
red-plex gui --host 0.0.0.0 --port 8080

# Debug mode with auto-reload
red-plex gui --debug
```

The web interface provides the same functionality as the CLI commands but with a user-friendly visual interface, real-time progress updates, and intuitive navigation.

## What are RED and OPS?

- **Redacted (RED)**: A private music tracker focused on high-quality audio files
- **Orpheus Network (OPS)**: Another private music tracker with curated content
- Both use the Gazelle framework and offer "collages" (curated collections) and personal bookmarks

## Table of Contents
- [Prerequisites](#prerequisites)
- [Installation](#installation)
- [Getting API Keys](#getting-api-keys)
- [Configuration](#configuration)
- [Web Interface](#web-interface)
- [Overview](#overview)
- [Features](#features)
- [Usage & Commands](#usage--commands)
  - [Configuration Commands](#configuration-commands)
  - [Collages](#collages)
  - [Bookmarks](#bookmarks)
  - [Fetch Mode (-fm)](#fetch-mode--fm)
  - [Database Commands](#database-commands)
- [Examples](#examples)
  - [Creating Collections](#creating-collections)
  - [Updating Collections](#updating-collections)
  - [Using Query Fetch Mode](#using-query-fetch-mode)
- [Configuration Details](#configuration-details)
- [Configuration Tips](#configuration-tips)
- [Troubleshooting](#troubleshooting)
- [Important Considerations](#important-considerations)
- [Contributing](#contributing)

---

## Prerequisites

- **Python 3.8 or higher**
- **Plex Media Server** with a configured music library
- **Active account** on RED and/or OPS with API access
- **Music library** organized in your Plex server

## Installation

### Using pip (recommended)

```bash
pip install red-plex
```

### Using pipx (isolated environment)

```bash
pipx install red-plex
```

### From source

```bash
git clone https://github.com/marceljungle/red-plex.git
cd red-plex
pip install -e .
```

## Getting API Keys

### For Redacted (RED)
1. Log into your RED account
2. Go to your profile settings
3. Navigate to "Access Settings" or "API"
4. Generate a new API key
5. **Keep this key secure and private**

### For Orpheus Network (OPS)
1. Log into your OPS account
2. Go to your user settings
3. Find the API section
4. Generate a new API key
5. **Keep this key secure and private**

## Configuration

After installation, you need to configure red-plex with your credentials:

```bash
# Open configuration file in your default editor
red-plex config edit
```

Edit the configuration file with your details:

```yaml
LOG_LEVEL: INFO
PLEX_URL: http://localhost:32400
PLEX_TOKEN: your_plex_token_here
SECTION_NAME: Music
RED:
  API_KEY: your_red_api_key_here
  BASE_URL: https://redacted.sh
  RATE_LIMIT:
    calls: 10
    seconds: 10
OPS:
  API_KEY: your_ops_api_key_here
  BASE_URL: https://orpheus.network
  RATE_LIMIT:
    calls: 4
    seconds: 15
```

### Getting Your Plex Token

Visit: https://plex.tv/api/resources?includeHttps=1&X-Plex-Token={YOUR_TOKEN}

## Overview

- **Stores Data in SQLite**: Instead of CSV-based "caches," red-plex now stores albums, collages, and bookmarks in a lightweight SQLite database.
- **Collages & Bookmarks**: Fetch and manage torrent-based "collages" or personal "bookmarks" from Gazelle-based sites.
- **Plex Integration**: Compare the torrent group info with your Plex music library to create or update Plex collections.
- **Flexible Album Matching**: Match albums in Plex using either the original `torrent_name` (directory name) or a query-based approach (`Artist/Album`), ideal for organized libraries (e.g., Beets/Lidarr).
- **Incremental Updating**: Update previously created collections as new albums become available or site data changes.

## Features

- **Multi-Site**: Works with Redacted ("red") and Orpheus Network ("ops").
- **Web Interface**: Modern Flask-based GUI with Bootstrap styling and real-time updates.
- **Collections from Collages/Bookmarks**: Create or update entire Plex collections for each collage or bookmarked set.
- **Local SQLite Database**: All data (albums, collages, bookmarks) is kept in one DB, no more CSV.
- **Two Fetch Modes**: Choose between `torrent_name` (default) for direct path matching or `query` for metadata-based searches in Plex.
- **Configurable Logging**: Choose between INFO, DEBUG, etc., in `config.yml`.
- **Rate Limiting**: Respects site rate limits and retries on errors.
- **Dual Interface**: Access all functionality via both command-line interface and web GUI.
- **Python 3.8+ Compatible**: Runs on modern Python versions with no external database dependencies.

## Usage & Commands

Type `red-plex --help` for detailed usage. Below is a summary of the main commands.

### Web Interface Commands

```bash
# Launch web GUI server
red-plex gui [--host HOST] [--port PORT] [--debug]

# Examples:
red-plex gui                           # Default: http://127.0.0.1:8000
red-plex gui --host 0.0.0.0            # Bind to all interfaces
red-plex gui --port 8080               # Custom port
red-plex gui --debug                   # Debug mode with auto-reload
```

### Configuration Commands

```bash
# Show current configuration (YAML)
red-plex config show

# Edit configuration in your default editor
red-plex config edit

# Reset configuration to default values
red-plex config reset
```

### Collages

```bash
# Create Plex collections for specific collage IDs
red-plex collages convert [COLLAGE_IDS] --site [red|ops] --fetch-mode [torrent_name|query]

# Update all collages in the database, re-checking the site data
red-plex collages update --fetch-mode [torrent_name|query]
```

### Bookmarks

```bash
# Create Plex collections from your bookmarked releases
red-plex bookmarks convert --site [red|ops] --fetch-mode [torrent_name|query]

# Update all bookmarks in the database
red-plex bookmarks update --fetch-mode [torrent_name|query]
```

### Fetch Mode (-fm)

The `--fetch-mode` (or `-fm`) option controls how red-plex locates albums in Plex:

#### For all commands (`collages convert`, `collages update`, `bookmarks convert`, `bookmarks update`):
- **torrent_name** (default): Searches for directories matching the torrent folder name
- **query**: Searches using `Artist` and `Album` metadata, ideal for organized libraries managed by tools like Beets or Lidarr

### Database Commands

```bash
# Show database location
red-plex db location

# Manage albums table
red-plex db albums reset        # Clear all album records
red-plex db albums update       # Pull fresh album info from Plex

# Manage collections table
red-plex db collections reset   # Clear the collage collections table

# Manage bookmarks table
red-plex db bookmarks reset     # Clear the bookmark collections table
```

## Examples

### Creating Collections

```bash
# Single collage (Redacted), default mode
red-plex collages convert 12345 --site red

# Multiple collages (Orpheus), default mode
red-plex collages convert 1111 2222 3333 --site ops

# From bookmarks (RED or OPS), default mode
red-plex bookmarks convert --site red
```

### Updating Collections

```bash
# Update all stored collages
red-plex collages update

# Update all stored bookmarks
red-plex bookmarks update

# Update albums from Plex
red-plex db albums update
```

### Using Query Fetch Mode

```bash
# Create a collection using query mode (for Beets/Lidarr organized libraries)
red-plex collages convert 12345 --site red --fetch-mode query

# Update all bookmarks using query mode
red-plex bookmarks update --site ops -fm query
```

### Complete Workflow Example

#### Command Line Interface
```bash
# 1. First time setup
red-plex config edit  # Add your API keys and Plex details

# 2. Update your local album database from Plex
red-plex db albums update

# 3. Create collections from specific collages
red-plex collages convert 12345 67890 --site red

# 4. Create collection from your bookmarks
red-plex bookmarks convert --site red

# 5. Later, update all collections with new releases
red-plex collages update
red-plex bookmarks update
```

#### Web Interface
```bash
# 1. Launch the web interface
red-plex gui

# 2. Open http://127.0.0.1:8000 in your browser

# 3. Navigate to Configuration to add your API keys and Plex details

# 4. Use the Database page to update your local album database

# 5. Use the Collages page to convert specific collages

# 6. Use the Bookmarks page to convert your bookmarks

# 7. Return to Database page later to update all collections
```

## Configuration Details

By default, configuration is stored in `~/.config/red-plex/config.yml`:

```yaml
LOG_LEVEL: INFO
OPS:
  API_KEY: your_ops_api_key_here
  BASE_URL: https://orpheus.network
  RATE_LIMIT:
    calls: 4
    seconds: 15
PLEX_TOKEN: your_plex_token_here
PLEX_URL: http://localhost:32400
RED:
  API_KEY: your_red_api_key_here
  BASE_URL: https://redacted.sh
  RATE_LIMIT:
    calls: 10
    seconds: 10
SECTION_NAME: Music
```

## Configuration Tips

- If HTTP fails, fetch an HTTPS URL:
  ```
  https://plex.tv/api/resources?includeHttps=1&X-Plex-Token={YOUR_TOKEN}
  ```
- Look for the `<Device>` node in the XML for a `uri`, use this `plex.direct` address.
- Use `DEBUG` log level for verbose debugging information
- Use `WARNING` log level for minimal output

## Troubleshooting

### Common Issues

#### "No module named 'plexapi'" Error
```bash
pip install plexapi
# or
pip install red-plex --upgrade
```

#### Authentication Errors
- Verify your API keys are correct in `config.yml`
- Check that your Plex token is valid
- Ensure you have access to the sites you're trying to use

#### No Albums Found
- Run `red-plex db albums update` to refresh your Plex library
- Check that your Plex music library is properly configured
- Verify the `SECTION_NAME` in your config matches your Plex music library name

#### Rate Limiting Issues
- The tool respects site rate limits automatically
- If you encounter issues, try reducing the rate limit values in your config

#### Fetch Mode Issues
- Use `torrent_name` mode if your library structure matches torrent folder names
- Use `query` mode if you use Beets, Lidarr, or have renamed your music files
- Try both modes to see which works better for your library

#### Web Interface Issues
- **GUI won't start**: Ensure `gunicorn` and `eventlet` are installed: `pip install gunicorn eventlet`
- **Can't access GUI**: Check if the port is available and not blocked by firewall
- **GUI stuck on "Starting..."**: Check terminal logs for error messages
- **WebSocket connection failed**: Ensure your browser supports WebSockets and isn't blocking them

### Getting Help

1. Check the logs with `LOG_LEVEL: DEBUG` in your config
2. Verify your configuration with `red-plex config show`
3. Test your Plex connection by running `red-plex db albums update`
4. Open an issue on GitHub with detailed error messages

## Important Considerations

- **Album Matching Strategy**:
  - `torrent_name` (default): Matches albums by comparing torrent folder names with Plex directory paths
  - `query`: Uses artist and album metadata for matching, ideal for libraries organized by Beets, Lidarr, or other tools that rename files
- **Database Management**: All data is stored in `red_plex.db`. Use database reset commands (`db albums reset`, etc.) to clear specific tables when needed
- **Site Credentials**: Ensure your API keys are valid and have proper permissions
- **Rate Limiting**: The tool automatically respects site-specific rate limits to avoid being banned
- **Logging Levels**: 
  - `DEBUG`: Verbose output for troubleshooting
  - `INFO`: Standard information (default)
  - `WARNING`: Minimal output
- **Collection Updates**: When you run `collages update` or `bookmarks update`, new albums are added to existing Plex collections, but removed items from tracker collages are not automatically removed from Plex collections

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

### Development Setup

```bash
git clone https://github.com/marceljungle/red-plex.git
cd red-plex
pip install -e .
```

---

**Disclaimer**: This tool is for personal use with your own music library and tracker accounts. Respect the rules and terms of service of the private trackers you use.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/marceljungle/red-plex",
    "name": "red-plex",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "plex music collections red ops redacted orpheus gazelle tracker",
    "author": "marceljungle",
    "author_email": "gigi.dan2011@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/ac/9d/79c73686287c86e372b4f5f90ea30f566ccfefeb1616c9fbecdd967dbb99/red_plex-1.11.2.tar.gz",
    "platform": null,
    "description": "# red-plex\n\n[![PyPI version](https://badge.fury.io/py/red-plex.svg)](https://badge.fury.io/py/red-plex)\n[![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\nA command-line tool and web interface for creating and updating Plex collections based on collages and bookmarks from Gazelle-based music trackers like **Redacted** (\"RED\") and **Orpheus Network** (\"OPS\"). \n\nred-plex bridges the gap between your curated music collections on private trackers and your personal Plex media server, automatically creating and maintaining Plex collections that mirror your tracker collages and bookmarks.\n\n## Quick Start\n\n1. **Install red-plex**: `pip install red-plex`\n2. **Configure your API keys**: `red-plex config edit`\n3. **Create your first collection**: \n   - **CLI**: `red-plex collages convert 12345 --site red`\n   - **Web GUI**: `red-plex gui` (then visit http://127.0.0.1:8000)\n\n## Web Interface\n\nred-plex now includes a comprehensive web-based GUI for users who prefer a visual interface over command-line operations.\n\n### Features\n\n- **\ud83c\udf10 Dashboard**: Clean overview with feature cards and navigation\n- **\u2699\ufe0f Configuration Management**: View and edit all settings (API keys, Plex config, rate limits) through web forms\n- **\ud83c\udfa8 Collage Operations**: Convert new collages and view existing collections\n- **\ud83d\udd16 Bookmark Operations**: Convert bookmarks from RED and OPS trackers\n- **\ud83d\uddc4\ufe0f Database Management**: View statistics, update albums, reset tables\n- **\u26a1 Real-time Updates**: Live status updates during long operations via WebSocket\n- **\ud83d\udcf1 Mobile-Responsive**: Bootstrap-based design that works on all devices\n\n### Usage\n\n```bash\n# Launch GUI server (default: http://127.0.0.1:8000)\nred-plex gui\n\n# Custom host/port\nred-plex gui --host 0.0.0.0 --port 8080\n\n# Debug mode with auto-reload\nred-plex gui --debug\n```\n\nThe web interface provides the same functionality as the CLI commands but with a user-friendly visual interface, real-time progress updates, and intuitive navigation.\n\n## What are RED and OPS?\n\n- **Redacted (RED)**: A private music tracker focused on high-quality audio files\n- **Orpheus Network (OPS)**: Another private music tracker with curated content\n- Both use the Gazelle framework and offer \"collages\" (curated collections) and personal bookmarks\n\n## Table of Contents\n- [Prerequisites](#prerequisites)\n- [Installation](#installation)\n- [Getting API Keys](#getting-api-keys)\n- [Configuration](#configuration)\n- [Web Interface](#web-interface)\n- [Overview](#overview)\n- [Features](#features)\n- [Usage & Commands](#usage--commands)\n  - [Configuration Commands](#configuration-commands)\n  - [Collages](#collages)\n  - [Bookmarks](#bookmarks)\n  - [Fetch Mode (-fm)](#fetch-mode--fm)\n  - [Database Commands](#database-commands)\n- [Examples](#examples)\n  - [Creating Collections](#creating-collections)\n  - [Updating Collections](#updating-collections)\n  - [Using Query Fetch Mode](#using-query-fetch-mode)\n- [Configuration Details](#configuration-details)\n- [Configuration Tips](#configuration-tips)\n- [Troubleshooting](#troubleshooting)\n- [Important Considerations](#important-considerations)\n- [Contributing](#contributing)\n\n---\n\n## Prerequisites\n\n- **Python 3.8 or higher**\n- **Plex Media Server** with a configured music library\n- **Active account** on RED and/or OPS with API access\n- **Music library** organized in your Plex server\n\n## Installation\n\n### Using pip (recommended)\n\n```bash\npip install red-plex\n```\n\n### Using pipx (isolated environment)\n\n```bash\npipx install red-plex\n```\n\n### From source\n\n```bash\ngit clone https://github.com/marceljungle/red-plex.git\ncd red-plex\npip install -e .\n```\n\n## Getting API Keys\n\n### For Redacted (RED)\n1. Log into your RED account\n2. Go to your profile settings\n3. Navigate to \"Access Settings\" or \"API\"\n4. Generate a new API key\n5. **Keep this key secure and private**\n\n### For Orpheus Network (OPS)\n1. Log into your OPS account\n2. Go to your user settings\n3. Find the API section\n4. Generate a new API key\n5. **Keep this key secure and private**\n\n## Configuration\n\nAfter installation, you need to configure red-plex with your credentials:\n\n```bash\n# Open configuration file in your default editor\nred-plex config edit\n```\n\nEdit the configuration file with your details:\n\n```yaml\nLOG_LEVEL: INFO\nPLEX_URL: http://localhost:32400\nPLEX_TOKEN: your_plex_token_here\nSECTION_NAME: Music\nRED:\n  API_KEY: your_red_api_key_here\n  BASE_URL: https://redacted.sh\n  RATE_LIMIT:\n    calls: 10\n    seconds: 10\nOPS:\n  API_KEY: your_ops_api_key_here\n  BASE_URL: https://orpheus.network\n  RATE_LIMIT:\n    calls: 4\n    seconds: 15\n```\n\n### Getting Your Plex Token\n\nVisit: https://plex.tv/api/resources?includeHttps=1&X-Plex-Token={YOUR_TOKEN}\n\n## Overview\n\n- **Stores Data in SQLite**: Instead of CSV-based \"caches,\" red-plex now stores albums, collages, and bookmarks in a lightweight SQLite database.\n- **Collages & Bookmarks**: Fetch and manage torrent-based \"collages\" or personal \"bookmarks\" from Gazelle-based sites.\n- **Plex Integration**: Compare the torrent group info with your Plex music library to create or update Plex collections.\n- **Flexible Album Matching**: Match albums in Plex using either the original `torrent_name` (directory name) or a query-based approach (`Artist/Album`), ideal for organized libraries (e.g., Beets/Lidarr).\n- **Incremental Updating**: Update previously created collections as new albums become available or site data changes.\n\n## Features\n\n- **Multi-Site**: Works with Redacted (\"red\") and Orpheus Network (\"ops\").\n- **Web Interface**: Modern Flask-based GUI with Bootstrap styling and real-time updates.\n- **Collections from Collages/Bookmarks**: Create or update entire Plex collections for each collage or bookmarked set.\n- **Local SQLite Database**: All data (albums, collages, bookmarks) is kept in one DB, no more CSV.\n- **Two Fetch Modes**: Choose between `torrent_name` (default) for direct path matching or `query` for metadata-based searches in Plex.\n- **Configurable Logging**: Choose between INFO, DEBUG, etc., in `config.yml`.\n- **Rate Limiting**: Respects site rate limits and retries on errors.\n- **Dual Interface**: Access all functionality via both command-line interface and web GUI.\n- **Python 3.8+ Compatible**: Runs on modern Python versions with no external database dependencies.\n\n## Usage & Commands\n\nType `red-plex --help` for detailed usage. Below is a summary of the main commands.\n\n### Web Interface Commands\n\n```bash\n# Launch web GUI server\nred-plex gui [--host HOST] [--port PORT] [--debug]\n\n# Examples:\nred-plex gui                           # Default: http://127.0.0.1:8000\nred-plex gui --host 0.0.0.0            # Bind to all interfaces\nred-plex gui --port 8080               # Custom port\nred-plex gui --debug                   # Debug mode with auto-reload\n```\n\n### Configuration Commands\n\n```bash\n# Show current configuration (YAML)\nred-plex config show\n\n# Edit configuration in your default editor\nred-plex config edit\n\n# Reset configuration to default values\nred-plex config reset\n```\n\n### Collages\n\n```bash\n# Create Plex collections for specific collage IDs\nred-plex collages convert [COLLAGE_IDS] --site [red|ops] --fetch-mode [torrent_name|query]\n\n# Update all collages in the database, re-checking the site data\nred-plex collages update --fetch-mode [torrent_name|query]\n```\n\n### Bookmarks\n\n```bash\n# Create Plex collections from your bookmarked releases\nred-plex bookmarks convert --site [red|ops] --fetch-mode [torrent_name|query]\n\n# Update all bookmarks in the database\nred-plex bookmarks update --fetch-mode [torrent_name|query]\n```\n\n### Fetch Mode (-fm)\n\nThe `--fetch-mode` (or `-fm`) option controls how red-plex locates albums in Plex:\n\n#### For all commands (`collages convert`, `collages update`, `bookmarks convert`, `bookmarks update`):\n- **torrent_name** (default): Searches for directories matching the torrent folder name\n- **query**: Searches using `Artist` and `Album` metadata, ideal for organized libraries managed by tools like Beets or Lidarr\n\n### Database Commands\n\n```bash\n# Show database location\nred-plex db location\n\n# Manage albums table\nred-plex db albums reset        # Clear all album records\nred-plex db albums update       # Pull fresh album info from Plex\n\n# Manage collections table\nred-plex db collections reset   # Clear the collage collections table\n\n# Manage bookmarks table\nred-plex db bookmarks reset     # Clear the bookmark collections table\n```\n\n## Examples\n\n### Creating Collections\n\n```bash\n# Single collage (Redacted), default mode\nred-plex collages convert 12345 --site red\n\n# Multiple collages (Orpheus), default mode\nred-plex collages convert 1111 2222 3333 --site ops\n\n# From bookmarks (RED or OPS), default mode\nred-plex bookmarks convert --site red\n```\n\n### Updating Collections\n\n```bash\n# Update all stored collages\nred-plex collages update\n\n# Update all stored bookmarks\nred-plex bookmarks update\n\n# Update albums from Plex\nred-plex db albums update\n```\n\n### Using Query Fetch Mode\n\n```bash\n# Create a collection using query mode (for Beets/Lidarr organized libraries)\nred-plex collages convert 12345 --site red --fetch-mode query\n\n# Update all bookmarks using query mode\nred-plex bookmarks update --site ops -fm query\n```\n\n### Complete Workflow Example\n\n#### Command Line Interface\n```bash\n# 1. First time setup\nred-plex config edit  # Add your API keys and Plex details\n\n# 2. Update your local album database from Plex\nred-plex db albums update\n\n# 3. Create collections from specific collages\nred-plex collages convert 12345 67890 --site red\n\n# 4. Create collection from your bookmarks\nred-plex bookmarks convert --site red\n\n# 5. Later, update all collections with new releases\nred-plex collages update\nred-plex bookmarks update\n```\n\n#### Web Interface\n```bash\n# 1. Launch the web interface\nred-plex gui\n\n# 2. Open http://127.0.0.1:8000 in your browser\n\n# 3. Navigate to Configuration to add your API keys and Plex details\n\n# 4. Use the Database page to update your local album database\n\n# 5. Use the Collages page to convert specific collages\n\n# 6. Use the Bookmarks page to convert your bookmarks\n\n# 7. Return to Database page later to update all collections\n```\n\n## Configuration Details\n\nBy default, configuration is stored in `~/.config/red-plex/config.yml`:\n\n```yaml\nLOG_LEVEL: INFO\nOPS:\n  API_KEY: your_ops_api_key_here\n  BASE_URL: https://orpheus.network\n  RATE_LIMIT:\n    calls: 4\n    seconds: 15\nPLEX_TOKEN: your_plex_token_here\nPLEX_URL: http://localhost:32400\nRED:\n  API_KEY: your_red_api_key_here\n  BASE_URL: https://redacted.sh\n  RATE_LIMIT:\n    calls: 10\n    seconds: 10\nSECTION_NAME: Music\n```\n\n## Configuration Tips\n\n- If HTTP fails, fetch an HTTPS URL:\n  ```\n  https://plex.tv/api/resources?includeHttps=1&X-Plex-Token={YOUR_TOKEN}\n  ```\n- Look for the `<Device>` node in the XML for a `uri`, use this `plex.direct` address.\n- Use `DEBUG` log level for verbose debugging information\n- Use `WARNING` log level for minimal output\n\n## Troubleshooting\n\n### Common Issues\n\n#### \"No module named 'plexapi'\" Error\n```bash\npip install plexapi\n# or\npip install red-plex --upgrade\n```\n\n#### Authentication Errors\n- Verify your API keys are correct in `config.yml`\n- Check that your Plex token is valid\n- Ensure you have access to the sites you're trying to use\n\n#### No Albums Found\n- Run `red-plex db albums update` to refresh your Plex library\n- Check that your Plex music library is properly configured\n- Verify the `SECTION_NAME` in your config matches your Plex music library name\n\n#### Rate Limiting Issues\n- The tool respects site rate limits automatically\n- If you encounter issues, try reducing the rate limit values in your config\n\n#### Fetch Mode Issues\n- Use `torrent_name` mode if your library structure matches torrent folder names\n- Use `query` mode if you use Beets, Lidarr, or have renamed your music files\n- Try both modes to see which works better for your library\n\n#### Web Interface Issues\n- **GUI won't start**: Ensure `gunicorn` and `eventlet` are installed: `pip install gunicorn eventlet`\n- **Can't access GUI**: Check if the port is available and not blocked by firewall\n- **GUI stuck on \"Starting...\"**: Check terminal logs for error messages\n- **WebSocket connection failed**: Ensure your browser supports WebSockets and isn't blocking them\n\n### Getting Help\n\n1. Check the logs with `LOG_LEVEL: DEBUG` in your config\n2. Verify your configuration with `red-plex config show`\n3. Test your Plex connection by running `red-plex db albums update`\n4. Open an issue on GitHub with detailed error messages\n\n## Important Considerations\n\n- **Album Matching Strategy**:\n  - `torrent_name` (default): Matches albums by comparing torrent folder names with Plex directory paths\n  - `query`: Uses artist and album metadata for matching, ideal for libraries organized by Beets, Lidarr, or other tools that rename files\n- **Database Management**: All data is stored in `red_plex.db`. Use database reset commands (`db albums reset`, etc.) to clear specific tables when needed\n- **Site Credentials**: Ensure your API keys are valid and have proper permissions\n- **Rate Limiting**: The tool automatically respects site-specific rate limits to avoid being banned\n- **Logging Levels**: \n  - `DEBUG`: Verbose output for troubleshooting\n  - `INFO`: Standard information (default)\n  - `WARNING`: Minimal output\n- **Collection Updates**: When you run `collages update` or `bookmarks update`, new albums are added to existing Plex collections, but removed items from tracker collages are not automatically removed from Plex collections\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.\n\n### Development Setup\n\n```bash\ngit clone https://github.com/marceljungle/red-plex.git\ncd red-plex\npip install -e .\n```\n\n---\n\n**Disclaimer**: This tool is for personal use with your own music library and tracker accounts. Respect the rules and terms of service of the private trackers you use.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A CLI and web GUI tool for creating Plex collections from RED and OPS collages and bookmarks",
    "version": "1.11.2",
    "project_urls": {
        "Bug Reports": "https://github.com/marceljungle/red-plex/issues",
        "Documentation": "https://github.com/marceljungle/red-plex#readme",
        "Homepage": "https://github.com/marceljungle/red-plex",
        "Source": "https://github.com/marceljungle/red-plex"
    },
    "split_keywords": [
        "plex",
        "music",
        "collections",
        "red",
        "ops",
        "redacted",
        "orpheus",
        "gazelle",
        "tracker"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "74b33cc3feacb32883da722532f79322284d8ebc68fb984257f652533facf13f",
                "md5": "793b3a076b0e22338f5cd0362698af33",
                "sha256": "a18e7d03ea8e4d92bc40b136e85844dd2cff4e3d2fcfbd7a294a376a64a2d977"
            },
            "downloads": -1,
            "filename": "red_plex-1.11.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "793b3a076b0e22338f5cd0362698af33",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 59077,
            "upload_time": "2025-07-15T21:26:10",
            "upload_time_iso_8601": "2025-07-15T21:26:10.431487Z",
            "url": "https://files.pythonhosted.org/packages/74/b3/3cc3feacb32883da722532f79322284d8ebc68fb984257f652533facf13f/red_plex-1.11.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "ac9d79c73686287c86e372b4f5f90ea30f566ccfefeb1616c9fbecdd967dbb99",
                "md5": "346a71d686d7f09736beb5beede9fec0",
                "sha256": "ff9f6c32603c4881cef885c14a901e9c1209b53d8c661b823064049d1902b252"
            },
            "downloads": -1,
            "filename": "red_plex-1.11.2.tar.gz",
            "has_sig": false,
            "md5_digest": "346a71d686d7f09736beb5beede9fec0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 50831,
            "upload_time": "2025-07-15T21:26:11",
            "upload_time_iso_8601": "2025-07-15T21:26:11.646515Z",
            "url": "https://files.pythonhosted.org/packages/ac/9d/79c73686287c86e372b4f5f90ea30f566ccfefeb1616c9fbecdd967dbb99/red_plex-1.11.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-15 21:26:11",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "marceljungle",
    "github_project": "red-plex",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [
        {
            "name": "plexapi",
            "specs": []
        },
        {
            "name": "requests",
            "specs": []
        },
        {
            "name": "pyrate-limiter",
            "specs": []
        },
        {
            "name": "tenacity",
            "specs": []
        },
        {
            "name": "click",
            "specs": []
        },
        {
            "name": "pyyaml",
            "specs": []
        },
        {
            "name": "flask",
            "specs": []
        },
        {
            "name": "flask-socketio",
            "specs": []
        },
        {
            "name": "gunicorn",
            "specs": []
        },
        {
            "name": "eventlet",
            "specs": []
        }
    ],
    "lcname": "red-plex"
}
        
Elapsed time: 1.12679s