Extensions - RockinChaos/Shiru GitHub Wiki
Available Extensions
- anisearch (aniresourced) - Designed to fetch torrents from animetosho and seadex, this has a very high accuracy, though it doesn't always work with sequel anime--batches specifically.
- nyaasearch - By CrypticWyvern it is designed to fetch torrents from Nyaa and Sukebei (NSFW). This is sometimes a hit or miss depending on the title complexity, you may experience some torrents being fetched that are not related to the anime you are searching for. This is extremely useful for when animetosho is down or if you want to watch hentai from Sukebei.
Did you make an extension for Shiru? Let me know and I'll add it here.
About Extensions
Frequently Asked Questions about Extensions.
What are some recommended extensions and sources?
Shiru is bring-your-own-content and does not offer anything, however anisearch is recommended.
Is there a curated list of extensions and sources?
No. Shiru is not directly associated with any extensions or sources. It's merely a client for streaming one's own media.
How to install/uninstall extensions?
Inside Settings > Torrent > Extensions you can add extensions by either inputting a full URL such as https://example.website/file.js
or if an extension is published on npm packagename and pressing add. This will automatically import all sources the extension provides. You can then uninstall an extension by pressing the remove button next to it.
Can you disable sources?
You can disable sources in the sources list by clicking on it's toggle.
How to develop new extensions?
Extensions for Shiru need to be written in JavaScript which are run in an isolated Web Worker. Make sure the data you're fetching is CORS enabled. Extension type definitions and example structures are available on GitHub. For testing you can specify a file path to the extension you are developing to quickly verify changes.
Options object, which is passed to the class's single, batch and movie functions as the first parameters has the following fields:
- anilistId: number - Anilist anime id, can be used to query data from Anilist, such as MalID, episode metadata etc
- anidbAid?: number - AniDB anime id, not always present, useful to query mapping API's
- anidbEid?: number - AniDB episode id, not always present, useful to query specific data, as AnidbEIDs map to manually maintained files
- titles: string[] - list of titles and alternative titles for the given anime
- episode?: number - episode to look for, not always present
- episodeCount?: number - total episode count for the series, not always present
- resolution: '2160' | '1080' | '720' | '540' | '480' | '' - resolution height. empty string means any
- exclusions: string[] - list of keywords to exclude from searches such as codecs unsuppored by the platform, etc
Results object, array of which is returned by the functions of the class has the following fields:
- title: string - torrent title, this isn't always the file title as a torrent might include multiple files
- link: string - http:// link to .torrent file, or magnet:// link
- id?: number - unused for now
- seeders: number
- leechers: number
- downloads: number
- hash: string - info hash REQUIRED
- size: number - size in bytes
- verified: boolean - if it's a verified release, e.g. it's 100% certain it's the correct episode, manually verified by the provider e.g. anidb
- date: Date - date the torrent was uploaded
- type?: 'batch' | 'best' | 'alt' - type of the result best/alt means it's the best known release