Skip to content

Add Team & access screens and workspace creation to the dashboard - #680

Merged
kanishkmorey merged 1 commit into
stagefrom
P0097-clean
Nov 12, 2026
Merged

kanishkmorey merged 1 commit into
stagefrom
P0097-clean

Conversation

@kanishkmorey

Copy link
Copy Markdown
Collaborator

Summary

Operator-side backend APIs that had no dashboard UI now have screens:

  • Team & access (/app/team, new sidebar item):
    • Members: list/search (GET /users), invite by email and role (POST /invite), change role (PUT /updateUserRole). Declined or expired invitations can be re-sent. A member cannot change their own role from the UI.
    • Roles: read-only permission matrix from GET /rolePermissions.
    • API keys: list, create, rename, change role, activate/deactivate, delete (/authentications). Secrets are masked until revealed; deactivate and delete ask for confirmation.
  • Create workspace: new entry in the sidebar workspace switcher calling POST /clients. The API switches the session into the new workspace, so the panel reloads as it does after a switch. The switcher previously opened only with two or more workspaces, so single-workspace users had no way to create one.

Every screen has distinct loading, empty, failed (with Retry) and access-denied states. Server authorization remains authoritative.

Intentionally not included: permission-aware hiding of controls (GET /getUserPermissions), IP access rules (/userIps), accepting/rejecting pending invitations, workspace rename/log-storage settings.

Deployment impact

None identified: no new environment variables or secrets, no backend change, no change to authentication/session behaviour, no migrations. Note for reviewers: the API returns full API-key secrets to anyone with the view_authkeys permission (all four roles); the UI masks them by default but cannot change that backend behaviour.

Branch note

Branched from production (per repo workflow, already at the latest origin/production) and targeted at stage as requested. It merges cleanly into current origin/stage.

Verification

  • ngc -p apps/36-blocks/tsconfig.app.json --noEmit: clean (template checking confirmed with a deliberate error).
  • npm run review:build: succeeded. The synthetic-data review build was driven in headless Chrome: desktop and 390px mobile render with no console errors or horizontal overflow; invite, change-role, API-key and create-workspace dialogs showed validation.
  • node --test tools/tests/*.test.cjs: 44 passed (14 new in tools/tests/team-access.test.cjs). Prettier and git diff --check clean.
  • Not verified: any real API call (the checked-in config points at a remote test API and no mutations were run there), invitation email delivery, role-change effects, authentication with a newly created key, per-role 403 states.

🤖 Generated with Claude Code

Operator-side APIs that had no UI now have screens:
- /app/team: Members (list, invite, change role, re-send expired or
  declined invitations), Roles (read-only permission matrix) and API keys
  (list, create, rename, change role, activate/deactivate, delete; secret
  masked until revealed).
- Create workspace entry in the sidebar workspace switcher (POST /clients).
  The switcher previously opened only with two or more workspaces.

Review-mode fixtures and focused node tests are included. No backend,
environment-variable or authentication-behaviour changes.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@kanishkmorey
kanishkmorey merged commit 17954ff into stage Nov 12, 2026
1 check passed
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.

1 participant