### Install TMDbLib via NuGet Source: https://github.com/jellyfin/tmdblib/blob/master/Readme.md Use this command to add the TMDbLib package to your .NET project. ```bash dotnet add package TMDbLib ``` -------------------------------- ### Search for Movies Source: https://github.com/jellyfin/tmdblib/blob/master/Readme.md Search for movies by a query string. This example searches for '007'. Requires an API key. ```csharp using TMDbLib.Client; using TMDbLib.Objects.General; using TMDbLib.Objects.Search; var client = new TMDbClient("APIKey"); var results = await client.SearchMovieAsync("007"); Console.WriteLine($"Got {results.Results.Count:N0} of {results.TotalResults:N0} results"); foreach (var result in results.Results) Console.WriteLine(result.Title); ``` -------------------------------- ### Work with Movie Collections Source: https://github.com/jellyfin/tmdblib/blob/master/Readme.md Find and list movies within a collection. This example searches for the 'James Bond' collection. Requires an API key. ```csharp using TMDbLib.Client; using TMDbLib.Objects.Collections; using TMDbLib.Objects.General; using TMDbLib.Objects.Search; var client = new TMDbClient("APIKey"); var collections = await client.SearchCollectionAsync("James Bond"); Console.WriteLine($"Got {collections.Results.Count:N0} collections"); var jamesBond = await client.GetCollectionAsync(collections.Results.First().Id); Console.WriteLine($"Collection: {jamesBond.Name}"); Console.WriteLine($"Got {jamesBond.Parts.Count:N0} James Bond movies"); foreach (var part in jamesBond.Parts) Console.WriteLine(part.Title); ``` -------------------------------- ### Basic Movie Info Retrieval Source: https://github.com/jellyfin/tmdblib/blob/master/Readme.md Get basic information for a movie using its ID. Requires an API key. ```csharp using TMDbLib.Client; var client = new TMDbClient("APIKey"); var movie = await client.GetMovieAsync(47964); Console.WriteLine($"Movie name: {movie.Title}"); ``` -------------------------------- ### Fetch Movie Credits and Videos Source: https://github.com/jellyfin/tmdblib/blob/master/Readme.md Retrieve additional movie data like credits and videos by specifying desired methods. Requires an API key. ```csharp using TMDbLib.Client; using TMDbLib.Objects.Movies; var client = new TMDbClient("APIKey"); var movie = await client.GetMovieAsync(47964, MovieMethods.Credits | MovieMethods.Videos); Console.WriteLine($"Movie title: {movie.Title}"); foreach (var cast in movie.Credits.Cast) Console.WriteLine($"{cast.Name} - {cast.Character}"); Console.WriteLine(); foreach (var video in movie.Videos.Results) Console.WriteLine($"Trailer: {video.Type} ({video.Site}), {video.Name}"); ``` -------------------------------- ### Configuration Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Retrieves general configuration information for the TMDb API. ```APIDOC ## GET /configuration ### Description Retrieves the API configuration data. ### Method GET ### Endpoint /configuration ``` -------------------------------- ### Account Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Endpoints for managing user account details, lists, and rated items. ```APIDOC ## GET /account ### Description Get the account details of the logged in user. ### Method GET ### Endpoint /account ``` ```APIDOC ## GET /account/{id}/lists ### Description Get the lists for a specific account. ### Method GET ### Endpoint /account/{id}/lists ``` ```APIDOC ## GET /account/{id}/favorite/movies ### Description Get the favorite movies for a specific account. ### Method GET ### Endpoint /account/{id}/favorite/movies ``` ```APIDOC ## GET /account/{id}/favorite/tv ### Description Get the favorite TV shows for a specific account. ### Method GET ### Endpoint /account/{id}/favorite/tv ``` ```APIDOC ## POST /account/{id}/favorite ### Description Mark a movie or TV show as favorite. ### Method POST ### Endpoint /account/{id}/favorite ``` ```APIDOC ## GET /account/{id}/rated/movies ### Description Get the rated movies for a specific account. ### Method GET ### Endpoint /account/{id}/rated/movies ``` ```APIDOC ## GET /account/{id}/rated/tv ### Description Get the rated TV shows for a specific account. ### Method GET ### Endpoint /account/{id}/rated/tv ``` ```APIDOC ## GET /account/{id}/rated/tv/episodes ### Description Get the rated TV episodes for a specific account. ### Method GET ### Endpoint /account/{id}/rated/tv/episodes ``` ```APIDOC ## GET /account/{id}/watchlist/movies ### Description Get the watchlist movies for a specific account. ### Method GET ### Endpoint /account/{id}/watchlist/movies ``` ```APIDOC ## GET /account/{id}/watchlist/tv ### Description Get the watchlist TV shows for a specific account. ### Method GET ### Endpoint /account/{id}/watchlist/tv ``` ```APIDOC ## POST /account/{id}/watchlist ### Description Add a movie or TV show to the watchlist. ### Method POST ### Endpoint /account/{id}/watchlist ``` -------------------------------- ### Jobs Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Retrieve a list of all jobs. ```APIDOC ## GET /job/list ### Description Get the list of all jobs. ### Method GET ### Endpoint /job/list ``` -------------------------------- ### Guest Sessions Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Retrieve rated movies for a guest session. ```APIDOC ## GET /guest_session/{guest_session_id}/rated_movies ### Description Get the movies rated by a guest session. ### Method GET ### Endpoint /guest_session/{guest_session_id}/rated_movies ``` -------------------------------- ### Changes Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Endpoints to retrieve changes for movies, people, and TV shows. ```APIDOC ## GET /movie/changes ### Description Get a list of all movies that have been changed. ### Method GET ### Endpoint /movie/changes ``` ```APIDOC ## GET /person/changes ### Description Get a list of all people that have been changed. ### Method GET ### Endpoint /person/changes ``` ```APIDOC ## GET /tv/changes ### Description Get a list of all TV shows that have been changed. ### Method GET ### Endpoint /tv/changes ``` -------------------------------- ### Keywords Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Endpoints for retrieving details and movies associated with a keyword. ```APIDOC ## GET /keyword/{id} ### Description Get the details of a keyword. ### Method GET ### Endpoint /keyword/{id} ``` ```APIDOC ## GET /keyword/{id}/movies ### Description Get the movies associated with a keyword. ### Method GET ### Endpoint /keyword/{id}/movies ``` -------------------------------- ### Lists Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Endpoints for managing and retrieving movie lists. ```APIDOC ## GET /list/{id} ### Description Get the details of a specific list. ### Method GET ### Endpoint /list/{id} ``` ```APIDOC ## GET /list/{id}/item_status ### Description Check if an item is in a specific list. ### Method GET ### Endpoint /list/{id}/item_status ``` ```APIDOC ## POST /list ### Description Create a new list. ### Method POST ### Endpoint /list ``` ```APIDOC ## POST /list/{id}/add_item ### Description Add an item to a list. ### Method POST ### Endpoint /list/{id}/add_item ``` ```APIDOC ## POST /list/{id}/remove_item ### Description Remove an item from a list. ### Method POST ### Endpoint /list/{id}/remove_item ``` ```APIDOC ## POST /list/{id}/clear ### Description Clear all items from a list. ### Method POST ### Endpoint /list/{id}/clear ``` -------------------------------- ### Discover Source: https://github.com/jellyfin/tmdblib/wiki/TMDb-Services Endpoints for discovering movies and TV shows based on various criteria. ```APIDOC ## GET /discover/movie ### Description Discover movies based on different criteria. ### Method GET ### Endpoint /discover/movie ``` ```APIDOC ## GET /discover/tv ### Description Discover TV shows based on different criteria. ### Method GET ### Endpoint /discover/tv ```