Python API

class tmdb_async_movies.main.TmdbAsyncMovies(tmdb_api_key: str | None = None, include_adult: bool = True, language: str = 'en_US', naming_convention: int = 0, backup_call: bool = True)[source]

TMDB Async Movies.

generic_parse(queries: List[str]) None[source]

For a list of given queries, their TMDB IDs will be searched and used to lookup movie details and cast.

Parameters:

queries – list of strings

async get_metadata(metadata: str, tmdb_ids: Set[int]) None[source]

For a given set of TMDB IDs movie details or credits are searched and stored.

Parameters:
  • metadata – either ‘movie_details’ or ‘credits’

  • tmdb_ids – a set of TMDB IDs

Raises:

KeyError – if metadata is not specified correctly

parse_movie_dirs(input_path: Path) None[source]

For a given input path, subfolders will be used for quering the TMDB for metadata.

Parameters:

queries – list of strings

Raises:

FileNotFoundError – if input_path doesn’t exist.

async search_ids(canon_input: DataFrame) DataFrame[source]

Given a canonical input TMDB IDs are searched.

Parameters:

canon_input – dataframe with title and year column

Returns:

dataframe with columns tmdb_id, request url

write(output_path: Path) None[source]

Writes all internal tables to output_path.

Parameters:

output_path – path where files should get written to.

Raises:

FileNotFoundError – if output_path doesn’t exist