Plugins
Two plugins ship with the project, and everything else is a plugin too — the Kotlin loader, the HTTP backend, the HLS adapter. The kernel itself knows no protocol.
Official plugins
HLS VOD Backend
Treats an `.m3u8` URL as a stream to assemble rather than a text file to save: playlist resolution, variant selection, concurrent segments with per-segment retry, AES-128 decryption, byte ranges.
dev.turbodl:turbo-plugin-hls:0.2.2.0
JavaScript Plugin Loader
Loads TurboDL plugins written in JavaScript. One QuickJS runtime and context per script, a stable `host`/`plugin` ABI, and a load/unload sequence that never closes a runtime while its script is still executing.
dev.turbodl:turbo-plugin-js:0.2.2.0
Plugin categories
A plugin declares one category in its manifest. The category says what it is allowed to plug into — nothing else.
| Category | What it plugs in |
|---|---|
| turbodl-backend | A protocol backend (replaces or extends the built-in HTTP engine). |
| turbodl-protocol | Declares the protocols/schemes it handles (the manifest `protocols` list). |
| turbodl-adapter | Bridges an external downloader. |
| turbodl-parser | Turns a share link / magnet / kouling into download requests. |
| turbodl-hook | Observes or rewrites requests and results. |
| turbodl-loader | Loads plugins written in another language — this is what the JS loader is. |
Writing your own
A plugin is an ordinary class implementing one interface. Third-party plugins are discovered through a GitHub topic plus a manifest — there is no registry to sign up to.
class MyPlugin : Plugin {
override val id = "parser.example"
override fun onLoad(context: PluginContext) {
context.registerExtension(ExtensionPoints.LINK_PARSER, LinkParser { input ->
input.takeIf { it.startsWith("example://") }
?.let { listOf(DownloadRequest(url = it, destination = File("out.bin"))) }
})
}
}