-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.example
More file actions
88 lines (73 loc) · 3.2 KB
/
Copy path.env.example
File metadata and controls
88 lines (73 loc) · 3.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
# Twitter/X Authentication (Required for X Spaces)
# Get these from your browser's cookies at x.com
TWITTER_AUTH_TOKEN=your_auth_token_here
TWITTER_CT0=your_ct0_cookie_here
# Or use a Netscape format cookie file instead
# TWITTER_COOKIE_FILE=/path/to/cookies.txt
# Twitter bearer token (optional - uses public web client token by default)
# Only override if Twitter changes their public token
# TWITTER_BEARER_TOKEN=AAAA...
# Telegram Bot (Optional)
# Get this from @BotFather on Telegram
TELEGRAM_BOT_TOKEN=your_telegram_bot_token_here
# Webhook mode requires a secret token (validates incoming Telegram requests).
# Only needed when TELEGRAM_BOT_MODE=webhook.
TELEGRAM_WEBHOOK_SECRET=
# Server Configuration
HOST=127.0.0.1 # Use 0.0.0.0 to expose to network
PORT=8000
# API Authentication (Optional)
# If set, all API requests require X-API-Key header
# Leave unset for open access (recommended for local use)
# API_KEY=your-secret-key-here
# Encryption key for secrets at rest (required for production)
# Encrypts stored API keys; if unset, a guessable key is derived from
# DOWNLOAD_DIR. Generate one with: openssl rand -hex 32
ENCRYPTION_KEY=
# CORS Origins (comma-separated, or "*" for all)
# Default: localhost dev servers
CORS_ORIGINS=http://localhost:5173,http://localhost:3000
# Rate Limiting
RATE_LIMIT=60/minute
RATE_LIMIT_ENABLED=true
# Request Timeout (seconds)
REQUEST_TIMEOUT=300
# Sentry Error Tracking (optional)
# Get DSN from https://sentry.io
# SENTRY_DSN=https://xxx@xxx.ingest.sentry.io/xxx
# SENTRY_ENVIRONMENT=production
# SENTRY_TRACES_SAMPLE_RATE=0.1
# Download Settings
DOWNLOAD_DIR=/tmp/xdownloader
MAX_CONCURRENT_DOWNLOADS=5
CLEANUP_AFTER_HOURS=24
# YouTube (Optional)
# Only needed when YouTube blocks the server IP ("Sign in to confirm you're
# not a bot" / HTTP 429) or for age-restricted videos.
# Read fresh cookies straight from a local browser (takes precedence):
# YOUTUBE_COOKIES_FROM_BROWSER=chrome
# ...or export a Netscape cookies.txt while logged in:
# YOUTUBE_COOKIES_FILE=/path/to/youtube.com_cookies.txt
# Instagram (Optional)
# Required to download most Instagram reels/posts (Instagram gates content
# behind login). See docs/instagram-setup.md for a no-coding walkthrough.
# Export a Netscape cookies.txt while logged in, then set its path here:
# INSTAGRAM_COOKIES_FILE=/path/to/instagram.com_cookies.txt
# (Advanced/Linux) read cookies directly from a local browser instead:
# INSTAGRAM_COOKIES_FROM_BROWSER=chrome
# Spotify Transcript (Optional)
# Required for fetching Spotify Read Along transcripts
# 1. Open https://open.spotify.com and log in
# 2. Open DevTools (F12) → Application tab → Cookies → https://open.spotify.com
# 3. Copy the value of the "sp_dc" cookie
# SPOTIFY_SP_DC=your_sp_dc_cookie_here
# Speaker Diarization (Optional)
# Required for identifying different speakers in transcriptions
# 1. Get token: https://huggingface.co/settings/tokens (Read access)
# 2. Accept model terms:
# - https://huggingface.co/pyannote/speaker-diarization-3.1
# - https://huggingface.co/pyannote/segmentation-3.0
# 3. Install: uv sync --extra diarize
# Option A: Set token here
HUGGINGFACE_TOKEN=REPLACE_WITH_YOUR_TOKEN
# Option B: Or run `huggingface-cli login` instead (no need to set token here)