0.1.2 • Published 8 years ago
hiveapi v0.1.2
node-hiveapi
Please note I'm not really a player of The Hive or Minecraft at all, I was interested in doing this project because I thought it could be helpful
A simple API wrapper for The Hive API
Installation
npm install hiveapi
Usage
var HiveAPI = require('hiveapi');
var api = new HiveAPI();
The first available function is getPlayer()
, it returns a JSON object in body
api.getPlayer('uuid', function(error, body) {
console.log(body);
// You can access any property of the JSON API
console.log(body.username);
console.log(body.tokens);
});
getServerPlayerCount()
will also return the current player count of the server
api.getServerPlayerCount(function(error, body) {
console.log(body.count);
});