Files
Showy/docs-vault/Search.md

1.3 KiB

title, tags
title tags
Search
feature
search
tmdb

Search

Overview

Showy provides TMDB multi-search for discovering new content to add to the library.

How It Works

  1. User types a query in the Pages#SearchPage
  2. Input is debounced via Hooks#useDebounce
  3. GET /entries/tmdb/search?query=&page= called via API Clients
  4. Backend proxies to TMDB /search/multi via TMDB Integration
  5. Results returned as TmdbPaginatedResponse<TmdbEntry>
  6. Each result checked against Stores — if already in library, the local entry card is shown instead

Library Cross-Reference

When search results are displayed, the frontend checks each TMDB result's ID against entries in the Zustand store. If a match is found (entry.entry_ids.tmdb_id === result.id), the local EntryCard is rendered with library actions instead of the "Add" button.

People search is also available on the Pages#PeoplePage:

  • GET /people/tmdb/search?query= → TMDB person search
  • Local DB search via GET /people/search?query=

Discover Pages

Browse TMDB by category on Pages#DiscoverPage:

  • Popular movies/TV
  • Trending movies/TV
  • Top-rated movies/TV
  • Upcoming movies

All use infinite scrolling via Hooks#useTmdb hooks.