Skip to content

Conversation

@khaliqgant
Copy link
Collaborator

No description provided.

khaliqgant and others added 8 commits January 6, 2026 15:12
1. billing.ts: Transform plans to frontend format with price: { monthly, yearly }
   instead of priceMonthly/priceYearly. Also converts cents to dollars.

2. App.tsx: Skip bridge data fetch in cloud mode to prevent 404 errors.
   The bridge endpoint only exists on the workspace daemon, not cloud server.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
When a user tries to create a workspace for a repo that already has a
workspace (and they have access via owner/member/contributor), return
the existing workspace instead of creating a duplicate.

- POST /api/workspaces/quick: Returns existing workspace with 200
- POST /api/workspaces: Returns 409 conflict with existing workspace info

This fixes the issue where multiple users with access to the same GitHub
repo would each create their own workspace instead of sharing one.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
The repositories table had workspace_id NULL for all records because
repos were never linked to workspaces during provisioning. This broke:
1. /api/workspaces/accessible contributor access (looks for workspaceId)
2. Duplicate workspace prevention (needs to find existing workspace for repo)

Now during workspace creation:
- Find existing repo records for the user and link them to workspace
- Create placeholder records with workspaceId for repos not yet imported

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add PATCH /api/workspaces/:id endpoint for workspace renaming
- Add GET /api/workspaces/:id/repos endpoint to list workspace repos
- Add DELETE /api/workspaces/:id/repos/:repoId to unlink repos
- Create WorkspaceSettingsPanel component for managing workspace
- Add useWorkspaceRepos hook for fetching workspace repositories
- Wire up App.tsx to show repos as project folders in multi-repo workspaces

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add WorkspaceSettingsPanel and useWorkspaceRepos imports
- Add state for workspace settings panel modal
- Update handleWorkspaceSettingsClick to open settings panel
- Convert workspaces to projects with multi-repo folder view
- Render WorkspaceSettingsPanel with refetch callbacks

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
Security cleanup: tokens are no longer stored centrally in the cloud DB.
CLI tools authenticate directly on workspace instances.

Changes:
- Remove vault directory (encrypted token storage was never used in production)
- Update credentials schema: drop accessToken, refreshToken, tokenExpiresAt columns
- Update drizzle queries: remove updateTokens method, simplify upsert
- Update provisioner: remove vault import and loadCredentialToken
- Update providers API: mark as connected without storing tokens
- Update onboarding API: validate tokens but don't store them
- Update daemons API: return connected providers info only
- Add migration 0010_remove_credential_tokens

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add WorkspaceSettingsPanel component render in App.tsx
- Add multi-repo folder view logic when workspace has multiple repos
- Each repo shows as a separate project folder in sidebar
- Panel opens from workspace settings button with refetch callbacks

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@khaliqgant khaliqgant merged commit 05c6534 into main Jan 6, 2026
8 checks passed
@khaliqgant khaliqgant deleted the feature/billing-bridge-fixes branch January 6, 2026 14:51
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.

2 participants