game-challenge API

Running on port 24535

Endpoints

MethodPathDescriptionAuth
GET/meCurrent user from Google ID tokenGoogle JWT
POST/scoresSubmit a score for a gameGoogle JWT
GET/scores/meCaller's score history (all games)Google JWT
GET/scores/me/:game_idCaller's history + personal best for a gameGoogle JWT
GET/scores/me/dailyCaller's daily-challenge history with precomputed rank/total per dayGoogle JWT
GET/leaderboard/:game_idTop N rows for a game (one row per user — their best)
GET/leaderboard/daily/:date/:game_idDaily-challenge leaderboard for a given local date
GET/gamesGame IDs and the metric keys this server accepts
GET/daily/todayToday's featured game (accepts ?tz=<IANA>)
GET/me/daily-subscriptionCaller's daily-email subscription stateGoogle JWT
POST/me/daily-subscriptionSubscribe / update timezone & send_hour_localGoogle JWT
DELETE/me/daily-subscriptionUnsubscribe (in-app)Google JWT
GET/unsubscribeOne-click unsubscribe from email linkstoken
POST/me/invite-friendEmail a daily-challenge invite to a friend (rate-limited 5/day)Google JWT
GET/no-invitesOne-click opt-out from invitation emailstoken

Games

wordlecrosswordhangmansudokumemoryanagramswordsearchboggleconnectionsbrickssnakeinvadersasteroidssquadrondefenderchomperchomper2stackercombine

Setup checks ✓

Database
Postgres reachable — 34 scores from 2 users
Google Client ID
Configured
Session JWT secret
30-day session JWTs enabled
CORS origins
http://localhost:5173, http://localhost:5174, http://localhost:5175, https://games.fjrois.com
Dev auth
disabled