A polished, 100% client-side web application for managing your TorBox media library. Built with React, TypeScript, and Vite.
- π Secure Authentication - TorBox API key stored locally in browser
- π Library Browser - View all your TorBox content with beautiful posters
- π Smart Search - Search for media and check cache availability
- π¨ Rich Metadata - Integration with TMDB for posters and details
- β‘ Offline Support - PWA with offline capability
- π± Fully Responsive - Mobile-first design that works everywhere
- RPDB Integration - Enhanced poster quality with RatingPosterDB
- Flexible Grid Views - Small, medium, or large poster grids
- Smart Filtering - Filter by type, search, and sort options
- Download Management - Download files directly from TorBox
- Real-time Sync - Always up-to-date with your TorBox library
- Framework: React 18 + TypeScript
- Build Tool: Vite
- Routing: React Router v6
- State Management: Zustand + TanStack Query
- Styling: Tailwind CSS
- Animations: Framer Motion
- Icons: Lucide React
- PWA: vite-plugin-pwa + Workbox
- Node.js 18+ and npm
- TorBox account with API key (Get one here)
- (Optional) TMDB API key for enhanced metadata (Get one here)
- (Optional) RPDB API key for premium posters (Get one here)
-
Clone the repository
git clone <repository-url> cd torbox-manager
-
Install dependencies
npm install
-
Configure environment (optional)
cp .env.example .env
Edit
.envand add your TMDB API key:VITE_TMDB_API_KEY=your_tmdb_api_key_hereNote: RPDB API key is configured in the app's Settings page, not in
.env -
Start development server
npm run dev
-
Build for production
npm run build
The built files will be in the
distfolder. -
Preview production build
npm run preview
- Open the app and you'll see the login page
- Enter your TorBox API key
- Click "Sign In"
- Your API key is validated and stored locally (never sent anywhere else)
- View Library: Browse all your TorBox content with rich metadata
- Filter & Sort: Use the controls to filter by type and sort by date/title/size
- View Details: Click any poster to see full details, files, and actions
- Download: Click the download button to get direct download links
- Remove: Remove items from your TorBox library
- Search for any movie or TV show by title
- Include year for better results: "Inception 2010"
- Search by IMDB ID: "tt1375666"
- See cache status instantly
- Add uncached items to TorBox (requires torrent/magnet integration)
- RPDB Posters: Enable and configure RPDB for enhanced posters
- Grid Size: Choose small, medium, or large poster grids
- Show Badges: Toggle cache status and media type badges
- Poster Priority: Set your preferred poster source
π Your data stays on your device:
- API keys are stored in browser localStorage only
- No backend server - all API calls are made directly from your browser
- No analytics or tracking
- No data is sent to third parties (except TorBox, TMDB, and RPDB APIs)
The TorBox API does not support direct browser requests due to CORS restrictions. This is expected and a known limitation of client-side applications.
Option 1: Browser Extension (Easiest for Development)
- Install a CORS unblock extension:
- Chrome: Allow CORS: Access-Control-Allow-Origin
- Firefox: CORS Everywhere
- Enable the extension for
https://api.torbox.app - Refresh the page and try logging in again
Option 2: Chrome with CORS Disabled (Development Only)
# macOS/Linux
google-chrome --disable-web-security --user-data-dir=/tmp/chrome-dev
# Windows
"C:\Program Files\Google\Chrome\Application\chrome.exe" --disable-web-security --user-data-dir=C:\tmp\chrome-devOption 3: Deploy with Reverse Proxy (Production)
For production deployment, use the included Cloudflare Worker that's ready to deploy directly from this GitHub repository.
π Quick Deploy (Choose One):
A) Automatic Git Deployment (Recommended)
- Go to Cloudflare Dashboard β Workers & Pages
- Click Create β Workers β Connect to Git
- Select this repository:
iPraBhu/torbox-manager - Cloudflare auto-detects
wrangler.tomland deploys your worker - Copy your worker URL:
https://torbox-proxy.YOUR-SUBDOMAIN.workers.dev - Update
src/lib/torbox/client.tsline 4 with your worker URL - Done! Future pushes auto-deploy both app and worker
B) GitHub Actions (CI/CD)
- Get Cloudflare API Token from here
- Add to repo secrets:
CLOUDFLARE_API_TOKENandCLOUDFLARE_ACCOUNT_ID - Push to main - GitHub Actions deploys automatically
- See
.github/workflows/deploy-worker.ymlfor details
C) Manual CLI Deploy
npm install
npm run deploy:worker # Deploys immediatelySee WORKER_DEPLOYMENT.md for complete instructions, GitHub Actions setup, custom domains, and monitoring.
- Double-check your API key from TorBox settings
- Ensure no extra spaces when pasting
- Try generating a new API key
- Without TMDB: You'll see placeholder icons instead of posters
- Add TMDB Key: Get a free API key from TMDB and add to
.env - RPDB Not Working: Verify your RPDB API key in Settings
- Check browser console for errors (F12)
- Verify your TorBox account has content
- Try the refresh button
- Clear browser cache and reload
src/
βββ components/ # React components
β βββ Layout.tsx
β βββ Navbar.tsx
β βββ MediaGrid.tsx
β βββ MediaCard.tsx
β βββ MediaDetailModal.tsx
β βββ SearchResults.tsx
βββ pages/ # Page components
β βββ LoginPage.tsx
β βββ LibraryPage.tsx
β βββ SearchPage.tsx
β βββ SettingsPage.tsx
βββ lib/ # API clients and utilities
β βββ torbox/
β β βββ client.ts
β β βββ endpoints.ts
β βββ search/
β βββ tmdb.ts
β βββ rpdb.ts
β βββ resolver.ts
βββ stores/ # Zustand stores
β βββ authStore.ts
β βββ settingsStore.ts
βββ types/ # TypeScript types
β βββ index.ts
βββ App.tsx # Main app component
βββ main.tsx # Entry point
βββ index.css # Global styles
- TorBox: https://api.torbox.app/docs
- TMDB: https://developers.themoviedb.org/3
- RPDB: https://ratingposterdb.com
The codebase is structured for easy extension:
- New API endpoint: Add to
src/lib/torbox/endpoints.ts - New metadata source: Create provider in
src/lib/search/ - New page: Add component in
src/pages/and route inApp.tsx - New setting: Update types and add to
SettingsPage.tsx
- Torrent Search: Search page shows results but doesn't include torrent search (requires integration with torrent indexers)
- Streaming: No built-in streaming player (downloads only)
- Batch Operations: No multi-select for batch actions
- Real-time Updates: Uses polling instead of WebSocket for status updates
Contributions are welcome! Please feel free to submit a Pull Request.
MIT License - feel free to use this project for personal or commercial purposes.
This is a library management tool for content you own or are authorized to access. The developers are not responsible for how you use this software. Please respect copyright laws and terms of service.
- TorBox Support: https://torbox.app/support
- Issues: Open an issue on GitHub
- Documentation: See inline code comments
Built with β€οΈ using React, TypeScript, and Vite