TmdbElixir.Search (tmdb_elixir v1.1.0)

Used for making calls to search within TMDb.

Summary

Functions

Search for movies by their original, translated and alternative titles.

Search for people by their name and also known as names.

Functions

movies(query, params \\ %{})

Search for movies by their original, translated and alternative titles.

Returns a map with a paginated list of movie search results.

Accepts query params listed in the TMDb Docs in the form of a map.

Examples

iex> TmdbElixir.Search.movies("spongebob")
%{
  "page" => 1,
  "results" => [
    %{
      "title" => "The SpongeBob SquarePants Movie",
      ...
    },
    ...
  ],,
  "total_pages" => 10,
  "total_results" => 250
}

people(query, params \\ %{})

Search for people by their name and also known as names.

Returns a map with a paginated list of person search results.

Accepts query params listed in the TMDb Docs in the form of a map.

Examples

iex> TmdbElixir.Search.people("brad pitt")
%{
  "page" => 1,
  "results" => [
    %{
      "name" => "Brad Pitt",
      ...
    },
    ...
  ],,
  "total_pages" => 10,
  "total_results" => 250
}