🍿 @lorenzopant/tmdb

Collections

Search for collections by their original, translated and alternative names.

Search for collections by their original, translated, and alternative names.

async collections(params: SearchCollectionsParams): Promise<PaginatedResponse<CollectionResultItem>>

TMDB Reference: Search Collection

Parameters

NameTypeRequiredDescription
querystringSearch query text.
include_adultbooleanInclude adult (18+) content in results. Defaults to false.
languageLanguageLanguage for localized results. Defaults to en-US.
pagenumberPage number for paginated results. Defaults to 1.
regionCountryISO3166_1ISO 3166-1 country code to filter results by region.

Returns

A PaginatedResponse<CollectionResultItem> containing an array of CollectionResultItem objects.

Example

import { TMDB } from "@lorenzopant/tmdb";

const tmdb = new TMDB("your-api-key");
const { results } = await tmdb.search.collections({ query: "The Dark Knight" });

console.log(results);
// [
//   { id: 263, name: "The Dark Knight Collection", ... },
//   ...
// ]

Types

On this page