Skip to content

Restore Cloudflare admin workspace controls - #2022

Open
baggiiiie wants to merge 1 commit into
UsefulSoftwareCo:mainfrom
baggiiiie:fix/cloudflare-admin-workspace-controls
Open

baggiiiie wants to merge 1 commit into
UsefulSoftwareCo:mainfrom
baggiiiie:fix/cloudflare-admin-workspace-controls

Conversation

@baggiiiie

@baggiiiie baggiiiie commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

Summary

when hosted on cloudflare, admins are configured through ADMIN_EMAILS, which are authorized server-side. but the console gets an empty member list and treats admins as members, hiding Workspace option

this change returns the Access principal from /account/members with its role, so the console recognizes admins while Cloudflare Access remains authoritative for membership and writes.

before

Cloudflare Access admin cannot choose Workspace or manage workspace connections

after

Cloudflare Access admin can choose Workspace and manage workspace connections

Linked issue

Fixes #1958

Verification

  • bun run format:check
  • bun run lint
  • bun run typecheck
  • TURBO_TEST_CONCURRENCY=2 bun run test — 39/39 tasks passed
  • e2e — Cloudflare · an Access admin can choose Workspace for a connectionrecording

Checklist

  • Added a changeset (bun run changeset), or this change needs none.
  • Added or updated tests for the new behaviour.
  • No secrets, credentials, or private data in the diff.

…dmins

The console derives the current user's role from /account/members, not
/account/me (which carries no role). The Cloudflare provider hardcoded an
empty member list, so an ADMIN_EMAILS admin was never recognized client-side
and every workspace action (Workspace owner option, Edit/Reconnect/Remove on
org connections) was hidden even though the server authorized the writes.
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.

[bug] host-cloudflare: AccountProvider.me omits orgRole, so the console hides every workspace mutation from admins

1 participant