Guides

Player Profiles

Learn how to fetch, utilize, and render player information inside your HTML5 games using the Boofer SDK.

Fetching Player Data

Use the Boofer.getPlayerInfo() method to retrieve details about the currently logged-in player.

const player = await Boofer.getPlayerInfo();
console.log("Player Handle:", player.displayName);
console.log("Player Level:", player.level);

Profile Fields Reference

FieldTypeDescription
userIdstringUnique player identifier.
displayNamestringThe player's username or nickname.
avatarUrlstringPublic URI to the user's profile image.
levelnumberThe player's global Boofer level.
highScorenumberThe player's personal high score for the game.