Setup guide

AllDebrid redirector setup

AllDebrid blocks the TPB 4K Porn addon server's datacenter IP, and its API has no way to forward your IP. So AllDebrid resolves through a small redirector running on your own machine. The Stremio player hits it from your residential IP, and it runs the full AllDebrid flow and hands the player the CDN link.

Why a redirector

Real-Debrid and TorBox let the addon server resolve on your behalf by forwarding your IP. AllDebrid's /magnet/upload and /link/unlock endpoints return MAGNET_NO_SERVER when called from a datacenter IP, and there is no IP parameter. The only reliable way to originate AllDebrid calls from your residential IP is to run a tiny HTTP service on your machine that the Stremio player calls directly. The addon server makes zero AllDebrid API calls.

1. Get your AllDebrid API key

Sign in at alldebrid.com/apikeys and copy your API key.

2. Run the redirector

A single-file Python reference is shipped with the addon. Download it:

curl -O https://adult-addons.click/redirector/alldebrid_redirector.py

Install its three dependencies and start it:

pip install fastapi uvicorn requests
uvicorn alldebrid_redirector:app --port 8282

It now listens on http://localhost:8282. The reference is a minimal FastAPI app: it takes a magnet, uploads it to AllDebrid, polls until ready, picks the largest video file, unlocks the link, and 302-redirects the player to the CDN URL. On any error or while the torrent is still downloading, it redirects to a short caching clip so playback never errors out. You can read and audit the file before you run it.

You can also write your own in any language. The contract the addon expects is:

GET /play?apikey=<ad_key>&magnet=<magnet_uri>&t=<title>&caching=<fallback_url>
-> 302 to the AllDebrid CDN link, or 302 to <fallback_url> on error / while downloading

3. Point the addon at it

Open the TPB 4K Porn configure page. In the Debrid Providers card:

  • Paste your AllDebrid API key into the AllDebrid API key field.
  • An AllDebrid redirector URL field appears. Set it to http://localhost:8282 (or wherever your redirector runs).

Save and (re)install. AllDebrid streams now resolve through your redirector. Other debrid providers you have configured are unaffected.

4. Verify

Play an AllDebrid stream in Stremio. The redirector's console will log AllDebrid API calls from your residential IP, and Stremio will play the CDN link. An uncached magnet may show the caching clip first, then play on retry. If no stream appears at all, make sure both the API key and the redirector URL are set in the configure page.

More questions

Why does AllDebrid need a redirector when Real-Debrid and TorBox do not?
AllDebrid's magnet upload and link unlock endpoints reject datacenter IPs with a MAGNET_NO_SERVER error, and the API has no parameter to forward your IP. Real-Debrid and TorBox both support IP forwarding, so the addon server can resolve on your behalf. AllDebrid cannot, so the call has to come from your residential IP through a small local redirector.
Does the addon server ever see my AllDebrid API key?
Your API key is stored in your install URL config and placed into the stream URL that the Stremio player sends to your local redirector. The addon server never makes an AllDebrid API call. The key travels between your player and your redirector, both on your own machine.
Can I run the redirector on a remote VPS instead of my own machine?
You can, but then AllDebrid sees the VPS IP, not your residential IP. If that VPS is a datacenter IP, AllDebrid may still block it with MAGNET_NO_SERVER. Run the redirector on your own machine (or any residential IP) for the best result.
Does AllDebrid support pre-cache (prewarm)?
No. AllDebrid streams resolve on play through the redirector. There is no background pre-cache, and no cached or uncached label distinction. The first play of an uncached magnet may take a few seconds while the redirector uploads and polls.
What happens while the torrent is still downloading?
The redirector polls AllDebrid for up to two minutes. If the torrent is not ready by then, it redirects the player to a short caching clip, and the download continues on AllDebrid. Retry the stream shortly after and it usually plays.