goneko

package module
v0.0.0-...-826e2f7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 30, 2023 License: MIT Imports: 7 Imported by: 0

README

GoNeko: A golang scraping package for Nyaa

Go Report Card

GoNeko is a simple, lightweight and ultrafast scraper for nyaa.si
You can search torrents just like on the website, and get the result as golang structs.

Installation

go get github.com/Yanisssssse/goneko

Documentation

- Parse(url string)

return an array containing the nyaa entrys of the specified url.

- HomePage()

return an array containing the nyaa entrys of the home page.

- Search(opts *Opts)

Allow you to make a precise search

  • Query (string) : The text of your search.

  • Page (int) : The page number

  • User (string) : Show only entrys posted by the specified user

  • Filter (int) :

    • 0 - No Filter
    • 1 - No Remakes
    • 2 - Trusted Only
  • Cat (int) & Subcat (int) :

    • 0 - All Categories (& Subcategories)

    • 1 - Anime - 1.1 - Anime Music Video

      • 1.2 - English-translated
      • 1.3 - Non-English-translated
      • 1.4 - Raw
    • 2 - Audio - 2.1 - Lossless

      • 2.2 - Lossy
    • 3 - Literature

      • 3.1 - English-translated
      • 3.2 - Non-English-translated
      • 3.3 - Raw
    • 4 - Live Action

      • 4.1 - English-translated
      • 4.2 - Idol/Promotional Video
      • 4.3 - Non-English-translated
      • 4.4 - Raw
    • 5 - Pictures

      • 5.1 - Graphics
      • 5.2 - Photos
    • 6- Software

      • 6.1 - Applications
      • 6.2 - Games

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Opts

type Opts struct {
	Query  string
	Filter int
	Cat    int
	Subcat int
	Page   int
	User   string
}

type Result

type Result struct {
	Cat          string
	Title        string
	CommentCount int
	Magnet       string
	View         string
	Size         string
	TimeStamp    int
	Seeders      int
	Leechers     int
	Completed    int
}

func HomePage

func HomePage() ([]*Result, error)

Parse the nyaa Home Page and return an array of Result pointers

func Parse

func Parse(link string) ([]*Result, error)

return an array of Result pointers

func Search(opts *Opts) ([]*Result, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL