Skip to content

feat(#567): admin UI for channel API keys - #608

Open
sneumannb5 wants to merge 2 commits into
byte5ai:mainfrom
sneumannb5:feat/567-admin-ui-for-channel-api-keys
Open

feat(#567): admin UI for channel API keys#608
sneumannb5 wants to merge 2 commits into
byte5ai:mainfrom
sneumannb5:feat/567-admin-ui-for-channel-api-keys

Conversation

@sneumannb5

@sneumannb5 sneumannb5 commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

What

Adds /admin/api-keys (create/list/revoke) for the channel API keys exposed by createAdminKeysRouter, which shipped in #438/#439 with no web-ui page. Closes #567 (follow-through from #550).

Why

Keys could only be minted via curl, and a public MCP key-binding (#550) is keyed on ApiKeyRecord.id - so an operator had to read that id out of the API by hand. Each key row now shows the id verbatim with a one-click copy, plus a reveal-once token, a scopes:[] guard, and a two-step revoke.

Test plan

  • npm run typecheck in web-ui
  • npx eslint app/admin/api-keys app/_lib/api.ts app/admin/page.tsx
  • npx vitest run app/admin/api-keys - 15/15 pass (incl. copy-id flow + 2 concurrency regression guards)
  • npm run i18n:check - en/de parity, 3379 keys
  • manual: create key → copy id → paste into an MCP binding; revoke → confirm row flips to Revoked

Risk / blast radius

Frontend only — the channel-api router is unchanged (no schema, no public API, no env-var). Auth inherits the existing /api operator-session gate. No rotate path by design (revoke + replace).

Naming-decisions still pending


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Admin UI for channel API keys (#438/#439 follow-through)

2 participants