2.0.3 • Published 5 years ago

mojangjs v2.0.3

Weekly downloads
101
License
MIT
Repository
github
Last release
5 years ago

mojangjs

A lightweight, simple way to get UUIDs of usernames.

Usage

Of course after running npm install mojangjs the methods are simple.
All methods use Promise style callbacks as they are preferred.

Methods

getUUID(uuid) - Gets the UUID of the player.

mojangjs.getUUID('Thorin').then(uuid => {
    console.log(uuid);
}).catch(err => console.error(err));

nameHistory.byName(playername) - Gets the name history of a player.

mojangjs.nameHistory.byName('Thorin').then(nameHistory => {
	console.log(nameHistory);
}).catch(err => console.error(err));

nameHistory.byUUID(uuid) - Gets the name history of a UUID.

mojangjs.nameHistory.byUUID('5de3d1d51a954fb3a2b788e4938ae11c').then(nameHistory => {
	console.log(nameHistory);
}).catch(err => console.error(err));

statusCheck() - Gets the current status from Mojang.

mojangjs.statusCheck().then(status => {
	console.log(status);
}).catch(err => console.error(err));

getNameFromUUID(uuid) - Gets the current playername from a UUID.

mojangjs.getNameFromUUID(uuid).then(name => {
	console.log(name);
}).catch(err => console.error(err));
2.0.3

5 years ago

2.0.2

5 years ago

2.0.1

5 years ago

2.0.0

5 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago