Skip to content

Add workspace-scoped mail and team management#30

Open
oathis wants to merge 1 commit into
caley-io:mainfrom
oathis:bounty-1-workspaces-mail-scoping
Open

Add workspace-scoped mail and team management#30
oathis wants to merge 1 commit into
caley-io:mainfrom
oathis:bounty-1-workspaces-mail-scoping

Conversation

@oathis
Copy link
Copy Markdown

@oathis oathis commented May 31, 2026

/claim #1

Summary

  • Create/repair a personal workspace for signed-in users and wire /api/workspaces to list, create, and update persisted workspaces.
  • Add workspace member invite, accept, role update, and removal APIs backed by the existing Organization, Membership, and EmailAccount models.
  • Add workspace email account APIs and store Gmail OAuth material on workspace email accounts so workspace-scoped mail requests can use the selected account's Gmail client.
  • Replace the hardcoded workspace rail in /mail with real workspaces, account selection, creation, and workspace management UI.
  • Send email invitations with an accept link; invited users are only attached after accepting, and their current Google account is added to the workspace on accept.

Notes

This uses the existing Prisma workspace models rather than introducing new tables. It also keeps newly created workspaces usable immediately by adding the creator's current Google account as an email account.

Verification

  • corepack pnpm --filter inbox-zero-ai exec prisma generate --schema=prisma/schema.prisma
  • corepack pnpm --filter inbox-zero-ai exec tsc --noEmit
  • corepack pnpm --filter @inboxzero/resend exec tsc --noEmit
  • corepack pnpm --filter inbox-zero-ai lint with required env vars set to local dummy values
  • git diff --check

Lint passes with existing warnings in unrelated files:

  • components/CommandK.tsx
  • components/mail/components/mail-list.tsx
  • components/ui/single-image-dropzone.tsx

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