mcapi
Version:
An unofficial Node.js library for fetching data from Mojang
13 lines (11 loc) • 357 B
JavaScript
const mcapi = require("./index.js");
const username = "Deftware";
mcapi.usernameToUUID(username).then((uuid) => {
return mcapi.uuidToUsername(uuid);
}).then((name) => {
if (username === name) {
console.log("API is working");
} else {
console.log("API seems to not work (Throttled?)");
}
}).catch(console.error);