Models
Submitter
dataclass
Represents the user who submitted the torrent.
is_trusted
instance-attribute
is_trusted: bool
Indicates whether the user is trusted (green) or not.
NyaaTorrentPage
dataclass
NyaaTorrentPage(
*,
id: int,
url: str,
title: str,
category: Category,
submitter: Submitter | None,
datetime: datetime,
information: str | None,
seeders: int,
leechers: int,
completed: int,
size: int,
infohash: str,
is_trusted: bool,
is_remake: bool,
description: str | None,
torrent: str,
magnet: str,
)
Represents Nyaa's torrent page.
completed
class-attribute
instance-attribute
Number of completed downloads.
is_remake
instance-attribute
is_remake: bool
Indicates whether the upload is a remake (red) or not.
Note
An upload can be both trusted and a remake, in which case,
the remake takes priority, that is, is_remake
will be True
and is_trusted
will be False
.
is_trusted
instance-attribute
is_trusted: bool
Indicates whether the upload is trusted (green) or not.
Note
An upload can be both trusted and a remake, in which case,
the remake takes priority, that is, is_remake
will be True
and is_trusted
will be False
.
leechers
class-attribute
instance-attribute
Number of leechers.
magnet
instance-attribute
magnet: str
Magnet link of the torrent.
Note
The magnet link provided by Nyaa is different from the one
you'll get if you simply generated it from the .torrent
file itself
because Nyaa strips away all trackers except it's own
and the ones listed here.
submitter
instance-attribute
submitter: Submitter | None
User who submitted the torrent.
This will be None
if the submitter is anonymous.
torrent
instance-attribute
torrent: str
URL pointing to the .torrent
file (https://nyaa.si/download/123456.torrent
)