modl.gg

Get Player by Name

Look up a player by their Minecraft username (case-insensitive).

GET /v1/minecraft/players/by-name

Look up a player by their Minecraft username. The search is case-insensitive and matches against the player's full username history.

Authentication

Requires the X-API-Key header with your server's API key.

X-API-Key: your-api-key-here

Request

Headers

HeaderTypeRequiredDescription
X-API-KeystringYesYour server's API key.

Query Parameters

ParameterTypeRequiredDescription
usernamestringYesThe player's Minecraft username (case-insensitive).

Example

GET /v1/minecraft/players/by-name?username=Notch

Response

200 OK

{
  "status": 200,
  "message": "Player found",
  "player": {
    "_id": "65a1b2c3d4e5f6a7b8c9d0e1",
    "minecraftUuid": "550e8400-e29b-41d4-a716-446655440000",
    "usernames": [
      {
        "username": "Notch",
        "date": "2024-01-15T10:30:00.000Z"
      }
    ],
    "notes": [],
    "ipList": [],
    "punishments": [],
    "pendingNotifications": []
  }
}

Error Responses

Status CodeDescription
401Missing or invalid API key.
404Player not found for the given username.
429Rate limit exceeded.
500Internal server error.

On this page