Skip to content
kasundigitalPublic

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

Β 

History

43 Commits

Folders and files

Repository files navigation

🎬 ArrRelay

Discord requests β†’ smart validation β†’ Radarr / Sonarr β†’ private Telegram review

A lightweight, self-hosted media request relay built for Docker.

Docker Python Discord Telegram Radarr Sonarr Port Open Source

Features β€’ How it works β€’ Install β€’ Configuration β€’ Support


Buy Me a Coffee

✨ What is ArrRelay?

ArrRelay is a free, open-source automation service that watches selected Discord channels for movie and series requests.

It validates each request, routes movies to Radarr and series to Sonarr, and sends anything uncertain or broken to a private Telegram admin review flow.

πŸ’¬ Discord is the request inbox.
🎬 Radarr / Sonarr handle media automation.
πŸ“² Telegram is the private review console.
πŸ” ArrRelay connects everything together.


πŸš€ Features

Feature Description
🐳 Docker-first Simple Docker / Docker Compose deployment
πŸ” Admin-only dashboard First-run admin setup and protected login
🌐 Web UI on port 3032 Manage integrations and view activity from the browser
πŸ’¬ Discord listener Watches only the servers/channels you configure
🧠 Request validation Requires Movie/Series + Title + Year before automatic processing
🎬 Radarr integration Movie lookup, duplicate detection, add and search
πŸ“Ί Sonarr integration Series lookup, duplicate detection, add and search
πŸ“² Telegram review Ambiguous matches and errors are sent privately to the admin
βœ… Telegram actions Select the correct result or cancel directly from Telegram
πŸ” Duplicate protection Prevents adding media that already exists
πŸ—ƒοΈ SQLite history Request history survives Docker restarts
πŸ“Š Usage dashboard Tracks requests, additions, failures and review activity
πŸ“₯ Library statistics Shows Radarr movies and Sonarr episode download totals
πŸ§ͺ Dry Run mode Test safely without actually adding or downloading media
πŸ“± Responsive UI Designed for desktop and mobile
β˜• Built-in support link Optional Buy Me a Coffee button for the project

🧭 How it works

flowchart LR
    A[πŸ’¬ Discord Request] --> B{ArrRelay Validation}

    B -->|Missing type / year| C[βœ‰οΈ Ask Requester]
    B -->|Movie| D[🎬 Search Radarr]
    B -->|Series| E[πŸ“Ί Search Sonarr]

    D --> F{Clear Match?}
    E --> F

    F -->|Yes| G[βœ… Add + Search]
    F -->|No| H[πŸ“² Telegram Review]

    H --> I[Select Correct Result]
    H --> J[❌ Cancel]

    I --> G
    G --> K[πŸ“Š Save Request History]
Loading

Request flow

Discord
   β”‚
   β–Ό
ArrRelay
   β”‚
   β”œβ”€β”€ Missing information ───────► Ask requester
   β”‚
   β”œβ”€β”€ Movie + clear match ───────► Radarr β–Ί Add + Search
   β”‚
   β”œβ”€β”€ Series + clear match ──────► Sonarr β–Ί Add + Search
   β”‚
   └── Ambiguous / error ─────────► Telegram Admin
                                      β”‚
                                      β”œβ”€β”€ Select result
                                      └── Cancel

πŸ’¬ Request format

ArrRelay is deliberately conservative. A request should contain:

  • Type β€” Movie or Series
  • Title
  • Year

βœ… Good requests

Movie: No Time to Die (2021)
Series: FBI (2018)
Chicago PD (2014) - Series

⚠️ Missing information

The Drop

ArrRelay will not guess and download something automatically.

Instead, it asks the requester for the missing information:

Please include the type, title and year.

Movie: Title (Year)
Series: Title (Year)

πŸ“² Telegram review

When ArrRelay cannot confidently identify the correct item, the request is sent to your private Telegram bot.

Example:

⚠️ ArrRelay review required

Movie: The Drop (2026)
Best confidence: 78%

Select the correct result or cancel.

Telegram buttons allow the administrator to:

  • βœ… Select the correct movie or series
  • ❌ Cancel the request
  • 🚨 Receive lookup/add errors

Only the configured Telegram Admin Chat ID is authorized to approve requests.


πŸ“Š Admin dashboard

The dashboard is available at:

http://YOUR-SERVER-IP:3032

It currently shows:

Metric Purpose
πŸ“₯ Total Requests All requests ArrRelay has received
🎬 Movie Requests Requests routed toward Radarr
πŸ“Ί Series Requests Requests routed toward Sonarr
⚠️ Needs Review Requests waiting for manual attention
βœ… Added Successfully added items
❌ Failed Requests that failed
🎞️ Radarr Movies Total movies currently in Radarr
πŸ’Ύ Downloaded Movies Radarr movies that already have files
πŸ“‘ Sonarr Series Total series currently in Sonarr
πŸ“Ί Episodes Downloaded vs total episodes
🟒 Discord Listener Current bot/listener status
πŸ•˜ Recent Requests Latest request activity

🐳 Docker quick start

ArrRelay is designed so Discord, Telegram, Radarr and Sonarr credentials are entered in the browser wizard β€” not in the Docker command.

Option A β€” Docker Run

mkdir -p /opt/arrrelay/data

docker run -d \
  --name arrrelay \
  --restart unless-stopped \
  -p 3032:3032 \
  -v /opt/arrrelay/data:/data \
  ghcr.io/kasundigital/arrrelay:latest

Then open:

http://YOUR-SERVER-IP:3032

That's it. ArrRelay automatically creates and stores its own persistent application secret under /data.

Option B β€” Docker Compose

mkdir -p /opt/arrrelay && cd /opt/arrrelay
curl -fsSLO https://raw.githubusercontent.com/kasundigital/ArrRelay/main/docker-compose.yml
docker compose up -d

Open:

http://YOUR-SERVER-IP:3032

Update later

Docker Compose:

cd /opt/arrrelay
docker compose pull
docker compose up -d

Docker Run:

docker pull ghcr.io/kasundigital/arrrelay:latest
docker stop arrrelay
docker rm arrrelay

Then run the same docker run command again. Your settings remain in /opt/arrrelay/data.

Build from source

Developers who want to build the current source locally can use:

git clone https://github.com/kasundigital/ArrRelay.git
cd ArrRelay
docker compose -f docker-compose.build.yml up -d --build

βš™οΈ First-run setup

The first time you open ArrRelay, a 6-step setup wizard collects everything the application needs:

  1. πŸ” Admin account

    • Admin username
    • Admin password
  2. πŸ’¬ Discord

    • Bot token
    • Server / Guild ID
    • Request channel ID(s)
    • Private-DM or temporary channel-reply mode
  3. πŸ“² Telegram

    • Bot token
    • Admin Chat ID
  4. 🎬 Radarr

    • URL
    • API key
    • Root folder
    • Quality profile ID
  5. πŸ“Ί Sonarr

    • URL
    • API key
    • Root folder
    • Quality profile ID
  6. πŸ§ͺ Automation

    • Match confidence
    • Dry Run

All integration values are stored in the persistent ArrRelay SQLite database under /data.

Recommended: leave Dry Run enabled until Discord β†’ ArrRelay β†’ Radarr/Sonarr β†’ Telegram has been tested successfully.

πŸ“˜ Don't know where to get the tokens or IDs?

Use the detailed setup guide:

FIRST-RUN-SETUP.md β†’ Discord token, Server ID, Channel ID, Telegram Chat ID, Radarr/Sonarr API keys and more

The same help link is available directly from the ArrRelay wizard and Settings page.


πŸ’¬ Discord requirements

Your Discord bot should have only the permissions it needs for the configured request channels:

  • πŸ‘οΈ View Channel
  • πŸ“š Read Message History
  • βœ‰οΈ Send Messages β€” only if using channel replies
  • πŸ“ Message Content Intent enabled in the Discord Developer Portal

For a quieter setup, choose:

DM requester privately

in ArrRelay settings.

Discord does not support a normal channel message that is visible only to one regular user. Use DM mode when strict privacy is required.


πŸ” Security

ArrRelay is designed to keep administration private.

Recommended

  • πŸ”‘ Never commit your .env file
  • πŸ”’ Never expose Discord / Telegram / Radarr / Sonarr API keys
  • πŸ§‚ Change APP_SECRET before deployment
  • 🌐 Use HTTPS behind a reverse proxy for internet access
  • 🏠 Keep the dashboard LAN/VPN-only where possible
  • πŸ“² Use only your private Telegram Chat ID for approval
  • πŸ§ͺ Start with DRY_RUN=true

πŸ—ƒοΈ Persistent data

ArrRelay stores application data in SQLite:

/data/arrrelay.db

Docker Compose maps:

./data:/data

This preserves:

  • Admin account
  • Integration settings
  • Request history
  • Request statuses
  • Dashboard statistics

across container recreation.


πŸ“ Project structure

ArrRelay/
β”œβ”€β”€ app/
β”‚   β”œβ”€β”€ main.py
β”‚   β”œβ”€β”€ web.py
β”‚   β”œβ”€β”€ runtime.py
β”‚   β”œβ”€β”€ discord_bot.py
β”‚   β”œβ”€β”€ telegram_bot.py
β”‚   β”œβ”€β”€ service.py
β”‚   β”œβ”€β”€ parser.py
β”‚   β”œβ”€β”€ arr_client.py
β”‚   β”œβ”€β”€ database.py
β”‚   β”œβ”€β”€ settings_store.py
β”‚   β”œβ”€β”€ models.py
β”‚   β”œβ”€β”€ config.py
β”‚   β”œβ”€β”€ templates/
β”‚   └── static/
β”œβ”€β”€ tests/
β”œβ”€β”€ data/
β”œβ”€β”€ Dockerfile
β”œβ”€β”€ docker-compose.yml
β”œβ”€β”€ requirements.txt
└── README.md

πŸ›£οΈ Roadmap

  • Discord request listener
  • Movie / Series / Year validation
  • Radarr lookup and add
  • Sonarr lookup and add
  • Telegram review buttons
  • Admin-only dashboard
  • Browser-based settings
  • Docker deployment
  • Request statistics
  • Buy Me a Coffee support link
  • Persist Telegram review candidates across container restarts
  • Better natural-language request parsing
  • Requester follow-up context
  • Playback/problem report detection
  • Additional dashboard charts
  • Release tags and upgrade instructions

🀝 Contributing

Contributions, bug reports and feature requests are welcome.

If you find a problem, open a GitHub issue with:

  • ArrRelay version / commit
  • Docker logs
  • Expected behavior
  • Actual behavior
  • Radarr / Sonarr version where relevant

Please never include API keys, bot tokens or passwords in an issue.


β˜• Support ArrRelay

ArrRelay is free and open source.

If ArrRelay saves you time or you would like to support continued development:

Buy Me a Coffee

Support free and open-source development of ArrRelay.

The same support option is available from the ArrRelay admin interface.


πŸ‘¨β€πŸ’» Author

Kasun Indika
GitHub: @kasundigital


🎬 ArrRelay

Discord β†’ Radarr / Sonarr β†’ Telegram

Built for self-hosters who want simple, controlled media request automation.

⭐ If ArrRelay is useful to you, consider starring the repository.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages