Skip to contents

These functions return the most anticipated movies/shows on trakt.tv.

Usage

movies_anticipated(
  limit = 10,
  extended = "min",
  filters = NULL,
  query = NULL,
  years = NULL,
  genres = NULL,
  languages = NULL,
  countries = NULL,
  runtimes = NULL,
  ratings = NULL,
  certifications = NULL
)

shows_anticipated(
  limit = 10,
  extended = "min",
  filters = NULL,
  query = NULL,
  years = NULL,
  genres = NULL,
  languages = NULL,
  countries = NULL,
  runtimes = NULL,
  ratings = NULL,
  certifications = NULL,
  networks = NULL,
  status = NULL
)

Source

movies_anticipated() wraps endpoint /movies/anticipated.

shows_anticipated() wraps endpoint /shows/anticipated.

Arguments

limit

integer(1) [10L]: Number of items to return. Must be greater than 0 and will be coerced via as.integer().

extended

character: Level of detail for the API response.

  • "min" (default): Minimal info (title, year, IDs). Omits the extended query param.

  • "full": Complete info including overview, ratings, runtime, etc.

  • "images": Minimal info plus image URLs (returned as a list-column).

  • "full,images": Complete info plus images.

  • "metadata": Collection endpoints only; adds video/audio metadata.

Multiple values can be combined as a comma-separated string (e.g. "full,images") or a character vector (e.g. c("full", "images")).

filters

A trakt_filters object created with filters_movies(), filters_shows(), or filters_episodes() that refines which items are returned. See filters for the full set of supported filters. Supplying filters as individual arguments (genres, years, networks, ...) is soft-deprecated in favour of this argument; if both are given, filters takes precedence.

query

character(1): Search string for titles and descriptions. For search_query() other fields are searched depending on the type of media. See the API docs for a full reference.

years

character | integer: 4-digit year (2010) or range, e.g. "2010-2020". Can also be an integer vector of length two which will be coerced appropriately, e.g. c(2010, 2020).

genres

character(n): Genre slug(s). See trakt_genres for a table of genres. Multiple values are allowed and will be concatenated.

languages

character(n): Two-letter language code(s). Also see trakt_languages for available languages (code and name).

countries

character(n): Two-letter country code(s). See trakt_countries.

runtimes

character | integer: Integer range in minutes, e.g. 30-90. Can also be an integer vector of length two which will be coerced appropriately.

ratings

character | integer: Integer range between 0 and 100. Can also be an integer vector of length two which will be coerced appropriately. Note that user-supplied ratings are in the range of 1 to 10, yet the ratings on the site itself are scaled to the range of 1 to 100.

certifications

character(n): Certification(s) like pg-13. Multiple values are allowed. Use trakt_certifications for reference. Note that there are different certifications for shows and movies.

networks

character(n): (Shows only) Network name like HBO. See trakt_networks for a list of known networks.

status

character(n): (Shows only) The status of the shows. One of "returning series", "in production", "planned", "canceled", or "ended".

Value

A tibble(). If the function has a limit parameter (defaulting to 10), this will be the (maximum) number of rows of the tibble. If there are no results (or the API is unreachable), an empty tibble() is returned.

The Dynamic Lists on trakt.tv

These functions access the automatically updated lists provided by trakt.tv. Each function comes in two flavors: Shows or movies. The following descriptions are adapted directly from the API reference.

  • Popular: Popularity is calculated using the rating percentage and the number of ratings.

  • Trending: Returns all movies/shows being watched right now. Movies/shows with the most users are returned first.

  • Played: Returns the most played (a single user can watch multiple times) movies/shows in the specified time period.

  • Watched: Returns the most watched (unique users) movies/shows in the specified time period.

  • Collected: Returns the most collected (unique users) movies/shows in the specified time period.

  • Anticipated: Returns the most anticipated movies/shows based on the number of lists a movie/show appears on. The functions for Played, Watched, Collected and Played each return the same additional variables besides the media information: watcher_count, play_count, collected_count, collector_count.

Examples

# Get 15 the most anticipated upcoming shows on Netflix that air this year
current_year <- format(Sys.Date(), "%Y")
shows_anticipated(
  limit = 15,
  filters = filters_shows(networks = "Netflix", years = current_year)
)
#> # A tibble: 15 × 11
#>    list_count  year title aired_episodes imdb  slug  tmdb  tvdb  trakt plex_guid
#>         <int> <int> <chr>          <int> <chr> <chr> <chr> <chr> <chr> <chr>    
#>  1      10450  2026 HIS …              6 tt33… his-… 2597… 4525… 2494… 66a33f8e…
#>  2       9646  2026 I Wi…              8 tt34… i-wi… 2781… 4571… 2653… 6749125e…
#>  3       9329  2026 The …              8 tt27… the-… 2249… 4339… 2045… 64456c8c…
#>  4       6668  2026 Some…              8 tt32… some… 2592… 4522… 2487… 669816fb…
#>  5       5517  2026 Man …              7 tt27… man-… 2233… 4330… 2035… 6424274b…
#>  6       5352  2026 Lege…              6 tt33… lege… 2622… 4536… 2530… 670911d7…
#>  7       4598  2026 Big …              8 tt36… big-… 2915… 4668… 2857… 68a2c3a9…
#>  8       4108  2026 Dete…              9 tt31… dete… 2495… 4478… 2317… 65fbe43c…
#>  9       4005  2026 How …              8 tt31… how-… 2330… 4385… 2082… 64e5bf3d…
#> 10       4002  2026 Run …              8 tt91… run-… 2442… 4450… 2208… 65b0456b…
#> 11       3999  2026 Stra…             10 tt27… stra… 2242… 4629… 2042… 68093ee0…
#> 12       3982  2026 Agat…              3 tt31… agat… 2505… 4484… 2331… 66680ebb…
#> 13       3546  2026 Berl…              8 tt42… berl… 3080… 4776… 3107… 694c8321…
#> 14       3519  2026 Teac…             10 tt34… teac… 2761… 4643… 2626… 68667e7f…
#> 15       3299  2026 Neme…              8 tt36… neme… 2858… 4610… 2784… 67c993ea…
#> # ℹ 1 more variable: plex_slug <chr>