Skip to content

Filter and redirect media requests based on requester, keywords, age ratings, and more. Supports routing to multiple instances simultaneously.

varthe/Redirecterr

Repository files navigation

Redirecterr

Docker Compose

services:
  redirecterr:
    image: varthe/redirecterr:latest
    container_name: redirecterr
    hostname: redirecterr
    ports:
      - 8481:8481
    volumes:
      - /path/to/config.yaml:/config/config.yaml
      - /path/to/logs:/logs
    environment:
      - LOG_LEVEL=info

Webhook setup

Important

Disable automatic request approval for your users

In Overseerr go to Settings -> Notifications -> Webhook and configure the following:

  • Enable Agent: Enabled
  • Webhook URL: http://redirecterr:8481/webhook
  • Notification Types: Select Request Pending Approval
  • JSON Payload:
    {
    	"notification_type": "{{notification_type}}",
    	"media": {
    		"media_type": "{{media_type}}",
    		"tmdbId": "{{media_tmdbid}}",
    		"status": "{{media_status}}",
    		"status4k": "{{media_status4k}}"
    	},
    	"request": {
    		"request_id": "{{request_id}}",
    		"requestedBy_email": "{{requestedBy_email}}",
    		"requestedBy_username": "{{requestedBy_username}}"
    	},
    	"{{extra}}": []
    }

Config

Create a config.yaml file with the following sections:

Overseerr settings

overseerr_url: ""
overseerr_api_token: ""
approve_on_no_match: true # Auto-approve if no filters match

Instances

Define your Radarr/Sonarr instances

instances:
  radarr:
    server_id: 0 # Match the order in Overseerr > Settings > Services (example below)
    root_folder: /mnt/movies
    # quality_profile_id: 1  # Optional
    # approve: false         # Optional (default is true)
  • server_id: Starts at 0, increases left to right in Overseerr UI. Visual example

  • quality_profile_id (Optional): Override Overseerr default. Get IDs from:

    http://<arr-url>/api/v3/qualityProfile?apiKey=<api-key>
    
  • approve: Set to false to disable auto-approval.

Filters

Filters route requests based on conditions.

filters:
  - media_type: movie
    # is_4k: true  # Optional
    conditions:
      keywords:
        include: ["anime", "animation"]
      contentRatings:
        exclude: [12, 16]
      requestedBy_username: user
      max_seasons: 2
    apply: radarr_anime

Fields

  • media_type: movie or tv
  • is_4k (Optional): Set to true to only match 4K requests. Set to false to only match non-4k requests. Leave empty to match both.
  • conditions:
    • field:
      • require: All values must match
      • exclude: None of the values must match
      • include: At least one value matches
  • apply: One or more instance names

Tip

For a list of possible condition fields see fields.md

Sample config

overseerr_url: ""
overseerr_api_token: ""

approve_on_no_match: true

instances:
  sonarr:
    server_id: 0
    root_folder: "/mnt/plex/Shows"
  sonarr_4k:
    server_id: 1
    root_folder: "/mnt/plex/Shows - 4K"
  sonarr_anime:
    server_id: 2
    root_folder: "/mnt/plex/Anime"

filters:
  # Send anime to sonarr_anime
  - media_type: tv
    conditions:
      keywords: anime
    apply: sonarr_anime

  # Send everything else to sonarr and sonarr_4k instances
  - media_type: tv
    apply: ["sonarr", "sonarr_4k"]

About

Filter and redirect media requests based on requester, keywords, age ratings, and more. Supports routing to multiple instances simultaneously.

Topics

Resources

Stars

Watchers

Forks