{"analyzedAt":"2022-07-07T08:30:06.252Z","collected":{"metadata":{"name":"nyaasiscrapper","scope":"unscoped","version":"1.1.0","description":"A light scrapper for nyaasi","keywords":["nyaa.si","scrapper","api","anime"],"date":"2020-07-01T22:23:40.582Z","author":{"name":"Lotrez"},"publisher":{"username":"lotrez","email":"voltzlucien@gmail.com"},"maintainers":[{"username":"lotrez","email":"voltzlucien@gmail.com"}],"repository":{"type":"git","url":"git+https://github.com/lotrez/nyaasiscrapper.git"},"links":{"npm":"https://www.npmjs.com/package/nyaasiscrapper"},"license":"ISC","dependencies":{"@types/node":"^14.0.14","fast-xml-parser":"^3.17.4","node-fetch":"^2.6.0","node-html-parser":"^1.2.20","nodemon":"^2.0.4","ts-node":"^8.10.2"},"devDependencies":{"@types/jest":"^26.0.3","@typescript-eslint/eslint-plugin":"^3.5.0","@typescript-eslint/parser":"^3.5.0","eslint":"^7.3.1","jest":"^26.1.0","ts-jest":"^26.1.1","typescript":"^3.9.5"},"releases":[{"from":"2022-06-07T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":0},{"from":"2022-04-08T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":1},{"from":"2022-01-08T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":1},{"from":"2021-07-07T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":1},{"from":"2020-07-07T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":1}],"hasTestScript":true,"readme":"# Nyaascrapper\n\n[![npm version](https://badge.fury.io/js/nyaasiscrapper.svg)](https://www.npmjs.com/package/nyaasiscrapper)\n\nNyaascrapper is a simple tool to search and index nyaa.si\n\n# Installation\n\n\n```sh\n$ npm install nyaasiscrapper\n```\n\n## Functions\n\n| function | use |\n| ------ | ------ |\n| **searchNyaa** | main function that allows to search with parameters nyaa.si, returns animeItem[] |\n| **advancedInfo** | Searches for advanced info that isn't on nyaa's rss feed, it has to query every page and scrape it so it might be slower |\n\n\n## Using\n\n#### searchNyaa()\n\n```javascript\nconst nyaa = require('nyaasiscrapper')\nvar search = nyaa.searchNyaa(searchOptions);\nsearch.then((results) => console.dir(results))\n```\n\n##### searchOptions\n\nEvery argument is optional, if you don't specify any you'll get the equivalent of the main page.\n\n| property | type | meaning |\n| ------ | :------: | ------ |\n| **term** | `string` | the term you want to search\n| **category** | `Nyaa's categories`, for more info go see the index.d.ts or the index.ts in github /src | A category of your choice\n| **filter** | `0,1,2` | No filter, no remake, trusted only\n| **user** | `string` | search a user's only torrents\n| **page** | `number` | an index of a page\n| **sortType** | go see the declaration too, also id == date | what you want to sort torrents by\n| **sortDirection** | `Ascending, Descending, desc, asc` | in what direction you want to sort torrents\n| **advanced** | `boolean` | when true it will search every page for more info so it will be slower\n\nAdvanced gets the description, the user, the files and the magnet, comments are a WIP.\n\n##### getAdvancedInfos()\n\nThis function takes a animeItem or an array of them and returns it with more advanced infos.\n\n##### animeItem\nanimeItem is the type of result you get using this module.\n\n| property | type | meaning \n| ------ | :------: | ------ |\n| **title** | `string` | Torrent title\n| **category** | `string` | category such as \"English translated\"\n| **categoryId** | `string` | categoryId: '0_0' is all for example\n| **downloadUrl** | `string` | Torrent file url\n| **size** | `string` | Size followed by unit\n| **date** | `Date` | Date format of upload time\n| **seeders** | `number` | Seeder amount\n| **leechers** | `number` | Leecher amount\n| **grabs** | `number` | Number of downloads\n| **nyaaUrl** | `string` | Url to nyaa page\n| **infoHash** | `string` | Infohash of torrent\n| **trusted** | `boolean` | Was the torrent uploaded by a trusted user?\n| **remake** | `boolean` | Is the torrent a reupload?\n| **description** [advanced] | `string` | Description available on the torrent page\n| **magnet** [advanced] | `string` | magnet link\n| **user** [advanced] | `string` | uploader\n| **files** [advanced] | `file[]` | array of files that have a title, size and emplacement property\n| **comments** [advanced] | `comment[]` | user, content, Date and edited boolean\n\n## TO DO\n\n* #### more tests\n* #### better error handling (pretty much non existent)"},"npm":{"downloads":[{"from":"2022-07-06T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":0},{"from":"2022-06-30T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":1},{"from":"2022-06-07T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":7},{"from":"2022-04-08T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":74},{"from":"2022-01-08T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":170},{"from":"2021-07-07T00:00:00.000Z","to":"2022-07-07T00:00:00.000Z","count":358}],"starsCount":0}},"evaluation":{"quality":{"carefulness":0.33,"tests":0,"health":0,"branding":0},"popularity":{"communityInterest":0,"downloadsCount":24.666666666666668,"downloadsAcceleration":-0.19596651445966512,"dependentsCount":0},"maintenance":{"releasesFrequency":0.28664383561643836,"commitsFrequency":0,"openIssues":0,"issuesDistribution":0}},"score":{"final":0.1789511405760489,"detail":{"quality":0.20086796360358883,"popularity":0.006269923110211879,"maintenance":0.3328465097325661}}}