A comprehensive .NET class library that provides unified search capabilities for movies, series, subtitles, and torrents. MedflixAPI leverages the TMDB (The Movie Database) API for media information retrieval and integrates services for subtitle discovery and torrent sourcing across multiple languages and regions.
- π¬ Movie & Series Search: Comprehensive search capabilities via TMDB API with filtering by genre, platform, and popularity
- π€ Subtitle Search: Multi-language subtitle discovery and download (English, French)
- π Torrent Search: Source torrent files across multiple regions (Original and French versions)
- π Detailed Information: Retrieve comprehensive media details including cast, crew, ratings, and metadata
- π― Platform Filtering: Search by streaming platforms (Netflix, Disney+, etc.)
- .NET Runtime: .NET 10.0 or higher
- TMDB API Key: Required for movie and series searches (free to obtain)
- Get your API key: TMDB API Documentation
Install the NuGet package:
dotnet add package MedflixAPIOr via Package Manager:
Install-Package MedflixAPIusing MedflixAPI.Services;
// Initialize searchers
var movieSearcher = MedflixAPIFactory.Instance.CreateMovieSearcher(apiKey);
var seriesSearcher = MedflixAPIFactory.Instance.CreateSeriesSearcher(apiKey);
// Search for movies
var movies = await movieSearcher.SearchMoviesAsync("Encanto");
foreach (var movie in movies)
{
Console.WriteLine($"{movie.Title} ({movie.Year})");
}Initialize the searchers with your TMDB API key:
var movieSearcher = MedflixAPIFactory.Instance.CreateMovieSearcher(apiKey);
var seriesSearcher = MedflixAPIFactory.Instance.CreateSeriesSearcher(apiKey);Search by Title
var movies = await movieSearcher.SearchMoviesAsync("Encanto");
var series = await seriesSearcher.SearchSeriesAsync("Breaking Bad");Search by Platform
var moviesPlatforms = await movieSearcher.GetMoviePlatformsAsync();
var moviesOfPlatform = await movieSearcher.GetMoviesByPlatformAsync(moviesPlatforms[0].Id, page: 1);
var seriesPlatforms = await seriesSearcher.GetSeriePlatformsAsync();
var seriesOfPlatform = await seriesSearcher.GetSeriesByPlatformAsync(seriesPlatforms[0].Id, page: 1);Search by Genre
var moviesGenres = await movieSearcher.GetMovieGenresAsync();
var moviesOfGenre = await movieSearcher.GetMoviesByGenreAsync(moviesGenres[0].Id, page: 1);
var seriesGenres = await seriesSearcher.GetSerieGenresAsync();
var seriesOfGenre = await seriesSearcher.GetSeriesByGenreAsync(seriesGenres[0].Id, page: 1);Get Popular Content by Platform
var popularMovies = await movieSearcher.GetPopularDisneyPlusMoviesAsync();
var popularSeries = await seriesSearcher.GetPopularNetflixSeriesAsync();Retrieve Detailed Information The methods above return basic information. For comprehensive details (cast, crew, ratings, images, etc.):
var movies = await movieSearcher.SearchMoviesAsync("Encanto");
var movieDetails = await movieSearcher.GetMovieDetailsAsync(movies[0].Id);
var series = await seriesSearcher.SearchSeriesAsync("Breaking Bad");
var seriesDetails = await seriesSearcher.GetSerieDetailsAsync(series[0].Id);Search for and download subtitles in multiple languages:
// Initialize the subtitles search manager
var downloadFolder = "/path/to/subtitles";
var subtitlesSearchManager = MedflixAPIFactory.Instance.CreateSubstitlesSearchManager(downloadFolder);
// Get movie details
var movies = await movieSearcher.SearchMoviesAsync("Encanto");
var movieDetails = await movieSearcher.GetMovieDetailsAsync(movies[0].Id);
// Retrieve available subtitle URLs
var subtitleUrls = await subtitlesSearchManager.GetAvailableMovieSubtitlesUrlsAsync(
movieDetails.ImdbId,
SubtitlesLanguage.French
);
// For series
var seriesSubtitleUrls = await subtitlesSearchManager.GetAvailableSerieSubtitlesUrlsAsync(
season: 1,
episode: 5,
seriesDetails.ImdbId,
SubtitlesLanguage.English
);
// Download and extract the subtitle file
var filePath = await subtitlesSearchManager.DownloadSubtitlesFileAsync(subtitleUrls.FirstOrDefault());Search for torrent sources for movies and TV series:
// Initialize the torrent search manager
var torrentSearchManager = MedflixAPIFactory.Instance.CreateTorrentSearchManager();
// Search for movie torrents (Original Version)
var torrentsVo = await torrentSearchManager.SearchVoTorrentsMovieAsync("The Wild Robot", 2024);
// Search for movie torrents (French Version)
var torrentsVf = await torrentSearchManager.SearchVfTorrentsMovieAsync("Le Robot Sauvage", 2024);
// Search for series torrents
var seriesTorrentsVf = await torrentSearchManager.SearchVfTorrentsSerieAsync("Breaking Bad", season: 1, episode: 3);
var seriesTorrentsVo = await torrentSearchManager.SearchVoTorrentsSerieAsync("Breaking Bad", season: 1, episode: 3);
// Process and display results
foreach (var torrent in seriesTorrentsVo)
{
Console.WriteLine($"Quality: {torrent.Quality} | URL: {torrent.DownloadUrl}");
// Note: DownloadUrl can be a magnet link or an HTTP URL to a .torrent file
}This project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit issues and pull requests.
For more information and examples, refer to the MedflixAPISample project in the repository.