Skip to main content
The admin panel lives in DualMind_Admin-UI and is served by the Cloudflare Worker admin-dualmind at admin.dualmindlab.tech. Admins use it to watch the arena, manage models, providers and keys, moderate comparisons, votes and threads, manage users and send email.
The panel is being rebuilt as a React app in DualMind_Admin-UI pull request #4. This page describes the panel as it is in that pull request. Until it merges, production runs the older static panel.

Stack

Pages

Admin routes above are relative to /api/admin. GET /api/health, GET /api/arena/model-stats and GET /api/settings/feature-flag/{key} are public routes at the API root. The full list, with request and response shapes, is in the admin API reference.

How it talks to the API

One API client handles every call: base URL serverUrl + /api/admin, the bearer token, JSON, a timeout per request and a single error type with codes network, timeout, unauthorized, forbidden, not_found, bad_request, server and api_error. PostgREST errors that the backend passes through as JSON strings are turned into readable messages.

Rules the panel follows

The backend’s PUT handlers write every field of the DTO, so a missing field becomes null. Edit forms load the record and send all fields back. The Playwright test asserts this.
Comparisons and votes return model and user IDs only. The panel loads models (up to 500) and users (up to 500) and maps IDs to names.
The key list returns display_mask; the panel fetches GET /keys/{keyId} for the rows on screen to show the full key, with a per-browser Show full keys switch to turn that off.
There are no admin routes for audit logs, exports, bulk actions, editing feature flags or filtering comparisons by date. The panel shows those as “not available yet” instead of faking them. POST for votes, threads and messages exists in the API but isn’t exposed, so admins can’t invent arena data.
The Email page calls the send-admin-email Edge Function with { emails, subject, title, html } and the admin’s token, and shows { sent, failed }. The HTML preview renders in a sandboxed iframe.

Run it locally

The full UI on fake data. Mock mode is only honoured on localhost, so it can’t be switched on in production.

Ship it

See Deploy and operate for the release checklist.
Last modified on October 18, 2026