2024-04-21 04:47:52 +00:00
|
|
|
---
|
2024-04-22 19:07:53 +00:00
|
|
|
title: Player Username to UUID
|
2024-04-21 04:47:52 +00:00
|
|
|
summary: Get a player's UUID from their username.
|
|
|
|
---
|
|
|
|
|
2024-04-22 19:07:53 +00:00
|
|
|
# Overview
|
2024-04-21 04:47:52 +00:00
|
|
|
|
|
|
|
The player username to UUID endpoint allows you to get a player's UUID from their username.
|
|
|
|
|
|
|
|
## Endpoint
|
|
|
|
|
|
|
|
```
|
|
|
|
GET /player/uuid/:query
|
|
|
|
```
|
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
|
|
|
| Parameter | Description | Required |
|
|
|
|
|-----------|---------------------------------------------------------|----------|
|
|
|
|
| query | The username of the player you want to look up. | Yes |
|
|
|
|
|
|
|
|
## Example
|
|
|
|
|
|
|
|
```bash
|
|
|
|
curl -X GET "https://api.mcutils.xyz/player/uuid/imfascinated" -H "accept: application/json"
|
|
|
|
```
|
|
|
|
|
|
|
|
## Response
|
|
|
|
|
|
|
|
```json
|
|
|
|
{
|
|
|
|
"cache": {
|
|
|
|
"cached": false,
|
|
|
|
"cachedTime": -1
|
|
|
|
},
|
|
|
|
"uniqueId": "eeab5f8a-18dd-4d58-af78-2b3c4543da48",
|
|
|
|
"username": "ImFascinated"
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## Errors
|
|
|
|
|
|
|
|
| Status Code | Description |
|
|
|
|
|-------------|-----------------------------------------------|
|
|
|
|
| 400 | The username is invalid. |
|
|
|
|
| 429 | The Mojang API rate limit has been exhausted. |
|