Skip to content

Examples and Use Cases

Christian Blank edited this page Nov 8, 2024 · 1 revision

Examples and Use Cases

Basic Usage Examples

Adding a TV Show

You: /tv Breaking Bad
Bot: 🔍 Breaking Bad (2008)
     Rating: 9.5/10
     Status: Ended
     Network: AMC
     
     Description: A high school chemistry teacher turned methamphetamine manufacturer 
     partners with a former student to secure his family's financial future.

     [Add All Seasons] [Select Seasons] [Cancel]

You: *clicks [Add All Seasons]*
Bot: ✅ Added Breaking Bad to Sonarr
     All seasons will be monitored

Adding a Movie

You: /movie Inception
Bot: 🎬 Inception (2010)
     Rating: 8.8/10
     Director: Christopher Nolan
     Runtime: 2h 28min
     
     Description: A thief who steals corporate secrets through dream-sharing technology 
     is given the inverse task of planting an idea into the mind of a C.E.O.

     [Add Movie] [Cancel]

You: *clicks [Add Movie]*
Bot: ✅ Added Inception to Radarr
     Quality profile: HD-1080p

Advanced Use Cases

Managing Multiple Quality Profiles

# config.ini
[sonarr]
quality_profiles = HD-1080p, HD-720p, SD
default_profile = HD-1080p

[radarr]
quality_profiles = Remux-1080p, Web-1080p, HD-720p
default_profile = Web-1080p

Setting Up Notifications

# config.ini
[telegram]
notify_on_grab = true
notify_on_download = true
notify_on_upgrade = true
notification_format = {title} ({quality}) - {status}

Example notifications:

🔍 Grabbed: Breaking Bad S01E01 (1080p WEB-DL)
✅ Downloaded: Inception (1080p BluRay)
⬆️ Upgraded: The Matrix (2160p UHD BluRay)

Common Workflows

Weekly Show Management

  1. Check upcoming episodes:
You: /upcoming
Bot: Upcoming Episodes:
     - Show1 S02E05 - Tomorrow
     - Show2 S01E08 - In 2 days
     - Show3 S04E01 - Next week

Movie Library Organization

  1. Check your movie list:
You: /mymovies
Bot: Your Movie Collection:
     🎬 Recently Added:
     - Inception (2010)
     - The Dark Knight (2008)
     
     🔜 Pending Download:
     - Interstellar (2014)

Automation Examples

Using Webhooks

# config.ini
[webhooks]
enabled = true
url = https://discord.webhook.url
events = grab,download

# Example webhook payload
{
    "event": "download",
    "title": "Breaking Bad",
    "season": 1,
    "episode": 1,
    "quality": "1080p"
}

Custom Scripts Integration

#!/bin/bash
# post-add.sh
# Example script that runs after adding content

TITLE="$1"
TYPE="$2"

# Log addition
echo "[$(date)] Added $TYPE: $TITLE" >> /var/log/addarr/additions.log

# Send notification to another service
curl -X POST "https://notify.example.com" -d "title=$TITLE&type=$TYPE"

Best Practice Examples

Organized Search Patterns

Good searches:
/tv "Breaking Bad" 2008
/movie "The Matrix" 1999

Avoid:
/tv breaking bad
/movie matrix

Quality Profile Strategy

# For 4K TV:
[sonarr]
quality_profile = 4K-HDR
root_folder = /media/tv/4K

# For standard HD:
[sonarr]
quality_profile = HD-1080p
root_folder = /media/tv/HD

Troubleshooting Examples

Common Error Scenarios

Error: Connection refused
Solution: Check if Sonarr/Radarr is running
Command: docker ps (for Docker installs)

Error: Unauthorized
Solution: Verify admin ID in config.ini
Command: /start (to check authorization)

Debug Mode Examples

[logging]
debug = true
log_level = DEBUG
log_file = /config/addarr.log

# Example debug log output:
2024-01-01 12:00:00 DEBUG: Searching for "Breaking Bad"
2024-01-01 12:00:01 DEBUG: Found 3 results
2024-01-01 12:00:02 DEBUG: Selected quality profile: HD-1080p

Docker Deployment Examples

Basic Docker Setup

docker run -d \
  --name=addarr \
  -v /path/to/config:/config \
  -e TZ=Europe/London \
  --restart unless-stopped \
  cyneric/addarr

Docker Compose Example

version: '3'
services:
  addarr:
    image: cyneric/addarr
    container_name: addarr
    volumes:
      - /path/to/config:/config
    environment:
      - TZ=Europe/London
    restart: unless-stopped

Clone this wiki locally