0.0.3 • Published 5 years ago

wynn.js v0.0.3

Weekly downloads
4
License
AGPL-3.0
Repository
github
Last release
5 years ago

Wynn.js

A wrapper library for the wynncraft api Currently does not cover all api endpoints

Example usage

Players

Get a specific player by username:

const wynn = require('wynn.js')

wynn.players.get('Hoi_A').then(player => {
  // returns object containing all player information as defined in the API Docs
}).catch(err => console.error(err))

Search for all players on wynncraft:

wynn.players.search('salte').then(results => {
  // returns array of usernames
}).catch(err => console.error(err))

Items

Listing items by category:

wynn.items.getCategoryItems('all').then(items => {
  // returns all items that belong to a category
}).catch(err => console.error(err))

let categories = wynn.items.getCategories() // Returns an array of possible categories
console.log(categories)

Search for an item by name:

wynn.items.search('harp').then(items => {
  // returns all items that have match the passed name
}).catch(err => console.error(err))
0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago