Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

node-papermc

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-papermc - npm Package Compare versions

Comparing version 0.1.0 to 1.0.0

LICENSE

23

package.json
{
"name": "node-papermc",
"version": "0.1.0",
"version": "1.0.0",
"description": "PaperMC API",
"main": "src/index.js",
"directories": {
"test": "test"
},
"main": "dist/index.js",
"types": "dist/index.d.ts",
"scripts": {
"test": "node ./tests/test.js"
"test:js": "node tests/test.js",
"test:ts": "ts-node tests/test.ts",
"build": "tsc",
"prepublish": "tsc"
},

@@ -19,3 +20,11 @@ "keywords": [

"node-fetch": "^2.6.1"
}
},
"devDependencies": {
"@types/node-fetch": "^2.5.8",
"ts-node": "^9.1.1",
"typescript": "^4.1.3"
},
"files": [
"dist/**/*"
]
}
# node-papermc
## functions
### BASE_URL: string
Base URL of rest api
### projects
Get Projects
### getProject(project: string)
### getProjectInfo(project: string): Promise\<PaperProjectInfos>
Get project id, project name, version groups, versions
### getVersion(project: string, version: string)
### getVersionInfo(project: string, version: string) Promise\<PaperVersionInfos>
Get project id, project name, version, builds
### getVersions(project: string, version: string)
### getVersionGroupInfo(project: string, version_group: string): Promise\<PaperVersionGroupInfos>
Get project id, project name, version group, versions
### getBuilds(project: string, version: string)
### getVersionGroupBuilds(project: string, version_group: string): Promise\<PaperVersionGroupBuilds>
Get project id, project name, version group, versions, builds
### getBuild(project: string, version: string, build: number)
### getBuildInfo(project: string, version: string, build: number): Promise\<PaperBuildInfos>
Get project id, project name, build, time, changes, downloads
## example
```javascript
const papermc = require('node-papermc');
const papermc = new node()
Promise.all([
api.project,
api.getProject('paper'),
api.getVersion('paper', '1.16.4'),
api.getVersions('paper', '1.16'),
api.getBuilds('paper', '1.16'),
api.getBuild('paper', '1.16.4', 256),
]).then(console.log)
```
### download(project: string, version: string, build: number, name: string): Promise\<Blob>
Get build file blob
## examples
[<image src="https://upload.wikimedia.org/wikipedia/commons/thumb/9/99/Unofficial_JavaScript_logo_2.svg/1024px-Unofficial_JavaScript_logo_2.svg.png" width="20"> javascript example](tests/test.js)
[<image src="https://upload.wikimedia.org/wikipedia/commons/thumb/4/4c/Typescript_logo_2020.svg/1200px-Typescript_logo_2020.svg.png" width="20"> typescript example](tests/test.js)
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc