YTS.NET
1.2.1
dotnet add package YTS.NET --version 1.2.1
NuGet\Install-Package YTS.NET -Version 1.2.1
<PackageReference Include="YTS.NET" Version="1.2.1" />
<PackageVersion Include="YTS.NET" Version="1.2.1" />
<PackageReference Include="YTS.NET" />
paket add YTS.NET --version 1.2.1
#r "nuget: YTS.NET, 1.2.1"
#:package YTS.NET@1.2.1
#addin nuget:?package=YTS.NET&version=1.2.1
#tool nuget:?package=YTS.NET&version=1.2.1
YTS.NET
YTS.NET is a .NET Wrapper for YTS API. It provides access to working functionalities of the API like listing movies and so on. As of right now writing this document, there is only three working functions in the API, not the library, the API documentary of YTS might be outdated or incomplete. And fun fact, this is my first ever project that is published online!
Getting Started
First of all you must have a targetting version that is compatible with .NET Standard 2.0, once you have the right version you install YTS.NET from the Package Manager Console or using the Package Manager Dialog.
Package Manager Console
In Visual Studio, Click
View>Other Windows>Package Manager Console.Type in,
Install-Package YTS.NETto get the latest version.
Package Manager Dialog
Right-click on your project and select
Manage NuGet Packages.Search for
YTS.NETand clickInstallto get the latest version.
API Usage
Let's say we are searching for a movie, let's say "harry potter" and so I put it in the method and get the response, and then select the movie that comes first in the results
var API = new YTS.Services(new Uri("https://yts.mx/api/v2"));
var Response = API.GetMovieList(Query: "Harry Potter"); // Searches For Movies With The Query
var Movies = Response.Data.Movies; // Results Matching The Query
var Movie = Movies[0]; // Selecting The First Movie
And then let's get the movie's cast and then get other movie suggestions for the user.
var Details = API.GetMovieDetails(Movie.ID); // Gets Movie Details
var Cast = Details.Data.Movie.Cast; // Array Containing Actors
var Suggestions = API.GetMovieSuggestions(Movie.ID).Data.Movies; // Array Containing Movie Suggestions
And so, we'll get a 1080p torrent magnet link for that movie, and trackers for the torrent.
var Trackers = new string[] // Creating Trackers For Torrent
{
"udp://glotorrents.pw:6969/announce",
"udp://tracker.opentrackr.org:1337/announce",
"udp://torrent.gresille.org:80/announce",
"udp://tracker.openbittorrent.com:80",
"udp://tracker.coppersurfer.tk:6969",
"udp://tracker.leechers-paradise.org:6969",
"udp://p4p.arenabg.ch:1337",
"udp://tracker.internetwarriors.net:1337"
};
string Magnet = null;
foreach (var Torrent in Movie.Torrents)
if (Torrent.Quality == "1080p") // Checks If The Torrent Is 1080p
Magnet = Torrent.GetMagnet("NAME THE TORRENT ANYTHING YOU WANT", Trackers); // Gets The Magnet Link
System.Diagnostics.Process.Start(Magnet); // Calls Another Program To Download The Movie
And that's all I can explain for now. Anything wrong with the documentary or the project, please add an issue.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- Newtonsoft.Json (>= 12.0.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.