REST API: players and profiles
GET /me
The authenticated player, entitlement and membership summary.
{
"ok": true,
"data": {
"player": {
"id": 42, "username": "ada", "display_name": "Ada", "avatar_url": "https://allgameclub.com/media/avatars/42-ab12cd.png",
"bio": null, "country": "DE", "member_since": "2026-10-01 09:12:00",
"email": "ada@example.com", "email_verified": true, "role": "player", "newsletter": false
},
"entitlement": { "unlimited": false, "allowance_seconds": 900, "used_seconds": 120, "remaining_seconds": 780, "limit_reached": false, "resets_in_seconds": 41234, "day": "2026-10-11" },
"membership": { "unlimited": false, "plan": "free", "status": "none", "renews_at": null, "ends_at": null }
}
}
PATCH /me
Update profile fields. All optional.
| Field | Rules |
|---|---|
display_name | 2–40 characters |
username | 3–32, letters, digits, underscore; must be unique (409 username_taken) |
bio | up to 300 characters, empty string clears |
country | ISO 3166-1 alpha-2 |
newsletter | boolean |
POST /me/avatar
multipart/form-data with field avatar (JPG, PNG, GIF, WebP, ≤ 2 MB). The image is cropped square and resized to 256 px. Returns { avatar_url }. DELETE /me/avatar removes it (a generated initials avatar is used instead).
GET /me/entitlement
Today's allowance; see play sessions.
GET /me/playtime?days=14
{ "today": { … }, "total_seconds": 48120, "history": [{ "day": "2026-10-11", "seconds": 900, "sessions": 2 }, …] }
GET /me/scores
Best score per game plus the 20 most recent submissions.
Tokens
GET /me/tokenslists the player's tokens (prefix only).POST /me/tokens{ name }creates one (201, token shown once).DELETE /me/tokens/{id}revokes.
GET /players/{username}
Public profile of any active player. No authentication required.
{ "player": { "id": 42, "username": "ada", "display_name": "Ada", "avatar_url": "…", "bio": null, "country": "DE", "member_since": "…" },
"unlimited": true,
"best_scores": [{ "game": "target-rush", "game_name": "Target Rush", "best": 4210, "unit": "points" }] } Last updated October 11, 2026.