[RQ-4695 / RQ-4696 / RQ-4699] Deprecate legacy API Client: onboarding cleanup, hide local workspaces, block sending#81
Open
Kanishkrawatt wants to merge 8 commits into
Conversation
… creation
The API Client is now a separate standalone product, but the Interceptor
app still surfaced it in onboarding and workspace creation, funneling
users into creating local workspaces (which only ever held API Client
files). Per epic RQ-4191, remove all API Client touchpoints from these
flows so onboarding offers only Interceptor:
- DesktopOnboardingModal / WelcomeCard: remove the "Start using API
Client" welcome card (expandable local-workspace create/open options)
and the FOLDER_SELECTION local-workspace-creation step it fed into;
drop the now-unused WorkspaceCreationProvider wrapper and the hooks
(useCreateDefaultLocalWorkspace / useOpenLocalWorkspace /
LocalWorkspaceCreateOptions / redirectToApiClient). "Skip" now simply
completes onboarding instead of creating a local API Client workspace
and redirecting to the API Client. Drop FOLDER_SELECTION from the
OnboardingStep enum.
- CreateWorkspaceModalOld: remove the entire "Local workspace" option
("only API client files are supported") and its dead local-workspace
creation code — the modal now creates team workspaces only.
- personaRecommendationData: remove the dead "Test API endpoints ->
API Client" recommendation entry.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Follow-up to the onboarding/workspace-creation removal: strip every user-reachable API Client entry point from the Interceptor app so the product is fully inaccessible/invisible. The shared infrastructure that happens to live under features/apiClient/ (workspace system, tab system, variable/secrets slices, environment backend) is left in place — other features depend on it — but nothing routes to or surfaces the API Client product anymore. Removed: - Route: apiClientRoutes registration in routes/index.tsx. - Primary sidebar "APIs" item (+ SidebarItemKey.APIs, icon, order entries). - Home page ApiClientCard (component deleted) + its render. - "API Client" breadcrumb label; PATHS.API_CLIENT.INDEX from the root-path landing set (useRootPathRedirector). - Network inspector "Edit and Replay" context-menu item and its APIClientModal replay chain (ContextMenu -> VirtualTableV2 -> NetworkTable). - Mock editor "Test" button and its APIClientModal test-mock chain. - Session viewer "Replay Request" context-menu item and its APIClientModal chain. - cURL-import deep link (AppModeInitializer OPEN_CURL_IMPORT_MODAL listener that navigated to the API Client). Orphaned imports/vars from the above cleaned up. Verified: ESLint clean on changed files (one pre-existing exhaustive-deps warning), `tsc --noEmit` introduces zero new errors (net -9 vs the repo's 1298 baseline), and `vite build` succeeds. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The desktop first-run onboarding still opened on a feature-selection screen (WelcomeCard) that framed a choice between the API Client and Rules and funnelled users into local-workspace creation. The API Client is now a standalone product, so that screen is obsolete. - Remove the FEATURE_SELECTION step / WelcomeCard (and WelcomeCardHeader) in full; drop FEATURE_SELECTION from the OnboardingStep enum. The step machine now initializes — and stays — at AUTH, so first-run users land directly on the sign-in/sign-up card. - AuthCard: remove the back-arrow (onBackClick) — there is no prior step to return to. No path creates a local workspace or redirects to the API Client during onboarding. Extension/web onboarding (OnboardingModal) is untouched. Verified: ESLint clean on changed files; `tsc --noEmit` net 0 new errors (1289 baseline unchanged); `vite build` succeeds. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
WorkspaceType.LOCAL workspaces existed only to back the API Client, which is being removed. Hide them from every user-facing surface. This is UI-hiding only — on-disk workspace folders are NOT deleted, and LOCAL_STORAGE (logged-out) behavior is unchanged. - Central lever (useWorkspaceFetcher): stop fetching/injecting local workspaces into `allWorkspaces`; only shared (team) workspaces flow in now. Everything that reads `allWorkspaces` (dropdown/overlay/settings) therefore surfaces no LOCAL entry. - WorkspacesOverlay: remove the "Local workspaces" list section entirely (list rows, "Add", the empty-state section and its "New/Create local workspace" CTA) and the local-sync gating; drop the now-dead hasLocalWorkspaces / isLocalSyncEnabled state. Only the shared section and the common empty view remain. This also closes the MULTI (multi-workspace) view — its only UI entry was the LOCAL row checkboxes. - CommonEmptyView: remove the desktop-only "New local workspace" button and the local mention from the description (team-only now). - WorkspaceDropdown: remove the active-local avatar special-casing (use the generic WorkspaceAvatar for all single-view workspaces) and the "Load latest changes from your local files" refresh button. Per the ticket's decision, a user currently active in a LOCAL workspace is not force-switched or errored — they simply have no LOCAL entries to switch back to (one-way door). Migration segment strings are unchanged. Verified: ESLint clean on changed files; `tsc --noEmit` net 0 new errors (1289 baseline unchanged); `vite build` succeeds. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This PR is being narrowed to exactly the three linked stories (RQ-4695, RQ-4696, RQ-4699). RQ-4699 keeps the legacy API Client mounted but blocks request execution behind a mandatory migration modal — a strategy that is mutually exclusive with RQ-4283's wholesale removal (the modal only mounts inside the API Client container and makeRequest is only reachable from the Send UI, both of which the route/product-surface removal deleted). Revert the app-wide product-surface removal so the API Client is reachable again and RQ-4699 can gate it: - routes/index.tsx apiClientRoutes registration - PrimarySidebar "APIs" item - Home ApiClientCard (+ component files) - RQBreadcrumb "API Client" label - useRootPathRedirector root-path landing entry - NetworkInspector "Edit and Replay", MockEditor "Test", SessionViewer "Replay Request" (APIClientModal chains) - AppModeInitializer cURL-import deep link - personaRecommendationData "Test API endpoints -> API Client" entry The onboarding (RQ-4695) and CreateWorkspaceModalOld local-option (RQ-4696) changes from the original RQ-4283 commits are retained — they belong to the two sibling stories. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…on modal The migration block was a modal overlaid on a fully-live client — it never gated the request engine, so Send/Cmd+Enter kept firing requests. Add a real, unconditional stop and make the comms mandatory. Web + desktop legacy client (the client stays mounted; only sending is blocked). The block (single choke point): - makeRequest() (apiClient/screens/apiClient/utils.ts) is the universal exit for all six outbound paths — HTTP send, GraphQL send, response-panel Retry, Collection Runner, GraphQL introspection, WSDL/SOAP import fetch. Guard it before dispatching to extension/proxy: if the migration block is on, reject with a typed MigrationBlockedError. One edit = full coverage (per the ticket's DECISION: guard makeRequest for a full stop). - Read block state from the GrowthBook singleton (growthbook.isOn), not a hook — makeRequest is not a React context. isOn returns a boolean even before features load, so the guard can't itself throw. Same MIGRATION_BLOCK_FLAG the container uses to mount the modal, so block + modal engage together. The comms (mandatory modal, MigrationBlockModal.tsx): - Force dismissable = false → drives every variant's Modal closable/keyboard/maskClosable/onCancel, so the modal is non-dismissable. - Drop the three per-segment early-returns so the modal shows for all segments (local-storage / auto-cloud / auto-local-fs) whenever the master kill-switch is on; remove the now-unused per-segment variant flags. - Workspace-loading guards are retained — irrelevant to the block since the engine is stopped in makeRequest regardless of modal render timing. Verified: ESLint clean on changed files; `tsc --noEmit` adds zero new errors (utils.ts holds the same 10 pre-existing errors with and without the guard; MigrationBlockModal + MigrationBlockedError are error-free). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…tions Drop the "Test API endpoints -> API Client" recommendation entry (and the now-unused ApiOutlined import). Last remaining API Client touchpoint in the legacy onboarding surface; the recommendations grid is itself unreferenced (dead code), so no behavior change. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Widen the home-screen primary cards (325px -> 588px) so they fill the content width. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Kanishkrawatt
marked this pull request as ready for review
July 20, 2026 14:10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Part of epic RQ-4191 — wind down the legacy API Client in the Interceptor app and stop funnelling users into it. Bundles four tickets. Net: 17 files, +101 / −583 (mostly deletions).
Changes by ticket
RQ-4695 — Desktop onboarding → straight to auth
WelcomeCard.tsx(the "Start using API Client" + "Intercept and Modify Web Traffic" chooser) +WelcomeCardHeader.tsx,welcomeCard.scss,welcomeCardHeader.scssDesktopOnboardingModal.tsx— removed theFEATURE_SELECTIONandFOLDER_SELECTIONsteps and the "Skip → create local workspace" funnel; init at theAUTHstepAuthCard.tsx— minor adjustments for landing here directlytypes.ts— droppedFOLDER_SELECTIONfromOnboardingStepRQ-4696 — Hide local (file-system) workspaces (UI-only, non-destructive)
useWorkspaceFetcher.ts— stop injecting local workspaces (central lever)WorkspaceDropdown.tsx— remove local-workspace section, active-local avatar, "load latest from local files" refreshWorkspacesOverlay.tsx— remove the "Local workspaces" sectionCommonEmptyView.tsx— remove the "New local workspace" empty-state CTALOCAL_STORAGE/logged-out behaviour unchanged; no on-disk data deletedRQ-4283 — Remove API Client from onboarding + workspace creation
CreateWorkspaceModalOld.tsx— removed the "Local workspace — only API client files" option + its dead local-workspace-creation code (team workspaces only)personaRecommendationData.tsx— removed the dead "Test API endpoints → API Client" recommendation entryRQ-4699 — Block API Client sending + mandatory migration modal
apiClient/screens/apiClient/utils.ts— guardmakeRequest()(the universal outbound choke point) so every send rejects with a typed errorMigrationBlockedError.ts(new) — the typed "API Client has moved" errorMigrationBlockModal.tsx— made mandatory (non-dismissable, all segments)Misc
home.scss— enlarge the home-screen primary feature cardsReviewer notes
ONBOARDING_V2(desktop ≥ 26.2.4) path (DesktopOnboardingModal). Older desktops (< 26.2.4) fall to the untouchedOnboardingModal(the "Skip for now" + social-proof auth screen); verify both.api_client_request_sent → 0is necessary but not sufficient (runner/introspection don't emit it) — confirm at the network level across HTTP send, GraphQL send, Retry, Collection Runner, introspection, WSDL import.🤖 Generated with Claude Code