{"repo":"lacymorrow/movie-trailer","free":true,"listed":false,"github":"https://github.com/lacymorrow/movie-trailer","clone":"git clone https://github.com/lacymorrow/movie-trailer.git","description":"Find YouTube trailer URLs for any movie or TV show","language":"JavaScript","stars":34,"topics":["movie","trailer","movie-trailer","javascript","callback","tmdb","cli","node","lookup","api"],"license":"MIT","category":"api-integrations-sdks","readme_excerpt":"Find YouTube trailer URLs for any movie or TV show ➔ \"Up\" → https://www.youtube.com/watch?v=… --- [!IMPORTANT] This library is feature-complete and only receives bug-fix updates. Feature requests still welcome — please open an issue. Features - Fetch YouTube trailers for any movie or TV show - Return one URL or many — videos, IDs, or full URLs - Async/await, Promise, and callback API - Use anywhere — browser or Node, UMD bundle (browser support) - Works in React + Next.js, client and server, via isomorphic-fetch - Bring your own TMDB API key, or use the default Install In the browser: Also available via JSDelivr. Usage TV shows Many trailers — IDs only Year disambiguation + multiple URLs Legacy positional year [!TIP] Try it live — open in RunKit (example output). API movieTrailer(movie [, options] [, callback]) Pass a movie or show title (or null if searching by tmdbId ). Returns a Promise that resolves to a YouTube URL — or an array of URLs / IDs depending on options . Option Type Default Description --- --- --- --- apiKey string TMDB default Use your own TMDB key — get one free id boolean false Return only YouTube video IDs (e.g. \"abc123\" instead of full URLs) language string Movie release language code (e.g. \"de DE\" ) multi boolean false Return an array of results instead of a single result tmdbId string \\ number Search by TMDB content ID instead of a title (pass null as the first argument) year string \\ number Release-year disambiguator videoType \"movie\" \\ \"tv\" \"movie\" Mo","default_branch":null,"files":null,"tree":[],"storefront":"/r/lacymorrow","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/lacymorrow/movie-trailer/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}