clickndebrid v1.1.2
ClicknDebrid
A modern Node.js Click'n'Load proxy server that converts links via debrid services and forwards them to download managers. ClicknDebrid sits between file hosting sites and your download manager, automatically processing links through premium debrid services to unlock faster downloads without captchas or speed limits.
Features
- Click'n'Load Integration: Intercepts CNL2 requests for link processing
- Debrid Service Support: Converts links using Real-Debrid API
- Admin Dashboard: Modern web interface for package management
- Responsive Design: Dark-themed UI with Tailwind CSS
- Flexible Storage: Redis or in-memory caching
Key Benefits
- Automatic Processing: No manual copy-pasting of links between services
- Premium Features: Get full download speeds without site restrictions
- Centralized Management: View all packages and their processing status in the admin UI
- Self-Hosted: Complete control over your data and downloads
- Extensible: Support for multiple debrid services (currently Real-Debrid, more planned)
Prerequisites
- Node.js 20.x or higher
- npm 10.x or higher
- Redis (optional, for production use)
Installation
From Source
# Clone the repository
git clone https://github.com/XaverLeet/clickndebrid.git
# Navigate to the project directory
cd clickndebrid
# Install dependencies
npm install
# Start the application
npm startUsing Docker
Single Container
# Build the image
docker build -t clickndebrid .
# Run the container
docker run --rm -p 127.0.0.1:9666:9666 \
-e CND_REALDEBRID_APITOKEN=YOUR_API_TOKEN \
-e CND_DESTINATION_URL=http://192.168.1.1:9666 \
clickndebridDocker Compose (Recommended)
# Start with docker-compose
docker compose up -dFind a docker-compose.yml example in the docker-compose.yml file.
services:
app:
build:
dockerfile: Dockerfile
restart: unless-stopped
user: 1000:1000
ports:
- 127.0.0.1:9666:9666
environment:
- "CND_DEBRIDSERVICE=realdebrid"
- "CND_REALDEBRID_APITOKEN="
# Click'n'Load Destination (e.g. PyLoad)
- "CND_DESTINATION_URL=http://localhost:9666"
- "CND_PORT=9666"
# Redis Configuration
- "CND_REDIS_ENABLED=true"
- "CND_REDIS_URL=redis://redis:6379"
- "CND_REDIS_USERNAME="
- "CND_REDIS_PASSWORD="
- "CND_REDIS_TTL=360000"
# Logger Configuration
- "CND_LOG_LEVEL=info"
redis:
image: redis:alpine
restart: unless-stopped
volumes:
- ./redis:/dataConfiguration
Environment Variables
| Variable | Description | Default |
|---|---|---|
NODE_ENV | Node.js environment | development |
CND_DEBRIDSERVICE | Debrid service to use (e.g., realdebrid) | realdebrid |
CND_REALDEBRID_APITOKEN | Real-Debrid API token | required |
CND_DESTINATION_URL | URL of the Click'n'Load server | required |
CND_PORT | Port for the server | 9666 |
CND_REDIS_ENABLED | Enable Redis cache | false |
CND_REDIS_URL | Redis server URL | redis://localhost:6379 |
CND_REDIS_USERNAME | Redis username | |
CND_REDIS_PASSWORD | Redis password | |
CND_REDIS_TTL | Time-To-Live for cached object | 360000 |
CND_LOG_LEVEL | Logging level (debug, info, warn, error) | info |
Configuration Methods
- Environment Variables: Set directly in your environment
- Dotenv File: Create a
.envfile based on.env.example - Docker Environment: Pass as environment variables to Docker
Usage & How It Works
Interception: When a user clicks a Click'n'Load button on a website, instead of sending the encrypted package to the default CNL port (9666), it's sent to ClicknDebrid running on the same port.
Decryption: ClicknDebrid decrypts the Click'n'Load package to extract the original links.
Link Conversion: The extracted links are sent to configured debrid service (e.g., Real-Debrid) which returns unrestricted links with direct access to the files. This converts premium-only links into direct download links accessible at full speed.
Forwarding: ClicknDebrid forwards these unrestricted links to your configured download manager (e.g., PyLoad, JDownloader, etc.).
Storage: Package information and processing results are stored in Redis (or memory cache if Redis is disabled) for management via the admin interface.
Admin Interface
Access the admin interface at /admin to:
- View all packages
- Delete packages
- Re-Process packages with debrid service
- Re-Submit packages to your download manager
Development
# Start development server with hot reloading
npm run dev
# Build the production version
npm run build
# Run tests
npm test
# Format code
npm run format
# Run linter
npm run lintArchitecture
See Architecture Documentation for details on the project structure and components.
Contributing
- Fork the repository
- Create your feature branch:
git checkout -b feature/amazing-feature - Commit your changes using conventional commits:
git commit -m "feat: add amazing feature" - Push to the branch:
git push origin feature/amazing-feature - Open a Pull Request
License
This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details.