1.1.7 • Published 3 years ago

minecraft-user v1.1.7

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
3 years ago

minecraft-user

Hello before continuing, join our support server on discord for the team to answer your questions.

How to get a user by the player's name or UUID:

const mine = require("minecraft-user");
const user = await mine.getUser("Minecraft nickname or minecraft uuid");

user.name: String
user.id: String
user.avatar: String <Link Image>
user.body: String <Link Image>
user.combo: String <Link Image>
user.head: String <Link Image>
user.skin: String <Link Image>

And to check if a user exists by name or uuid:

const hasUser = await mine.hasUser("Minecraft nickname or minecraft uuid");
if ( !hasUser ) console.log("Minecraft username or uuid is invalid.");
if ( hasUser ) console.log("Minecraft username or uuid is valid.");

Here are simple functions that can help you if you only want one thing from the player, and in the images instead of having a link you can choose to have an image, look below:

const userName = await mine.getUserName("Minecraft name or minecraft uuid");
const userUUID = await mine.getUserUUID("Minecraft name or minecraft uuid");

userName: String
userUUID: String

Here you will learn how to obtain an image link or simply an image:

// How to get a link image
const userAvatarLink = await mine.getUserAvatar("Minecraft name or minecraft uuid", { type: "link" });
const userBodyLink = await mine.getUserBody("Minecraft name or minecraft uuid", { type: "link" });
const userComboLink = await mine.getUserCombo("Minecraft name or minecraft uuid", { type: "link" });
const userHeadLink = await mine.getUserHead("Minecraft name or minecraft uuid", { type: "link" });
const userSkinLink = await mine.getUserSkin("Minecraft name or minecraft uuid", { type: "link" });

userAvatarLink: String <Link Image>
userBodyLink: String <Link Image>
userComboLink: String <Link Image>
userHeadLink: String <Link Image>
userSkinLink: String <Link Image>

// How to get a image
const userAvatarImage = await mine.getUserAvatar("Minecraft name or minecraft uuid", { type: "image" });
const userBodyImage = await mine.getUserBody("Minecraft name or minecraft uuid", { type: "image" });
const userComboImage = await mine.getUserCombo("Minecraft name or minecraft uuid", { type: "image" });
const userHeadImage = await mine.getUserHead("Minecraft name or minecraft uuid", { type: "image" });
const userSkinImage = await mine.getUserSkin("Minecraft name or minecraft uuid", { type: "image" });

userAvatarImage: Image
userBodyImage: Image
userComboImage: Image
userHeadImage: Image
userSkinImage: Image

We are planning more about updates, just wait and have good use!

1.1.1

3 years ago

1.1.0

3 years ago

1.0.9

3 years ago

1.1.7

3 years ago

1.1.6

3 years ago

1.1.5

3 years ago

1.1.4

3 years ago

1.1.3

3 years ago

1.1.2

3 years ago

1.0.8

3 years ago

2.0.0

3 years ago

1.0.5

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago