We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
get_uuid()
1 parent 1a0b21f commit 8b96199Copy full SHA for 8b96199
api.py
@@ -9,6 +9,7 @@ def __init__(self, api_key: str):
9
self.api_key = api_key
10
11
def get_uuid(self, player_name: str) -> str:
12
+ """Fetches the UUID of a player based on their username."""
13
api_request = requests.get(f"https://api.mojang.com/users/profiles/minecraft/{player_name}")
14
content = parse(api_request.content)
15
return content["id"]
0 commit comments