Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/rivenmedia/riven-ts/llms.txt

Use this file to discover all available pages before exploring further.

The Torrentio plugin connects Riven to Torrentio — a public Stremio addon that aggregates torrents from a wide range of indexers including YTS, EZTV, RARBG mirrors, The Pirate Bay, and more. No API key or self-hosted instance is required. Riven sends a single HTTP request per item using a configurable filter string, then parses the returned stream list into { infoHash → title } pairs that feed the torrent ranking engine.

What Torrentio does

When Riven raises a MediaItemScrapeRequested event, the Torrentio plugin:
  1. Resolves the Stremio-style identifier for the item via the shared getStremioScrapeConfig utility.
  2. Calls GET /{filter}/stream/{type}/{identifier}.json on torrentio.strem.fun.
  3. Parses each stream object, strips the seeder count suffix from the title (everything after \n👤), and collects infoHash → rawTitle pairs.
  4. Returns the full torrent map for the ranking engine to score and select from.
Torrentio requires every scraped item to have an IMDb ID. Items without an imdbId are skipped with an error log entry.

Enabling the plugin

Add torrentio to RIVEN_SETTING__enabledPlugins:
RIVEN_SETTING__enabledPlugins=torrentio,stremthru,plex,seerr

Settings

filter
string
The Torrentio filter string appended to every stream request URL. Controls sort order and which quality tiers are excluded from results. The default filter sorts by quality-adjusted size and removes 3D, 480p, screener, and cam releases.

Configuration

RIVEN_PLUGIN_SETTING__REPO_PLUGIN_TORRENTIO__filter="sort=qualitysize%7Cqualityfilter=threed,480p,scr,cam"

Full .env example

# Enable Torrentio (add alongside other plugins)
RIVEN_SETTING__enabledPlugins=torrentio,stremthru,plex,seerr

# Torrentio filter — default excludes 3D, 480p, screener, and cam releases
RIVEN_PLUGIN_SETTING__REPO_PLUGIN_TORRENTIO__filter="sort=qualitysize%7Cqualityfilter=threed,480p,scr,cam"

Customising the filter string

The filter string is passed directly as a URL path segment to torrentio.strem.fun. You can build a custom filter using the Torrentio web configurator at torrentio.strem.fun — click Install, copy the path from the generated addon URL, and paste it into the filter setting.
ParameterDescriptionExample
sortSort order for resultssort=qualitysize, sort=seeders
qualityfilterComma-separated qualities to excludequalityfilter=threed,480p,scr,cam
providersLimit to specific indexer providersproviders=yts,eztv
limitMaximum number of results per requestlimit=20
Parameters are joined with %7C (URL-encoded |). Example:
sort=qualitysize%7Cqualityfilter=threed,480p%7Climit=30

Supported media types

The Torrentio plugin uses Riven’s shared getStremioScrapeConfig utility to build identifiers, producing the same path format used across all Stremio addons:
Media typeTorrentio endpoint pattern
Movie/{filter}/stream/movie/{imdbId}.json
Show (all seasons)/{filter}/stream/series/{imdbId}.json
Season/{filter}/stream/series/{imdbId}:{seasonNumber}.json
Episode/{filter}/stream/series/{imdbId}:{seasonNumber}:{episodeNumber}.json

Rate limiting

The Torrentio plugin applies an in-process rate limiter of 150 requests per 60 seconds to stay within Torrentio’s acceptable use limits. Since torrentio.strem.fun is a public, unauthenticated service, avoid configuring very high scrape frequencies.
Run Torrentio alongside the Comet plugin for broader indexer coverage. Both scrapers are invoked for every item, and the ranking engine selects the best torrent from the combined result set.

Combining with Comet

Torrentio and Comet serve complementary roles. Torrentio is the zero-config public option; Comet adds debrid-aware filtering from a self-hosted or private instance. Enabling both maximises torrent candidate coverage before the ranking step.

Comet Plugin

Add Comet alongside Torrentio for debrid-checked, self-hosted torrent scraping.

Ranking Overview

Configure how Riven scores and selects from the combined scraper results.

Build docs developers (and LLMs) love