trendarr
TMDB weekly trending in the terminal — IMDb ratings via OMDb, Radarr/Sonarr library flags and adds, SABnzbd queue control.
Install
pnpm add -g @astrofoundry/trendarr
Node 24+. Run trendarr init once — prompts for TMDB API Read Access Token (themoviedb.org/settings/api), OMDb, Radarr, Sonarr, and SABnzbd credentials, validates each live, and saves to ~/.trendarr/config.json (mode 600). Books are optional: init then also asks for Chaptarr, Audiobookshelf, and Prowlarr. No environment variables.
Commands
trendarr trending [--max-entries 10] [--type movies|series] [--min-rating 6.5] [--json|--discord]
trendarr search <query> [--max-entries 10] [--type movies|series] [--json|--discord]
trendarr recommend [--max-entries 10] [--type movies|series] [--exclude tt1,tt2] [--json]
trendarr add-movies <imdbIds...> [--json]
trendarr add-series <imdbIds...> [--json]
trendarr sabnzbd status|pause|resume|unpause [--json]
trendarr books search <query> [--max-entries 10] [--json]
trendarr books add <bookId> --format audiobook|ebook [--json]
trendarr books narrators <bookId> [--max-entries 5] [--json]
trendarr books releases <bookId> --format audiobook|ebook [--edition <id>] [--max-entries 10] [--json]
trendarr books grab <chaptarrId> <guid> <indexerId> [--json]
trendarr books push <chaptarrId> <infoHash> [--json]
trendarr books best <bookId> --format audiobook|ebook [--edition <id>] [--json]
trendarr books ready <chaptarrId> [--json]
trendarr books send <chaptarrId> <device> [--json]
trendarr books ebooks [--json]
trendarr books send-item <itemId> <device> [--json]
trendarr <command> --help shows parameters and output shapes. Movies below the IMDb min-rating (default 6.5) are dropped from trending; unrated movies are kept; --min-rating 0 disables the filter. recommend ranks the titles TMDB recommends for your Radarr and Sonarr library by how many library titles lead to them, and keeps released titles not in the library with IMDb 7.0+ and 5,000 votes (movies) or 2,000 (series).
books works with Chaptarr, which keeps an audiobook and an ebook entry per work. add lets Chaptarr pick the release and waits up to 2 minutes to report whether it grabbed one; releases then grab let you pick one yourself (narrator, size, format). narrators lists an audiobook's narrations, most rated first; --edition on releases and best monitors the one you pick first. Audiobook releases come best first: the narrator's surname in the name, then M4B, then the bitrate estimated from the edition's length. Chaptarr refuses some public trackers (its indexer test finds no book in their recent list), so with Prowlarr configured, audiobook releases also include the torrents of Prowlarr indexers Chaptarr lacks; push sends one to Chaptarr, which checks it like an RSS release and files it under the monitored book its name matches. best grabs or pushes the first of them without a Chaptarr rejection, or leaves the book wanted. ready tells whether a book has its file and, for an ebook, whether Audiobookshelf has it. send emails an ebook to a Kindle through Audiobookshelf's e-reader devices. ebooks lists every ebook in Audiobookshelf, newest first, and send-item emails one of them by its item id.
Development
pnpm check # typecheck, lint, tests
pnpm build
pnpm release:patch # or release:minor / release:major