Revert "Implement admin back-pass flow and guarded admin actions"
This reverts commit 5595bfd3b1.
This commit is contained in:
10
API.md
10
API.md
@@ -14,7 +14,7 @@ GET /api/me — id, displayName, username, isAdmin, currentPhase, votesFinal
|
||||
|
||||
## Player (requires auth)
|
||||
POST /api/me/phase/next — advance caller to next phase (Suggest→Vote requires at least one own suggestion; Vote→Results is gated by resultsOpen)
|
||||
POST /api/me/phase/prev — move caller backward (admin: Results→Vote→Suggest, player: Vote→Suggest only when granted a one-time back pass)
|
||||
POST /api/me/phase/prev — admin-only move caller backward (Results→Vote→Suggest)
|
||||
|
||||
## Suggestions (requires auth + phase gating)
|
||||
GET /api/suggestions/mine — own suggestions (Suggest phase)
|
||||
@@ -32,11 +32,9 @@ POST /api/votes/finalize — `{ final: bool }` toggles caller’s finalized stat
|
||||
GET /api/results — leaderboard with totals, counts, averages, caller’s vote, media/links, link metadata
|
||||
|
||||
## Admin (requires authenticated admin user)
|
||||
POST /api/admin/results — `{ resultsOpen: bool }` locks/unlocks results and aligns player phases (closing results moves players with suggestions to `Vote`, players without suggestions to `Suggest`)
|
||||
POST /api/admin/results — `{ resultsOpen: bool }` locks/unlocks results and aligns player phases
|
||||
GET /api/admin/vote-status — readiness overview (who finalized)
|
||||
POST /api/admin/players/{playerId}/phase — `{ phase: "Suggest" }`; move a player from `Vote` back to `Suggest`
|
||||
DELETE /api/admin/players/{playerId} — `{ adminPassword: string }`; delete a player and all related data
|
||||
POST /api/admin/link-suggestions — `{ sourceSuggestionId, targetSuggestionId }`; merges vote groups during Vote, clears votes in the linked group, unfinalizes **all** players
|
||||
POST /api/admin/unlink-suggestions — `{ suggestionId }`; breaks links, clears votes for that group, unfinalizes **all** players
|
||||
POST /api/admin/reset — `{ adminPassword: string }`; clear suggestions/votes; keep players; reset phases/vote-final flags
|
||||
POST /api/admin/factory-reset — `{ adminPassword: string }`; wipe players, suggestions, votes, state
|
||||
POST /api/admin/reset — clear suggestions/votes; keep players; reset phases/vote-final flags
|
||||
POST /api/admin/factory-reset — wipe players, suggestions, votes, state
|
||||
|
||||
Reference in New Issue
Block a user